1
\$\begingroup\$

I want to drive a 12v inductive load with arduino (a motor) . This device has 3 wires a common GND and one wire to go in one direction an another one to go on the opposite direction, as it has a common GND If I understand it correctly I can't use a NChannel mosfet. following diferents ideas on the internet I came up with the following design:

enter image description here

A few questions :

  1. Why is R4 really necessary?
  2. What's the use for Q1 , I have seen diffent designs using only Q2, if I was driving a 5v device (the same as V as the arduino could Q1 being removed?
\$\endgroup\$
9
  • \$\begingroup\$ Q2 is placed wrong. The load will be energized regardless of QA signal as the body diode is forward biased. Source (2) should be tied to VIN, and Drain (3) should be tied to the load. Fix it then the answer will come. \$\endgroup\$ Commented Jul 27, 2020 at 14:19
  • \$\begingroup\$ Ok @RohatKılıç, corrected orentation of Q2 \$\endgroup\$
    – Marc
    Commented Jul 27, 2020 at 14:33
  • \$\begingroup\$ You indicate the motor interface is bipolar on 2 wires, (Fwd,Rev) +gnd , yet you have a unipolar (hi-side driver) design? what's wrong with this picture? \$\endgroup\$ Commented Jul 27, 2020 at 15:02
  • \$\begingroup\$ @TonyStewartSunnyskyguyEE75 no, the system is not bipolar on two wires, rather it is clearly stated to have three wires which makes it unipolar with a distinct winding or power feed for each direction. The question shows one of the two identical copies of the drive circuit needed, there's no point in showing both when the question concerns the implementation of each copy rather than the application of two of them to driving the load. \$\endgroup\$ Commented Jul 27, 2020 at 15:14
  • 1
    \$\begingroup\$ Your LED will not turn on as shown. You need to move the anode to QA directly. \$\endgroup\$ Commented Jul 27, 2020 at 15:37

2 Answers 2

2
\$\begingroup\$

For your current circuit:

Why is R4 really necessary?

You need a way to make sure that the source and the gate of the PMOS are the same potential to keep it OFF. That way, when Q1 is not ON, R4 will guarantee that the PMOS remains OFF. Remember that a MOSFET is turned on when there is enough potential difference between gate and source, \$V_{GS}\$. In a PMOS, you need to pull the gate voltage, sufficiently, below of that of the source in order to turn it on. In your circuit, when the PMOS is ON―which happens when Q1 is ON― \$V_{GS}\approx -V_{in}\$ (a little less because of the drop across Q1).

Another good point brought up in the comments, without R4, when Q1 is ON, it would short \$V_{IN}\$ to ground. That is, of course, if you were to replace R4 with just a short circuit. If you took it out, leave that open, you wouldn't short VIN to ground but the previous paragraph explains what could happen.

What's the use for Q1 , I have seen diffent designs using only Q2, if I was driving a 5v device (the same as V as the arduino could Q1 being removed?

Yes, you could live without Q1 under this case you mention. If VIN, however, were some voltage like 12V, then you still need Q1 to protect the arduino's GPIO from the higher voltage.

\$\endgroup\$
4
  • \$\begingroup\$ re R4, without it, Q1 would short VIN to GND; an expensive way of cutting off the FET. \$\endgroup\$
    – dandavis
    Commented Jul 27, 2020 at 14:56
  • \$\begingroup\$ @dandavis that is right, that's another point. Also works as a pull up to guarantee the PMOS off when needed, which happens when Q1 is not active \$\endgroup\$
    – Big6
    Commented Jul 27, 2020 at 14:58
  • \$\begingroup\$ @dandavis edited answer to reflect your comment. \$\endgroup\$
    – Big6
    Commented Jul 27, 2020 at 15:00
  • 1
    \$\begingroup\$ @dandavis On second thought, what you say is valid if the OP replaced R4 with a short. My guess is that he means to remove R4 and leave an open in place of R4--not short across gate and source. \$\endgroup\$
    – Big6
    Commented Jul 27, 2020 at 15:06
1
\$\begingroup\$
  1. Why is R4 really necessary?

Yes Open collectors have a tiny leakage current and R4=10k to FET gate capacitance is not too slow enough for this valve switch. But without R4 will turn ON from Q1 leakage.

  1. What's the use for Q1, I have seen different designs using the only Q2, if I was driving a 5v device (the same as V as the Arduino could Q1 being removed?

Q1 is just a 5 to 12V inverter switch. If the output was 5V supply to valve, you wouldn't need an inverting level shifting switch like Q1. But then the logic is inverted.

The LED won't get 5V as you have it. (or even 3.3) enter image description here

\$\endgroup\$
4
  • \$\begingroup\$ You removed R3 (the pull down resistor for Q1) was it intentional? I want to make sure Q1 is off by default while the arduino pin is in a unknown state during startup \$\endgroup\$
    – Marc
    Commented Jul 27, 2020 at 20:06
  • \$\begingroup\$ I assumed QA pulls down Q1b with R1 to make R3 redundant. Right? \$\endgroup\$ Commented Jul 27, 2020 at 21:29
  • \$\begingroup\$ If I understand it correctly R1 and R3 have different purpose, R1 is to limit the base current drawn from the Arduino output pin while R3 is used as a pull down, QA is connected directly to an Arduino pin so both resistors should be required to achieve the desired result \$\endgroup\$
    – Marc
    Commented Jul 27, 2020 at 22:06
  • \$\begingroup\$ If you had a diode in series, that would be true, but you do not \$\endgroup\$ Commented Jul 27, 2020 at 22:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.