Question: This program should be in C Language or x86 language This program should rotate the LEDs using both variable delay and direction. The delay and

This program should be in C Language or x86 language

This program should be in C Language or x86 language This program

This program should rotate the LEDs using both variable delay and direction. The delay and direction should be controlled by the on-board potentiometer, which is read by the analog to digital converter (ADC) on the microcontroller. When the arrow on the potentiometer is pointing straight up (toward the edge of the board where the PICkit3 programmer connects), the LEDs should not change at all. If the arrow points to the left of that position, the LEDs should rotate left; if the arrow points to the right of that position, the LEDs should rotate right. The speed of rotation is dependent on how far from the center the arrow is, as shown below. Please note that "fast rotation" should still be slow enough that you can sec the LEDs rotating they shouldn't change so fast that all lights appear to be on. In addition to using the potentiometer to control direction and speed of rotation, this exercise should use the switch to enable and disable rotation. If the switch is pressed while the LEDs are rotating, the system should pause in its current position, regardless of whether the ADC input value changes. If the switch is pressed while everything is paused, the system should resume rotating in the appropriate direction based on the ADC input value. Demonstration; You must show that the potentiometer controls the direction and speed of rotation in the manner described-both slow and fast rotation in either direction, as well as pausing when the potentiometer is centered. You must also show that the button toggles the mode of operation-press the button to pause the system, and move the potentiometer to show that it does not affect the LEDs when paused. Press the button again to show that rotation resumes at that point

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!