This section defines the server part API of the service discovery protocol, so that the user can add the customized records.
More...
This section defines the server part API of the service discovery protocol, so that the user can add the customized records.
Terms and Acronyms
| Terms | Details |
| SDP | Service Discovery Protocol. For more information, please refer to Wikipedia. |
| L2CAP | Logical Link Control And Adaptation Protocol Specification. For more information, please refer to Wikipedia. |
| ATT | Attribute Protocol. For more information, please refer to Wikipedia. |
| UUID | Universally Unique Identifier. For more information, please refer to Wikipedia. |
| RFCOMM | Radio Frequency Communications. For more information, please refer to Wikipedia. |
| OBEX | Object exchange. For more information, please refer to Wikipedia. |
| SIM | Subscriber identity module. For more information, please refer to Wikipedia. |
| URL | Uniform resource locator. For more information, please refer to Wikipedia. |
How to use this module
- Add a customized record with the service name, language list, service class ID list and the protocol description list for a sample profile. Please add your own record according to the SDP interoperability requirements in the related profile specification. To add customized records with the SDP macros and API:
- Sample code:
static const uint8_t bt_sample_service_name[] =
{
'S', 'a', 'm', 'p', 'l', 'e','\0'
};
static const uint8_t bt_sample_language_list[] =
{
};
static const uint8_t bt_sample_service_class_id_list[] =
{
};
static const uint8_t bt_sample_protocol_description_list[] =
{
};
{
};
{
.attribute_list = bt_sample_sdp_attributes,
};
&bt_sample_sdp_record,
};
{
*record_list = &sdps_sample_record;
}
|
| | Define |
| | This section defines the macros for the SDP server.
|
| |
| | Struct |
| | This section defines the structures for the SDP server.
|
| |
This is a user defined callback and called by the SDP.
It might be implemented by the application to provide the customized record and record number.
- Parameters
-
| [in] | record_list | is a pointer to the record list. If there is no customized record, the record_list should be NULL and return 0. |
- Returns
- The record number.