OpenMarine
Logging battery amps - Printable Version

+- OpenMarine (https://forum.openmarine.net)
+-- Forum: OpenPlotter (https://forum.openmarine.net/forumdisplay.php?fid=1)
+--- Forum: How I did it (https://forum.openmarine.net/forumdisplay.php?fid=6)
+--- Thread: Logging battery amps (/showthread.php?tid=1448)

Pages: 1 2 3 4 5


RE: Logging battery amps - e-sailing - 2019-05-08

Negative side should be also connected to ground. Load should be connected between negative side and -Vin. battery positiv to +Vin. (left picture).


RE: Logging battery amps - PaddyB - 2019-05-08

(2019-05-08, 10:16 AM)e-sailing Wrote: Negative side should be also connected to ground. Load should be connected between negative side and -Vin. battery positiv to +Vin. (left picture).
You only actually need the neg to ground if you want the measure the voltage as well, if you want to do that then load needs to be on the neg side as you say otherwise don't think it matters though I'll check that later to make sure. I prefer using ads1115 for voltage as you can measure differential voltage between to points so no risk of ground loops.

Sent from my SM-T813 using Tapatalk


RE: Logging battery amps - Saqqara - 2019-06-01

AliceJ21,

I am attempting to use the same size shunt and an ESP8266, might you share your code?


RE: Logging battery amps - svkatielee - 2019-06-18

I have been monitoring my batteries with an ESP8266 and ADS1115 to MQTT for a while, before I heard of openplotter.
My code is at https://github.com/svkatielee/ESP8266_Arduino_projects/tree/master/Boat_volt_mon4 if anyone is interested.


RE: Logging battery amps - ddelorme - 2020-01-31

I am having a bit of an issue with this PaddyB. I have a esp8266 and a ina219 my shunt on the low side is a 50 amp 75 mv.

I can connect and get values but i cant seem to get the right values.
I am using the TI INA219 hi-side i2c current/power monitor Library for Arduino.
It would help if i could see some code? Please


RE: Logging battery amps - PaddyB - 2020-02-01

(2020-01-31, 03:19 PM)ddelorme Wrote: I am having a bit of an issue with this PaddyB. I have a esp8266 and a ina219 my shunt on the low side is a 50 amp 75 mv.

I can connect and get values but i cant seem to get the right values.
I am using the TI INA219 hi-side i2c current/power monitor Library for Arduino.
It would help if i could see some code? Please

Can't find the old C++ code, I'm moving over to micropython for ESP32 stuff, but you will need to add a calibration factor, I just kept tweaking the calibration 'til it matched the battery monitor, or a dc clamp ammeter. Calibration will depend on the shunt.


RE: Logging battery amps - ddelorme - 2020-02-01

(2020-02-01, 11:38 AM)PaddyB Wrote:
(2020-01-31, 03:19 PM)ddelorme Wrote: I am having a bit of an issue with this PaddyB. I have a esp8266 and a ina219 my shunt on the low side is a 50 amp 75 mv.

I can connect and get values but i cant seem to get the right values.
I am using the TI INA219 hi-side i2c current/power monitor Library for Arduino.
It would help if i could see some code? Please

Can't find the old C++ code, I'm moving over to micropython for ESP32 stuff, but you will need to add a calibration factor, I just kept tweaking the calibration 'til it matched the battery monitor, or a dc clamp ammeter. Calibration will depend on the shunt.

LOL OK I sort of fix the problem in the same way...."I like it when the math makes sense. I am going to try on high side.. I want the bat voltage.



RE: Logging battery amps - ddelorme - 2020-02-09

Well I have it working. I calculated the Shunt 100 Amp 75 mV in parallel with the onboard shunt.
Had an issue with what i thought was a buck converter, that really was a dressed up lm317t it was eating .110 amps and was very warm... thanks amazon..
added a little .91 oled.
Struggled a bit with the small size of the terminal block on the ina219.. What size of wire should i run? I am using awg 18. to the shunt and awg 22 to the buck converter.
I was going to mount it within a .5m of the battery.


RE: Logging battery amps - affinite - 2020-11-14

I want to monitor battery current In/Out using an INA219 and my existing NASA BM1 100A/50mV external shunt.
Data to be fed into an ESP8266 running ESPEASY and then on to OpenPlotter via MQTT

I'm a little unclear on a couple of points...

1) Can you draw a heavy load through an external shunt in parallel with the onboard without blowing the onboard shunt?
If the load is drawing say 50A (e.g. battery charging) doesn't 50A get pulled through the (parallel) shunts thus destroying the (3.2A) on-board shunt?
I know the simple answer is to remove the on-board shunt but I note above that Paddy just "piggy-backed" the INA219 onto the external shunt - I'd like to understand why that didn't result in Blue smoke !

2) Unfortunately although INA219 is supported in ESPEASY it doesn't have a calibration option to support external shunts. 
Has anyone used ESPEASY with an INA219 and an external shunt and if so how did you calibrate the external shunt?
Did you simply use a formula in ESPEASY ? and if so do you have the formula for a 100A/50mV or a 50A/75mV shunt (yes I know I'm lazy)  Rolleyes

Thanks - Keep Safe

PS - THREAD ALSO POSTED IN "HOW DO I"


RE: Logging battery amps - PaddyB - 2020-11-14

(2020-11-14, 11:25 AM)affinite Wrote: 1) Can you draw a heavy load through an external shunt in parallel with the onboard without blowing the onboard shunt?
If the load is drawing say 50A (e.g. battery charging) doesn't 50A get pulled through the (parallel) shunts thus destroying the (3.2A) on-board shunt?
I know the simple answer is to remove the on-board shunt but I note above that Paddy just "piggy-backed" the INA219 onto the external shunt - I'd like to understand why that didn't result in Blue smoke !

Yes, it's fine on an external  shunt like 50mA/100A.
The sense resistor in the ina219 is massive compared to the external shunt so next to no current goes through it. It would be more 'proper' to remove the internal sense resister on the ina219 but I didn't bother (yet) , just calibrated by hand to measured current when setting up.