mirror of
https://github.com/home-assistant/core.git
synced 2025-08-10 08:05:06 +02:00
Add debugging message to confirm platform setup
This commit is contained in:
@@ -31,6 +31,9 @@ def async_setup_platform(hass, config, async_add_devices, discovery_info=None):
|
||||
device = plm.devices[address]
|
||||
state_key = discovery_info['state_key']
|
||||
|
||||
_LOGGER.debug('Adding device %s with state name %s to Binary Sensor platform.',
|
||||
device.address.hex, device.states[state_key].name)
|
||||
|
||||
entities.append(InsteonPLMBinarySensor(device, state_key))
|
||||
|
||||
async_add_devices(entities)
|
||||
|
@@ -39,6 +39,9 @@ def async_setup_platform(hass, config, async_add_devices, discovery_info=None):
|
||||
device = plm.devices[address]
|
||||
state_key = discovery_info['state_key']
|
||||
|
||||
_LOGGER.debug('Adding device %s with state name %s to Fan platform.',
|
||||
device.address.hex, device.states[state_key].name)
|
||||
|
||||
entities.append(InsteonPLMFan(device, state_key, SUPPORT_SET_SPEED))
|
||||
|
||||
async_add_devices(entities)
|
||||
|
@@ -29,6 +29,9 @@ def async_setup_platform(hass, config, async_add_devices, discovery_info=None):
|
||||
device = plm.devices[address]
|
||||
state_key = discovery_info['state_key']
|
||||
|
||||
_LOGGER.debug('Adding device %s with state name %s to Light platform.',
|
||||
device.address.hex, device.states[state_key].name)
|
||||
|
||||
entities.append(InsteonPLMDimmerDevice(device, state_key))
|
||||
|
||||
async_add_devices(entities)
|
||||
|
@@ -26,6 +26,9 @@ def async_setup_platform(hass, config, async_add_devices, discovery_info=None):
|
||||
device = plm.devices[address]
|
||||
state_key = discovery_info['state_key']
|
||||
|
||||
_LOGGER.debug('Adding device %s with state name %s to Sensor platform.',
|
||||
device.address.hex, device.states[state_key].name)
|
||||
|
||||
entities.append(InsteonPLMSensorDevice(device, state_key))
|
||||
|
||||
async_add_devices(entities)
|
||||
|
@@ -28,6 +28,9 @@ def async_setup_platform(hass, config, async_add_devices, discovery_info=None):
|
||||
|
||||
state_name = device.states[state_key].name
|
||||
|
||||
_LOGGER.debug('Adding device %s with state name %s to Switch platform.',
|
||||
device.address.hex, device.states[state_key].name)
|
||||
|
||||
if state_name in ['lightOnOff', 'outletTopOnOff', 'outletBottomOnOff']:
|
||||
entities.append(InsteonPLMSwitchDevice(device, state_key))
|
||||
elif state_name == 'openClosedRelay':
|
||||
|
Reference in New Issue
Block a user