-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Machine disconnected #2
Comments
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/ ]. Also by using PacketLogger, I exported the log snoop.log an run the hexdump command, resulting: 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: Log: Did I miss something? Any suggestions on how to get the plugin working with my machine? |
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. |
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. |
@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.
Also make sure you're not connected with the app at the same time. |
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? |
@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. |
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! |
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! |
Thanks for creating this plugin, I'd love to get it to work and get Siri to brew me a fresh coffee in the morning.
I've used Bluetooth HCI Snoop on an Android phone to get the btsnoop_hci.log file. I tried the hexdump command, but gave me no results. Tried with Wireshark, but was not abled to get the key.
Then I followed the instructions by n2k here [ https://gist.github.com/farminf/94f681eaca2760212f457ac59da99f23 ] and tried extracting the key from the database by using a rooted Android phone.
$ sqlite3 nespresso_app_fusion.db 'SELECT pairing_key FROM MyMachines;'
2FAECC7DFF8C42E6BBBCAC1810F011E8
Running the pairing_key.java script gave me this result
Current key: 2FAECC7DFF8C42E6BBBCAC1810F011E8
Current key hex: 82FAECC7DFF8C42E
So now I have a key, but how do I convert this into a valid token?
Firmware 6.0
Connectivity Firmware 1.27
The text was updated successfully, but these errors were encountered: