DlnSpiMasterReadWrite() Function
The DlnSpiMasterReadWrite() function sends and receives data via SPI bus. The data are received as an array of 1-byte elements. This function is suited to transmit data frames of 8 bits or less. In case you set a frame size of more than 8 bits, it is advised to use the DlnSpiMasterReadWrite16() function.
Parameters:
- handle
- A handle to the DLN-series adapter.
- port
- A number of the SPI master port.
- size
- The size of the message buffer. This parameter is specified in bytes. The maximum value is 256 bytes.
- writeBuffer
- A pointer to an array of unsigned 8-bit integers. This array must be filled with data to be sent to a slave during the function execution.
- readBuffer
- A pointer to an array of unsigned 8-bit integers. This array will be filled with data received from slave during the function execution.
This function is defined in the dln_spi_master.h file.
2006-2012