Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

After you have verified the operation, you will write a program to control the m

ID: 2081681 • Letter: A

Question

After you have verified the operation, you will write a program to control the motor. Your application should use two pins as user inputs, which we will call A and B. If the user inputs AB 00, the motor should be off. If the user inputs AB 11, the motor should be on. If the user inputs AB 01, you should turn the motor on and off at 2 second intervals. If the user inputs AE 10, you should apply a pulse train to the control input with a frequency according to the table below that is 50% high and 50% low. This should mak the motor rotate at half speed. A 12v IN 4001 Control IRF620 Input Cnd Figure 21: Controlling a DC motor with a MosFET.

Explanation / Answer

To control a DC motor from a microcontroller, you use switching arrangement known as an H bridge. It looks like this: