diy solar

diy solar

Managing extra power and automating with PLCs

sunsurfer

Solar Addict
Joined
Sep 3, 2022
Messages
883
This is just a thought thread for ideas from the collective. I'm off-grid but I know this could apply to those with hybrid setups. I've been thinking about how I am going to automate. Everything I'm doing right now is manual so its time to come up with a system that I can repair/maintain. Right now, I'm living off extension cords. Even the well runs of a cord to fill a holding tank. I currently live in a small house (750sq ft) and I want to design my systems now so it can incorporate into the home when I build next spring.

Here is my base idea. Use PLCs to run EVERYTHING! The well could be relayed via PLC with float switches since its a soft start grundfoss but I'm going to run a second well from the creek for irrigation. It would be a 3 phase pump run off a VFD from the PLC. Pressure pump? Also VFD driven.

I'm doing hydraunic floor heat with a large 1500 gal holding tank. I will build a custom heat pump (ground source/water to water) and a PLC would be perfect for this! It could vary out put depending on batt state of charge or voltage. No problem at all.

I have worked in factories and PLCs are very robust and flexible. I really love the interface too! You can monitor/adjust multiple PLCs from any computer and make custom buttons/graphs etc....

Thoughts / ideas anyone? I was originally going the raspberry pi route but PLCs are so much more robust and functional.

A PLC could be used for running mini-splits. They could be setup to ramp up or down depending on the sun output.
 
I thought about incorporating automation into my house for various things. I had several things worked out in my mind that would have been fun and effective .... but I started wondering if anyone besides myself would be be able to understand and maintain the system.
In the end, I decided it may actually be a liability for anyone besides me and opted not to do it.

Doing more of a KISS method .... for example, instead of setting up my HVAC system with zone dampers and controlled use of outdoor air ... just set up some individual mini splits .... still not doing intelligent control of outdoor air, but having zoned temperature control.

If you do automate .... I'd do some really serious documentation that would allow someone else to understand and maintain the system.
 
I thought about incorporating automation into my house for various things. I had several things worked out in my mind that would have been fun and effective .... but I started wondering if anyone besides myself would be be able to understand and maintain the system.
In the end, I decided it may actually be a liability for anyone besides me and opted not to do it.

Doing more of a KISS method .... for example, instead of setting up my HVAC system with zone dampers and controlled use of outdoor air ... just set up some individual mini splits .... still not doing intelligent control of outdoor air, but having zoned temperature control.

If you do automate .... I'd do some really serious documentation that would allow someone else to understand and maintain the system.
I agree with the individual mini splits. I have two right now on my tiny home. I wish someone made a 2500 btu unit for small bedrooms. I may make my own micro mini-split for small areas. I'm building monolithic domes and air flow management is challenging but BTU load is very small.
 
I use BACnet controllers and not plc's but the concept is the same, the controllers I use just allow higher level programming than a plc.

But the issue of who maintains them if I get hit by a bus is a consideration I've chosen to deal with head on. My solution is/was to have several extra controllers on site with detailed instructions on how to push the backup file to them to make them clones of the original unit.

Considering they're off the shelf parts I also list all of the various models of controllers that would accept the programming files in case they need to go to eBay for yet another controller in case the backups burn in the same fire, etc.

I think I've done enough but I'll never know for sure since I'd be dead before this became an issue ?
 
I'm keeping things simple.
When I get to that point. I'll just be using the dry contacts on my AIO's to control various loads, at different SOC's.
 
I put a few things on wireless control 'smart plug-ins' (the ones that plug into an outlet, then you plug in the appliance) these are just too simple and run on my I-phone. The timer function turns on and off things like coffee pot, Shop HWT (programed to only run Mon-Fri, 8:00 - 17:00) I even rigged one up for the EV charger using a relay so I can switch on the EV charger power only if the shop loads are low, and the sun is high. Yeah I know pretty low-tech, not really automated beyond time settings, but it all works!, and I don't feel like it requires any documentation for someone to understand it.
 
I have 3 Hubitat automation controllers at our home, and another at my wife's shop. They control primarily lights and thermostats but I've recently connected a dry contact sensor to the generator start relay on my Victron Multiplus, which powers my "off-grid" buildings (that now actually have an AC line running to them from the house, because I wanted to make it easier to recharge the batteries if needed). When the Multiplus says the batteries are down to 30%, the dry contact sensor opens. That informs the Hubitat device, which turns on a switch to allow AC to flow to the Multiplus. When the batteries get to 80%, the Multiplus closes the dry contact sensor, which tells the Hubitat device, which turns off the switch and stops the AC flow. And before anyone asks, yes, I could also just start a generator, but then I have to maintain the thing. I'm getting lazy in my old age...

As others have noted, the problem with home automation is that you are almost always the ONLY person that knows how it works. Good documentation helps, but the reality is that if I get hit by a bus, my wife will have no earthly idea how to manage any of my automations. So, I tend to automate for convenience, but not function. For example, I tend to use thermostats that CAN talk to my automation system, but can function perfectly well as "plain", old programmable thermostats without my automation controller (Ecobee is a good example). I've also started using Switchbots that can turn a device off or on via automation, but if that's not present, the device still turns on with a push of its original button (because the Switchbot just "pushes the button"). For lighting, I've gone with Lutron Caseta switches. They work great with an automation system if you have their "Pro" bridge, but if either the bridge or the automation controller go down or are absent, the switches work just fine on their own. The problem with PLCs is that you need to know how to program them, and few people - including others in your household - have that knowledge.
 
