Arduino Load Control
LPhillippi
Registered Users Posts: 4 ✭
I created an Arduino project to control loads attached to my 12v off-grid solar system. Project source code is at the following url for anybody that is interested:
http://forum.arduino.cc/index.php?topic=236980.0
My objective was to control the inverter that has an air conditioner attached to it to keep my RV cool while I'm not there. Turn on the AC when the batteries are fully charged (13.6v) and turn it off when the batteries are somewhere below resting voltage(12.6v). I'm turning the inverter off below 12.3v which gives it plenty of time to charge up to 12.6v at the end of the day.
A Low Voltage Disconnect device wouldn’t work to control this type of behavior because the Xantrex inverter doesn't start back up when power is re-applied to disconnect circuit. The inverter is turned on by pressing and holding a button until it powers up. This is the behavior I’m emulating with the Arduino. I soldered wires to the remote start button and connected them to an Arduino relay board. The inverter has a USB power output which I used to detect when it responds to the emulated button press. The relay returns to NC when the USB voltage change is detected.
Additional relays are programmed to control a swamp cooler pump and a fan that is used to cool the charge controller and inverter.
The project uses a 3.2" TFT LCD screen that isn't required for core functionality. It displays current voltages, load states, temp and humidity values. It can also be used to adjust voltage, temp and humidity settings.
Arduino information and the IDE is here: http://arduino.cc/
http://forum.arduino.cc/index.php?topic=236980.0
My objective was to control the inverter that has an air conditioner attached to it to keep my RV cool while I'm not there. Turn on the AC when the batteries are fully charged (13.6v) and turn it off when the batteries are somewhere below resting voltage(12.6v). I'm turning the inverter off below 12.3v which gives it plenty of time to charge up to 12.6v at the end of the day.
A Low Voltage Disconnect device wouldn’t work to control this type of behavior because the Xantrex inverter doesn't start back up when power is re-applied to disconnect circuit. The inverter is turned on by pressing and holding a button until it powers up. This is the behavior I’m emulating with the Arduino. I soldered wires to the remote start button and connected them to an Arduino relay board. The inverter has a USB power output which I used to detect when it responds to the emulated button press. The relay returns to NC when the USB voltage change is detected.
Additional relays are programmed to control a swamp cooler pump and a fan that is used to cool the charge controller and inverter.
The project uses a 3.2" TFT LCD screen that isn't required for core functionality. It displays current voltages, load states, temp and humidity values. It can also be used to adjust voltage, temp and humidity settings.
Arduino information and the IDE is here: http://arduino.cc/
Comments
-
Re: Arduino Load Control
I like it and need to do something similar myself.
I understand that the state of charge of a lead acid battery is hard to determine. Ie, measuring the voltage while under load and after a long rest (the usual assumption) leads to different results. For example, with a brief, heavy load, the voltage of a fully charged battery might drop to 12.0V, but this doesn't mean that that battery needs charging. Are there good solutions to this? Ie, how can one separate low charge from low voltage created by load?I am available for custom hardware/firmware development
-
Re: Arduino Load Control
SOC is best measured using a ah counting based algo, which means having a shunt and associated intregration logic. There are some factors that influence ah capacity and efficiency such as temperature, current, soc etc, and there doenst seem to be much open info about modelling those around.
The beauty of a uP project like this is than you can also measure things like potential solar harvest, so determining *how much* spare power there is.1.8kWp CSUN, 10kWh AGM, Midnite Classic 150, Outback VFX3024E,
http://zoneblue.org/cms/page.php?view=off-grid-solar -
Re: Arduino Load Control
Here is a generic set of drawings of what a battery voltage looks like across currents (charging/discharging) vs state of charge--You can also throw temperature in there too--if you want a bit more confusion.New poster "leaf" has a really nice set of charts that compare battery voltage against different rates of discharging and charging (as well as resting voltage readings).
[note charts are from: I believe those charts are from Home Power #36, August- September 1993. Lead-Acid Battery State of Charge vs. Voltage ©1993 Richard Perez.
Here is a link: http://www.scubaengineer.com/documen...ing_graphs.pdf
vtMaps]
I don't quite a agree with the resting voltage line (I think the voltage is a bit low)--But it shows how to estimate a battery's state of charge while operating.
Note, where the charts "flatten out"--the room for error estimating state of charge is pretty high.
-Bill
-BillNear San Francisco California: 3.5kWatt Grid Tied Solar power system+small backup genset -
Re: Arduino Load Control
Thanks. Looking into it more, I'm tempted to use Lithium batteries. Especially with the high temperatures my situation has.I am available for custom hardware/firmware development
-
Re: Arduino Load Control
What kind of charge controller are you using? You may be able to get a "charged" indicator from it in some way.
For the fancy ones (such as my Outback FM-80) you could program an auxiliary relay to come on when it hits absorb or float, or perhaps even communicate with it.
My Morningstar MPPT controller has three LEDs for charge state, could wait for the "full" LED to be on.
Even some simpler controllers may give a usable output - I have a couple small Morningstar controllers that only have a single LED. Off at night, steady-on for "bulk", flashing for absorb/float. Since it doesn't distinguish between absorb and float, you'd have to time it - perhaps start a timer when it begins flashing and switch on loads after an hour or two.
If you have enough solar panels to run the inverter AC directly, it may be desirable to add a DC current sensor to monitor amps in/out of the battery. (Or pull that info from the CC or BMS if you can communicate to it.) You'll know roughly what your AC draws, and can make sure you don't draw down the battery too much.
I do this - though all my kit is communicating / networked together - with a mini-split in the back room. Once the system drops to float the mini-split is powered and it controls to its own thermostat. If the sky clouds up (amps-in drops below amps-out) I let it run for 15 minutes in case it's temporary, then shut off the AC. In my case it's an old-style compressor so about 1500W running. That's right at the limit of my solar array, with the other usual household loads, so any reduction in power (overcast, blowing dust, dirty panels) starts using battery power. I'd love to get an inverter AC unit that I could control to run higher/lower to match available surplus power, but can't justify the expense since the current unit works well enough. -
Re: Arduino Load Controlit may be desirable to add a DC current sensor to monitor amps in/out of the battery.
Is there an off-the-shelf or easy to implement (say Arduino + source code) SOC monitor that will turn my inverter off when state of charge gets too low? I don't mind opening the inverter and wiring a relay to the on/off switch.I am available for custom hardware/firmware development
-
Re: Arduino Load Control
I finally got around to implementing such a controller. To recap, my problems were a) the inverter would allow battery voltage/SOC to drop too far before shutting down (bad for the batteries) and b) once it turned off, it would never come back on. So now an arduino monitors battery voltage and turns the inverter off at the right voltage and then back on when it rises.
The application is dehumidification of a shipping container.I am available for custom hardware/firmware development
Categories
- All Categories
- 222 Forum & Website
- 130 Solar Forum News and Announcements
- 1.3K Solar News, Reviews, & Product Announcements
- 191 Solar Information links & sources, event announcements
- 887 Solar Product Reviews & Opinions
- 254 Solar Skeptics, Hype, & Scams Corner
- 22.3K Solar Electric Power, Wind Power & Balance of System
- 3.5K General Solar Power Topics
- 6.7K Solar Beginners Corner
- 1K PV Installers Forum - NEC, Wiring, Installation
- 2K Advanced Solar Electric Technical Forum
- 5.5K Off Grid Solar & Battery Systems
- 424 Caravan, Recreational Vehicle, and Marine Power Systems
- 1.1K Grid Tie and Grid Interactive Systems
- 651 Solar Water Pumping
- 815 Wind Power Generation
- 621 Energy Use & Conservation
- 608 Discussion Forums/Café
- 302 In the Weeds--Member's Choice
- 74 Construction
- 124 New Battery Technologies
- 108 Old Battery Tech Discussions
- 3.8K Solar News - Automatic Feed
- 3.8K Solar Energy News RSS Feed