Battery level in spin
p00ndawg
Posts: 70
possible on the msr1?
I got a 12v battery connected to two hb-25's, and a 9v rc battery connected to the msr1.
Anyway I could check the level of either?
I got a 12v battery connected to two hb-25's, and a 9v rc battery connected to the msr1.
Anyway I could check the level of either?
Comments
Max volts on a 12V battery might be 14V. It would be very unlikely to go above 15V. So if you divide by five, 15V becomes 3V which is within specs for a propeller.
You can use 1% resistors for greater accuracy. Or measure the actual volts for two resistors and calibrate with that. Eg you could use 6.8k in series with 1.8k. That gives a ratio of 0.21 (1.8/1.8+6.8) which is pretty close. High resistor to the 12V. Measure it first before connecting a propeller or any other chip. Then you need to work out the maths - division of 0.21 and a 3.3V supply - you can have some real fun with the maths in software.
The above only works best if you have a regulated supply to the sensing chip, but that would be true for the propeller.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.smarthome.viviti.com/propeller