News:

we are back up and running again!

Main Menu

another automation scheme

Started by mobile_bob, September 29, 2009, 09:26:21 AM

Previous topic - Next topic

mobile_bob

i decided to write up an overview of my automation system

because i have the trigenerator that is basically a changfa 195, direct driving an st head, belt driving twin alternators
one of which is a 160amp 14volt 110-555jho and the other is to be a 7.5kwatt 57.6volt (48v nominal), and a sanden
rotary A/C compressor, the engine cannot pull all driven components at full load so i need a level of automation or control.

in testing the results have proven that i need to load the engine to full capacity (approx 7kwatts) to get max fuel economy
and the highest heat quality for recovery of the exchangers.

i am using what is known as a master/slave architecture

the master will monitor all loads, electrical, heat, refrigeration etc. and also monitor all power production i have available
such as solar, wind, the trigen, and the battery bank/inverter system
it will make the decision which loads or combination of loads will be serviced by what power source, and then put out a start or come
on line command to a slave controller

a typical slave would be as follows, one that takes control of autostarting the trigen, and controlling each of its driven components
in a manner that keeps the load on the engine close to full capacity (after a suitable warm up period of course).

other slaves will be used to control things like battery 3 step charging, heat/cooling loads and the thermal storage system, major electrical
loads that can be scheduled, refrigeration, water pump/ water heating etc.

for micro controllers i settle on the parallax BS2, which is one of the most expensive in the way of hardware out there at
about 50 bucks each, but they are very well engineered, easy as can be to program and they have a support system unparalleled
in the game for the DIY'er, as well as an active forum.

the bs2 micro needs a board to plug into so i decided on a cubloc product that is a small daughterboard and comes with all the needed
components to interface the microcontroller to power, programming and I/O , its price is very good at 5 bucks although it requires soldering as a kit,, easy to put together with a 15watt iron.

finally to drive the outside world i needed a relay board, and settled on a 8 relay board from a guy on ebay in thailand
which worked out to something like 20 bucks a board, the boards have 8 relays that can control 120/240 loads at about 10amps
which is enough to power small loads and certainly enough to power larger relays for heavy loads.

to house this system, i chose a rack mounted drive case, it hold 8 bays
into those bays i installed 8 removable drive caddy's and the caddy's have just enough room internally
to hold the micro and its daughterboard, and the 8relay board, so the master occupies on bay
and i have up to 7 slave bays.

not a cheap solution, but certainly a easier solution that does not require a phd in controller programming
the total cost of the system will be about 500-600bucks.

it will be a multiprocessor that is truely capable of parallel processing (able to do many things at the same time)
whereas a single processor could probably be beaten into submission and do every function that i want to have done
it could only to one thing at a time effectively, before it moves on to the next chore. (there are ways around this
but it would require about 50x more coding and a much smarter fellow than i am)

there will be no fancy touch screen, i plan on using a rack mount lcd screen that is connected to a rack mount puter
that is used to alter the programming of the controllers as needed, and finally have a screen that will monitor the system
and give me a few important readings, maybe later some data logging and other stuff.

if i live long enough that is

at this point i have my master controller working, i also have the slave for the trigen
that can do the full unattended autostart, from glowplug preheat, starter control, low idle warm up, high idle AC power production
high and low speed charging, and A/C or refrigeration and a few other things related to these driven components, such as switchgear
and valveing of refrigerant to either thermal storage or refrigeration or reverse for heat pump,

the capabilities are incredible, certainly not KISS, likely to have some issues to sort out, and maybe even ongoing issues
that take some human intervention, but
if i keep manual override ready, i can always fall back on human control if need be and have a system that is no harder to control
than most any other.

if i can find where i filed my schematics i will post the pics, they are in jpeg format so should work here.

bob g

BruceM

#1
Bob,
That sounds like a good design, and you processor and interface product selection shows a lot of thought.  

I'll try to do the same for my system.  I'm a EE(CS) guy with lots of microprocessor experience, both hardware and software.  After a bout with encephalitis, and ongoing MS,  I strive for the simplest possible design that can meet my needs.  

I needed remote control and monitoring of my 6/1. It's about 350 feet from my shop, over a hill.  The location was selected for noise abatement, though not needed for the Listeroid.   I have air available at all times as the 6/1 does dual duty as air compressor (feeding a 500 gallon air storage tank near my shop). I had already developed an air motor starter, pneumatic valve lifter and rack closer.

I had previously used a PIC processor preloaded with a Basic Language interpreter for another project. The company who developed this is Revolution Education in England, and they now have quite a line of these "PICAXE" processors.  There is no development equipment required if you have a PC with Windows and a serial port.  For about $10 each, I got a couple of the 40X1 chips. They give you about 32 useable input, output and analog pins.  I used a breadboard with processor from PHAnderson.com for my "programming socket" and for testing my software, using a bunch of LEDs on the outputs and jumpers to simulate inputs. He now sells one that's USB plug in for $30 including the 40x1.

All my outputs were either 12V relays or 12V solenoid valves for air cylinders. So after not finding a commercial product that had solid state relays for a reasonable price, I decided to do my own.  I used  logic level gated MOSFETs which I got for about $0.65 each.  These can be directly connected to the output pins of the Picaxe processor, and can handle over 20 amps each.  

The inputs from vibration sensor, oil level (high/low), over temperature snap switch, and hall effect gear tooth sensor (senses spokes on the flywheel for rpm) are all 5 volt logic or pull downs only (open collector) and require no interface to the processor except a pull up resistor.

