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

How can i get primary service which i don't know

Hi. I'm using PCA10028, SDK10.0.0, S130 and "ble_app_uart_c" as reference.

As "ble_app_uart_c" source code, it already knows Service UUID.

uint32_t ble_nus_c_init(ble_nus_c_t * p_ble_nus_c, ble_nus_c_init_t * p_ble_nus_c_init) {

......

uart_uuid.type = p_ble_nus_c->uuid_type;
uart_uuid.uuid = BLE_UUID_NUS_SERVICE;

......

return ble_db_discovery_evt_register(&uart_uuid, db_discover_evt_handler);

}

What if I don't know service UUID? How can I discover all primary services which peripheral supports?

Related