Kenji Arai / mbed-os_TYBLE16

Dependents:   TYBLE16_simple_data_logger TYBLE16_MP3_Air

Embed: (wiki syntax)

« Back to documentation index

Implementation

Implementation

Transport

typedef void(* nfc_transport_write_fn_t )(uint8_t address, const uint8_t *outBuf, size_t outLen, void *pUser)
 Function called to write a register's value.
typedef void(* nfc_transport_read_fn_t )(uint8_t address, uint8_t *inBuf, size_t inLen, void *pUser)
 Function called to read a register's value.
typedef struct __transport nfc_transport_t
static void nfc_transport_write (nfc_transport_t *pTransport, uint8_t address, const uint8_t *outBuf, size_t outLen)
static void nfc_transport_read (nfc_transport_t *pTransport, uint8_t address, uint8_t *inBuf, size_t inLen)

Transport

void nfc_transport_init (nfc_transport_t *pTransport, nfc_transport_write_fn_t write, nfc_transport_read_fn_t read, void *pUser)
 Initialize transport with a specific implementation.

Typedef Documentation

typedef void(* nfc_transport_read_fn_t)(uint8_t address, uint8_t *inBuf, size_t inLen, void *pUser)

Function called to read a register's value.

Parameters:
addressaddress to read packet from
outBufbuffer to read
outLenbuffer's length
pUserparameter passed to the nfc_transport_init function

Definition at line 53 of file nfc_transport.h.

typedef void(* nfc_transport_write_fn_t)(uint8_t address, const uint8_t *outBuf, size_t outLen, void *pUser)

Function called to write a register's value.

Parameters:
addressaddress of the register to write to
outBufbuffer to write
outLenbuffer's length
pUserparameter passed to the nfc_transport_init function

Definition at line 45 of file nfc_transport.h.


Function Documentation

void nfc_transport_init ( nfc_transport_t *  pTransport,
nfc_transport_write_fn_t  write,
nfc_transport_read_fn_t  read,
void *  pUser 
)

Initialize transport with a specific implementation.

Parameters:
pTransportpointer to a nfc_transport_t structure to initialize
writetransport write function
readtransport read function
pUserparameter that will be passed to any of the above functions

Definition at line 39 of file nfc_transport.c.