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

ble_gatts_service_add error code 0x07

I brought up the Template example on the S110 for nrf51822 and as an exercise, attempted to add in the battery service. I just did a few simple things:

in main.c: -included ble_bas.h -declared static ble_bas_t -in services_init, i added : ble_bas_init(&m_bas, &init); -in ble_evt_dispatch, i added : ble_bas_on_ble_evt(&m_bas, p_ble_evt)

i am getting error 0x07 when the services are initialized and then it jumps to NVIC RESET. If I comment out the service initialization, my device beacons as expected, but obviously without the service running.

What is wrong? Why didn't this work? I am modeling my own service after this one, and of course, I am getting the same result. How do I fix this?

Related