Greetings. I'm hoping to gain a better understanding of what is going on in a particular circuit design.
I have an ATtiny running off of a 3V CR1225. It's driving a charge pump to about 4.2V, the output of which is feeding a 1k resistor connected to the anode of a ~20cd 5mm white LED with datasheet citing Vf=3.2V @ 20mA. The cathode is directly connected to the microcontroller pin to test my theory that this shouldn't be detrimental to the MCU.
When the microcontroller's output pin is set logic high, the LED is unlit. At the same time, voltage at the output pin measures about 2.6V, voltage across the LED is about 1.6V (which I would expect: 4.2V-2.6V=1.6V), and voltage across the 1K is about 5mV (I=5uA). Battery voltage is measures about 2.6V as well. Alright, sure, I should measure with a DMM not an oscilloscope.
What I think is happening is that the LED is only just barely forward biased when "off", so very little current can flow. I guess this current is passing through the high side protection diode which is itself very slightly forward biased.
While we're at it, what's a reasonable way to model the AVR output in LTSpice? Forgive me if this is stupid but I have a high side PMOS, low side NMOS, and two Schottky diodes. The model behaves more or less similarly to the real circuit as far as I can see so far. In that model, the small "off" current is indeed going through the high side protection diode.
Insights welcome. Many thanks in advance.