diff --git a/custom_components/meross_cloud/switch.py b/custom_components/meross_cloud/switch.py index 0d70a471e3..a043455434 100644 --- a/custom_components/meross_cloud/switch.py +++ b/custom_components/meross_cloud/switch.py @@ -15,9 +15,12 @@ def __init__(self, device: GenericPlug, channel: int): self._device = device self._channel_id = channel self._id = calculate_switch_id(self._device.uuid, channel) - if len(self._device.get_channels())>1: - self._device_name = "%s (channel: %d)" % (self._device.name, channel) + if channel > 0: + # This is a sub-channel within the multi-way adapter + channelData = self._device.get_channels()[channel] + self._device_name = channelData['devName'] else: + # This is the root device self._device_name = self._device.name device.register_event_callback(self.handler)