This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Add CTS current time service

Hi all,

i want to add a cts service to my project. i started with ble_cts example of sdk 11.0, but it's not clear what is the correct procedure to do it. I add the service in service init and the db_ event_handler and cts_event_handler in my project. But the problem is that softdevice don't receive the BLE_GATTC_EVT_CHAR_DISC_RSP. There is other thing that i must done? What is the correct procedure to add a service current time?

Thank you!!

Parents
  • Hy Krisitin,

    thank you for the answer. I add all things about the service:

    • initialization of service cts in service_init();
    • initialization of db disc discovery in my main();
    • add db_disc_handler
    • Add ble_conn_state_on_ble_evt and ble_cts_c_on_ble_evt in my ble_evt_dispatch
    • Finally the on_cts_c_evt().

    I debug the example ble_app_cts_c and i see that after the connection softdevice send event BLE_GATTC_EVT_CHAR_DISC_RSP to db_discovery_on_ble_evt. The problem is that MY progect this events not oocurs... And i don't know why. It's not clear how the sfotdevice send a events that are processed from ble_evt_dispatch...

    One different from my project and ble_app_cts_c is that i use a peer manager and in the example use a device_manager_init.

    Thank you, Anna

Reply
  • Hy Krisitin,

    thank you for the answer. I add all things about the service:

    • initialization of service cts in service_init();
    • initialization of db disc discovery in my main();
    • add db_disc_handler
    • Add ble_conn_state_on_ble_evt and ble_cts_c_on_ble_evt in my ble_evt_dispatch
    • Finally the on_cts_c_evt().

    I debug the example ble_app_cts_c and i see that after the connection softdevice send event BLE_GATTC_EVT_CHAR_DISC_RSP to db_discovery_on_ble_evt. The problem is that MY progect this events not oocurs... And i don't know why. It's not clear how the sfotdevice send a events that are processed from ble_evt_dispatch...

    One different from my project and ble_app_cts_c is that i use a peer manager and in the example use a device_manager_init.

    Thank you, Anna

Children
No Data
Related