Unable to discover service

Hi,

I'm using SDK5 17.1.0 and SD132 v7.3.0. At the moment I'm developing a central device which scans for a peripheral. I did this a few times before with other devices and never had a problem with it. But now, the central is unable to discover the services of the peripheral. In my db discovery event handler I always get the event IDs for BLE_DB_DISCOVERY_SRV_NOT_FOUND and BLE_DB_DISCOVERY_AVAILABLE. I double checked the custom UUID of the service and it's correct. If I use nrf connect on my mobile phone the discovery is completed without any error. 

My service definition looks like this: 

#define DNC_C_BASE_UUID             {0x48, 0x62, 0x6d, 0x47, 0x20, 0x65, 0x63, 0x6e, 0x61, 0x44, 0x20, 0x20, 0x00, 0x00, 0x00, 0x00} 
#define BLE_UUID_DNC_C_SERVICE      0x1000  // UUID of DNC Client Service

and the service I'm looking for looks like this in nrf connect: UUID: 00001000-2020-4461-6e63-6520476d6248

I found this post, but I'm using the peer manager and I also handled this event. By the way, if I change the UUID and advertising search pattern to another device with a different service, I can find it without problems. At the moment I have no idea what I'm missing. Is there a way in the SDK to see all available services of my device instead of searching for a specific UUID?

Best regards,

Christian

Parents Reply Children
  • Hi Kenneth,

    tanks for your reply. If I understood this correctly, it was about setting the service UUID to the stack via sd_ble_uuid_vs_add(). I'm doing this already at application start when I initialise the services. So for me it looks, like the service is still not found at all. In my post above I saw the service UUID and thought that it was found, but I think it was only shown because I set the UUID before with ble_db_discovery_evt_register. Do you have any other idea, that could help?

    Best regards,

    Christian

Related