Author Topic: Power Outages and Autostart  (Read 14921 times)

DaveW

  • Full Member
  • ***
  • Posts: 175
    • View Profile
Power Outages and Autostart
« on: March 31, 2007, 09:35:12 PM »
  I hate it when my house is the only one with lights on the block.   ;)  High winds, pouring rain and lightning galore this morning resulted in a 6 1/2 hour outage.  The trouble is, I'm getting old and lazy.  It is only fifty feet to the generator from the back door, but when the only light I have is lightning and the rain is falling by the bucket full and tree branches are falling I start to think about that semi automatic start circuit that has been put off for too long.
  I don't want the whole automatic scene, just a way to start the generator from the back porch.  Then a swing by the panels and and hit the transfer switch and head back to bed.  But I hate the thought of remote starting without monitoring oil pressure, temperature, RPM, voltage, all the stuff that the eye and ear can take in at a glance.  So it is not yet finished, but getting closer.
  This morning (early) while ducking  at the lightning flashes I started thinking about a toy I built a few years back.  A lightning detector, based on about 300Khz, that will detect a storm approaching from a distance.  Why not incorporate a lightning detector into the transfer switch panel and kill the computers and televisions at the least when a strong storm approaches?  In the spring in Houston this seems to make good sense.  I could even send an early shutdown signal to the computers before hand to make shutdown tidy.

rmchambers

  • Hero Member
  • *****
  • Posts: 505
    • View Profile
Re: Power Outages and Autostart
« Reply #1 on: April 01, 2007, 01:59:34 AM »
Kind of a neat idea.  an ADF in an airplane is a crude lightning detector.  Picks up AM signals which lighting will "transmit" on.  As for the computer thing.. what you would need to do though is shut the pc's down and after a suitable amount of time physically break the connection between the power source and the computers.  Even turned off a lightning strike that drops a big surge on the wire will get into your computer and will cause it harm.  You need to pull yourself off the grid, and put your computers up on insulated blocks so to speak.  Dont forget you need to get the TV's off as well cos nobody likes it when the TV is smokin'.

Robert

DaveW

  • Full Member
  • ***
  • Posts: 175
    • View Profile
Re: Power Outages and Autostart
« Reply #2 on: April 01, 2007, 03:43:01 AM »
rmchambers -
  Understood. But just dropping the power makes for a mess when coming back up on the computers.  So I thought of a shutdown signal, a time delay, then dropping the relays.  Its actually a little more messy than that, since I have a big ups that doesn't need to run unless I'm at the computers.  I had been doing this a piece at a time as string logic, it looks like I need to develop a plan and break out a micro and some programming.  When I miss a step it gets complicated with random logic to insert something.
   Same problem I'm having with the autostart and monitoring of the gen set.  I get one part thought out and implemented, and then the next, and after about five steps remember something that should have been checked three steps ago.  That can make it difficult to go back and insert an AND or an OR or a time delay in the right place.  I'm well up to speed on high end massive memory systems, but that seems overkill in this case.  Hope I'm not too old to learn a little 4 or 8 bit processor for this project.

Doug

  • Hero Member
  • *****
  • Posts: 3386
  • Why don't pictures ever work for me?
    • View Profile
    • Doug's Petteroid Stuff
Re: Power Outages and Autostart
« Reply #3 on: April 01, 2007, 04:07:18 AM »
They still make a 4 bit processor?

I just had a flash back to the SCMP and that led to stinging memory of the 6800HC11 that hit me like a 2 by 4 to the back of the skull......

Dave if you look on ebay now and then you see some Siemens LOGO PLCs. For the price its hard to beat these simple controlers provided you are willing to use Bolean logic to program the task you want threw that tiny little screen and with the function keys ( not simple, but a hell of a lot easier than writing code for 6800 or Z80 ).

Ebay.
130095188766

Also a nice little controler is the Simatic S7 by Siemens, the Micro logics 1000 by Allen Bradley and and the Modicon micro PLCs ( the good ones like the 311 to 612, not the stupid rebranded French made ones they sell now ). The machines in this post are progressively more powerful and exponential more likely to cause hair loss also a lot of reading to use and program as well as the correct software to program in some cases.

Doug
It's a Good Life, If You Don't Weaken

Guy_Incognito

  • Sr. Member
  • ****
  • Posts: 255
  • Just a guy, incognito.
    • View Profile
Re: Power Outages and Autostart
« Reply #4 on: April 01, 2007, 04:51:35 AM »
Something like this is a useful thing to start with, at $33.95. You can get variants with less I/O but with LCD's and pushbuttons for more interactive use.

http://www.sparkfun.com/commerce/product_info.php?products_id=20

Quote
Description: Development board for 18 pin PIC microcontrollers with power supply circuit, crystal oscillator circuit, RS232 port, ICSP/ICD port, 4 relay output, 4 optocoupler isolated inputs.

    * FR-4, 1.5 mm (0.062"), green solder mask, white silkscreen component print
    * ICSP/ICD connector for programming with PIC Programmers and Debuggers (for PICs with ICD support)
    * Power plug-in jack for +12VDC power supply
    * Voltage regulator +5V, 78L05 and filtering capacitors
    * Status LED connected to RB5
    * Quartz crystal oscillator circuit - 20MHz
    * DIL18 microcontroller socket
    * RS232 DB9 female connector
    * RS232 interface circuit with Tx, Rx signals
    * 4 optocoupler isolated inputs with screw terminals
    * Input status LEDs
    * 4 relay outputs with 10A/250VAC contacts with screw terminals
    * Output status LEDs


DaveW

  • Full Member
  • ***
  • Posts: 175
    • View Profile
Re: Power Outages and Autostart
« Reply #5 on: April 01, 2007, 05:15:57 AM »
Doug -
    Thanks for the tip. I just jumped on the 'net for a brief look and some of it looks interesting.  Sad to say, I went from ramdom logic to IBM mainframes, the micros were after my time.  I did a little in z80s and the 6809e, with a side trip through intel from 4 bit through pentiums, but mostly as imbedded subsystems off the server.
    Tonight I am supposed to be cleaning out the shop now that retirement is real.  The better half is off with her buddies to dinner and a show.  (I begged off going out with 6 grey haired ladies who swoon over some 35 year old snot prancing across a stage in tights-besides, I looked better at 50 than...but I blather)
    Under one of the benches I found an engineering development kit from Dovation.  Reps were always dropping off such like in the hopes I would design it in a system.  I had forgotten all about it.  A complete 486 system, with memory, drivers for 2 com, parallel, vga, keyboard, mouse, power supply, and the cutest little hard drive (all of 20 meg) about the size a cigarette lighter.  The whole thing is about the size of half a carton of cigarettes.  Looks to be DOS based.  This may be overkill, but I take it as a sign.  I have some LCD panels upstairs somewhere,  so the shop cleaning may slow to a crawl.
    Just stumbled across a flat of G2-1A05 solid state relays and a carton of 25 amp 3 pole double throw relays.  This project was meant to be.  I'll snap a picture of the hard drive.  The very latest in 17 year old technology.  Cleaning out the shop may be the most fun I've had since retirement.  Even found some 700, 800 and 900 series ICs from the early 70s.  And by the way, I have half a tube of 4 bit processors....

Doug

  • Hero Member
  • *****
  • Posts: 3386
  • Why don't pictures ever work for me?
    • View Profile
    • Doug's Petteroid Stuff
Re: Power Outages and Autostart
« Reply #6 on: April 01, 2007, 04:09:06 PM »
Sounds like you got all the bases covered already....

Your head and shoulders above me on that front. The 6800 and Bufalo ( compiler ) were never friends of mine....

Just for laughs I typed "debug" in a dos prompt on my PC, its still there and I guess you have all the tools you need. Good luck

As Dave sugests
Some younger guys at work have told me about eh PIC controlers, I don't know much about them but they say a monkey can use them...

Doug
It's a Good Life, If You Don't Weaken

DaveW

  • Full Member
  • ***
  • Posts: 175
    • View Profile
Re: Power Outages and Autostart
« Reply #7 on: April 01, 2007, 05:53:21 PM »
Guy and Doug -
  At a glance the PIC looks very interesting as a local (gen set) dedicated controller, and I was taken with the break out boards available.  I can see an ethernet link in the near future with a dedicated DOS microcomputer in-house, all on battery power of course. 
  The real trick is revisiting all the links about what needs to be monitored and properly ordering a successful startup, runtime and emergency shutdown routine.  If I recall, there were posts by GF and others on their favorite schemes, and George has spoken of murphy switches at times.  This time I might do it right, plan it out, work the plan, and check it off as each step is accomplished.  But I still want to incorporate a storm detector in the system.  It is disconcerting to forget to check the weather and wake up in the middle of the night to lightning flashing everywhere, knowing that there is electronics all over the house plugged in to local power.  I have once before lost everything electrical in the house to lightning, and hope to forestall a repeat.
  The bad part is that all this will have to be set up on my current Wisconsin/Allmand gen set, and then converted once I get the Lister back in one piece and running.  I still intend to move from gas to diesel on my backup system.

mjn

  • Full Member
  • ***
  • Posts: 116
    • View Profile
    • My Changfa Generator Project
Re: Power Outages and Autostart
« Reply #8 on: April 02, 2007, 07:06:01 PM »
I'm in the process of building a computerized controller for my generator.  I have finished wiring the controller, now I'm debugging it and writing software.  Unfortunately writing code is more like work for me so my pace is not as fast as when I'm doing something fun.   Once finished, I'll be able to close a switch at the house and the generator will start itself and warm up.  Once running, I can throw the transfer switch and the lights come back on... All without having to go out to the generator shed.

Based on following several of the threads on the subject, I am monitoring the following items:
  RPM (via optical pickup on flywheel)
  oil pressure
  water temperature
  injector line temperature
  fuel level (WVO and diesel)
  run/stop
  emergency stop

I am providing the following outputs:
  Starter relay
  decompression relay
  fuel relay (WVO/diesel)
  speed control (via stepper motor)
  glow plug relay (If I ever add one to my engine)

I'm using a stepper motor to move the speed control on the engine.  I'll be able to start the engine and allow it to warm up at a reasonable speed before raising the rpm to 1800 to generate power.

Once the engine is fully up to temperature and the injector line is at least 70ºC I will switch from diesel to WVO fuel.  On shutdown, the controller will switch to diesel fuel for a couple of minutes to purge the WVO from the system.  An emergency shutdown (low oil pressure etc...) will immediately move the speed control to stop and open the decompression lever until all rotation has stopped.

After shutdown, the controller will move the speed control back to the nominal 1800 rpm setting so I can manually start the engine in case of a dead battery or a failed controller.

Eventually I will build in a software PID controller to keep the RPM exactly at 1800 rpm (the Changfa governor is not perfect).

I am using an Atmel ATMega8 AVR cpu as the heart of the controller.  The AVR is similar to the PIC cpu.  At work, one of our customers uses AVR cpus, so I've had some exposure to using them.

Here is my first version of the schematic:


I am open to suggestions for ways to improve the system.

Changfa 195 7.5 kw ST.  WVO conversion http://martin.nile.googlepages.com/
Metro 6/1 DI Listeroid. Pumping water for fire control.
1933 Stover CT-1 hit and miss
1936 Farmall F-12 -- unrestored, still used to mow the field

luismc

  • Newbie
  • *
  • Posts: 17
    • View Profile
Re: Power Outages and Autostart
« Reply #9 on: April 02, 2007, 08:55:48 PM »
 Hi MJN
   can you give more information on the type of decompression relay you are using as have not been able to find one with a long stroke so I am using a universal safety door lock for a van.How is the optical sensor working I am using a hall effect sensor and what type of stepper motor

Thanks
Luismc

mjn

  • Full Member
  • ***
  • Posts: 116
    • View Profile
    • My Changfa Generator Project
Re: Power Outages and Autostart
« Reply #10 on: April 02, 2007, 10:13:48 PM »
Hi Luismc, I haven't selected a decompression solenoid yet.  I think the door lock solenoid would work fine.  My current plan is to use a solenoid from McMaster-Carr (#69905K5).  It has a 1 inch stroke with a 74 ounce pull.

In my case, decompression is not essential for starting, but is nice.   I'm counting on using the compression release as an emergency stop mechanism.

I'm using one of these for the rpm sensor: http://www.fairchildsemi.com/ds/QR/QRB1114.pdf.  I have not yet installed it on the engine, but I breadboarded the circuit and it works just fine.  I will paint the side of the flywheel with flat black paint, and paint a white stripe in one place.  This will give me one pulse per rotation.

I considered a hall effect sensor, but I could never come up with a suitable location or method to attach the magnet to the flywheel.  I did not like the idea of using glue or drilling a hole to hold the magnet.  (I had visions of the magnet flying off and my governor driving the engine to pieces because it was thinking the engine was too slow.)

My stepper motor is a slo-syn M061 8 wire nema-23 motor with a leadscrew assembly.  I'm running the motor in unipolor mode.  The biggest problem with the leadscrew is the slow speed.  My design could be improved by using a chopper drive, but I went for ease of implementation over efficiency.  (I'm burning over 60 watts of power in the limiting resistors while the motor is running.)

