fix(temp-sens): return temperature_sensor function

The description says the function should return ESP_FAIL when parsing the sensor data fails
This commit is contained in:
juan-lopez-pragmafw
2025-04-24 12:25:49 -03:00
parent 465b159cd8
commit 2b4265bd39

View File

@ -301,7 +301,7 @@ esp_err_t temperature_sensor_get_celsius(temperature_sensor_handle_t tsens, floa
if (*out_celsius < TEMPERATURE_SENSOR_LL_MEASURE_MIN || *out_celsius > TEMPERATURE_SENSOR_LL_MEASURE_MAX) {
ESP_LOGE(TAG, "Exceeding temperature measure range.");
return ESP_ERR_INVALID_STATE;
return ESP_FAIL;
}
if (range_changed) {
s_update_tsens_attribute(tsens);