IMP002 - Red/Green Status / Common Anode vs Cathode Detection

When I use a good ( power supply, my common cathode LED is detected no problem. This is following Section 5 where we use a 100k resistor on the red LED. After boot is complete, the RG LED blinks Green-Off-Green-OFF

When I use a LM1117T-3.3 as my 3.3V power source, the LED is detected as common Anode. After boot, the RG LED blinks Orange-Red-Orange-Red (or G+R, R, G+R, R). Although operation is just fine, the Red light won’t turn off since the pin is on negative logic and has 2.0volts on it (meaning IMP wants it off, but actually turns it on). FYI Tried various capacitors on input/output of LM1117T-3.3. Wish I had an O-scope, but don’t have it just this moment.

I’m not sure what the root cause of this is, however it would be nice to know how to compensate for this simple type of power supply and have the LED operating the “right” way.

Any ideas?

Quick note: Using a hard drive power supply (12V and 5V), 5V -> LM1117T-3.3, I get the strange problem.

Using the USB->5V DF Robot Power Supply -> LM1117T-3.3 the problem goes away.

Must be something odd about the hard drive power supply?

Also of note, I used the 5V from the HDD Power Supply as well as used a HDD Power Supply 12V -> LM7805 -> LM1117T-3.3 and that still has the problem. So it doesn’t seem like giving a cleaner 5V signal from the LM7805 helps.


the DFRobot’s power supply is based on a couple of 11117T. Not LM but AMS. Is the same product just from different manufacturer.

We use only original 1117* from ON because as result of our tests offers the best protection against failures and over heating.

This said, the problem must be in the 1117T-3.3 you are using.

The most common cause of problems with these components is very simple: they are fake!

Can you please detail how do you use it for your tests? On PCB, breadboard, can you provide the circuit you are using?


It’s possible there is a rise time issue here. If you change the 100k resistor to a 10k, does that help detection at all?

Hi Guys, on travel for a bit.

@Hugo, thanks for the suggestion. I’ll update you when I get a chance to try the 10k resistor.

@smartmaker, thanks for the info. Hopefully my LM1117 is real :slight_smile: I ordered it from Jameco and there’s an STMicroelectronics logo on it.

I have since reworked the circuit to use an LM2576T-005G rather than the LM7805. Still taking 12V in from the same power supply. While the same problem appears, here’s an odd thing that makes me suspect the power supply itself is part of the issue.

This is my setup in general: [wall outlet] -> Cord #1 -> [HDD Power supply] ->12V Wire -> [5V regulator/SMPS] -> [LM1117T-3.3]

If I connect/disconnect “Cord #1”, almost 80% of the time the LED detection is backwards.

If I connect/disconnect “12V Wire”, then the LED detection is backwards only 50% of the time.

Granted there may be other issues, but it seems that letting the HDD Power Supply “boot up” and level out helps. Which is similar to saying I think there’s odd startup power issues with this $10 HDD Power supply.

I’d be thrilled to get a better PS when I run across one. But first… when I can, that 10k resistor test :slight_smile:

Thanks guys!

@Hugo - Good news! Switch from 100k -> 10k resistor solved the issue.

Yep, this sounds very much like a rise time issue. What’s happening is that because the voltage ramp is slow, the imp is booting and doing the LED type detection before the voltage has got high enough to be able to discern the LED conduction.

The resistor is there to help this, but in certain circumstances (eg high capacitance on that line) you need more current to read the type reliably.

Yeah I read up on the whole rise-time issue yesterday after you mentioned it, which totally explains the lower resistor value solving the issue.

This is not your problem to solve, but I’m just wondering out loud why I have a rise time issue:

  • The resistor goes to ground, so it’s not really “rising to 0”… or perhaps somehow there’s a bunch of voltage that needs to get “drained out” quickly. But where does that “charge” originate from being that the device was off?

IMP.RED->100 Ohm->LED.RED.PIN->10k Ohm->GND

Anyways, if anyone passing by has ideas, please let me know so I can design better in the future!