5static const char *
const TAG =
"tuya.automation";
10 if (dp.
type != expected) {
11 ESP_LOGW(TAG,
"Tuya sensor %u expected datapoint type %#02hhX but got %#02hhX", dp.
id,
12 static_cast<uint8_t
>(expected),
static_cast<uint8_t
>(dp.
type));
void trigger(const Ts &...x) ESPHOME_ALWAYS_INLINE
TuyaBitmaskDatapointUpdateTrigger(Tuya *parent, uint8_t sensor_id)
TuyaBoolDatapointUpdateTrigger(Tuya *parent, uint8_t sensor_id)
TuyaEnumDatapointUpdateTrigger(Tuya *parent, uint8_t sensor_id)
void register_listener(uint8_t datapoint_id, const std::function< void(TuyaDatapoint)> &func)
TuyaIntDatapointUpdateTrigger(Tuya *parent, uint8_t sensor_id)
TuyaRawDatapointUpdateTrigger(Tuya *parent, uint8_t sensor_id)
TuyaStringDatapointUpdateTrigger(Tuya *parent, uint8_t sensor_id)
TuyaUIntDatapointUpdateTrigger(Tuya *parent, uint8_t sensor_id)
void check_expected_datapoint(const TuyaDatapoint &dp, TuyaDatapointType expected)
std::vector< uint8_t > value_raw