Rtos API example
AttReadResponse Struct Reference
The read response is sent in reply to a received Read Request and contains the value of the attribute that has been read. More...
#include <AttServerMessage.h>
Inherits ble::pal::AttServerMessage.
Public Member Functions | |
AttReadResponse (ArrayView< const uint8_t > data_) | |
Construct a Read Response from an array of bytes. | |
size_t | size () const |
Return the number of octets presents in the response. | |
uint8_t | operator[] (size_t index) const |
Return the octet at the specified index. | |
const uint8_t * | data () const |
Return the pointer to the actual data. | |
Data Fields | |
const AttributeOpcode | opcode |
Op code used to identify the type of the attribute response. |
Detailed Description
The read response is sent in reply to a received Read Request and contains the value of the attribute that has been read.
The attribute value shall be set to the value of the attribute identified by the attribute handle in the request. If the attribute value is longer than (ATT_MTU-1) then the first (ATT_MTU-1) octets shall be included in this response.
- Note:
- The Read Blob Request would be used to read the remaining octets of a long attribute value.
- see BLUETOOTH SPECIFICATION Version 5.0 | Vol 3, Part F Section 3.4.4.4
Definition at line 445 of file AttServerMessage.h.
Constructor & Destructor Documentation
AttReadResponse | ( | ArrayView< const uint8_t > | data_ ) |
Construct a Read Response from an array of bytes.
Definition at line 449 of file AttServerMessage.h.
Member Function Documentation
const uint8_t* data | ( | ) | const |
Return the pointer to the actual data.
Definition at line 471 of file AttServerMessage.h.
uint8_t operator[] | ( | size_t | index ) | const |
Return the octet at the specified index.
- Note:
- Out of range access is undefined.
Definition at line 464 of file AttServerMessage.h.
size_t size | ( | ) | const |
Return the number of octets presents in the response.
Definition at line 456 of file AttServerMessage.h.
Field Documentation
const AttributeOpcode opcode [inherited] |
Op code used to identify the type of the attribute response.
Definition at line 102 of file AttServerMessage.h.
Generated on Sun Jul 17 2022 08:25:43 by 1.7.2