Hi,
I am creating a wrapper that uses nrf-ble-driver-sd_api_v6-mt-4_1_1.dll. I had burn the dongle with fw: connectivity_4.1.1_usb_with_s140_6.1.1.hex.
I am trying to create a central app by following and modifying the heart_rate_collector example.
There are 2 questions that i need help currently.
Question 1:
Why is it that i am unable to find the name of some of the ble peripheral by follow the heart_rate_collector example but i am able to find the names using nRF connect application?
I am using the code:
//search for advertising names
err_code = adv_report_parse(BLE_GAP_AD_TYPE_COMPLETE_LOCAL_NAME,
&adv_data,
&dev_name);
and
// Look for the short local name if it was not found as complete
err_code = adv_report_parse(BLE_GAP_AD_TYPE_SHORT_LOCAL_NAME,
&adv_data,
&dev_name);
Question 2:
Upon using the peer address to connect, how can i discover all of the peripheral services?
From the code:
static uint32_t service_discovery_start()
{
uint32_t err_code;
uint16_t start_handle = 0x01;
ble_uuid_t srvc_uuid;
printf("Discovering primary services\n");
fflush(stdout);
srvc_uuid.type = BLE_UUID_TYPE_BLE;
srvc_uuid.uuid = BLE_UUID_HEART_RATE_SERVICE;
// Initiate procedure to find the primary BLE_UUID_HEART_RATE_SERVICE.
err_code = sd_ble_gattc_primary_services_discover(m_adapter,
m_connection_handle, start_handle,
&srvc_uuid);
So by changing the uuid, i can discover individual services. Is it possible to find all of the ble peripheral services instead of looking for it 1 by 1?
If the uuid is a vendor specific uuid, how can i find them?
Thanks for helping.
Regards,
LC