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

NRF51822 scan_start problems

Hello all,

I am having problems with scan_start function (or something connected with it). I am using NRF51822 on custom board, using BLE functionality and also UART for communication to PC. I am using CLOCK_LFCLKSRC_SRC_RC clock source. My pins for UART are p0.26 and p0.21. P0.26 has internal pull-up enabled. I have also disabled flow control.

My program works normally if I am using UART and my device is advertising. I can receive and transmit data to PC. But as soon as I use scan_start function, problems appear. It does not happen every time, but still very often, than during/soon after scan, command sent through UART hangs the execution of code on processor - I get a Hard fault. Those LOG_INFOs in scan_start are transmitted normally - error_code: 0.

Are there any known problems with UART & scanning/advertising? Could be the problem with advertising during scan?

Any suggestion would help.

Those are my parameters and scan_start function. code.txt

Related