I've started putting together the sensors for my solar panel monitoring project.
So far, I have the voltage divider for the battery, shown in the diagram.
I discovered that in order for the voltage divider to work, the battery negative terminal must be connected to the Arduino ground... Probably a "duh" moment for the rest of you, but that was last night's discovery.
So if this is the case, if I also have a voltage divider for the solar panel, the panel's negative terminal will also need to be connected to the Arduino ground.
Question 1) Is this correct, taking into account that there is also a charge controller connected between the battery and solar panel?
Not having done this before, I'm worried that the whole thing might go BOOM if I connect the battery and solar panel terminals to the Arduino ground, while also having the battery and solar panel connected to the charge controller.
Question 2) For the ACS712 breakout boards, it seems it should be connected to the circuit by a "tail" (not pass-through like the atto-pilot) to the current being measured. Is this correct?
The horribly drawn diagram attached should help make my questions clearer.
Thanks in advance.
P.S. I realize the resistor divider ratio is a little large for these voltages. I'm planning on reducing the ratio to obtain higher resolution measurements. Its currently about 0.05 volt per ADC value. Even just 0.025 would be nice.
Well, I think I can get a little further towards answering my own question about grounds, by measuring resistance between:
The solar panel negative terminal and the battery negative terminal. If its almost 0, I have already effectively grounded everything (panel, battery, solar controller).
But, if the component's negative terminals are somehow separated, I will probably do something nasty by joining them all together.
Yes, that's pretty much it - don't join the negatives of panel and battery unless the charge controller does.
If they are not at the same potential you'll have to find out which is most negative, use that to common with Arduino ground, and measure the other one's voltage with another analog pin (and possibly divider).
Its fairly likely the negatives are common though.
Those ACS712's are not looking right, current measurements are generally done in series on one leg of the supply wiring, not in parallel as your diagram would indicate.
Connect your solar system together and place a wire from ground of the Arduino to the battery negative lead and connect all of your measurement return leads to that point. Insert the current sensors in the positive leads of the power supplies (Battery and solar panel) connect the sensor output common leads separately to the SAME point on the Arduino. This forces a star topology that prevents ground potential differences caused by load and charge currents from affecting the measurements as a whole.
MarkT:
Yes, that's pretty much it - don't join the negatives of panel and battery unless the charge controller does.
If they are not at the same potential you'll have to find out which is most negative, use that to common with Arduino ground, and measure the other one's voltage with another analog pin (and possibly divider).
Its fairly likely the negatives are common though.
Excellent. Thanks for the comments - especially about what to do if they are not at the same potential.
Docedison:
Those ACS712's are not looking right, current measurements are generally done in series on one leg of the supply wiring, not in parallel as your diagram would indicate.
Connect your solar system together and place a wire from ground of the Arduino to the battery negative lead and connect all of your measurement return leads to that point. Insert the current sensors in the positive leads of the power supplies (Battery and solar panel) connect the sensor output common leads separately to the SAME point on the Arduino. This forces a star topology that prevents ground potential differences caused by load and charge currents from affecting the measurements as a whole.
Doc
Thanks for these excellent comments too. I was starting to wonder about the current sensor connections! Good advice about grounding. Thanks!