This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[参考译文] MSP430FR2433:输出引脚不会变为高电平或低电平

Guru**** 2538950 points
Other Parts Discussed in Thread: MSP430FR2433

请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

https://e2e.ti.com/support/microcontrollers/msp-low-power-microcontrollers-group/msp430/f/msp-low-power-microcontroller-forum/1107244/msp430fr2433-output-pin-wont-go-high-or-low

器件型号:MSP430FR2433

每当我调用驱动程序库函数时、引脚永远不会变为低电平、也不能将其更改为高电平、 但是、如果我访问寄存器来代替驱动程序库函数  、我可以正确控制引脚、而不会出现任何问题。IAM 将引脚配置为输出、我不确定为什么会这样做。有什么想法吗?

GPIO_setAsOutputPin(GPIO_PORT_PX,GPIO_PINX); //Config pins

PXOut |=  (1<< PIN) //Works and can toggle pins

GPIO_setOutputLowOnPin(GPIO_PORT_PX,PIN_X); //Doesnt toogle pins

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    尊敬的 John:

      在 GPIO 配置之后、您是否调用过 PMM_unlockLPM5?

       PMM_unlockLPM5();

    MSP430FR2433上的引脚在启动时为高阻抗、您完成的初始化在 PM5CTL 中清零 LOCKLPM5位后才会生效。 有关  这方面的更多详细信息、请参阅《MSP430FR4xx 和 MSP430FR2xx 系列用户指南》(SLAU445)的第8.3.1节。  

    此致、
    Brandon Fisher