1
\$\begingroup\$

I would appreciate some comments/insights/criticism on my design:

I want to turn on/off a linear regulator (MIC5504) based on the light. I have tried just using a resistor and photoresistor voltage divider on the gate of the FET, but this causes flickering in certain lighting conditions (which is somewhat reduced with a 0.1uF cap, but whatever).

To overcome this, I decided to put in a Schmitt trigger roughly between 2/3V.

The op-amp then turns the FET on, enabling the 3.3V linear regulator.

I have not picked an op-amp. I have LM358P on hand, but am willing to go for some SOT-23 alternative, like AD8541. Not sure what the best "general purpose" op-amps are, but I feel like any old op-amp would work for my scenario. The reason I want to go for SOT-23 is because I have breakout boards to DIP for them on hand.

(The battery is connected to a BQ21040 for charging, but that is not included in this schematic.)

(I'm also aware that the battery won't stay at 3.7, and will be somewhere between 4.2 and 3-ish V. In those cases, I'm OK with the trigger values changing).

schematic

\$\endgroup\$
2
  • \$\begingroup\$ The 2N7000 seems suspicious. Why is its source connected to the next stage and not its drain? \$\endgroup\$
    – Reinderien
    Nov 8, 2020 at 4:56
  • \$\begingroup\$ It's connected to a pin with an input impedance of 4MOhm. That's what that resistor represents. If I connect it to drain, it will be enabled since voltage at that point will be Vbat (3.7V). \$\endgroup\$
    – Ozbekov
    Nov 8, 2020 at 5:08

2 Answers 2

1
\$\begingroup\$

My suggestion is to drive the fet with a phototransistor instead of an LDR. They have much higher sensitivity (change in resistance versus illumination) than LDRs which should minimize the flicker dramatically and you wouldn't need the opamp circuit at all in my opinion. Though, using a schmitt trigger is still a good idea to have a defined signal at medium illumination.

You can just arrange the phototransistor in series with a pull-up resistor to drive the FET (or the schmitt trigger respectively).

\$\endgroup\$
1
\$\begingroup\$

I think you've approached driving the MIC5504 EN the wrong way. Based on the specsheet, it has a pull-down resistor, so you need a high-side switch, not a low-side switch. Currently your depicted circuit is half-and-half: it uses the wrong transistor in the right place.

For it to work as you intend, you need to have a P-channel device with source connected to Vdd and drain connected to EN. Since Vdd is 3.2V, the output of your opamp will need to drop below that - how much depends on the Vgs characteristics of the device you pick.

\$\endgroup\$
4
  • \$\begingroup\$ I have two questions: 1) On my breadboard, driving the EN pin using 2N7000 is working fine. Why would that be? and 2) I might as well just drive the EN pin from the output of the op-amp (or comparator). Would this be fine? \$\endgroup\$
    – Ozbekov
    Nov 8, 2020 at 17:13
  • \$\begingroup\$ Yes - direct drive from the output of the op-amp is preferred, so long as the polarity is correct. \$\endgroup\$
    – Reinderien
    Nov 8, 2020 at 17:14
  • \$\begingroup\$ You had used common drain configuration - en.wikipedia.org/wiki/Common_drain - this is not used as often in simple port-driving applications. Read e.g. electronics-notes.com/articles/analogue_circuits/… \$\endgroup\$
    – Reinderien
    Nov 8, 2020 at 17:19
  • \$\begingroup\$ Thank you! I will read these. \$\endgroup\$
    – Ozbekov
    Nov 8, 2020 at 21:53

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.