Part Number: MSP432P401R
Tool/software: Code Composer Studio
Hi everyone I am new to MSP432 . I want to turn on led by pressing push button.
Since i am new to this, i would like to know detailed about pin selction and coding details.can anyone please help in this.
#include "msp.h"
void main(void)
{
volatile uint32_t i;
WDTCTL = WDTPW | WDTHOLD;
int value = P1IN & BIT1;
while(1)
{
if(value==0)
P1OUT |= BIT0;
else
P1OUT &= ~BIT0;
}
}