如果I/O口设为第二功能,还要设为输入输出吗?例如P1SEL=0XFF;P1还要设为输出吗
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.
fan yu,
在IO被选择为第二功能后,还需要根据功能设置输入输出。以下为datasheet原话:
Setting PxSELx = 1 does not automatically set the pin direction. Other peripheral module functions may
require the PxDIRx bits to be configured according to the direction needed for the module function. See
the pin schematics in the device-specific data sheet.
希望我的回答对您有帮助。