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

Adding PWM Driver to ble_blinky_central example

Hi All,

I created one channel PWM from pwm_drive example and its works well.

Now i m trying to add the PWM functions ...into my ble_blinky_central example.

Compilations fine but during run time Fault handler error at ->     nrf_pwm_configure(p_instance->p_registers,
        p_config->base_clock, p_config->count_mode, p_config->top_value);

no clue why this is happening ...

attached  the sdk_config.h for reference sdk_config.h

thanks

Ashok

Parents Reply Children
  • Hi,

    What Softdevice and board are you using?

    I'm sorry I should have elaborated a bit more on my previous reply, the debug terminal should print what file and line number that you're getting the error at if you define the #DEBUG flag in the preprocessor defines. See this similar thread if you're unsure on how to define it.

    regards

    Jared 

  • Hi JaFF0000,

    Point 1: Some times i did not see replay option here for the latest thread. -> for community developer

    Point 2:  Debug Prints -> example NRF_LOG_() i have no idea where this gets printed, really worried for this kind of complexity with nordic SDK. 

    Expectation is : any example if i open and run, i should see the prints out in debug console without doing any circus with configuration.

    I struggled but completed my work without using any console print outs. The reason is SDK and implementation was awesome.

    Still, Nordic should think of handling the sdk_config.h file better way in future.

    Point3: PWM now works with the app_pwm.c file , earlier i tried with driver files where i got trapped. I can suggest how we can reproduce the issue on your end.

    1.Take any ble_client example projects , add PWM drivers to that then you see the issue.

    Thanks
    Ashok r

  • Hi again.

    Thank your for the feedback, I'll pass it further to the appropriate persons. Good that you solved the issue.

    regards

    Jared 

Related