hannseman / homebridge-mi-hygrothermograph

Homebridge plugin for the Xiaomi Mi Bluetooth Temperature and Humidity Sensor
MIT License
266 stars 52 forks source link

LYWSD03MMC encryption #137

Closed fmpmsilva closed 3 years ago

fmpmsilva commented 3 years ago

Hi there,

Trying to connect LYWSD03MMC. Sorry but i didn't understand the encryption part. Can someone please help me what steps and how to do it?

Thanks

maddinek commented 3 years ago

{ "accessory": "Hygrotermograph", "name": "Temperature & Humidity", "address": "4c:64:a8:d0:ae:65", "timeout": 15, "temperatureName": "Temperature", "humidityName": "Humidity", "fakeGatoEnabled": true, "bindKey": "keyyoufoundwiththeinstructions" }

From my understanding it should work like this. Unfortunately, it doesn't work for me.

fmpmsilva commented 3 years ago

Me neither. Im getting this: Error: Sensor data is encrypted. Please configure a bindKey. at Parser.decryptPayload (/usr/local/lib/node_modules/homebridge-mi-hygrothermograph/lib/parser.js:163:13) at Parser.parse (/usr/local/lib/node_modules/homebridge-mi-hygrothermograph/lib/parser.js:59:12) at Scanner.parseServiceData (/usr/local/lib/node_modules/homebridge-mi-hygrothermograph/lib/scanner.js:171:52) at Scanner.onDiscover (/usr/local/lib/node_modules/homebridge-mi-hygrothermograph/lib/scanner.js:92:25) at Noble.emit (events.js:315:20) at Noble.onDiscover (/usr/local/lib/node_modules/homebridge-mi-hygrothermograph/node_modules/@abandonware/noble/lib/noble.js:196:10) at NobleMac.emit (events.js:315:20)

hannseman commented 3 years ago

@fmpmsilva looks like you haven't configured a bindKey. You need to set it in your configuration.

fmpmsilva commented 3 years ago

Thanks. New at this and i don't know how to it on a Imac.

codyc1515 commented 3 years ago

https://github.com/custom-components/ble_monitor/blob/master/faq.md#my-sensors-ble-advertisements-are-encrypted-how-can-i-get-the-key