Hi AVR Experts,
As the title suggests, I'm having problem with the output of my ATTiny2313. I'm trying to drive my LED strip using PWM. Everything looks fine until I set the PWM duty cycle to 0. The LED doesn't turn off completely, there is still a little light shines, though, dimly.
I think this is really weird and check the output signal using my oscilloscope to make sure the duty cycle is really 0. Surprisingly, the duty cycle is really 0, but it has a higher voltage than the datasheet tells. It is supposed to have a maximum 0.7V, yet I have 0.8V and some spikes that peak up to 2V. However, the power supply is perfectly fine, it produces a flat 5V, you can see it in the attachment. The yellow one is my power supply voltage, the red one is the ATTiny output pin.
I don't understand how it happens. Can you guys tell me some clues to fix this?
Oh, btw I'm using the PWM to drive a TIP41C transistor in series with a 100K resistor.