Hi!
I'm trying to implement my own service, which is based on Thingy TCS and another one I implemented by following this tutorial. https://github.com/bjornspockeli/custom_ble_service_example.
I'm new to developing BLE solutions.
I do these things:
- Create a new Custom Service
- Add new Characteristics
- Add the new CUSTOM_SERV_UUID to advertising array in main.c
- Set NRF_SDH_BLE_VS_UUID_COUNT to 2 inside the sdk_config.h
- Initialize service.
- Set NRD_SDH_BLE_GATTS_ATTR_TAB_SIZE to 2000, instead of 1408, inside the sdk_config.h.
But when I try to run, my application stops to do advertising. My application crashes when executing this code, inside the ble_wcs_init function, which is inside in ble_wcs.c:
err_code = sd_ble_uuid_vs_add(&wcs_base_uuid, &p_wcs->uuid_type);
And after this, the error 4 is returned from sd_ble_uuid_vs_add() function.
I think I have two possible errors:
1 - I need to set the RAM_START and RAM_SIZE values. But how can I find a correct value from RAM_SIZE?
2 - When I created my new service, I put this in an advertising package and this made it exceed the allowed 31-byte value of advertising, one option is to configure advertising packet to scan response packet. But I do not want to do this, because my own "TCS" service does not need to be inside the ad packet.
Could anyone help me to solve this issue?
Ps: Sorry for my English and my question.