public interface SpiSlave
Modifier and Type | Method and Description |
---|---|
int |
getRxStatus(int[] pRxSize)
Get number of bytes in the receive queue.
|
int |
init()
Initialize the deivce as SPI slave.
|
int |
read(byte[] buffer,
int bufferSize,
int[] sizeOfRead)
Get number of bytes in the receive queue.
|
int |
reset()
Reset the SPI slave device.
|
int |
setMode(int cpol,
int cpha)
Set SPI slave mode.
|
int |
write(byte[] buffer,
int bufferSize,
int[] sizeTransferred)
Write data to the transmit queue of the SPI slave device.
|
int init()
int getRxStatus(int[] pRxSize)
iSpiIdx
- number of bytes in the receive queue.int read(byte[] buffer, int bufferSize, int[] sizeOfRead)
buffer
- buffer that receives the data from the device.bufferSize
- number of bytes to read from the device.sizeOfRead
- number of bytes read from the device.int write(byte[] buffer, int bufferSize, int[] sizeTransferred)
buffer
- buffer that contains the data to be written to the device.bufferSize
- number of bytes to read from the device.sizeTransferred
- number of bytes written to the device.int reset()
int setMode(int cpol, int cpha)
cpol
- Clock polaritycpha
- Clock phase