Connect with us

MOSFET 12VDC Relay?

Discussion in 'Power Electronics' started by adamq, May 4, 2021.

Scroll to continue with content
  1. adamq

    adamq

    78
    10
    Dec 17, 2013
    Yes you're right, I was lol. Apologies.
     
  2. crutschow

    crutschow

    43
    15
    May 7, 2021
    Yes, R3 limits the base current, which is required for a BJT.
    R4 is mainly to absorb any base leakage current and insure it stays fully off, especially if the device experiences higher temperatures.
     
    adamq likes this.
  3. adamq

    adamq

    78
    10
    Dec 17, 2013
    I think I understand now.

    R2 pulls up the gate voltage, but R3 pulls it down faster. Elegant solution.

    I don't think it will work in my situation, but I think the NPN will.
     
  4. adamq

    adamq

    78
    10
    Dec 17, 2013
    Gotcha.

    I'm expecting it shouldn't get too hot but one never knows.

    Since it's being used in the marine environment, I'd like to add tinned blade connectors and encase the whole thing in epoxy.
     
  5. crutschow

    crutschow

    43
    15
    May 7, 2021
    That's fine.
    Just make sure the epoxy is compatible with electronic parts and won't corrode them.
     
    adamq likes this.
  6. crutschow

    crutschow

    43
    15
    May 7, 2021
    I forgot to include a protection diode in case the load has some inductance to absorb any negative transient when it is turned off.

    Revised schematic below:

    upload_2021-5-7_11-31-12.png
     
    adamq likes this.
  7. adamq

    adamq

    78
    10
    Dec 17, 2013
    Thank you :)
     
  8. adamq

    adamq

    78
    10
    Dec 17, 2013
    Alright... this is what I've come up with including the optocoupler.

    relay_mosfet.png

    I should have downloaded KiCad a long time ago.
     
  9. crutschow

    crutschow

    43
    15
    May 7, 2021
    With the optocoupler, you likely don't need Q7.
    Just connect the opto output emitter (pin 3) to ground and the collector (pin 4) to M1's gate (with R1 of course).

    But depending upon the gain the of opto, you may need to reduce the value of R2 or increase the value of R1, to fully saturate the opto output transistor when its ON.
    Many optos have a transfer gain of less than 1.
     
    adamq likes this.
  10. Harald Kapp

    Harald Kapp Moderator Moderator

    11,415
    2,619
    Nov 17, 2011
    Q1 takes on the function of the switch in my circuit.
    Where did I miss the requirement for a positive control voltage to turn on the output?
     
  11. Harald Kapp

    Harald Kapp Moderator Moderator

    11,415
    2,619
    Nov 17, 2011
    Why the optocoupler? Replace Q? by the switch and resistor as shown in my post #16.
     
  12. Harald Kapp

    Harald Kapp Moderator Moderator

    11,415
    2,619
    Nov 17, 2011
    Why should a NPN transistor work but not the switch?
     
  13. adamq

    adamq

    78
    10
    Dec 17, 2013
    Just for an extra layer of safety.

    The signal wire is fused at the switch, but might be only 20ga.The load conductors are fused as well, but for 10ga loads.

    I prefer the two to be isolated because it's a harsh environment.
     
  14. adamq

    adamq

    78
    10
    Dec 17, 2013
    Hey Harrold. I appreciate your help on this.

    I believe your idea won't work because the switch is located physically far away from the circuitry. Because it's a retrofit solution it is challenging.

    The 12V "signal" comes via a single conductor up to 30ft away. It is not a pair of wires and there there is no ground at the switch. There is also no room for circuitry at the switch.

    In your example, I believe the switch must be between the two resistors to activate the gate. It definitely works just not for this application.
     
  15. crutschow

    crutschow

    43
    15
    May 7, 2021
    Here's the LTspice simulation of the circuit with an opto:

    upload_2021-5-8_10-1-15.png
     
    adamq likes this.
  16. adamq

    adamq

    78
    10
    Dec 17, 2013
    You may be right.

    As an example, the data sheet of the LTV-817, CTR is 50% at 5mA min. It's 100% at 10mA, or 50mW. 600% is maximum. Those are at 5V.

    At 12V, I'm unsure how it is affected, but I expect it is based on the brightness (power) of the octocoupler LED.

    So, I would expect [email protected] (60mW) should give the same capacity as [email protected] (50mW).

    In that case, perhaps a 2.4k resistor is appropriate for the input. That would give ~5mA at 12V.

    Thoughts?
     
  17. adamq

    adamq

    78
    10
    Dec 17, 2013
    I'm not familiar with simulators but it seems to work?
     
  18. crutschow

    crutschow

    43
    15
    May 7, 2021
    Yes.
    It's determined by the input current, not the voltage.
    So you select the input resistor to give the desired input current.
    The resistance would be the signal voltage minus the diode input voltage (typically about 1.3V) divided by the desired current.

    But you only need the input current that fully turns on the output transistor with the output load current (I would use about twice that from the transfer gain calculation).
    I simulate just about all circuits before I built them.
    It doesn't always give the exact results of the real circuit, but it gives you a heads-up in case you made a significant error in your design, before you build it.

    The simulated circuit works fine.
    Note the output voltage from the MOSFET follows the input voltage to the opto.
     
    Last edited: May 8, 2021
  19. Harald Kapp

    Harald Kapp Moderator Moderator

    11,415
    2,619
    Nov 17, 2011
    If the long wire from the switch to the MOSFET catches noise that interferes with the operation of the MOSFET, so will the same noise interfere with the operation of a driving transistor and thus finally the MOSFET.
    To reduce the influence of noise on the MOSFET simply add a filter capacitor between gate and source, e.g. 10 nF or 100 NF. The exact value is not relevant as switching will be slow anyway (the relay that is going to be replaced is much slower).
    The circuit by @crutschow will work. However, the value of R3 is to high. At 12 V for the control signal and ~ 1.6 V for the LED, the current through the LED will be on the order of 1 mA. You can buy low current optocouplers, but the majority is designed for 5 mA or 10 mA LED current. I suggest 1 kΩ for R3 to improve reliability. A higher current will also reduce the susceptibility of the circuit to noise. To further improve stability, add a filter capacitor as mentioned above, but this time not to the MOSFET but across theLED of the optocoupler. R3 and the capacitor will form a low pass filter that additionally reduces noise. Since the LED has a comparatively low impedance (compared to the MOSFET), you can chose a higher value for the capacitor, e.g. 1 µF ... 10 µF, whatever is in your parts bin.
     
    Last edited: May 8, 2021
  20. Harald Kapp

    Harald Kapp Moderator Moderator

    11,415
    2,619
    Nov 17, 2011
    You believe wrongly. It definitely will work.
     
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day

-