Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
COLB MQTT
#1
Hi

I have a situation when Home Assistant starts all my entities from 2 COLB modules have 'unknown' values. That's because the COLB modules are note sending periodic state messages ore they have no availability topic.   They are sending data only on state changes. That's could be critical in some situations like climate control. 
Example:
Turning on or off the heating in some rooms based on windows states. If a window in a room is closed then turn on the heating in that specific room. Now When HA starts the state of the window will be unknown so the heating won't start. That's only a banal example but in some critical scenes this could be an issue.
Proposed solution:
Make COLB to periodically (ex: every second) send stats data or when HA starts make some request to COLB topic to provide current sensor states.

This could massive improve the device reliability. Is it possible? Thank you.
Reply
#2
If you want to take the initiative to inquire by every seconds, you can send MQTT query command:

command_topic: ‘COLB/xxxxxxxxxxxxxxxxxxxxxxxx/set’

payload={State=D_FF} read all digital input sensor data

feedback:

{“D1”:{“on”:0},”D2″:{“on”:0},”D3″:{“on”:0},”D4″:{“on”:0},”D5″:{“on”:0},”D6″:{“on”:0},”D7″:{“on”:0},”D8″:{“on”:0},”D9″:{“on”:0},”D10″:{“on”:0},”D11″:{“on”:0},”D12″:{“on”:0},”D13″:{“on”:0},”D14″:{“on”:0},”D15″:{“on”:0},”D16″:{“on”:0}}

payload={State=A_FF} read all analog input sensor data

feedback:

{“A1”:{“value”:0.0},”A2″:{“value”:0.0},”A3″:{“value”:0.0},”A4″:{“value”:0.0},”A5″:{“value”:0.0},”A6″:{“value”:0.0},”A7″:{“value”:0.0},”A8″:{“value”:0.0},”A9″:{“value”:0.0},”A10″:{“value”:0.0},”A11″:{“value”:0.0},”A12″:{“value”:0.0},”A13″:{“value”:0.0},”A14″:{“value”:0.0},”A15″:{“value”:0.0},”A16″:{“value”:0.0}}

payload={State=T_FF} read all DS18B20 temperature sensor data

feedback:

{“T1”:{“value”:22.93},”T2″:{“value”:22.25},”T3″:{“value”:22.31},”T4″:{“value”:22.93},”T5″:{“value”:22.18}}



———–Enable/Disable Auto Report Function—————

payload={Auto_upload=1} Enable auto report function

feedback: {“upload”:{”ON”,1}}

payload={Auto_upload=0} Disable auto report function

feedback: {“upload”:{”ON”,0}}
Reply


Forum Jump:


Users browsing this thread:
1 Guest(s)