Write a C program that will do the following: Send “Ready:” message from the dragon12 board to the serial terminal in the computer using the serial communication interface in the HCS12. Wait until the user pushes a SW5. Once pushed, the program will make a random delay between 1 to 3 seconds. After that delay, your program will turn on LED 0 and make a tone (500 Hz) on the speaker. Once the user pushes SW2, the tone should stop and LED 0 should go off. Your program will then calculate the time interval in millisecond starting from turning on LED 0 until pushing SW2. Send “Your Time Reaction is: T ms” to the serial terminal in the computer where T represents that reaction time. Go back to step 1.
Write a C
Trending now
This is a popular solution!
Step by step
Solved in 2 steps