This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Is it possible to creat a pwm with 1sec period

Dear All :

Is it possible to creat a pwm with 1sec period? Since the lowest frequency of the base clock is 125kHz,the top count of the pwm with 1sec period will be 125000(for case of up counter)。But the top count is a uint16_t integer that the maximum value is 65536。

Besides, I find the available base clock frequency can be 0 - 16 MHz 1 - 8 MHz 2 - 4 MHz 3 - 2 MHz 4 - 1 MHz 5 - 500 kHz 6 - 250 kHz 7 - 125 MHz in PWM_DEFAULT_CONFIG_BASE_CLOCK.

But I can not find the base clock frequency below 125kHz in the structure nrf_pwm_clk_t (in the example pwm deiver); How can I use a base_clock frequency below 125kHz (Is it possible to change the pwm_clock? )

Thank you for your comment and suggestion。 Best Wishes!

Related