The last couple of days, I have been designing a LED light bar indicator for current consumption. It would be for a display on a power supply circuit, used instead of a panel meter to indicate how much current is being used (much less accurately, though). So, I put a sense resistor on the high side of the input voltage, with a 2.5 volt reference IC (I found some for less than 25 cents each on goldmine-elec-products.com) to generate a reference voltage 2.5 volts below Vin. Using the reference voltage, a couple of op-amps can generate a power supply any fixed amount I choose below the Vin (as long as it is still higher than ground). Then I was planning to use a resistor network to divide the Vin - Vref into several ranges, and each node between resistors would have a comparison with Vout (the downstream side of the sense resistor), to decide if the corresponding LED should be lit. After I did this much of the design, I realized there's a reason not to design things with reversed polarity from the way everyone else does it. There don't seem to be comparators that can operate on input voltages near the positive rail.
Anyone know if a comparator like this exists? Four in a package would be good.
Oh, I just found it I think: LMC6762. I searched for quite a while earlier, but just realized I had been searching for "LM6762" without the C. I couldn't find it for sale anywhere, and the one datasheet I found indicated that it is a deprecated design. Now that I am searching for the correct part number, I found several listings on Mouser and they don't indicate "NRND," so I think this is OK to use. The only thing is, this is only a dual regulator, and quad ones would be useful, but dual is better than single and much better than nothing. The other nice thing about the LMC6762 for this design is that it has enough output current to drive the LEDs directly.
I realize that this circuit could probably be designed more easily by putting the sense resistor on the output of the regulator, and driving the comparator + voltage from the input voltage. That way, inputs near the positive rail would not be required. But I wanted to also complete the design I am working on because it seems to be better for modularity, that is, it could be re-used in various situations where a higher voltage may not be readily available.