Hello. I am using LPC1114FBD48. I want to use pin 29 (P0.10) as a PWM output. However, it is not output by PWM but always outputs "HIGH" status. I need help with what is the problem.
Let me briefly list the code I tried.
For reference, if I program another PWM output pin in the same order as the code below, it works fine.
PWM0_PORT = 0,
PWM0_PIN = 10,
PWM0_MASK = 0b1 << 10,
PWM0_IOCON = IOCON_PIO0_10,
PWM0_MODE = 0x3|(0x1 << 3)
// configuration code
LPC_TIMER16_0->PWMC = 1<<0 | 1<<2; // M0,M2 to PWM
LPC_TIMER16_0->MR = 1999;
LPC_TIMER16_0->MCR = 0b010000000000; // M3 is used to set PWM Cycle
// code to output pwm pulse.
LPC_TIMER16_0->MR = 1000;