TI中文支持网
TI专业的中文技术问题搜集分享网站

MSP430FR5994: what is "PM5CTL0 &= ~LOCKLPM5;" meaning?

Part Number:MSP430FR5994

#include <msp430.h>

void main(void) {WDTCTL = WDTPW | WDTHOLD;// Stop watchdog timerPM5CTL0 &= ~LOCKLPM5;// Disable the GPIO power-on default high-impedance mode// to activate previously configured port settingsP1DIR = 0x01;// Set P1.0 to output directionP1OUT = 0x00;P1REN = 0x00;while(1){if ((P1IN & 0x08) == 0x08)P1OUT = 0x01;elseP1OUT = 0x00;}

}

In this code, i am try to achieve a voltage detecttion, however, i don't know the meaning of code "PM5CTL0 &= ~LOCKLPM5;". if i delete it, the output of specific pin would keep in off state. 

So i want to the accurate meaning of the code "PM5CTL0 &= ~LOCKLPM5;" and how to use it correctly.

Alice:

Hello,

       

       MSP430FR58xx, MSP430FR59xx, and MSP430FR6xx Family User's Guide (Rev. P) (ti.com.cn)

赞(0)
未经允许不得转载:TI中文支持网 » MSP430FR5994: what is "PM5CTL0 &= ~LOCKLPM5;" meaning?
分享到: 更多 (0)