One advantage I see with the PLC is that they use standard Industrial power supply -- 24 VDC. Thus you have a direct plug-in to your solar batteries (should be regulated to 24.0 volts). Proface has PLCs with the HMI, analog and digital inputs, and other features all built into a single unit (without having to add more "stuff"). Honeywell, Omron and others should have all the sensors (like the float sensor you mentioned) designed for the 24 volt power. Using PLC and industrial grade inputs and actuators will probably be more costly than other offerings, but quality is usually robust. Automation Direct (.com) has a decent catalog of lower-cost alternatives to the standard factory stuff.
 
That's a good point to make.

Commercial BACnet controllers and even evidently some PLC's will run off of 24vac or 24vdc.

That is surely an advantage over diy options like Arduino or Raspberry Pi type setups.
 
I personally think PLC are much easier than Raspi or Arduino to program. This may change as I dive deeper into this. I've done some work with them at a processing plant and I love how they work.

When it comes to data logging, it may be necessary for a PAC. I eventually would like one that monitors all my solar setup and do a few actions. Raspi or Arduino may be easier for this but I don't know yet.
 
I write software for PIC processors (initially with BASIC, and currently using "C"), Visual Studio (VB mostly), Nextion displays (a bastardized version of "C"), and have worked with PLCs. PLCs use "Ladder Logic" programming, which was rather unique to me. For someone who never delved into programming, Ladder Logic is much more intuitive than the other languages I've worked with.
 
I write software for PIC processors (initially with BASIC, and currently using "C"), Visual Studio (VB mostly), Nextion displays (a bastardized version of "C"), and have worked with PLCs. PLCs use "Ladder Logic" programming, which was rather unique to me. For someone who never delved into programming, Ladder Logic is much more intuitive than the other languages I've worked with.
I guess the idea was to replicate the old relay banks and how they where written out on paper as much as possible. I've worked with one old relay bank about 15 years ago. What a nightmare....

Its kinda hard to get use to the visual left to right line diagram but its starting to click with me. I really like how simple and robust they are. Of course, the newer more feature driven PLCs or what is called a PAC is a bit more of work.
 
I do PLC programming and industrial controls as my full time job.
A PLC or number of PLCs networked together can do many things. However they can be a lot more than what is required for home automation. And the costs can mount up, even if you use low cost PLCs.

One thing you should look into if you want to do home automation and tie in your Solar system is MQTT.
MQTT is an open network protocol that is now being implemented in many PLC and industrial IOT projects.

For instance:
I have an MQTT network running at home that consists of a Raspberry PI, which is running a Mosquitto MQTT broker, along with Node Red.
I have 5 different small remote boxes that are hooked up to vehicles and equipment that is near my house. That equipment has these small boxes attached to the battery. In the box is an ESP8266 board that runs as a MQTT client and communicates with the Raspberry pi via wifi.
The ESP8266 boards are less than $5.00 each. The 8266 transmits the current battery voltage to the MQTT broker every few minutes via wifi.
On my phone I can pull up a webpage that runs on the Raspberry pi and it will show me all of the battery voltages, ie their current state of charge.
The 8266s are programmed in the Arduino environment.

The Node Red programming that is in the Raspberry PI can make decisions based on the voltage levels and email me if a battery is low, flash a light, etc. I also have other tasks programmed in Node Red that can monitor and control other devices around my house.

The software is all free.

I have had the Raspberry Pi system up and running for about 2 years now. Its very reliable.

If the battery and inverter folks are smart they will start to incorporate MQTT into their devices via Ethernet and/or wifi. Its an open and free protocol and its easy to implement.
 
I do PLC programming and industrial controls as my full time job.
A PLC or number of PLCs networked together can do many things. However they can be a lot more than what is required for home automation. And the costs can mount up, even if you use low cost PLCs.

One thing you should look into if you want to do home automation and tie in your Solar system is MQTT.
MQTT is an open network protocol that is now being implemented in many PLC and industrial IOT projects.

For instance:
I have an MQTT network running at home that consists of a Raspberry PI, which is running a Mosquitto MQTT broker, along with Node Red.
I have 5 different small remote boxes that are hooked up to vehicles and equipment that is near my house. That equipment has these small boxes attached to the battery. In the box is an ESP8266 board that runs as a MQTT client and communicates with the Raspberry pi via wifi.
The ESP8266 boards are less than $5.00 each. The 8266 transmits the current battery voltage to the MQTT broker every few minutes via wifi.
On my phone I can pull up a webpage that runs on the Raspberry pi and it will show me all of the battery voltages, ie their current state of charge.
The 8266s are programmed in the Arduino environment.

The Node Red programming that is in the Raspberry PI can make decisions based on the voltage levels and email me if a battery is low, flash a light, etc. I also have other tasks programmed in Node Red that can monitor and control other devices around my house.

The software is all free.

I have had the Raspberry Pi system up and running for about 2 years now. Its very reliable.

If the battery and inverter folks are smart they will start to incorporate MQTT into their devices via Ethernet and/or wifi. Its an open and free protocol and its easy to implement.

I just realized that Solar Assistant uses MQTT. I believe Solar Assistant was an offshoot of Home Assistant. I have looked at Home Assistant a few times and I didn't like it. It hides what it is doing to make it appear to be "friendly". IMO, that is a mistake. At least from a programmer's perspective.
I haven't used Solar Assistant but if they did what Home Assistant did, you might be better off "rolling your own" and starting with the basics of Node-Red and the Mosquitto MQTT broker. There are a lot of You tube videos on how to tie things together with MQTT and Node Red. Start simple and add as desired.
 
Back
Top