This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

pwm can not work with softdevice, when i use s110(v7.1) , sdk 6.1

Hi Nordics,

I copy pwm sample code into my proximity project, to drive a buzzer .

I init pwm before softdevice. but, once "SOFTDEVICE_HANDLER_INIT" is excuted, the buzzer pin no longer toggle.

My question is , softdevice use TIMER0, my pwm use TIMER2, it seems that they are independent two modules. why pwm not working ?

Many thanks !

Bob

Parents
  • If you are using the code in pwm_example it may be because the example access some registers that are restricted when using SoftDevice, more specific NRF_CLOCK and NRF_POWER, see here. You will need to use sd_clock_hfclk_request and sd_power_mode_set instead, although these are not necessary (pwm will work fine with RC clock and not constant latency mode).

    This PWM example has a high possibility of inverting when using it with a SoftDevice. I will recommend to update to our newest SDK to use the newest driver which does not have this bug. You will need to update the SoftDevice also.

Reply
  • If you are using the code in pwm_example it may be because the example access some registers that are restricted when using SoftDevice, more specific NRF_CLOCK and NRF_POWER, see here. You will need to use sd_clock_hfclk_request and sd_power_mode_set instead, although these are not necessary (pwm will work fine with RC clock and not constant latency mode).

    This PWM example has a high possibility of inverting when using it with a SoftDevice. I will recommend to update to our newest SDK to use the newest driver which does not have this bug. You will need to update the SoftDevice also.

Children
No Data
Related