Giter VIP home page Giter VIP logo

Comments (10)

martijnmnnk avatar martijnmnnk commented on July 20, 2024

Already found the token by using the Xcode tool PacketLogger with my iPhone by following these instructions [ https://www.bluetooth.com/blog/a-new-way-to-debug-iosbluetooth-applications/ ].

Screenshot 2021-04-22 at 08 17 16

Also by using PacketLogger, I exported the log snoop.log an run the hexdump command, resulting:
$ hexdump -v -e '/1 "%02X "' snoop.log | grep -o '0B 00 04 00 12 14 00 <.. .. .. .. .. .. .. ..>'
0B 00 04 00 12 14 00 82 FA EC C7 DF F8 C4 2E

This is the same key as extracted from the nespresso_app_fusion.db by using my rooted Android phone, which means that there is some other problem as the machine disconnects immediately after connecting.

Config:
"platforms": [ "machines": [ { "name": "Expert&Milk_ED4BBFE387C8", "token": "82-FA-EC-C7-DF-F8-C4-2E", "temperature": "Medium" } ], "platform": "Brewer" } ]

Log:
[22/04/2021, 08:14:49] [Brewer] Initializing Brewer platform... [22/04/2021, 08:14:49] [Brewer] Loading accessory from cache: Expert&Milk_ED4BBFE387C8 [22/04/2021, 08:14:49] [Brewer] Restoring existing accessory from cache: Expert&Milk_ED4BBFE387C8 [22/04/2021, 08:14:49] Homebridge v1.3.4 (Homebride Expert) is running on port 51050. [22/04/2021, 08:17:21] [Brewer] Start scan... [22/04/2021, 08:17:23] [Brewer] Connected to Expert&Milk_ED4BBFE387C8 [22/04/2021, 08:17:26] [Brewer] Machine disconnected [22/04/2021, 08:17:35] [Brewer] Start scan... [22/04/2021, 08:17:36] [Brewer] Connected to Expert&Milk_ED4BBFE387C8 [22/04/2021, 08:17:36] [Brewer] Machine disconnected [22/04/2021, 08:19:24] [Brewer] Start scan... [22/04/2021, 08:19:25] [Brewer] Connected to Expert&Milk_ED4BBFE387C8 [22/04/2021, 08:21:25] [Brewer] Machine disconnected

Did I miss something? Any suggestions on how to get the plugin working with my machine?

from homebridge-brewer.

tritter avatar tritter commented on July 20, 2024

Hi @martijnmnnk,

Sorry didn't see the email of this issue at first. Could you try to run home bridge on another device? I experienced Problems with some Raspberry's Zero. I plan to improve the connection disconnection logic in a further update.
Could you also please attach the logs with DEBUG enabled inside the Homebridge settings? "To run Homebridge in full debug mode run the following command DEBUG=* homebridge -D." (https://github.com/homebridge/homebridge/wiki/Basic-Troubleshooting). Your research is perfect, I can't see issues there.

from homebridge-brewer.

martijnmnnk avatar martijnmnnk commented on July 20, 2024

Hey @tritter thanks for your response. I've run homebridge in debug mode but honestly the log does not make any sense to me. I've uploaded the logfile here [ homebridge-log.txt ], maybe you can see what's wrong? I've tried running the plugin on a RasPi 4 Model B Rev 1.1 and based on your suggestion I've installed the plugin on a RasPi 3 Model B Rev 1.2, and also tried running that Homebridge instance as root but to no avail.

from homebridge-brewer.

tritter avatar tritter commented on July 20, 2024

@martijnmnnk Thanks a lot, everything looks pretty good to me. It looks like the machine is rejecting the connection. Could you try to remove the device and re-add it again. (I just tried to change my token and it still worked with a wrong token). So it seems like homebridge or I may cache the token inside the homekit device between restarts.
Could you try:

  1. Remove device inside the config.json
  2. Restart home bridge
  3. (You should see in the log discovered device, and the device should be gone from your Home.app)
  4. Add the device again inside the config.json
  5. Restart again
  6. Should work? 🤞

Also make sure you're not connected with the app at the same time.

from homebridge-brewer.

martijnmnnk avatar martijnmnnk commented on July 20, 2024

Thanks for the suggestions and your help. I followed your instructions and removed the machine from config.json, restarted homebridge and added the machine again.. no succes :(

In addition I also tried factory resetting the machine and retrieving a new token with PacketLogger, closed the app and switched off bluetooth on my iPhone, and created a new homebridge instance with the new machine config.. unfortunately this also does not work.

I'm wondering which firmware version you are using. According to the app my machine is using firmware 6.0 and connectivity firmware 1.27. Is your machine maybe running on a different version?

from homebridge-brewer.

tritter avatar tritter commented on July 20, 2024

@martijnmnnk Thanks a lot for all the tests! I started the plugin using this website in Chrome: https://github.com/petergullberg/brewbutton/blob/master/brewbutton.html That will also probably not work for you!?

And I have firmware 6.0! Maybe that's the issue. Can you download the brewbutton.html open it in Chrome what works for you??

Maybe there is a new notify bluetooth characteristic which is only supported in 6.1. Unfortunately I only have one machine.

from homebridge-brewer.

martijnmnnk avatar martijnmnnk commented on July 20, 2024

My machine is on firmware 6.0 as well. I've tried the page brewbutton.html in Chrome but this also does not seem to work. I am sure the token is correct, but I can't figure out what I'm missing :(
Screenshot 2021-05-05 at 22 12 37

from homebridge-brewer.

tritter avatar tritter commented on July 20, 2024

You first need to press: Connect, then Status then Brew! Mine shows this. Yours should at least connect though. Did you get the connect dialog in Chrome? It doesn't even seem to write the Auth..

Screenshot 2021-05-05 at 22 25 42

from homebridge-brewer.

martijnmnnk avatar martijnmnnk commented on July 20, 2024

Goog news! Its finally working! The plugin is connecting with the machine and I can brew a coffee with the Home app.

I have some other bluetooth devices connected to the pi, some of them quite far away (10+ meters). However, the Nespresso machine needs a very strong connection. My machine is located roughly 4 meters from the Raspberry pi with a thin wall in between. When placing the machine next to the Raspberry Pi brewing a coffee is working without any issues.

I'm feeling a bit stupid that I did not try this before... Big thank you for your patience and help, and an even bigger thank you for creating the plugin. I'll buy you a coffee, you deserved it!

from homebridge-brewer.

tritter avatar tritter commented on July 20, 2024

Amazing! Thanks a lot, yes that was also a suggestion I wanted to make but I thought your probably did that ;-) I will add it to the README, as the Bluetooth-Chip isn't the strongest one in the raspberry. I think they wanted to make sure you're standing next to it...

No problem! I'm happy to help. PS. There's still many things I would like to add and improve. This was just my initial throw to schedule my coffee every morning :) If you have any ideas feel free to put them in the round here are also some: #1

Thanks a ton for the coffee 🙏🥳, just ordered some cups 💯 👍 If you have any issues, never feel stupid always feel free to ask!

from homebridge-brewer.

Related Issues (11)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.