Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Internal voltage level controll #193

Open
RA3TOX opened this issue Nov 17, 2024 · 17 comments
Open

Internal voltage level controll #193

RA3TOX opened this issue Nov 17, 2024 · 17 comments

Comments

@RA3TOX
Copy link

RA3TOX commented Nov 17, 2024

Tell me, how is the internal voltage level controlled?
I enabled the monitoring option, but it goes into sleep mode. The internal voltage shows 0.

My board is LILYGO®TTGO LoRa32 V2.1_1,6 433 МГц and is powered by a 3.6 V battery through a standard connector.
Now I have no access to the device and cannot reprogram it.

What should I do?

@richonguzman
Copy link
Owner

pin35 is the internal battery monitoring pin.

you should validate that the battery is read correctly on the board before you put the monitoring process.

if it works Fine, the monitoring process should validate that the voltage is higher than the SleepVoltage and if lower it will sleep

so first: check that the board reads the battery voltage

@RA3TOX
Copy link
Author

RA3TOX commented Nov 18, 2024

How to properly connect voltage to contact 35?

@RA3TOX
Copy link
Author

RA3TOX commented Nov 18, 2024

pinout_ttgo-int-akkum
Is this correct?
What are the resistor values?

@S57PNX
Copy link
Contributor

S57PNX commented Nov 18, 2024

You don't need to do anything. The internal voltage is internally connected on the board, the voltage divider is already on the board and the measurement should work without any modifications.

As @richonguzman says, disable voltage monitoring for now for easier troubleshooting until you get a valid voltage reading. Enable "Send internal voltage" and observe if the screen shows 3.6V or similar. If it shows 0V, you have two options:

a) you didn't flash the correct firmware for this board and the power management chip is not detected
b) your board is broken. Measure the voltage between PIN 35 and GND with a voltmeter and see if the voltage is non-zero.

The external voltage divider is only for external voltage measurements via pin 34.

@RA3TOX
Copy link
Author

RA3TOX commented Nov 18, 2024

At pin 35 this function does not work ;(
monitoring_akk

@S57PNX
Copy link
Contributor

S57PNX commented Nov 18, 2024

Try to monitor USB during boot (using VS Code) and see if the power management chip is detected correctly. (my point a) above).,

@S57PNX
Copy link
Contributor

S57PNX commented Nov 18, 2024

I just took a fresh Lora32 2.1 out of the box, flashed it with Lora32 2.1/1.6.1 firmware and enabled "Send internal Voltage". I can see the voltage on screen and on pin35 (lowered by the onboard internal voltage divider).

IMG_2183

IMG_2184

@RA3TOX
Copy link
Author

RA3TOX commented Nov 18, 2024

@S57PNX What is your firmware date?

@S57PNX
Copy link
Contributor

S57PNX commented Nov 18, 2024

For this example I used the latest firmware, 2024.11.6. But any other firmware from earlier this year should work, the voltage measurement code is old and hasn't changed in a long time.

@RA3TOX
Copy link
Author

RA3TOX commented Nov 18, 2024

@S57PNX and still this function does not work correctly ...
How to set the correct voltage?

@S57PNX
Copy link
Contributor

S57PNX commented Nov 18, 2024

If you measure 0V on pin35, it is not a matter of firmware. It means that your board is somehow broken. Try with another board if you have it.

image

@RA3TOX
Copy link
Author

RA3TOX commented Nov 18, 2024

This is not the best solution.
It seems we will have to give up this option :(

@richonguzman
Copy link
Owner

This is not the best solution. It seems we will have to give up this option :(

we have to stop and make this post a little more clear:

@RA3TOX , can you please confirm:

  1. your board is Lora32V2.1 (or V1.6.1)?

if (1) is YES, then..

  1. when powering the board (with power switch in ON position) does IO35 read any voltage?

  2. if (2) is YES, does it read the right voltage? (voltage read * 2 should be almost the same as battery real readings)

  3. if all from before is YES you should be able to send battery voltage with good values

@RA3TOX
Copy link
Author

RA3TOX commented Nov 18, 2024

@richonguzman
My board is Lora32V2.1 (or V1.6.1)
When I powering the board IO35 read 0 Volt
My firmware from 2024.10.25
image

@richonguzman
Copy link
Owner

it seems your board is bad.. as it should read battery voltage on pin35 with battery connected.

@RA3TOX
Copy link
Author

RA3TOX commented Nov 18, 2024

@richonguzman

your board is bad..

Possibly.
But @S57PNX also shows incorrect voltage.

@richonguzman
Copy link
Owner

@richonguzman

your board is bad..

Possibly. But @S57PNX also shows incorrect voltage.

this is reading the pin directly (and you have to multiply by two and add a minor correction for the board to get the real value)

the lora32v2.1 board has internal 1/2 voltage divider with two 100K resistors.

So @S57PNX is having a correct reading of the voltage it enters pin35

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants