temp sensor

This commit is contained in:
2025-06-24 01:46:38 -04:00
parent 6627338135
commit 0094771290

View File

@@ -12,7 +12,7 @@ static const char *TAGt = "ESP-NOW_Transmitter";
EXP32-C3 Chip built-in temprature sensor
Read & display the temperature value
*/
static void temp_sensor_task (void *arg) {
void temp_sensor_task (void *arg) {
while (true) {
ESP_LOGI(TAGt, "Reading sensor temperature");
float tsens_value;
@@ -21,7 +21,7 @@ static void temp_sensor_task (void *arg) {
vTaskDelay(5000 / portTICK_PERIOD_MS);
}
}
static void chip_sensor_init () {
void chip_sensor_init () {
temp_sensor = NULL;
temperature_sensor_config_t temp_sensor_config = TEMPERATURE_SENSOR_CONFIG_DEFAULT(10, 50);
ESP_ERROR_CHECK(temperature_sensor_install(&temp_sensor_config, &temp_sensor));