This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

S120 adding 2 uuids for 2 peripherals

Hello, I am working on S120 SD v2.1.0 for central and S110 v8.0 SD for peripheral and SDK9.0 and I am able to configure 1 single uuid on central and connect to multiple peripherals with the same UUID.

But now I am trying to configure different UUID for 2 different peripherals, and on the central side I added the UUID as follows:

	ble_uuid_t uuid;
uuid.type = m_base_uuid_type;
uuid.uuid = BLE_UUID_NUS_SERVICE;

err_code = ble_db_discovery_evt_register(&uuid, db_discovery_evt_handler);
APP_ERROR_CHECK(err_code);

uuid.type = m_base_uuid_type;
uuid.uuid = 0x0002;

err_code = ble_db_discovery_evt_register(&uuid, db_discovery_evt_handler);
APP_ERROR_CHECK(err_code);

i.e., one with NUS service and other with UUID = 0x0002. Now the issue I am facing is, the ID with 0x0002 is not able to connect. When the central connects to the device, I am getting BLE_DB_DISCOVERY_SRV_NOT_FOUND event . Since this is major requirement for my application, can anyone help me in configuring this? I'm I missing anything in configuration?

Regards,
Sowmya

Parents
  • I tested by adding a single service at a time, and it is able to discover and connect. Next, I need the central to connect to 2 different peripherals with different service. I am not getting to know how to add 2 services on the central? The service is not discovering only if I two services in the central. But each peripheral have unique services.

Reply
  • I tested by adding a single service at a time, and it is able to discover and connect. Next, I need the central to connect to 2 different peripherals with different service. I am not getting to know how to add 2 services on the central? The service is not discovering only if I two services in the central. But each peripheral have unique services.

Children
No Data
Related