Question: Code for part 2.1: //Include the needed header file #include //Driver code int main(void) { //Declare needed variable volatile int index; //Initialize stop watch dog

 Code for part 2.1: //Include the needed header file #include //Driver

Code for part 2.1:

//Include the needed header file #include

//Driver code int main(void) { //Declare needed variable volatile int index;

//Initialize stop watch dog timer WDTCTL = WDTPW | WDTHOLD; //Setup P1's bit 0 as output result P1DIR = 0x01; //Initialize P1's bit 0 as zero P1OUT = 0x00;

//Loop for (;;) { //Toggle the P1's bit 0 P1OUT ^= 0x01; //Delay for (index = 0; index

Start with your program in part 2.1 and create a C program that runs on the MSP430 that will execute an interrupt subroutine in response to pushing button P1.1 and as a result increases the rate at which LED1 (port 1 pin 0) blinks. Your program should increase the rate at which LED1 blinks for 4 button presses. On the fifth button press the program should reset the LED1 blink rate to 1 Hz. Start with your program in part 2.1 and create a C program that runs on the MSP430 that will execute an interrupt subroutine in response to pushing button P1.1 and as a result increases the rate at which LED1 (port 1 pin 0) blinks. Your program should increase the rate at which LED1 blinks for 4 button presses. On the fifth button press the program should reset the LED1 blink rate to 1 Hz

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!