Diesel Generator. Need To Kill If Over Temp...

Discussion in 'The Projects Forum' started by NFA Fabrication, Sep 11, 2012.

  1. NFA Fabrication

    Thread Starter Member

    Aug 12, 2012
    104
    3
    I am assuming that there is a very simple solution to this. A friend of mine has a diesel generator that he wants to add something to that will shut it off if it gets to a temp over it's normal operating range.

    What I have already is a relay that if activated, will kill the fuel solenoid on the injection pump, and a Chevy temp sensor with a varying resistance output. I figure I will just be making a simple voltage divider with the sensor, and a resistor to make a voltage signal reflecting temperature.

    So what it comes down to, is that I need to make a circuit that will activate a relay when a certain voltage input is reached. I am pretty limited as I am new to electronics, but I put together a way to make it work, but it is based on an LM3914, and I was just going to use one of the LED outputs that activated at the voltage I wanted, to operate a transistor to drive the relay. It would probably work, but is probably the wrong way to do it, as I am still pretty limited, but learning by the day! Thanks for any ideas!
     
  2. crutschow

    Expert

    Mar 14, 2008
    13,039
    3,243
    Do you know the resistance of the temp sensor at the trip temperature?
     
  3. wayneh

    Expert

    Sep 9, 2010
    12,148
    3,058
    That's not a bad approach, although it's overkill. A single comparator (instead of 10, and the other circuitry in that IC) would do the job.

    That said, using the LM3914 allows you to add indicator lights to actually show the temperature before the tripping point is reached. You could use the ubiquitous LM339 quad comparator to get 4 levels.
     
  4. NFA Fabrication

    Thread Starter Member

    Aug 12, 2012
    104
    3
    Here is a reference chart:

    [​IMG]

    I am assuming my cut-off is going to be around 200F - 210F. Lets just say 180 Ohms would be the desired cut-off.

    My electronics knowledge base is pretty limited so far, so I am kind of using the "Building Blocks" that I am familiar with. I do like your "Temp Display" idea however! I will look into that LM339.
     
    Last edited: Sep 11, 2012
  5. NFA Fabrication

    Thread Starter Member

    Aug 12, 2012
    104
    3
    After reading up on the LM339, it sounds like the obvious and simple solution to my project. Thanks!
     
  6. wayneh

    Expert

    Sep 9, 2010
    12,148
    3,058
    The biggest trap for anyone new to a comparator is that the "high" output is simply "open". You need an external resistor to pull the output high. The comparator completes a path to ground when it goes low, and that path cannot sink more than about 5mA of current. Not much, but enough for an indicator LED.
     
  7. NFA Fabrication

    Thread Starter Member

    Aug 12, 2012
    104
    3
    Good to know. I will be driving a relay, so I figure I'll use 2 resistors off of the 339 output (a 1K from the output to trigger a 2n2907, a maybe a 10K from the output to +). And then a protection 4001 diode on the 2n2907 output since it will be driving a relay. Now that brings me to a question, being that the 2907 is PNP, how do I install the protection diode? I have installed them on 2222's like this:

    [​IMG]

    But obviously that wont work on a PNP. How do I alter the installation of the protection diode for a PNP? I could use the 2907 to drive a 2222 and then install the diode as above, but I am assuming there is a way to get the diode on a 2907.
     
  8. Sensacell

    Well-Known Member

    Jun 19, 2012
    1,132
    267
    Diesel Generators are nasty in terms of heat, vibration, gunk, etc.
    The hardest piece of this project will be resolving the mounting problems for the delicate electronics.

    Keep it simple- bolt a mechanical thermostatic switch to the cylinder head and call it a day.
     
  9. NFA Fabrication

    Thread Starter Member

    Aug 12, 2012
    104
    3
    Understandable, but the system does not have to be mounted on the unit. It is a very large unit, not a portable generator. It is basically running a temporary housing situation for a friend that is currently having a new home built. Plus it's more fun to make a ridiculously over engineered solution to a simple problem;).
     
  10. wayneh

    Expert

    Sep 9, 2010
    12,148
    3,058
    I'm not so sure that will allow the transistor to turn off. If there's much base current at all, there will be a voltage drop across the 10K and the base voltage will never return to V+. A single resistor of about 3.3K is the usual way to pull up the output.
     
  11. NFA Fabrication

    Thread Starter Member

    Aug 12, 2012
    104
    3
    Thanks, I was wondering about that. I kinda pulled that value out of my A&*. I just didn't want to make it too low and put too much strain on the 339's output. I know that the 339's output is very low current handling (Like 2ma or something I read?).
     
  12. MikeML

    AAC Fanatic!

    Oct 2, 2009
    5,450
    1,066
    Its not as bad as you think: (Right off the LM339 datasheet)
    http://www.fairchildsemi.com/ds/LM/LM2901.pdf
     
  13. MikeML

    AAC Fanatic!

    Oct 2, 2009
    5,450
    1,066
    Here is my proposed solution. With the pot centered, the relay pulls in when the sensor resistance reaches 184.57 Ω (heating), and then drops out when it reaches 187 Ω (cooling). I provide enough hysteresis to prevent the relay from chattering as the sensor heats or cools. The Pot will allow you to move the trip point a few degrees +-.

    In the simulation, the green trace I(L1) is current through the relay, showing when it is pulled-in. The red trace V(i)/I(R2) is the resistance of the sensor. LTSpice lets you do arbitrary waveform arithmetic, R= E/I. I plotted that expression so we could see the resistance value at which the circuit trips.

    The independent variable of the simulation (X-axis) is time. LTSpice provides a tricky method of making a resistor a function of a node voltage V(s), which in turn is a linear function of voltage V1 0r V(s).

    I have not built this circuit, but it should work as described. If you build it, please provide some feedback.
     
  14. mlog

    Member

    Feb 11, 2012
    276
    36
    I have a few items that you might want to think about. Maybe you already have the answers, but it seems like everyone is diving into designing the circuit. That's no surprise since everyone here is so helpful.

    • Time Response. I didn't see anything about the required time response of the temperature sensor or the actuator circuit. Does this sensing system need to work in seconds or milliseconds?
    • What temperature is being sensed? Is it exhaust gas temperature, manifold temperature, heat exchanger water temperature, engine skin temperature, or something else? This can affect the choice of the sensor, placement and method of attachment of the sensor, and the time response (see above).
    • Reliability and Criticality. Do you care about false trips? What about a failed sensor? Is it critical if the sensor fails and you aren't aware of it? If it does fail, then what do you want to do? Do you want to shut down the engine or trigger an alarm? (Circuit redundancy can affect reliability and mitigate criticality.)
    • Accuracy. Does it matter? If so, what is needed?
    • Environment. Think about exposure to the elements. Rain, sun, ambient temperature, humidity, etc. This can affect response, accuracy, and reliability.
     
  15. Dodgydave

    Distinguished Member

    Jun 22, 2012
    4,999
    745
    Last edited: Sep 12, 2012
  16. NFA Fabrication

    Thread Starter Member

    Aug 12, 2012
    104
    3
    I will be going over your schematic more when I get a few minutes as I am sure you are better at this than I. I came up with this last night, but got stuck at trying to figure out a protection diode for the 2n2907 to control the relay. I have used 4001's after 2n2222's, but that obviously won't work for a PNP. Also, I hadn't chosen a bias resistor for the temp. sensor yet, but that will be easy. The hysteresis is the main thing I am missing, and I can see that being an issue. My initial plan was to put a capacitor on the trigger of the 2N2907 to buffer it's output. (I just edited this pic to add a protection diode as I found a similar circuit with it set up like this)

    [​IMG]

    It is going to be monitoring the cooling system (Temp sensor in the coolant). The sensor I am using is very reliable, and I was going to seal up the circuit very well, and will likely encase it in resin, as I don't see why It would generate much heat. It only needs to activate for a second or 2 to kill the motor, as it will kill fuel supply right at the pump, just like on a diesel car. I like these sensors because they use a common 3/8" NPT pipe thread. so they are easy to adapt into all kinds of things, are cheap, and extremely reliable. I will probably make a test button on the unit that will simulate an overheating resistance, to check that the relay circuit activates.

    This is actually a GM coolant sensor, it is great in applications like this for the reasons I mentioned above. It works great in the temp range I need.
     
    Last edited: Sep 13, 2012
  17. NFA Fabrication

    Thread Starter Member

    Aug 12, 2012
    104
    3
    I spent some time looking at you schematic now, and got very confused as it all seemed backwards (My fault, not yours!). I was operating with the idea of the 339 output going low, and not high, and hadn't really considered that it can be done both ways. I learned another new thing tonight! Now that I made sense of that, I can inspect the rest, and take some que's from it (Or possibly abandon my whole plan, and steal yours, lol!)
     
  18. wayneh

    Expert

    Sep 9, 2010
    12,148
    3,058
    No, you had it right. That's the role of R7 in Mike's schematic. The comparator can pull the transistor base low despite R7. When the comparator goes high, R7 ensures that the base goes high.
     
  19. MikeML

    AAC Fanatic!

    Oct 2, 2009
    5,450
    1,066
    I was trying to make a circuit where the relay comes on only if an overheat is detected. To shut the engine off, you would use the relay's normally closed contacts.

    The LM339 is diverting the base current of the switching transistor to ground while the temperature is normal, so no current flows in the collector/relay. When the 339 output shuts off, the voltage at the base only rises to about ~900mV, but all of the current that R7 can supply with ~12V across it goes into the base of the transistor, turning it on hard. The 900mV delta at the base is also the source of the positive feedback to accomplish the hysteresis. Look at the plots below. V(base) light blue shows what is going on.

    I also plotted the voltage across the sensor V(i) red trace (also the 339 inverting input) and V(n) green trace, which shows the effect of the positive feedback from V(base) to create the hysteresis.
     
    Last edited: Sep 13, 2012
Loading...