![]() |
nRF Connect SDK API 3.3.99
|
| int nfc_ndef_le_oob_rec_payload_constructor | ( | const struct nfc_ndef_le_oob_rec_payload_desc * | payload_desc, |
| uint8_t * | buff, | ||
| uint32_t * | len ) |
#include <include/nfc/ndef/le_oob_rec.h>
Construct the payload for a Bluetooth Carrier Configuration LE Record.
This function encodes the record payload according to the payload descriptor. It implements an API compatible with payload_constructor_t.
| payload_desc | Pointer to the description of the payload. |
| buff | Pointer to payload destination. If NULL, function will calculate the expected size of the record payload. |
| len | Size of available memory to write as input. Size of generated payload as output. |
| 0 | If the payload was encoded successfully. |
| -EINVAL | If parameters in the payload descriptor are invalid or missing. |
| -ENOMEM | If the predicted payload size is bigger than the provided buffer space. |