Does PWM frequency of all 4 channels in one pwm module on an nRF52840 have to be the same?

Hi,

I am developing an application for an nRF52840 using nRF Connect SDK v2.9.0. The application currently uses the Zephyr driver for simple PWM functions on several GPIOs. Does the PWM frequency across all 4 channels (CH0, CH1, CH2, CH3) in one module (for example pwm0) have to be the same?

I think the answer is yes per the nRF52840 product specification. Correct me if I'm wrong.

However, the follow up question: Does the SDK or the Devicetree Visual Editor detect different PWM frequencies as a problem? It doesn't seem like it does, and so, if different channels of one pwm module are set to different frequencies, what frequency will prevail?

Thanks,

Ken

Parents Reply
  • Hi Edvin,

    We are far away from my original ticket, but thank you so much for the discussion.  Indeed, I have found that Nordic's support provided here has been world class.  I appreciate it very much.

    You said "Unless you specify NCS applications to use the Zephyr controller, it will use the SoftDevice Controller by default".  I think I have used defaults all along the way so I think my application is using SoftDevice.  If I wanted to use the Zephyr control, how would I specify this?  How can I check to ensure my application is using SoftDevice?

    Ken

Children
  • Hello Ken,

    Sorry for not specifying in my previous reply.

    If you want to test the Zephyr Bluetooth Low Energy controller, instead of the Softdevice controller, you will have to add:

    CONFIG_BT_LL_SW_SPLIT=y

    in your prj.conf. 

    This config is defined in ncs\zephyr\subsys\bluetooth\controller\kconfig:

    config BT_LL_SW_SPLIT
    	bool "Software-based BLE Link Layer [EXPERIMENTAL]"
    	select EXPERIMENTAL
    	select ENTROPY_GENERATOR
    	help
    	  Use Zephyr software BLE Link Layer ULL LLL split implementation.
    

    So if you are using NCS, and do not have a line saying CONFIG_BT_LL_SW_SPLIT=y in your prj.conf or any other .conf files present in your application folder, then you are using the softdevice controller. 

    Best regards,

    Edvin

Related