The conduit run to the shop goes through another insulated shed which houses the battery bank and controller (another Picaxe project I'm working on now). The total run is about 400 plus feet, in the same metal conduit with the AC and DC power.  I used a balanced, 10ma 300 baud opto-isolated current loop for the serial link to the shop.  This consists of an opto transistor on both ends, and some relays. (A few bucks worth of parts).  

In the shop, another Picaxe 40x1 interfaces to a simple LED and switch box.  It has a very simple program; it waits for an LED status data packet from the Lister controller, and then sends the current switch positions.  

The Lister control processor has a real time processing loop of approximately 1 second. Based on the current status, it checks on the engine fault sensors, checks the rpm, checks the switch positions from the remote control processor to see if any changes are made (generator, compressor on/off, engine on/off).
Most of that one second is spent on timing the rpm, waiting on a single command.  While this time delay could be eliminated by turning the rpm into an analog signal with some additional hardware (op amp and some "glue"), I felt that a one second response time was perfectly acceptable.

This system had been operational for over 2 years now.  It's saved a lot of walking, and has saved my 6/1 from a low oil failure once.  I've only had one failure- a couple resistors and one opto isolator got fried from lighting.

The next step is to complete the 120VDC battery bank controller (BBC), which will monitor battery SOC and request AC power from the Lister controller.  The
BBC controller is also the AC charge controller; the AC charger is a novel design which uses a toroidal linear supply, with output regulated by zero cross swtiched capacitors before the inductive filter, as well as 2 levels of tranformer winding selection.  The BBC has current sensing for PV, wind, and AC charger as well as load sensing.  PV output regulation is also done by the BBC; charge current is reduced as the bank approaches charge completion.  Each 12V battery in the 10 battery string has it's own multilevel analog voltage monitor/shunt, so that frequent equalization charging is not required.  This approach I stole from ManzanitaPower.com, who developed it for electric vehicles. Of the total BBC project, just one more interface board needs to be done, then it's time for assembly and testing.

I think I have scanned but hand drawn schematics and of course the basic source code, if anyone has a serious need for it.

Best Wishes,
Bruce









BruceM

Thanks Jens. 

I forgot to mention:
My epilepsy is aggravated by typical digital EMI, so the processor(s) are located in a separate shielded enclosure (die cast aluminum box), with 5K ohm resistors on all lines leading out (and multistage L filters on power) followed by a pi filter DB connector(s).  This means all outputs must be buffered.

Because of the filtering, and subsequent buffering, the total amount of wiring and circuitry is much greater than would normally be required.  No one but me would need that.

I now have a PCB for the shielded processor module (40x1 or 40x2), which is being used in the battery bank controller (BBC).  ExpressPCB makes using PCBs cheap, and saves a tremendous amount of soldering iron time as well as wiring errors.

So it looks like I'm still the world leader in microprocessor automated Listeroids.  Oh, the glory!   ;)

Best Wishes,
Bruce

Chris

I just finished reading this post. Most of it is way over my head. I am an engineer, but CE, not EE.

What are you guys using to sensor Low oil? Pressure on a Lister is not there. Its an open system, no pressure. I have a Lister VA so temp sensing is not a problem, but I would really love to know what my oil level is doing!

BruceM

#4
I use a homemade oil level sight tube, which has a tiny magnet in a plastic float.  It solves two problems- makes it easy to visually check oil level, and provides the emergency shut down signal for my automation.

The float is a piece of milk tubing (HDPE) with the ends melted shut. The magnet is in the bottom end. The oil level is easier to see than shown, with black oil.  The copper pipe sleeve to hold the pipe straight wasn't needed in the final install.

Two magnetic reed relays (about $3 each at Digikey) are zip tied to the sight tube, and provide high/low oil signal to my Picaxe controller.   It has saved my engine once already.

I don't use the oil drain, I use a homemade vacuum oil sucker, taking off the big door to change the cotton rags in my gravity oil filter box when changing oil.


potter

Does the vacuum on the crankcase effect the reading ???.

BruceM

No, the vacuum doesn't affect the float in the visual sight tube, because as shown, it is not connected to the room air, but instead I have tapped a hole into the top of the crankcase, and the tube is sealed via a right angle hose barb back to the crankcase.  So both ends of the tube see the same vacuum. 

My inside the door gravity oil filter does affect the oil level, but by adjusting the low oil level reed relay for the cold running level (lowest as more oil is in the filter), it has worked out OK.  Low oil is then first detected only after starting the engine,  not before, when there is more oil in the crank.  I could add some logic and another reed relay to catch cold low oil before starting, but don't feel motivated enough to do it. But if I were starting over, I think the cold starting oil level would be the nicest, operator friendly way to go.  Then when you flipped the switch for a start, you'd get the low oil error code immediately.




potter

Thanks had not noticed the top end ::).

Chris

Bruce,

Thanks for the information. I need to sleep on it. May question first off would be, because I know what happens if I forget to close my oil filling hatch, Old style lister, VA, is that oil shoots out of that hole and makes a BIG mess. Yep I've done that once or twice in 40 years, and will probably do it a couple more times. So would not the oil level in the tube be pulsing all over the place, or does the tap from the top of the tube back to the crank case but a big damper on all of this and settle the oil down?

Thanks,

Chris

BruceM

#9
There is absolutely no rapid movement of the oil level with the setup as shown, with the inlet via drain plug. It just tracks the average oil depth.

If you want to keep the drain plug, you'd have to do another hole in the crankcase, very low. You can't use a Tee on the drain plug location there, it gets an air bubble and screws things up...I tried.