1
\$\begingroup\$

I need to turn off this constant current circuit with a gpio pin when an event is True. I'm using 6 of these circuits with 3 lm358 op-amps, so turning off the whole chip is not an option. Any ideas?enter image description here

\$\endgroup\$
  • 3
    \$\begingroup\$ Just add another (logic level) MOSFET in series to isolate the route to ground. \$\endgroup\$ – Majenko May 30 at 21:39
  • \$\begingroup\$ Have you tried connecting the op-amp's non-inverting input to ground through a resistor? \$\endgroup\$ – Seamus May 31 at 0:19
  • \$\begingroup\$ @Seamus You'd need to also disconnect the pot or you'd just be changing the adjustment voltage. You could disconnect the 5V from the top of the pot, which would give you 0V on the non-inverting input, which you could also achieve with an inline FET. \$\endgroup\$ – Majenko May 31 at 9:30
1
\$\begingroup\$

Switching off the supply is the safest option if the other opamp of 358 is not used:

schematic

simulate this circuit – Schematic created using CircuitLab

Another option is to add another IRLZ44N between the R1's lower terminal and the GND.

PS: If you connect the load as shown in the circuit it won't work. Load's positive terminal should be connected to the positive supply rail, and its negative terminal should be connected to the drain of Q1.

| improve this answer | |
\$\endgroup\$
0
\$\begingroup\$

Few ways to do it, simplest would be a logic level N-channel mosfet to ground out pin 3 of the op amp, this will reduce that current to between off and almost off (the op amp may have an offset votlage)

Next way would be a say 1M resistor between pin 2 of the op amp and 5V, and fit a N-channel mosfet inline with the sense wire, when you want it off, you switch its gate to ground, otherwise keep it high to keep in on,

| improve this answer | |
\$\endgroup\$
  • \$\begingroup\$ simplest would be a logic level N-channel mosfet to ground out pin 3 of the op amp this will short the supply to the ground when the pot is at max. Next way would be a say 1M resistor between pin 2 of the op amp and 5V, and fit a N-channel mosfet inline with the sense wire and this won't work since the source may be equal to the gate voltage. When you switch the FET off then pin2 will be floating. You cannot know what will happen with a comparator with floating input(s). The current source may be turned on forever. \$\endgroup\$ – Rohat Kılıç May 31 at 10:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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