nRF Connect SDK API 3.3.99
Loading...
Searching...
No Matches

◆ nfc_ndef_le_oob_rec_payload_constructor()

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.

Parameters
payload_descPointer to the description of the payload.
buffPointer to payload destination. If NULL, function will calculate the expected size of the record payload.
lenSize of available memory to write as input. Size of generated payload as output.
Return values
0If the payload was encoded successfully.
-EINVALIf parameters in the payload descriptor are invalid or missing.
-ENOMEMIf the predicted payload size is bigger than the provided buffer space.