7static const char *
const TAG =
"lm75b";
10 ESP_LOGCONFIG(TAG,
"LM75B:");
13 ESP_LOGE(TAG,
"Setting up LM75B failed!");
15 LOG_UPDATE_INTERVAL(
this);
16 LOG_SENSOR(
" ",
"Temperature",
this);
27 int16_t raw_temperature = (buff[0] << 8) | buff[1];
29 raw_temperature >>= 5;
void status_set_warning()
bool status_has_warning() const
void status_clear_warning()
ErrorCode read_register(uint8_t a_register, uint8_t *data, size_t len)
reads an array of bytes from a specific register in the I²C device
void dump_config() override
void publish_state(float state)
Publish a new state to the front-end.
@ ERROR_OK
No error found during execution of method.