|
|
|
@@ -1,289 +1,4 @@
|
|
|
|
|
# serializer version: 1
|
|
|
|
|
# name: test_sensor
|
|
|
|
|
StateSnapshot({
|
|
|
|
|
'attributes': ReadOnlyDict({
|
|
|
|
|
'device_class': 'power',
|
|
|
|
|
'friendly_name': 'EVSE 1.1.1.1 Photovoltaic power',
|
|
|
|
|
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
|
|
|
|
'unit_of_measurement': <UnitOfPower.WATT: 'W'>,
|
|
|
|
|
}),
|
|
|
|
|
'context': <ANY>,
|
|
|
|
|
'entity_id': 'sensor.evse_1_1_1_1_photovoltaic_power',
|
|
|
|
|
'last_changed': <ANY>,
|
|
|
|
|
'last_reported': <ANY>,
|
|
|
|
|
'last_updated': <ANY>,
|
|
|
|
|
'state': '0.0',
|
|
|
|
|
})
|
|
|
|
|
list([
|
|
|
|
|
EntityRegistryEntrySnapshot({
|
|
|
|
|
'aliases': set({
|
|
|
|
|
}),
|
|
|
|
|
'area_id': None,
|
|
|
|
|
'capabilities': dict({
|
|
|
|
|
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
|
|
|
|
}),
|
|
|
|
|
'config_entry_id': <ANY>,
|
|
|
|
|
'device_class': None,
|
|
|
|
|
'device_id': <ANY>,
|
|
|
|
|
'disabled_by': None,
|
|
|
|
|
'domain': 'sensor',
|
|
|
|
|
'entity_category': None,
|
|
|
|
|
'entity_id': 'sensor.evse_1_1_1_1_charge_power',
|
|
|
|
|
'has_entity_name': True,
|
|
|
|
|
'hidden_by': None,
|
|
|
|
|
'icon': None,
|
|
|
|
|
'id': <ANY>,
|
|
|
|
|
'labels': set({
|
|
|
|
|
}),
|
|
|
|
|
'name': None,
|
|
|
|
|
'options': dict({
|
|
|
|
|
}),
|
|
|
|
|
'original_device_class': <SensorDeviceClass.POWER: 'power'>,
|
|
|
|
|
'original_icon': 'mdi:ev-station',
|
|
|
|
|
'original_name': 'Charge power',
|
|
|
|
|
'platform': 'v2c',
|
|
|
|
|
'previous_unique_id': None,
|
|
|
|
|
'supported_features': 0,
|
|
|
|
|
'translation_key': 'charge_power',
|
|
|
|
|
'unique_id': '45a36e55aaddb2137c5f6602e0c38e72_charge_power',
|
|
|
|
|
'unit_of_measurement': <UnitOfPower.WATT: 'W'>,
|
|
|
|
|
}),
|
|
|
|
|
EntityRegistryEntrySnapshot({
|
|
|
|
|
'aliases': set({
|
|
|
|
|
}),
|
|
|
|
|
'area_id': None,
|
|
|
|
|
'capabilities': dict({
|
|
|
|
|
'state_class': <SensorStateClass.TOTAL_INCREASING: 'total_increasing'>,
|
|
|
|
|
}),
|
|
|
|
|
'config_entry_id': <ANY>,
|
|
|
|
|
'device_class': None,
|
|
|
|
|
'device_id': <ANY>,
|
|
|
|
|
'disabled_by': None,
|
|
|
|
|
'domain': 'sensor',
|
|
|
|
|
'entity_category': None,
|
|
|
|
|
'entity_id': 'sensor.evse_1_1_1_1_charge_energy',
|
|
|
|
|
'has_entity_name': True,
|
|
|
|
|
'hidden_by': None,
|
|
|
|
|
'icon': None,
|
|
|
|
|
'id': <ANY>,
|
|
|
|
|
'labels': set({
|
|
|
|
|
}),
|
|
|
|
|
'name': None,
|
|
|
|
|
'options': dict({
|
|
|
|
|
}),
|
|
|
|
|
'original_device_class': <SensorDeviceClass.ENERGY: 'energy'>,
|
|
|
|
|
'original_icon': None,
|
|
|
|
|
'original_name': 'Charge energy',
|
|
|
|
|
'platform': 'v2c',
|
|
|
|
|
'previous_unique_id': None,
|
|
|
|
|
'supported_features': 0,
|
|
|
|
|
'translation_key': 'charge_energy',
|
|
|
|
|
'unique_id': '45a36e55aaddb2137c5f6602e0c38e72_charge_energy',
|
|
|
|
|
'unit_of_measurement': <UnitOfEnergy.KILO_WATT_HOUR: 'kWh'>,
|
|
|
|
|
}),
|
|
|
|
|
EntityRegistryEntrySnapshot({
|
|
|
|
|
'aliases': set({
|
|
|
|
|
}),
|
|
|
|
|
'area_id': None,
|
|
|
|
|
'capabilities': dict({
|
|
|
|
|
'state_class': <SensorStateClass.TOTAL_INCREASING: 'total_increasing'>,
|
|
|
|
|
}),
|
|
|
|
|
'config_entry_id': <ANY>,
|
|
|
|
|
'device_class': None,
|
|
|
|
|
'device_id': <ANY>,
|
|
|
|
|
'disabled_by': None,
|
|
|
|
|
'domain': 'sensor',
|
|
|
|
|
'entity_category': None,
|
|
|
|
|
'entity_id': 'sensor.evse_1_1_1_1_charge_time',
|
|
|
|
|
'has_entity_name': True,
|
|
|
|
|
'hidden_by': None,
|
|
|
|
|
'icon': None,
|
|
|
|
|
'id': <ANY>,
|
|
|
|
|
'labels': set({
|
|
|
|
|
}),
|
|
|
|
|
'name': None,
|
|
|
|
|
'options': dict({
|
|
|
|
|
}),
|
|
|
|
|
'original_device_class': <SensorDeviceClass.DURATION: 'duration'>,
|
|
|
|
|
'original_icon': None,
|
|
|
|
|
'original_name': 'Charge time',
|
|
|
|
|
'platform': 'v2c',
|
|
|
|
|
'previous_unique_id': None,
|
|
|
|
|
'supported_features': 0,
|
|
|
|
|
'translation_key': 'charge_time',
|
|
|
|
|
'unique_id': '45a36e55aaddb2137c5f6602e0c38e72_charge_time',
|
|
|
|
|
'unit_of_measurement': <UnitOfTime.SECONDS: 's'>,
|
|
|
|
|
}),
|
|
|
|
|
EntityRegistryEntrySnapshot({
|
|
|
|
|
'aliases': set({
|
|
|
|
|
}),
|
|
|
|
|
'area_id': None,
|
|
|
|
|
'capabilities': dict({
|
|
|
|
|
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
|
|
|
|
}),
|
|
|
|
|
'config_entry_id': <ANY>,
|
|
|
|
|
'device_class': None,
|
|
|
|
|
'device_id': <ANY>,
|
|
|
|
|
'disabled_by': None,
|
|
|
|
|
'domain': 'sensor',
|
|
|
|
|
'entity_category': None,
|
|
|
|
|
'entity_id': 'sensor.evse_1_1_1_1_house_power',
|
|
|
|
|
'has_entity_name': True,
|
|
|
|
|
'hidden_by': None,
|
|
|
|
|
'icon': None,
|
|
|
|
|
'id': <ANY>,
|
|
|
|
|
'labels': set({
|
|
|
|
|
}),
|
|
|
|
|
'name': None,
|
|
|
|
|
'options': dict({
|
|
|
|
|
}),
|
|
|
|
|
'original_device_class': <SensorDeviceClass.POWER: 'power'>,
|
|
|
|
|
'original_icon': None,
|
|
|
|
|
'original_name': 'House power',
|
|
|
|
|
'platform': 'v2c',
|
|
|
|
|
'previous_unique_id': None,
|
|
|
|
|
'supported_features': 0,
|
|
|
|
|
'translation_key': 'house_power',
|
|
|
|
|
'unique_id': '45a36e55aaddb2137c5f6602e0c38e72_house_power',
|
|
|
|
|
'unit_of_measurement': <UnitOfPower.WATT: 'W'>,
|
|
|
|
|
}),
|
|
|
|
|
EntityRegistryEntrySnapshot({
|
|
|
|
|
'aliases': set({
|
|
|
|
|
}),
|
|
|
|
|
'area_id': None,
|
|
|
|
|
'capabilities': dict({
|
|
|
|
|
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
|
|
|
|
}),
|
|
|
|
|
'config_entry_id': <ANY>,
|
|
|
|
|
'device_class': None,
|
|
|
|
|
'device_id': <ANY>,
|
|
|
|
|
'disabled_by': None,
|
|
|
|
|
'domain': 'sensor',
|
|
|
|
|
'entity_category': None,
|
|
|
|
|
'entity_id': 'sensor.evse_1_1_1_1_photovoltaic_power',
|
|
|
|
|
'has_entity_name': True,
|
|
|
|
|
'hidden_by': None,
|
|
|
|
|
'icon': None,
|
|
|
|
|
'id': <ANY>,
|
|
|
|
|
'labels': set({
|
|
|
|
|
}),
|
|
|
|
|
'name': None,
|
|
|
|
|
'options': dict({
|
|
|
|
|
}),
|
|
|
|
|
'original_device_class': <SensorDeviceClass.POWER: 'power'>,
|
|
|
|
|
'original_icon': None,
|
|
|
|
|
'original_name': 'Photovoltaic power',
|
|
|
|
|
'platform': 'v2c',
|
|
|
|
|
'previous_unique_id': None,
|
|
|
|
|
'supported_features': 0,
|
|
|
|
|
'translation_key': 'fv_power',
|
|
|
|
|
'unique_id': '45a36e55aaddb2137c5f6602e0c38e72_fv_power',
|
|
|
|
|
'unit_of_measurement': <UnitOfPower.WATT: 'W'>,
|
|
|
|
|
}),
|
|
|
|
|
EntityRegistryEntrySnapshot({
|
|
|
|
|
'aliases': set({
|
|
|
|
|
}),
|
|
|
|
|
'area_id': None,
|
|
|
|
|
'capabilities': dict({
|
|
|
|
|
'options': list([
|
|
|
|
|
'no_error',
|
|
|
|
|
'communication',
|
|
|
|
|
'reading',
|
|
|
|
|
'slave',
|
|
|
|
|
'waiting_wifi',
|
|
|
|
|
'waiting_communication',
|
|
|
|
|
'wrong_ip',
|
|
|
|
|
'slave_not_found',
|
|
|
|
|
'wrong_slave',
|
|
|
|
|
'no_response',
|
|
|
|
|
'clamp_not_connected',
|
|
|
|
|
'illegal_function',
|
|
|
|
|
'illegal_data_address',
|
|
|
|
|
'illegal_data_value',
|
|
|
|
|
'server_device_failure',
|
|
|
|
|
'acknowledge',
|
|
|
|
|
'server_device_busy',
|
|
|
|
|
'negative_acknowledge',
|
|
|
|
|
'memory_parity_error',
|
|
|
|
|
'gateway_path_unavailable',
|
|
|
|
|
'gateway_target_no_resp',
|
|
|
|
|
'server_rtu_inactive244_timeout',
|
|
|
|
|
'invalid_server',
|
|
|
|
|
'crc_error',
|
|
|
|
|
'fc_missmatch',
|
|
|
|
|
'server_id_missmatch',
|
|
|
|
|
'packet_length_error',
|
|
|
|
|
'parameter_count_error',
|
|
|
|
|
'parameter_limit_error',
|
|
|
|
|
'request_queue_full',
|
|
|
|
|
'illegal_ip_or_port',
|
|
|
|
|
'ip_connection_failed',
|
|
|
|
|
'tcp_head_missmatch',
|
|
|
|
|
'empty_message',
|
|
|
|
|
'undefined_error',
|
|
|
|
|
]),
|
|
|
|
|
}),
|
|
|
|
|
'config_entry_id': <ANY>,
|
|
|
|
|
'device_class': None,
|
|
|
|
|
'device_id': <ANY>,
|
|
|
|
|
'disabled_by': <RegistryEntryDisabler.INTEGRATION: 'integration'>,
|
|
|
|
|
'domain': 'sensor',
|
|
|
|
|
'entity_category': None,
|
|
|
|
|
'entity_id': 'sensor.evse_1_1_1_1_slave_error',
|
|
|
|
|
'has_entity_name': True,
|
|
|
|
|
'hidden_by': None,
|
|
|
|
|
'icon': None,
|
|
|
|
|
'id': <ANY>,
|
|
|
|
|
'labels': set({
|
|
|
|
|
}),
|
|
|
|
|
'name': None,
|
|
|
|
|
'options': dict({
|
|
|
|
|
}),
|
|
|
|
|
'original_device_class': <SensorDeviceClass.ENUM: 'enum'>,
|
|
|
|
|
'original_icon': None,
|
|
|
|
|
'original_name': 'Slave error',
|
|
|
|
|
'platform': 'v2c',
|
|
|
|
|
'previous_unique_id': None,
|
|
|
|
|
'supported_features': 0,
|
|
|
|
|
'translation_key': 'slave_error',
|
|
|
|
|
'unique_id': '45a36e55aaddb2137c5f6602e0c38e72_slave_error',
|
|
|
|
|
'unit_of_measurement': None,
|
|
|
|
|
}),
|
|
|
|
|
EntityRegistryEntrySnapshot({
|
|
|
|
|
'aliases': set({
|
|
|
|
|
}),
|
|
|
|
|
'area_id': None,
|
|
|
|
|
'capabilities': dict({
|
|
|
|
|
'state_class': <SensorStateClass.MEASUREMENT: 'measurement'>,
|
|
|
|
|
}),
|
|
|
|
|
'config_entry_id': <ANY>,
|
|
|
|
|
'device_class': None,
|
|
|
|
|
'device_id': <ANY>,
|
|
|
|
|
'disabled_by': <RegistryEntryDisabler.INTEGRATION: 'integration'>,
|
|
|
|
|
'domain': 'sensor',
|
|
|
|
|
'entity_category': None,
|
|
|
|
|
'entity_id': 'sensor.evse_1_1_1_1_battery_power',
|
|
|
|
|
'has_entity_name': True,
|
|
|
|
|
'hidden_by': None,
|
|
|
|
|
'icon': None,
|
|
|
|
|
'id': <ANY>,
|
|
|
|
|
'labels': set({
|
|
|
|
|
}),
|
|
|
|
|
'name': None,
|
|
|
|
|
'options': dict({
|
|
|
|
|
}),
|
|
|
|
|
'original_device_class': <SensorDeviceClass.POWER: 'power'>,
|
|
|
|
|
'original_icon': None,
|
|
|
|
|
'original_name': 'Battery power',
|
|
|
|
|
'platform': 'v2c',
|
|
|
|
|
'previous_unique_id': None,
|
|
|
|
|
'supported_features': 0,
|
|
|
|
|
'translation_key': 'battery_power',
|
|
|
|
|
'unique_id': '45a36e55aaddb2137c5f6602e0c38e72_battery_power',
|
|
|
|
|
'unit_of_measurement': <UnitOfPower.WATT: 'W'>,
|
|
|
|
|
}),
|
|
|
|
|
])
|
|
|
|
|
# ---
|
|
|
|
|
# name: test_sensor[sensor.evse_1_1_1_1_battery_power-entry]
|
|
|
|
|
EntityRegistryEntrySnapshot({
|
|
|
|
|
'aliases': set({
|
|
|
|
@@ -540,6 +255,128 @@
|
|
|
|
|
'state': '0.0',
|
|
|
|
|
})
|
|
|
|
|
# ---
|
|
|
|
|
# name: test_sensor[sensor.evse_1_1_1_1_meter_error-entry]
|
|
|
|
|
EntityRegistryEntrySnapshot({
|
|
|
|
|
'aliases': set({
|
|
|
|
|
}),
|
|
|
|
|
'area_id': None,
|
|
|
|
|
'capabilities': dict({
|
|
|
|
|
'options': list([
|
|
|
|
|
'no_error',
|
|
|
|
|
'communication',
|
|
|
|
|
'reading',
|
|
|
|
|
'slave',
|
|
|
|
|
'waiting_wifi',
|
|
|
|
|
'waiting_communication',
|
|
|
|
|
'wrong_ip',
|
|
|
|
|
'slave_not_found',
|
|
|
|
|
'wrong_slave',
|
|
|
|
|
'no_response',
|
|
|
|
|
'clamp_not_connected',
|
|
|
|
|
'illegal_function',
|
|
|
|
|
'illegal_data_address',
|
|
|
|
|
'illegal_data_value',
|
|
|
|
|
'server_device_failure',
|
|
|
|
|
'acknowledge',
|
|
|
|
|
'server_device_busy',
|
|
|
|
|
'negative_acknowledge',
|
|
|
|
|
'memory_parity_error',
|
|
|
|
|
'gateway_path_unavailable',
|
|
|
|
|
'gateway_target_no_resp',
|
|
|
|
|
'server_rtu_inactive244_timeout',
|
|
|
|
|
'invalid_server',
|
|
|
|
|
'crc_error',
|
|
|
|
|
'fc_mismatch',
|
|
|
|
|
'server_id_mismatch',
|
|
|
|
|
'packet_length_error',
|
|
|
|
|
'parameter_count_error',
|
|
|
|
|
'parameter_limit_error',
|
|
|
|
|
'request_queue_full',
|
|
|
|
|
'illegal_ip_or_port',
|
|
|
|
|
'ip_connection_failed',
|
|
|
|
|
'tcp_head_mismatch',
|
|
|
|
|
'empty_message',
|
|
|
|
|
'undefined_error',
|
|
|
|
|
]),
|
|
|
|
|
}),
|
|
|
|
|
'config_entry_id': <ANY>,
|
|
|
|
|
'device_class': None,
|
|
|
|
|
'device_id': <ANY>,
|
|
|
|
|
'disabled_by': None,
|
|
|
|
|
'domain': 'sensor',
|
|
|
|
|
'entity_category': None,
|
|
|
|
|
'entity_id': 'sensor.evse_1_1_1_1_meter_error',
|
|
|
|
|
'has_entity_name': True,
|
|
|
|
|
'hidden_by': None,
|
|
|
|
|
'icon': None,
|
|
|
|
|
'id': <ANY>,
|
|
|
|
|
'labels': set({
|
|
|
|
|
}),
|
|
|
|
|
'name': None,
|
|
|
|
|
'options': dict({
|
|
|
|
|
}),
|
|
|
|
|
'original_device_class': <SensorDeviceClass.ENUM: 'enum'>,
|
|
|
|
|
'original_icon': None,
|
|
|
|
|
'original_name': 'Meter error',
|
|
|
|
|
'platform': 'v2c',
|
|
|
|
|
'previous_unique_id': None,
|
|
|
|
|
'supported_features': 0,
|
|
|
|
|
'translation_key': 'meter_error',
|
|
|
|
|
'unique_id': 'da58ee91f38c2406c2a36d0a1a7f8569_meter_error',
|
|
|
|
|
'unit_of_measurement': None,
|
|
|
|
|
})
|
|
|
|
|
# ---
|
|
|
|
|
# name: test_sensor[sensor.evse_1_1_1_1_meter_error-state]
|
|
|
|
|
StateSnapshot({
|
|
|
|
|
'attributes': ReadOnlyDict({
|
|
|
|
|
'device_class': 'enum',
|
|
|
|
|
'friendly_name': 'EVSE 1.1.1.1 Meter error',
|
|
|
|
|
'options': list([
|
|
|
|
|
'no_error',
|
|
|
|
|
'communication',
|
|
|
|
|
'reading',
|
|
|
|
|
'slave',
|
|
|
|
|
'waiting_wifi',
|
|
|
|
|
'waiting_communication',
|
|
|
|
|
'wrong_ip',
|
|
|
|
|
'slave_not_found',
|
|
|
|
|
'wrong_slave',
|
|
|
|
|
'no_response',
|
|
|
|
|
'clamp_not_connected',
|
|
|
|
|
'illegal_function',
|
|
|
|
|
'illegal_data_address',
|
|
|
|
|
'illegal_data_value',
|
|
|
|
|
'server_device_failure',
|
|
|
|
|
'acknowledge',
|
|
|
|
|
'server_device_busy',
|
|
|
|
|
'negative_acknowledge',
|
|
|
|
|
'memory_parity_error',
|
|
|
|
|
'gateway_path_unavailable',
|
|
|
|
|
'gateway_target_no_resp',
|
|
|
|
|
'server_rtu_inactive244_timeout',
|
|
|
|
|
'invalid_server',
|
|
|
|
|
'crc_error',
|
|
|
|
|
'fc_mismatch',
|
|
|
|
|
'server_id_mismatch',
|
|
|
|
|
'packet_length_error',
|
|
|
|
|
'parameter_count_error',
|
|
|
|
|
'parameter_limit_error',
|
|
|
|
|
'request_queue_full',
|
|
|
|
|
'illegal_ip_or_port',
|
|
|
|
|
'ip_connection_failed',
|
|
|
|
|
'tcp_head_mismatch',
|
|
|
|
|
'empty_message',
|
|
|
|
|
'undefined_error',
|
|
|
|
|
]),
|
|
|
|
|
}),
|
|
|
|
|
'context': <ANY>,
|
|
|
|
|
'entity_id': 'sensor.evse_1_1_1_1_meter_error',
|
|
|
|
|
'last_changed': <ANY>,
|
|
|
|
|
'last_reported': <ANY>,
|
|
|
|
|
'last_updated': <ANY>,
|
|
|
|
|
'state': 'waiting_wifi',
|
|
|
|
|
})
|
|
|
|
|
# ---
|
|
|
|
|
# name: test_sensor[sensor.evse_1_1_1_1_photovoltaic_power-entry]
|
|
|
|
|
EntityRegistryEntrySnapshot({
|
|
|
|
|
'aliases': set({
|
|
|
|
@@ -591,125 +428,3 @@
|
|
|
|
|
'state': '0.0',
|
|
|
|
|
})
|
|
|
|
|
# ---
|
|
|
|
|
# name: test_sensor[sensor.evse_1_1_1_1_slave_error-entry]
|
|
|
|
|
EntityRegistryEntrySnapshot({
|
|
|
|
|
'aliases': set({
|
|
|
|
|
}),
|
|
|
|
|
'area_id': None,
|
|
|
|
|
'capabilities': dict({
|
|
|
|
|
'options': list([
|
|
|
|
|
'no_error',
|
|
|
|
|
'communication',
|
|
|
|
|
'reading',
|
|
|
|
|
'slave',
|
|
|
|
|
'waiting_wifi',
|
|
|
|
|
'waiting_communication',
|
|
|
|
|
'wrong_ip',
|
|
|
|
|
'slave_not_found',
|
|
|
|
|
'wrong_slave',
|
|
|
|
|
'no_response',
|
|
|
|
|
'clamp_not_connected',
|
|
|
|
|
'illegal_function',
|
|
|
|
|
'illegal_data_address',
|
|
|
|
|
'illegal_data_value',
|
|
|
|
|
'server_device_failure',
|
|
|
|
|
'acknowledge',
|
|
|
|
|
'server_device_busy',
|
|
|
|
|
'negative_acknowledge',
|
|
|
|
|
'memory_parity_error',
|
|
|
|
|
'gateway_path_unavailable',
|
|
|
|
|
'gateway_target_no_resp',
|
|
|
|
|
'server_rtu_inactive244_timeout',
|
|
|
|
|
'invalid_server',
|
|
|
|
|
'crc_error',
|
|
|
|
|
'fc_mismatch',
|
|
|
|
|
'server_id_mismatch',
|
|
|
|
|
'packet_length_error',
|
|
|
|
|
'parameter_count_error',
|
|
|
|
|
'parameter_limit_error',
|
|
|
|
|
'request_queue_full',
|
|
|
|
|
'illegal_ip_or_port',
|
|
|
|
|
'ip_connection_failed',
|
|
|
|
|
'tcp_head_mismatch',
|
|
|
|
|
'empty_message',
|
|
|
|
|
'undefined_error',
|
|
|
|
|
]),
|
|
|
|
|
}),
|
|
|
|
|
'config_entry_id': <ANY>,
|
|
|
|
|
'device_class': None,
|
|
|
|
|
'device_id': <ANY>,
|
|
|
|
|
'disabled_by': None,
|
|
|
|
|
'domain': 'sensor',
|
|
|
|
|
'entity_category': None,
|
|
|
|
|
'entity_id': 'sensor.evse_1_1_1_1_slave_error',
|
|
|
|
|
'has_entity_name': True,
|
|
|
|
|
'hidden_by': None,
|
|
|
|
|
'icon': None,
|
|
|
|
|
'id': <ANY>,
|
|
|
|
|
'labels': set({
|
|
|
|
|
}),
|
|
|
|
|
'name': None,
|
|
|
|
|
'options': dict({
|
|
|
|
|
}),
|
|
|
|
|
'original_device_class': <SensorDeviceClass.ENUM: 'enum'>,
|
|
|
|
|
'original_icon': None,
|
|
|
|
|
'original_name': 'Slave error',
|
|
|
|
|
'platform': 'v2c',
|
|
|
|
|
'previous_unique_id': None,
|
|
|
|
|
'supported_features': 0,
|
|
|
|
|
'translation_key': 'slave_error',
|
|
|
|
|
'unique_id': 'da58ee91f38c2406c2a36d0a1a7f8569_slave_error',
|
|
|
|
|
'unit_of_measurement': None,
|
|
|
|
|
})
|
|
|
|
|
# ---
|
|
|
|
|
# name: test_sensor[sensor.evse_1_1_1_1_slave_error-state]
|
|
|
|
|
StateSnapshot({
|
|
|
|
|
'attributes': ReadOnlyDict({
|
|
|
|
|
'device_class': 'enum',
|
|
|
|
|
'friendly_name': 'EVSE 1.1.1.1 Slave error',
|
|
|
|
|
'options': list([
|
|
|
|
|
'no_error',
|
|
|
|
|
'communication',
|
|
|
|
|
'reading',
|
|
|
|
|
'slave',
|
|
|
|
|
'waiting_wifi',
|
|
|
|
|
'waiting_communication',
|
|
|
|
|
'wrong_ip',
|
|
|
|
|
'slave_not_found',
|
|
|
|
|
'wrong_slave',
|
|
|
|
|
'no_response',
|
|
|
|
|
'clamp_not_connected',
|
|
|
|
|
'illegal_function',
|
|
|
|
|
'illegal_data_address',
|
|
|
|
|
'illegal_data_value',
|
|
|
|
|
'server_device_failure',
|
|
|
|
|
'acknowledge',
|
|
|
|
|
'server_device_busy',
|
|
|
|
|
'negative_acknowledge',
|
|
|
|
|
'memory_parity_error',
|
|
|
|
|
'gateway_path_unavailable',
|
|
|
|
|
'gateway_target_no_resp',
|
|
|
|
|
'server_rtu_inactive244_timeout',
|
|
|
|
|
'invalid_server',
|
|
|
|
|
'crc_error',
|
|
|
|
|
'fc_mismatch',
|
|
|
|
|
'server_id_mismatch',
|
|
|
|
|
'packet_length_error',
|
|
|
|
|
'parameter_count_error',
|
|
|
|
|
'parameter_limit_error',
|
|
|
|
|
'request_queue_full',
|
|
|
|
|
'illegal_ip_or_port',
|
|
|
|
|
'ip_connection_failed',
|
|
|
|
|
'tcp_head_mismatch',
|
|
|
|
|
'empty_message',
|
|
|
|
|
'undefined_error',
|
|
|
|
|
]),
|
|
|
|
|
}),
|
|
|
|
|
'context': <ANY>,
|
|
|
|
|
'entity_id': 'sensor.evse_1_1_1_1_slave_error',
|
|
|
|
|
'last_changed': <ANY>,
|
|
|
|
|
'last_reported': <ANY>,
|
|
|
|
|
'last_updated': <ANY>,
|
|
|
|
|
'state': 'waiting_wifi',
|
|
|
|
|
})
|
|
|
|
|
# ---
|
|
|
|
|