1.2.2.1.2.4.5 GATTC_DiscoverPrimaryServiceByUUID

C

uint16_t GATTC_DiscoverPrimaryServiceByUUID(uint16_t connHandle, GATTC_DiscoverPrimaryServiceByUuidParams_T *p_discParams);

Description

GATT Client starts the procedure for discovering primary service by UUID within the given input handle range. Multiple instances of the primary service with specified UUID may be present on the GATT server. Hence, the event GATTC_EVT_DISC_PRIM_SERV_BY_UUID_RESP may be generated multiple times until all the service instances are discovered.

Following events may be generated:

Parameters

ParameterDescription
[in] connHandleHandle of the connection to discover the services.
[in] p_discParamsPointer to structure containing the UUID of the primary service and handle range to be queried.

Return values

Return valueDescription
MBA_RES_SUCCESSSuccessfully starts the discovering.
MBA_RES_OOMInternal memory allocation failure.
MBA_RES_INVALID_PARAInvalid parameters. Connection handle is not valid.
MBA_RES_BUSYGATT Client is busy. Another request is ongoing.