Hardware PWM in CubeCell-1/2AA

Hello. I want to use the hardware PWM from HelTecAutomation/ASR650x-Arduino/cores/asr650x/cores/PWM1.h on a CubeCell-1/2AA board, but I get an “undefined reference to `PWM1_Init()” compilation error. Do these functions need any special compiler settings?
Actually, with all functions from PWM1.h the same error.


could you update your Development environment and try this code:

Thanks for the answer. In this example, I don’t understand how to set the desired PWM frequency and how to set the duty cycle. I need a frequency of 50 kHz and a duty cycle of 2-98%. Yes, I did an Development environment update via git

for example:


the PWM frequency is a/b. c used for set dutycycle, it’s value can be 0-b;

I get an error when I try to upload this code

error: ‘setPWM_Frequency’ was not declared in this scope

I am using Arduino 1.8.13 Any idea as to why?


I have tested it. it work fine.

maybe you can updated your Development environment(git vesion).