Closed manju-rn closed 3 years ago
Hmm, could you try if disabling the web server makes any difference?
The Climate component is the problem. If I remove the climate component, it works fine. I have a question, let say I have following setup:
I have never tested such a scenario but I believe it should work. If you try it, please let me know, I am curious. :-) One hint: maybe you will have to set "use_BLE2902" to false. I think I have forgotten to document this option. If you enable it (which it is by default), the client has to tell the server that it wants to receive notifications whenever a value changes. I am not sure if the standard BLE client in ESPHome can handle that. If you disable this option, the server will happily send notifications in any case. That might waste some energy, but it should be safer. The option is on the same level as "exposes" or "characteristic".
okay - tried this with mixed results, it is very random:
Let me try with some other ESP 32 as well. Range is not a problem since they are right next to each other
One observation though, in the ESP client, I get the following. should the descriptor have a value?
[13:09:52][C][ble_sensor:021]: Service UUID : 4FAFC2011FB545-9E8F-CCC5-C9C3-31915D [13:09:52][C][ble_sensor:022]: Characteristic UUID: BEB5483E36E146-88B7-F5EA-0736-1B26AB [13:09:52][C][ble_sensor:023]: Descriptor UUID : 00000000000000-0000-0000-0000-000000
okay - ignore the above. I think my esp was a problem. I am able to consistently connect with or without that use_BLE2902 settings. So the notification works perfectly - thanks so much. Now I have to try that text_sensor, this will be a game changer :-)
Thanks for reporting back. I am glad it is working now. Depending on what you want to do with the text sensor you might also want to have a look at user-defined commands. I like them a lot. ;-)
@manju-rn can you please take a look at https://github.com/wifwucite/esphome-ble-controller/issues/15 and maybe share your server and client yamls so I can see what I'm doing wrong?
It seems from the log you pasted you are using it other way round - so for you the switch is server, right?
So in my case it would be possible with toggling virtual switch on button press on the and light would also toggle on ble_sensor state change?
I am trying to expose a template switch, I get the following error
[23:58:39]Fatal exception (0): IllegalInstruction [23:58:39]epc1=0x4008033a, epc2=0x00000000, epc3=0x00000000, excvaddr=0x00000000, depc=0x00000000
YAML