Hi @Irv95G
What's the board you are using? MIMXRT1020-EVK? If yes, J18_5 is GPIO_AD_B1_15.
About the PWM code, you can refer to the SDK code:
SDK_2_10_0_EVK-MIMXRT1020\boards\evkmimxrt1020\driver_examples\pwm
You need to check the PWM supported pins:
Your GPIO_AD_B1_15 is not the PWM pin.
So, you also can use the timer associated with the GPIO to toggle your GPIO_AD_B1_15.
About the timer, you can use PIT, GPT etc.
In fact, I think you can use the QTMR , PWM supported pins to output the PWM.
Wish it helps you!
Best Regards,
kerry