nrfxlib API 2.7.99
Loading...
Searching...
No Matches

◆ nfc_t4t_ndef_rwpayload_set()

int nfc_t4t_ndef_rwpayload_set ( uint8_t *  emulation_buffer,
size_t  buffer_length 
)

#include <nfc/include/nfc_t4t_lib.h>

Set emulation buffer and content for a NDEF Tag emulation that is Read/Writable.

The buffer needs to be kept accessible for the lifetime of the emulation. If an external Reader-Writer changes the NDEF content it is signaled through the app-callback. Buffer can be changed during the lifetime of the emulation, when NDEF READ or UPDATE procedure is pending, and it will be changed after this procedure has completed. To perform this procedure safely, make sure to disable NFC interrupts.

Parameters
emulation_bufferBuffer pointer
buffer_lengthLength of buffer (maximum writable NDEF size)
Return values
0Success.
-NRF_EINVALInvalid argument (for example, wrong data length, NULL pointer).
-NRF_EOPNOTSUPPIf the new buffer has a different length than the first one.
-NRF_EFAULTIf the provided buffer is the currently used buffer.