![]() |
Cordio Stack and Cordio Profiles
r2p3-02rel0
|
Data Structures | |
| struct | attcDiscChar_t |
| ATT client structure for characteristic and descriptor discovery. More... | |
| struct | attcDiscCfg_t |
| ATT client structure for characteristic and descriptor configuration. More... | |
| struct | attcDiscCb_t |
| ATT client discovery control block. More... | |
ATT Client Discovery and Configuration Settings | |
Settings used to configurate ATT Discovery procedure for ATT Clients. | |
| #define | ATTC_SET_UUID_128 0x01 |
| Set if the UUID is 128 bits in length. | |
| #define | ATTC_SET_REQUIRED 0x02 |
| Set if characteristic must be discovered. | |
| #define | ATTC_SET_DESCRIPTOR 0x04 |
| Set if this is a characteristic descriptor. | |
ATT Client Functions | |
| void | AttcInit (void) |
| Initialize ATT client. More... | |
| void | AttcSignInit (void) |
| Initialize ATT client for data signing. More... | |
| void | AttcFindInfoReq (dmConnId_t connId, uint16_t startHandle, uint16_t endHandle, bool_t continuing) |
| Initiate an attribute protocol Find Information Request. More... | |
| void | AttcFindByTypeValueReq (dmConnId_t connId, uint16_t startHandle, uint16_t endHandle, uint16_t uuid16, uint16_t valueLen, uint8_t *pValue, bool_t continuing) |
| Initiate an attribute protocol Find By Type Value Request. More... | |
| void | AttcReadByTypeReq (dmConnId_t connId, uint16_t startHandle, uint16_t endHandle, uint8_t uuidLen, uint8_t *pUuid, bool_t continuing) |
| Initiate an attribute protocol Read By Type Request. More... | |
| void | AttcReadReq (dmConnId_t connId, uint16_t handle) |
| Initiate an attribute protocol Read Request. More... | |
| void | AttcReadLongReq (dmConnId_t connId, uint16_t handle, uint16_t offset, bool_t continuing) |
| Initiate an attribute protocol Read Long Request. More... | |
| void | AttcReadMultipleReq (dmConnId_t connId, uint8_t numHandles, uint16_t *pHandles) |
| Initiate an attribute protocol Read Multiple Request. More... | |
| void | AttcReadByGroupTypeReq (dmConnId_t connId, uint16_t startHandle, uint16_t endHandle, uint8_t uuidLen, uint8_t *pUuid, bool_t continuing) |
| Initiate an attribute protocol Read By Group Type Request. More... | |
| void | AttcWriteReq (dmConnId_t connId, uint16_t handle, uint16_t valueLen, uint8_t *pValue) |
| Initiate an attribute protocol Write Request. More... | |
| void | AttcWriteCmd (dmConnId_t connId, uint16_t handle, uint16_t valueLen, uint8_t *pValue) |
| Initiate an attribute protocol Write Command. More... | |
| void | AttcSignedWriteCmd (dmConnId_t connId, uint16_t handle, uint32_t signCounter, uint16_t valueLen, uint8_t *pValue) |
| Initiate an attribute protocol signed Write Command. More... | |
| void | AttcPrepareWriteReq (dmConnId_t connId, uint16_t handle, uint16_t offset, uint16_t valueLen, uint8_t *pValue, bool_t valueByRef, bool_t continuing) |
| Initiate an attribute protocol Prepare Write Request. More... | |
| void | AttcExecuteWriteReq (dmConnId_t connId, bool_t writeAll) |
| Initiate an attribute protocol Execute Write Request. More... | |
| void | AttcCancelReq (dmConnId_t connId) |
| Cancel an attribute protocol request in progress. More... | |
| void | AttcDiscService (dmConnId_t connId, attcDiscCb_t *pCb, uint8_t uuidLen, uint8_t *pUuid) |
| This utility function discovers the given service on a peer device. Function AttcFindByTypeValueReq() is called to initiate the discovery procedure. More... | |
| uint8_t | AttcDiscServiceCmpl (attcDiscCb_t *pCb, attEvt_t *pMsg) |
| This utility function processes a service discovery result. It should be called when an ATTC_FIND_BY_TYPE_VALUE_RSP callback event is received after service discovery is initiated by calling AttcDiscService(). More... | |
| void | AttcDiscCharStart (dmConnId_t connId, attcDiscCb_t *pCb) |
| This utility function starts characteristic and characteristic descriptor discovery for a service on a peer device. The service must have been previously discovered by calling AttcDiscService() and AttcDiscServiceCmpl(). More... | |
| uint8_t | AttcDiscCharCmpl (attcDiscCb_t *pCb, attEvt_t *pMsg) |
| This utility function processes a characteristic discovery result. It should be called when an ATTC_READ_BY_TYPE_RSP or ATTC_FIND_INFO_RSP callback event is received after characteristic discovery is initiated by calling AttcDiscCharStart(). More... | |
| uint8_t | AttcDiscConfigStart (dmConnId_t connId, attcDiscCb_t *pCb) |
| This utility function starts characteristic configuration for characteristics on a peer device. The characteristics must have been previously discovered by calling AttcDiscCharStart() and AttcDiscCharCmpl(). More... | |
| uint8_t | AttcDiscConfigCmpl (dmConnId_t connId, attcDiscCb_t *pCb) |
| This utility function initiates the next characteristic configuration procedure. It should be called when an ATTC_READ_RSP or ATTC_WRITE_RSP callback event is received after characteristic configuration is initiated by calling AttcDiscConfigStart(). More... | |
| uint8_t | AttcDiscConfigResume (dmConnId_t connId, attcDiscCb_t *pCb) |
| This utility function resumes the characteristic configuration procedure. It can be called when an ATTC_READ_RSP or ATTC_WRITE_RSP callback event is received with failure status to attempt the read or write procedure again. More... | |
| void | AttcMtuReq (dmConnId_t connId, uint16_t mtu) |
| For internal use only. More... | |
| void AttcInit | ( | void | ) |
Initialize ATT client.
| void AttcSignInit | ( | void | ) |
Initialize ATT client for data signing.
| void AttcFindInfoReq | ( | dmConnId_t | connId, |
| uint16_t | startHandle, | ||
| uint16_t | endHandle, | ||
| bool_t | continuing | ||
| ) |
Initiate an attribute protocol Find Information Request.
| connId | DM connection ID. |
| startHandle | Attribute start handle. |
| endHandle | Attribute end handle. |
| continuing | TRUE if ATTC continues sending requests until complete. |
| void AttcFindByTypeValueReq | ( | dmConnId_t | connId, |
| uint16_t | startHandle, | ||
| uint16_t | endHandle, | ||
| uint16_t | uuid16, | ||
| uint16_t | valueLen, | ||
| uint8_t * | pValue, | ||
| bool_t | continuing | ||
| ) |
Initiate an attribute protocol Find By Type Value Request.
| connId | DM connection ID. |
| startHandle | Attribute start handle. |
| endHandle | Attribute end handle. |
| uuid16 | 16-bit UUID to find. |
| valueLen | Length of value data. |
| pValue | Pointer to value data. |
| continuing | TRUE if ATTC continues sending requests until complete. |
| void AttcReadByTypeReq | ( | dmConnId_t | connId, |
| uint16_t | startHandle, | ||
| uint16_t | endHandle, | ||
| uint8_t | uuidLen, | ||
| uint8_t * | pUuid, | ||
| bool_t | continuing | ||
| ) |
Initiate an attribute protocol Read By Type Request.
| connId | DM connection ID. |
| startHandle | Attribute start handle. |
| endHandle | Attribute end handle. |
| uuidLen | Length of UUID (2 or 16). |
| pUuid | Pointer to UUID data. |
| continuing | TRUE if ATTC continues sending requests until complete. |
| void AttcReadReq | ( | dmConnId_t | connId, |
| uint16_t | handle | ||
| ) |
Initiate an attribute protocol Read Request.
| connId | DM connection ID. |
| handle | Attribute handle. |
| void AttcReadLongReq | ( | dmConnId_t | connId, |
| uint16_t | handle, | ||
| uint16_t | offset, | ||
| bool_t | continuing | ||
| ) |
Initiate an attribute protocol Read Long Request.
| connId | DM connection ID. |
| handle | Attribute handle. |
| offset | Read attribute data starting at this offset. |
| continuing | TRUE if ATTC continues sending requests until complete. |
| void AttcReadMultipleReq | ( | dmConnId_t | connId, |
| uint8_t | numHandles, | ||
| uint16_t * | pHandles | ||
| ) |
Initiate an attribute protocol Read Multiple Request.
| connId | DM connection ID. |
| numHandles | Number of handles in attribute handle list. |
| pHandles | List of attribute handles. |
| void AttcReadByGroupTypeReq | ( | dmConnId_t | connId, |
| uint16_t | startHandle, | ||
| uint16_t | endHandle, | ||
| uint8_t | uuidLen, | ||
| uint8_t * | pUuid, | ||
| bool_t | continuing | ||
| ) |
Initiate an attribute protocol Read By Group Type Request.
| connId | DM connection ID. |
| startHandle | Attribute start handle. |
| endHandle | Attribute end handle. |
| uuidLen | Length of UUID (2 or 16). |
| pUuid | Pointer to UUID data. |
| continuing | TRUE if ATTC continues sending requests until complete. |
| void AttcWriteReq | ( | dmConnId_t | connId, |
| uint16_t | handle, | ||
| uint16_t | valueLen, | ||
| uint8_t * | pValue | ||
| ) |
Initiate an attribute protocol Write Request.
| connId | DM connection ID. |
| handle | Attribute handle. |
| valueLen | Length of value data. |
| pValue | Pointer to value data. |
| void AttcWriteCmd | ( | dmConnId_t | connId, |
| uint16_t | handle, | ||
| uint16_t | valueLen, | ||
| uint8_t * | pValue | ||
| ) |
Initiate an attribute protocol Write Command.
| connId | DM connection ID. |
| handle | Attribute handle. |
| valueLen | Length of value data. |
| pValue | Pointer to value data. |
| void AttcSignedWriteCmd | ( | dmConnId_t | connId, |
| uint16_t | handle, | ||
| uint32_t | signCounter, | ||
| uint16_t | valueLen, | ||
| uint8_t * | pValue | ||
| ) |
Initiate an attribute protocol signed Write Command.
| connId | DM connection ID. |
| handle | Attribute handle. |
| signCounter | Value of the sign counter. |
| valueLen | Length of value data. |
| pValue | Pointer to value data. |
| void AttcPrepareWriteReq | ( | dmConnId_t | connId, |
| uint16_t | handle, | ||
| uint16_t | offset, | ||
| uint16_t | valueLen, | ||
| uint8_t * | pValue, | ||
| bool_t | valueByRef, | ||
| bool_t | continuing | ||
| ) |
Initiate an attribute protocol Prepare Write Request.
| connId | DM connection ID. |
| handle | Attribute handle. |
| offset | Write attribute data starting at this offset. |
| valueLen | Length of value data. |
| pValue | Pointer to value data. |
| valueByRef | TRUE if pValue data is accessed by reference rather than copied. |
| continuing | TRUE if ATTC continues sending requests until complete. |
| void AttcExecuteWriteReq | ( | dmConnId_t | connId, |
| bool_t | writeAll | ||
| ) |
Initiate an attribute protocol Execute Write Request.
| connId | DM connection ID. |
| writeAll | TRUE to write all queued writes, FALSE to cancel all queued writes. |
| void AttcCancelReq | ( | dmConnId_t | connId | ) |
Cancel an attribute protocol request in progress.
| connId | DM connection ID. |
| void AttcDiscService | ( | dmConnId_t | connId, |
| attcDiscCb_t * | pCb, | ||
| uint8_t | uuidLen, | ||
| uint8_t * | pUuid | ||
| ) |
This utility function discovers the given service on a peer device. Function AttcFindByTypeValueReq() is called to initiate the discovery procedure.
| connId | DM connection ID. |
| pCb | Pointer to discovery control block. |
| uuidLen | Length of service UUID (2 or 16). |
| pUuid | Pointer to service UUID. |
| uint8_t AttcDiscServiceCmpl | ( | attcDiscCb_t * | pCb, |
| attEvt_t * | pMsg | ||
| ) |
This utility function processes a service discovery result. It should be called when an ATTC_FIND_BY_TYPE_VALUE_RSP callback event is received after service discovery is initiated by calling AttcDiscService().
| pCb | Pointer to discovery control block. |
| pMsg | ATT callback event message. |
| void AttcDiscCharStart | ( | dmConnId_t | connId, |
| attcDiscCb_t * | pCb | ||
| ) |
This utility function starts characteristic and characteristic descriptor discovery for a service on a peer device. The service must have been previously discovered by calling AttcDiscService() and AttcDiscServiceCmpl().
| connId | DM connection ID. |
| pCb | Pointer to discovery control block. |
| uint8_t AttcDiscCharCmpl | ( | attcDiscCb_t * | pCb, |
| attEvt_t * | pMsg | ||
| ) |
This utility function processes a characteristic discovery result. It should be called when an ATTC_READ_BY_TYPE_RSP or ATTC_FIND_INFO_RSP callback event is received after characteristic discovery is initiated by calling AttcDiscCharStart().
| pCb | Pointer to discovery control block. |
| pMsg | ATT callback event message. |
| uint8_t AttcDiscConfigStart | ( | dmConnId_t | connId, |
| attcDiscCb_t * | pCb | ||
| ) |
This utility function starts characteristic configuration for characteristics on a peer device. The characteristics must have been previously discovered by calling AttcDiscCharStart() and AttcDiscCharCmpl().
| connId | DM connection ID. |
| pCb | Pointer to discovery control block. |
| uint8_t AttcDiscConfigCmpl | ( | dmConnId_t | connId, |
| attcDiscCb_t * | pCb | ||
| ) |
This utility function initiates the next characteristic configuration procedure. It should be called when an ATTC_READ_RSP or ATTC_WRITE_RSP callback event is received after characteristic configuration is initiated by calling AttcDiscConfigStart().
| connId | DM connection ID. |
| pCb | Pointer to discovery control block. |
| uint8_t AttcDiscConfigResume | ( | dmConnId_t | connId, |
| attcDiscCb_t * | pCb | ||
| ) |
This utility function resumes the characteristic configuration procedure. It can be called when an ATTC_READ_RSP or ATTC_WRITE_RSP callback event is received with failure status to attempt the read or write procedure again.
| connId | DM connection ID. |
| pCb | Pointer to discovery control block. |
| void AttcMtuReq | ( | dmConnId_t | connId, |
| uint16_t | mtu | ||
| ) |
For internal use only.
| connId | DM connection ID. |
| mtu | Attribute protocol MTU. |