Bumped Mbed FW version to 01.20.0080
ADMW Host SPI interface functions
[ADMW Host Portability Layer]
Typedefs | |
typedef void * | ADMW_SPI_HANDLE |
Functions | |
ADMW_RESULT | admw_SpiOpen (ADMW_PLATFORM_SPI_CONFIG *pConfig, ADMW_SPI_HANDLE *phDevice) |
Open the SPI interface and allocate resources. | |
void | admw_SpiClose (ADMW_SPI_HANDLE hDevice) |
Close SPI interface and free resources. | |
ADMW_RESULT | admw_SpiTransfer (ADMW_SPI_HANDLE hDevice, void *pTxData, void *pRxData, unsigned nLength, bool bCsHold) |
Transfer data to slave device. |
Typedef Documentation
typedef void* ADMW_SPI_HANDLE |
A handle used in all API functions to identify the SPI interface context
Definition at line 56 of file admw_spi.h.
Function Documentation
void admw_SpiClose | ( | ADMW_SPI_HANDLE | hDevice ) |
Close SPI interface and free resources.
- Parameters:
-
[in] hDevice SPI interface context handle (admw_SpiOpen)
Definition at line 171 of file admw_spi.cpp.
ADMW_RESULT admw_SpiOpen | ( | ADMW_PLATFORM_SPI_CONFIG * | pConfig, |
ADMW_SPI_HANDLE * | phDevice | ||
) |
Open the SPI interface and allocate resources.
- Parameters:
-
[in] pConfig Pointer to platform-specific SPI interface details [out] phDevice Pointer to return a SPI interface context handle
- Returns:
- Status
- ADMW_SUCCESS Call completed successfully
- ADMW_NO_MEM Failed to allocate memory for interface context
Definition at line 71 of file admw_spi.cpp.
ADMW_RESULT admw_SpiTransfer | ( | ADMW_SPI_HANDLE | hDevice, |
void * | pTxData, | ||
void * | pRxData, | ||
unsigned | nLength, | ||
bool | bCsHold | ||
) |
Transfer data to slave device.
- Parameters:
-
[in] hDevice SPI interface context handle (admw_SpiOpen) [in] pTxData Transmit data buffer, or NULL for read-only transfers [in] pRxData Receive data buffer, or NULL for write-only transfers [in] nLength Number of bytes to transfer [in] bCsHold Leave the chip-select asserted when the transfer is done
- Returns:
- Status
- ADMW_SUCCESS Call completed successfully
- ADMW_FAILURE Failed to complete SPI transfer
Definition at line 138 of file admw_spi.cpp.
Generated on Thu Jul 14 2022 10:33:01 by 1.7.2