This is my circuit that lights up an LED for less than 4 seconds of volts using 4V. How do I make the LED light up? I thought the output of the comparator was the comparators supply voltage, and that current would go through the 330 ohm resistor R5, and then the LED.

1) is what I tried

2) is something I saw, tried, and it didn't work.

enter image description here

  • \$\begingroup\$ TLC372 compartor \$\endgroup\$ Commented Oct 21, 2019 at 23:42
  • \$\begingroup\$ Under what conditions do you want the LED to light up? Can you link the place you found the circuit on google? \$\endgroup\$
    – dos584
    Commented Oct 21, 2019 at 23:47
  • \$\begingroup\$ notice: The Capacitor was connected incorrecly \$\endgroup\$ Commented Oct 21, 2019 at 23:52

1 Answer 1


From the datasheet: "The outputs are n-channel open-drain configurations". This means that the when the comparator is "on" (In+ > In-) then the comparator output pin is shorted to ground, but when it is "off" (In+ < In-) the output pin is high impedance (effectively not connected to the rest of the output circuit).

So, you'll want something like your option (2), but without the GND connection to the LED. When the comparator is on, there will be a path from 5V to ground through the resistor, LED, and output pin. When the comparator is off, there will be no current path through the LED.

  • 1
    \$\begingroup\$ It can be a bit surprising when a comparator (or some other output pin) has this configuration, but it is a useful arrangement. It's especially common in comparators, as you've found out. It's a good habit to check datasheets for open-drain outputs. The other common output is a "push-pull" (aka "totem-pole") output, and they can short a pin to both ground or Vcc. \$\endgroup\$
    – remcycles
    Commented Oct 22, 2019 at 0:13

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.