Changfa 195 7.5 kw ST.  WVO conversion http://martin.nile.googlepages.com/
Metro 6/1 DI Listeroid. Pumping water for fire control.
1933 Stover CT-1 hit and miss
1936 Farmall F-12 -- unrestored, still used to mow the field

Andre Blanchard

  • Sr. Member
  • ****
  • Posts: 373
    • View Profile
Re: Power Outages and Autostart
« Reply #11 on: April 02, 2007, 10:36:55 PM »
I considered a hall effect sensor, but I could never come up with a suitable location or method to attach the magnet to the flywheel.  I did not like the idea of using glue or drilling a hole to hold the magnet.  (I had visions of the magnet flying off and my governor driving the engine to pieces because it was thinking the engine was too slow.)

Regardless of how you do the sensor there should be some kind of sanity circuit/software in place where if the signal from the sensor disappears for longer then it would at some minimum speed it assumes something is wrong and goes into E-stop mode.

Engines with belt driven governors often had a weighted arm with a wheel riding on the belt.  If the belt broke the arm dropped and tripped the governor into shutdown.
______________
Andre' B

mjn

  • Full Member
  • ***
  • Posts: 116
    • View Profile
    • My Changfa Generator Project
Re: Power Outages and Autostart
« Reply #12 on: April 02, 2007, 11:19:45 PM »
Regardless of how you do the sensor there should be some kind of sanity circuit/software in place where if the signal from the sensor disappears for longer then it would at some minimum speed it assumes something is wrong and goes into E-stop mode.
...

