About temprature_sens_read();
-
- Posts: 76
- Joined: Tue Sep 12, 2017 11:25 am
About temprature_sens_read();
Hi guys, I'd like to know why this function (temprature_sens_read ();) it gives me back a value of 175 approx. with this https://es.aliexpress.com/item/ESP32-De ... 10563.html and a value of approx. 75. with a board bought earlier, both revision 1 and the software is the same.
It's just a curiosity, Greetings.
It's just a curiosity, Greetings.
-
- Posts: 9770
- Joined: Thu Nov 26, 2015 4:08 am
Re: About temprature_sens_read();
The internal temperature sensor unfortunately has a pretty big random offset that differs from chip to chip. It can be useful to keep track of temperature deltas, but you can't really infer an absolute temperature from then value. We may have some more accurate ways to get the temperature, but at this moment they're not implemented in esp-idf yet.
-
- Posts: 76
- Joined: Tue Sep 12, 2017 11:25 am
Re: About temprature_sens_read();
Thanks for the answer, ESP_Sprite. No problem, I only use this value to check the chip stability, I get the temperature and humidity with I2C sensors.
Greetings,
Greetings,
Re: About temprature_sens_read();
Hi,
what is the include file to use the "temprature_sens_read" function?
I have searched all the esp-idf folder components but I don't find it..
How to read the internal temperature sensor
Note: I'm not using ArduinoESP32.. I use ESP32 with esp-idf (latest available version)
Thanks.
what is the include file to use the "temprature_sens_read" function?
I have searched all the esp-idf folder components but I don't find it..
How to read the internal temperature sensor
Note: I'm not using ArduinoESP32.. I use ESP32 with esp-idf (latest available version)
Thanks.
Re: About temprature_sens_read();
Just add to your source
Code: Select all
extern uint8_t temprature_sens_read();
Re: About temprature_sens_read();
Thanks Loboris, that works.
Re: About temprature_sens_read();
I have checked that temperature differs a lot from chip-to-chip (20 celsius degree).
I have also checked that when WiFi is turned on the temperature increases but measuring with a termometer the behaviour seems to be quite linear so I can take care of it. In practice this is not a big problem..
Regarding the spread of temperature read from chip-chip, I would like to know if the internal sensor is affected by the ADC problem with Vref and non-linearity. If this is the case, the new version of ESP-IDF which includes Vref and 2-point calibration stored on EFUSE, the problem should be automatically solved.
Or, the temperature sensor itself differ from chip-to-chip (I guess they use a PTAT circuit or something like that)?
Thanks
I have also checked that when WiFi is turned on the temperature increases but measuring with a termometer the behaviour seems to be quite linear so I can take care of it. In practice this is not a big problem..
Regarding the spread of temperature read from chip-chip, I would like to know if the internal sensor is affected by the ADC problem with Vref and non-linearity. If this is the case, the new version of ESP-IDF which includes Vref and 2-point calibration stored on EFUSE, the problem should be automatically solved.
Or, the temperature sensor itself differ from chip-to-chip (I guess they use a PTAT circuit or something like that)?
Thanks
-
- Posts: 9770
- Joined: Thu Nov 26, 2015 4:08 am
Re: About temprature_sens_read();
No, the temperature sensor is an entirely different subsystem; ADC calibration will not improve its precision.
Re: About temprature_sens_read();
OK ESP_Sprite, Thank you.
We use internal sensor as monitor for LiPo battery included on the product in order to stop charging outside a temperature range. So we are not looking for a high accuracy..just to have a measure to avoid damages to battery.
Do you think there could be a chance to improve the temperature sensor system at least to have less spread from chip-to-chip?
As I wrote, if the temperature rise when WiFi is turned on it is not a big deal. But having different value for different chip will require a compensation during production of the product.
Thanks
We use internal sensor as monitor for LiPo battery included on the product in order to stop charging outside a temperature range. So we are not looking for a high accuracy..just to have a measure to avoid damages to battery.
Do you think there could be a chance to improve the temperature sensor system at least to have less spread from chip-to-chip?
As I wrote, if the temperature rise when WiFi is turned on it is not a big deal. But having different value for different chip will require a compensation during production of the product.
Thanks
-
- Posts: 9770
- Joined: Thu Nov 26, 2015 4:08 am
Re: About temprature_sens_read();
Not as of now. We have some ideas in relation to using the internal oscillator as a crude temperature sensor: its frequency deviates from the set frequency in a somewhat linear way over the temperature range, and we think that may have less variation than the 'real' temperature sensor. We haven't looked into that further yet, however.
Who is online
Users browsing this forum: No registered users and 61 guests