Adjust model_id for both LYWSD03MMC/MJWSD05MMC_PVVX_BTHOME - #654
Conversation
…match to resolve issues with OpenMQTTGateway
|
Thanks @plambrechtsen
You might want to have a look at the code internal BM2 decoding, where decryption is already in place in OMG. There with a static bindkey however, applicable to all BM2s. For BTHome decryption, as well as the other two Decoder implemented encryption schemes, you will need to come up with a nice way to pass and store the MAC and Bindkey pairs. The You might have already looked at how these are implemented in Python for Theengs Gateway https://github.com/theengs/gateway/blob/development/TheengsGateway/decryption.py I. e. all the decryption schemes do send the decrypted payload to Theengs Decoder again for final decoding. |
|
Thanks @DigiH my current approach has been to add logic in process_bledata and checking for the It seems to all work and I am adding in configuring the |
|
Sounds great @plambrechtsen ! My reference to gatewayBLEConnect.cpp above was really only to show that AES decryption was already implemented in OMG,Decoder related decryption however will need to be implemented as you described above. I'll be looking forward to this addition to OMG :) As I don't have any encryption capable devices myself I will also ask the user who asked for, helped with and tested the Victron Energy decryption with me, to verify its OMG implementation. |
|
Just finished my first PR for OMG fixing up some UI issues. 1technophile/OpenMQTTGateway#2218 now building a new branch based on those changes for BTHome encryption. |
|
And a separate PR adding BTHome support. It's not pretty but it works. 1technophile/OpenMQTTGateway#2219 |
Adjust model_id for both LYWSD03MMC/MJWSD05MMC_PVVX_BTHOME frames removing the _1 and _2 to match to resolve issues with OpenMQTTGateway
Description:
When testing the updated LYWSD03MMC/MJWSD05MMC_PVVX_BTHOME decoder with OpenMQTTGateway there is an issue as the
model_idis used in the device name. Since I mistakenly had differentmodel_id's for the different frames then OpenMQTTGateway flip flops between the two names and that then flows into Home Assistant.I am working on adding Encrypted BTHome support to OpenMQTTGateway as well. What it should be doing is checking for the
actsso it will know there is additional frames that need to be supported.Checklist: