MOSFET double check

Discussion in 'General Electronics Chat' started by Jassper, Jul 20, 2011.

  1. Jassper

    Thread Starter Active Member

    Sep 24, 2008
    84
    1
    Hello

    First time playing with MOSFETs as a control switch so thought I would post my schem and see if I am missing anything.

    Works great in testing but second opinions are always a good thing. Any comments on what I should consider is welcome.

    Some info I have read over suggest useing a resistor between the Gate and the output pin of the MC, but not sure it applies here.

    I also wonder if I should use the same +12v supply to drive the LED instead of feeding it +5v - Pros / Cons / The way the board is laied out it is easiest to pull from the +5v rail

    Thanks for any input.
     
  2. #12

    Expert

    Nov 30, 2010
    16,284
    6,797
    Looks good, but your method of drawing makes my head spin. Could you try that in a horizontal fashion in the future?

    Ps, You are allowed to use any number of supplies you want as long as no parts will fail because of it.
     
  3. ErnieM

    AAC Fanatic!

    Apr 24, 2011
    7,388
    1,605
    You are placing -7V on the LED when the solenoid is off. I believe this may be a tad excessive.

    I agree: the schematic makes my head spin too!
     
  4. Jassper

    Thread Starter Active Member

    Sep 24, 2008
    84
    1
    Correct, So I need to make sure this does not exceed the LED reverse voltage.
     
  5. praondevou

    AAC Fanatic!

    Jul 9, 2011
    2,936
    488
    I think Ernie is right, at the moment when D4 is conducting (shortly after switching the solenoid off).
     
  6. praondevou

    AAC Fanatic!

    Jul 9, 2011
    2,936
    488
    Yes , or u use the 12V to supply power to your LED.;)
     
  7. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    I'll suggest putting R25 on the positive (anode) side of the LED, and using it as a jumper to get to the +12v rail.

    Electrically, you can place LED current limiting resistors anywhere in the series path for the LED. However, I prefer to have the resistor between the LED's anode and the positive supply. That way, if you accidentally short the LED cathode or anode to ground, nothing bad will happen.

    There are some very general standards to use when creating schematics.
    Inputs come from the left, and outputs flow towards the right.
    More positive voltages towards the top of the schematic, more negative towards the bottom.
    In keeping with those basic concepts, N-ch MOSFETs should have their gates to the left, drains up, source down, while P-ch MOSFETs should have their gates to the left, drains down, source up.
    There are exceptions to everything. Certain types of circuits are more easily understood if the right side is a mirror image of the left side, such as H-bridges and certain types of discrete astable multivibrators. However, if you try to follow the general concepts, you'll find that your schematics will be much easier to understand.
     
  8. Jassper

    Thread Starter Active Member

    Sep 24, 2008
    84
    1
    Awesome!

    Changes made: Resistor moved to Anode side of LED to 12v supply rail.

    Suggestions on Schematics design duly noted.

    Thanks.
     
  9. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    A few more Cadsoft Eagle-specific notes...
    You have "Common Ground" typed on the wire from the MOSFET source terminal.
    Rather than adding text like that, consider using the GND symbol in Supply1.lbr or Supply2.lbr; I personally prefer the symbols in Supply2.lbr

    Note that connecting symbols on a wire changes the NAME of the wire to that of the symbol. This is good.

    Note also that while using the Supplyx.library symbols is great for helping keep your naming conventions straight along with easy-to-interpret visual cues (symbols), they won't provide connections to get your signals on or off the board. You need to add connectors, headers, wirepads, or SOME method of physically attaching a real-world wire to that signal.

    Make certain to use the ERC function early, and use it often! Failing to resolve ERC errors before creating a PCB can make life very unpleasant; to the point of spending many, many hours trying to lay out a board and then finally having to discard the whole mess. (Ask me how I know this. :rolleyes:) ERC warnings may or may not cause you grief later; you need to evaluate them on a case-by-case basis.

    For example, you're using an Arduino uC. If the part is already in a library, it might be using Vdd and Vss for the power and ground pins instead of +V and GND or VCC and GND. If you connect a +5V symbol to a pin named as VDD, it's going to get flagged.
    If you connect a +5V symbol to a VDD symbol, you will have problems; the differently-named symbols connected to the same wire may leave things disconnected.
     
  10. Jassper

    Thread Starter Active Member

    Sep 24, 2008
    84
    1
    Thanks, just to note - That schematic was just a copy-paste into CoralDraw and the black text was added then, I just erased everything that wasn't relavent to my question, In hind sight I should have mentioned that.

    I only use Eagle for the Schematic, I use Pad2Pad for the board.
     
  11. ErnieM

    AAC Fanatic!

    Apr 24, 2011
    7,388
    1,605
    At the time you mention (the turn off) the voltage is actually greater then the 7V, as the solenoid (which is a coil or inductor) is dumping it's current thru D4 back to the power rail (you know this, others may not). So until the coil current goes to zero the drain of the FET is a diode drop above 12V.

    You can actually calculate how long this current takes to go to zero from V = L dI/dt (and solving for dt) where the V is the diode drop, L is the coil inductance (rarely specified but can be measured) and dI is the coil current just before switching it off.

    However, as long as the FET is off there is a steady state -7V on the diode: the coil is still a conductor and is feeding the 12V to the drain.

    While I am unsure if a transient reverse overvoltage is as bad as a continuous one but Jassper made a wise choice in eliminating either possibility.
     
  12. praondevou

    AAC Fanatic!

    Jul 9, 2011
    2,936
    488

    Yes u are right, seems I have a problem with components that are not visible on the schematic.. :rolleyes:
     
  13. Jassper

    Thread Starter Active Member

    Sep 24, 2008
    84
    1
    Now for my next question. Would a simple PTC rated about 1.5 amp surfice to prevent a direct short if someone connected +12v directly to the output or would another Diode be better? The Diode will give me a ~0.7 volt drop in voltage but don't think that would be a big deal and it would be cheaper.
     
  14. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    Gee, we have no idea what the output is.
    Or are you talking about the relay?
     
  15. Jassper

    Thread Starter Active Member

    Sep 24, 2008
    84
    1
    Oh sorry, yes where the solenoid connects.
    I'm sure the smoke will escape if someone was to apply +12v to that output
     
  16. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    You could use a PTC. I'd place it between the MOSFET drain and the junction with D4. You could also use a LED and current limiting resistor across the PTC as an overcurrent trip indicator, which could occur if the output were connected directly to +12v, or if the solenoids' windings had become overheated and shorted internally.
     
  17. Jassper

    Thread Starter Active Member

    Sep 24, 2008
    84
    1
    Thanks SgtWookie, probably just the PTC for now. I may add the LED later on.
     
Loading...