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

Hardfault Error after calling sd_ble_gap_adv_start

Hello,

im using NRF 51822 with SDK 10 / S110 8.0. Im working on a project that includes one or two timers (initialized by APP_timer function), the ble calender (like discriebed in ble_cts_c), some Gpio and the ble stack S110 module.

I initalized the ble stack and the inits like discriebed in some of the SKD10 examples. (template, ble_cts_c) and start one timer for time scheduling.

When I tested the system without acitiviating advertising start function my time schedule timer runs perfect. BLE stack is initalized at this point.

When I put in the Adversting start function (it dosn't matter if I'm usining the direct way via sd_ble_gab_adv_start() or the way like discribend in the expamples ( err_code = ble_advertising_start(BLE_ADV_MODE_FAST);) the system runs to a hard fault after some seconds. (in my mind it must be at the end of the first round of my time scheduler ~1s).

When I put out the starting of the advetismend the system runs fine again.

Does anyone has a idea whats going wrong?

Kind regards

Jens Woermann

Edit: For some more explanation: I'm using the timer for creating 1ms interrupts to build a internal time sceduler. After 1000 interrupts (1s) the internal counter will be reset to 0 and countings starts again. At the moment it looks like that around this point something happend what I can not see or debug when advertising is started. Normaly i can run one cycle - no more.

We dont using a Nordic devolpment board for our devolpment at the moment. It is a own created hardware with 51822. I only took the code from 3 examples (and one of a colouge of mine) and use it as orientation.

When I comment out sd_ble_gab_adv_start() in ble_advertising.c the system runs again. The idea of my colouge and me is that something is going wrong during the initalisation. But I'm not sure where I should look. Init Code is nearly hte same like in ble_cts_c exampe (I taken out the key boundery, because this works diffend at our board).

Related