I'll add "Loss of Signal" to the list of stuff I need to program.  Thanks for the advice.
Changfa 195 7.5 kw ST.  WVO conversion http://martin.nile.googlepages.com/
Metro 6/1 DI Listeroid. Pumping water for fire control.
1933 Stover CT-1 hit and miss
1936 Farmall F-12 -- unrestored, still used to mow the field

Doug

  • Hero Member
  • *****
  • Posts: 3386
  • Why don't pictures ever work for me?
    • View Profile
    • Doug's Petteroid Stuff
Re: Power Outages and Autostart
« Reply #13 on: April 03, 2007, 01:47:47 AM »
The Kubota dealer has some solenoids used to pull racks closed on some engines, duetz has a very big and heavy one to do the same thing....

Worth looking into if you know people whomight have scrap engines....
It's a Good Life, If You Don't Weaken

DaveW

  • Full Member
  • ***
  • Posts: 175
    • View Profile
Re: Power Outages and Autostart
« Reply #14 on: April 03, 2007, 02:14:45 AM »
 Good thoughts all.

MJN - A good list, I have mine broken down into pre-start check list, run list, e-stop list, and normal shutdown.

        To your list for pre-start I have added battery voltage, water level, oil level, and ambient temp.  The part of interest is a National LM903 fluid level detector, I have some on the way.  Looks like a great way to check the fluid levels before starting.

       My Lister already has a rack solenoid, so I'm in good shape there.

       For compression release I have some sample bistable push/pull solenoids from Shih Shin, real brutes but not a lot of throw so I'm thinking lever arms to trade distance for power.  Add some nut adjusted springs on the shaft and I won't have to get it set to perfection, just real close.

       On your schematic, you show the steppers as 3.8A 1.4V motors.  I thought that series was 5V at 1A, if it is that low a voltage why not do a low voltage high current supply and not waste all that energy in heat?  I've got a 12 volt linear actuator so a PWM through an H-bridge is all it takes for movement, and the speed is easy to control.

       As to overspeed, I have a belt tensioner to hold down on belt slap, with a big microswitch in the full travel position.  If I come up missing the belt, the rack is jacked closed.  I aim to add an alarm via the micro-controller to pass that information back to the house, and maybe a ball stop in the intake.

       This is starting to look like fun.