Add log info in the rfxtrx component
parent
0c97280479
commit
ebc95aca51
|
@ -59,6 +59,11 @@ def setup_platform(hass, config, add_devices_callback, discovery_info=None):
|
||||||
|
|
||||||
# Check if entity exists or previously added automatically
|
# Check if entity exists or previously added automatically
|
||||||
if entity_id in rfxtrx.RFX_DEVICES:
|
if entity_id in rfxtrx.RFX_DEVICES:
|
||||||
|
_LOGGER.info(
|
||||||
|
"EntityID: %s light_update. Command: %s",
|
||||||
|
entity_id,
|
||||||
|
event.values['Command']
|
||||||
|
)
|
||||||
if event.values['Command'] == 'On'\
|
if event.values['Command'] == 'On'\
|
||||||
or event.values['Command'] == 'Off':
|
or event.values['Command'] == 'Off':
|
||||||
if event.values['Command'] == 'On':
|
if event.values['Command'] == 'On':
|
||||||
|
|
|
@ -43,6 +43,10 @@ def setup_platform(hass, config, add_devices_callback, discovery_info=None):
|
||||||
rfxtrx.RFX_DEVICES[entity_id] = new_sensor
|
rfxtrx.RFX_DEVICES[entity_id] = new_sensor
|
||||||
add_devices_callback([new_sensor])
|
add_devices_callback([new_sensor])
|
||||||
else:
|
else:
|
||||||
|
_LOGGER.info(
|
||||||
|
"EntityID: %s sensor_update",
|
||||||
|
entity_id,
|
||||||
|
)
|
||||||
rfxtrx.RFX_DEVICES[entity_id].event = event
|
rfxtrx.RFX_DEVICES[entity_id].event = event
|
||||||
|
|
||||||
if sensor_update not in rfxtrx.RECEIVED_EVT_SUBSCRIBERS:
|
if sensor_update not in rfxtrx.RECEIVED_EVT_SUBSCRIBERS:
|
||||||
|
|
|
@ -61,6 +61,11 @@ def setup_platform(hass, config, add_devices_callback, discovery_info=None):
|
||||||
|
|
||||||
# Check if entity exists or previously added automatically
|
# Check if entity exists or previously added automatically
|
||||||
if entity_id in rfxtrx.RFX_DEVICES:
|
if entity_id in rfxtrx.RFX_DEVICES:
|
||||||
|
_LOGGER.info(
|
||||||
|
"EntityID: %s switch_update. Command: %s",
|
||||||
|
entity_id,
|
||||||
|
event.values['Command']
|
||||||
|
)
|
||||||
if event.values['Command'] == 'On'\
|
if event.values['Command'] == 'On'\
|
||||||
or event.values['Command'] == 'Off':
|
or event.values['Command'] == 'Off':
|
||||||
if event.values['Command'] == 'On':
|
if event.values['Command'] == 'On':
|
||||||
|
|
Loading…
Reference in New Issue