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.

28379D

在初始化时将GPIO口配置为PWM模式还能在设定数据寄存器的值为1吗?如下:

GpioCtrlRegs.GPAGMUX1.bit.GPIO0 = 0;
GpioCtrlRegs.GPAMUX1.bit.GPIO0 = 1; //配置为EPWM1A
GpioCtrlRegs.GPAPUD.bit.GPIO0 = 1; //关闭上拉;

GpioDataRegs.GPASET.bit.GPIO0= 1;    //默认输出设置为1