System Info Device: Internal Vcc measurement

Moderators: grovkillen, Stuntteam, TD-er

Post Reply
Message
Author
fm-maniac
Normal user
Posts: 22
Joined: 07 Nov 2021, 12:39
Location: Germany

System Info Device: Internal Vcc measurement

#1 Post by fm-maniac » 07 Nov 2021, 12:49

I flashed the latest Vcc Build: ESP_Easy_mega_20211005_normal_ESP8266_4M1M_VCC

and set up the system Info device to get the internal Vcc. The readout is 2.96 (Volts I assume). But I measure 3.26V on the ESP8266 Node 3 Board.

What am I doing wrong?

User avatar
Ath
Normal user
Posts: 3419
Joined: 10 Jun 2018, 12:06
Location: NL

Re: System Info Device: Internal Vcc measurement

#2 Post by Ath » 07 Nov 2021, 13:09

This can be caused by the (un)accuracy of the A/D converter. Not sure what the tolerance is supposed to be, but it's a factor that you can probably fix using a formula.
When monitoring f.e. a battery as the powersource for the ESP you will need to resort to other means, as the measurement for internal VCC is done at the output-side of the 3v3 regulator on board, so once it gets really low, it will usually be too late to respond anyway.
/Ton (PayPal.me)

TD-er
Core team member
Posts: 8644
Joined: 01 Sep 2017, 22:13
Location: the Netherlands
Contact:

Re: System Info Device: Internal Vcc measurement

#3 Post by TD-er » 07 Nov 2021, 14:05

I don't know if the Vcc measurements depend on what is connected to the A0 pin of the ESP.
Is there something connected to this pin?

Also when is the measurement done? Right at boot, or later?

fm-maniac
Normal user
Posts: 22
Joined: 07 Nov 2021, 12:39
Location: Germany

Re: System Info Device: Internal Vcc measurement

#4 Post by fm-maniac » 07 Nov 2021, 14:43

A0 is open on the Node MCU v3. So It's the voltage divider 220k/100k that's already on the bord. So finally 100k PD to GND.

Measurement is taken every 60s.

fm-maniac
Normal user
Posts: 22
Joined: 07 Nov 2021, 12:39
Location: Germany

Re: System Info Device: Internal Vcc measurement

#5 Post by fm-maniac » 07 Nov 2021, 14:51

Ath wrote: 07 Nov 2021, 13:09 This can be caused by the (un)accuracy of the A/D converter. Not sure what the tolerance is supposed to be, but it's a factor that you can probably fix using a formula.
When monitoring f.e. a battery as the powersource for the ESP you will need to resort to other means, as the measurement for internal VCC is done at the output-side of the 3v3 regulator on board, so once it gets really low, it will usually be too late to respond anyway.
It's fully clear that I have to measure the external battery voltage to predict it's charge status.

It's a 10Bit ADC so max. sampling error is 1V/(2^10-1) = 977µV. The inaccuracy can't be the cause.

TD-er
Core team member
Posts: 8644
Joined: 01 Sep 2017, 22:13
Location: the Netherlands
Contact:

Re: System Info Device: Internal Vcc measurement

#6 Post by TD-er » 07 Nov 2021, 14:58

I just did a quick search online and just about any source online suggests you need to keep the A0 line floating with the VCC mode enabled.
However, on a board like the NodeMCU, those resistors are already present, so you cannot easily remove them.
I think you need to compensate for the existing resistors.

This was also mentioned here: viewtopic.php?p=9758#p9758
The suggested factor of 1.1 does seem to comply with your readings.

fm-maniac
Normal user
Posts: 22
Joined: 07 Nov 2021, 12:39
Location: Germany

Re: System Info Device: Internal Vcc measurement

#7 Post by fm-maniac » 07 Nov 2021, 15:50

Thanks TD-er!

So the reason is in the unknown ESP8266 internals together with the external 100k PD on the Node MCU. I thought I did something wrong.

In between I flashed a regular binary w/o internal Vcc and hooked A0 up to an external voltage. The measurement I get is correct as expected.

Post Reply

Who is online

Users browsing this forum: No registered users and 53 guests