Measuring battery
-
Hi. I'm having some troubles when i try to read the voltage off my arduino batterys,
The problem it's not the code, my problem is the wire connection... Do i connect the battery (+) to A0 pin only or do i have the connect the battery (+) to the A0 pin and the VCC pin on the arduino pro mini ???
If i connect the arduino over USB to see the serial monitor i can see the voltage on 4.8V to 5V.
But when i try to connect to my battery the i get dead antenna.
-
Hello @mrc-core
You can use the Vcc.h library, and mesure the voltage without any wire
-
@carmelo42
How does this work when using a booster?
-
@meanmrgreen - No, since the booster will output a steady voltage and thats what read in that library. If you have a booster I always use resistors and connect it to A0 (https://www.mysensors.org/build/battery). Another way is to lower BOD by burning new fuses and bootloader but this is more advanced.
-
@sundberg84
Will look into that, i have a UNO lying around aswell so prehaps ill experiment with the bootloader burning eventually.
Suggested Topics
-
Welcome
Announcements • • hek