5. (15 points) Pulse width modulation (PWM) from pin 10 of an Arduino Uno (the kind you used in lab) is used to control the brightness of an LED. The 5 V PWM output is connected through a 262 Ω resistor to the LED and from the other end of the LED to ground. You can dim the LED almost continuously with commands like:
AnalogWrite(10,255); // Power the LED at maximum brightness
AnalogWrite(10,0); // Turn the LED off completely.
In the following, assume that the diode drop for the LED is 1.8 V (typical for a red LED).
(a) The LED is flickering at 490 Hz, which becomes noticeable when your eyes scan quickly past the LED. Explain why the flicker is happening. Draw a time series of the voltage and label the period.
(b) To eliminate the flicker, your lab partner puts a low pass filter (with fe well below 490 Hz) between the Arduino and the 262 Ω resistor. What is the lowest value of x for which AnalogWrite(10,x) will light the LED?
(c) Suggest an alternate way to make the flickering less noticeable (a qualitative answer is sufficient) as we did in lab.