Question: Problem 1 7 : ( 3 5 points ) In Figure 1 , the user can tune the LED intensity through an incremental rotary encoder.

Problem 17: (35 points)
In Figure 1, the user can tune the LED intensity through an incremental rotary encoder. This rotary encoder is designed to generate 24 counts per revolution. Within this configuration, the dsPIC33EP64MC502 microcontroller monitors the rotary encoder's rotation by employing the modulo counter mode of the quadrature encoder interface module. A single complete clockwise rotation of the encoder shaft sweeps the duty cycle over its full range from 0% to 100%.
(5 points) Specify the peripheral pins to which the QEA and QEB are connected. Justify your answer in one or two short sentences.
(12 points) Add the comments for lines 15,20,31,32,34, and 52.
(3 points) Determine the peripheral pin to which the LED output is connected. Justify your answer in one or two short sentences.
(15 points) Modify the code so that two complete clockwise rotations of the encoder shaft sweep the duty cycle from 10% to 80%. Clearly identify the line(s) that require modification in Figure 1 using the line number(s), and provide corresponding modified code, along with a brief justification for each change.Figure 1: C code for Problem 17.
Problem 1 7 : ( 3 5 points ) In Figure 1 , the

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 Electrical Engineering Questions!