Draw the state diagrams for both state machines. Whenever a signal influences the state of the other state machine, draw an arrow from that variable to the state in the other state machine.
What is the purpose of the
__IO in the
mytimer_t? Are there any other modifiers?
Explain in two sentences.
You can see that the numbers overflow after a certain amount of time. Measure that time using a stop watch and calculate the clock frequency. Write down your result. Does it agree with the frequency specified in the MSS Configurator Clock Manager block? Explain in two sentences.
How does the latency compare to the latency measured with the oscilloscope in Lab 4? Explain in two sentences.
Add PWM capabilities to your timer library, and write an application that generates a PWM signal at 100Hz and changes the duty cycle from 0 to 100% over 1 second. Observe the signal on an oscilloscope and the LED. Describe your observation in a few sentences and include a screenshot of the oscilloscope.
What do you observe between the synchronous and asynchronous capture values? Explain in a couple of sentences.
Change the GLC clock to 2.5 MHz, instead of 120 MHz and repeat the last experiment. Again, explain your findings.
Write a small reaction game. At a specific time, using the PWM output, toggle the LED on. The user has to hit the push button when he sees the light turning on. Then, output the time difference between LED toggle and button push on the serial terminal. How good is your reaction time in seconds?
Did you notice the symbol during the place
and route of your timer unit in