Methods for checking current state of periphery.
More...
Methods for checking current state of periphery.
◆ isSending()
bool HardwareSPI::isSending |
( |
| ) |
|
|
inline |
Checks if data are sending or transferring right now using DMA or IT and if periphery is busy.
- Returns
- True if data are sending or transferring right now.
◆ isReceiving()
bool HardwareSPI::isReceiving |
( |
| ) |
|
|
inline |
Checks if data are receiving or transferring right now using DMA or IT and if periphery is busy.
- Returns
- True if data are receiving or transferring right now.
◆ isTransfering()
bool HardwareSPI::isTransfering |
( |
| ) |
|
|
inline |
Checks if data are transferring right now using DMA or IT and if periphery is busy.
- Returns
- True if data are transferring right now.
◆ isTransacting()
bool HardwareSPI::isTransacting |
( |
| ) |
|
|
inline |
Checks if data are sending, receiving, transferring right now using DMA or IT and if periphery is busy.
- Returns
- True if data are sending, receiving, transferring right now.
◆ instanceExists()
bool HardwareSPI::instanceExists |
( |
void |
| ) |
|
|
inline |
Checks if SPI instance exists.
- Returns
- Returns true if SPI instance exists.
◆ isFullDuplex()
bool HardwareSPI::isFullDuplex |
( |
| ) |
|
Check, if full duplex mode is enabled for this periphery.
You can set it in .ioc file settings.
- Returns
- Returns true when this SPI can be used in full duplex mode, else it is not allowed to use transfer methods.
◆ isRxEnabled()
bool HardwareSPI::isRxEnabled |
( |
| ) |
|
Checks, if SPI periphery can receive data.
- Returns
- Returns true, if SPI periphery can receive data.
◆ isTxEnabled()
bool HardwareSPI::isTxEnabled |
( |
| ) |
|
Checks, if SPI periphery can transmit data.
- Returns
- Returns true, if SPI periphery can transmit data.
◆ operator bool()
HardwareSPI::operator bool |
( |
| ) |
const |
|
inline |
Checks if SPI instance exists.
◆ available()
bool HardwareSPI::available |
( |
| ) |
|
|
inline |
Checks if any data are available in RX FIFO buffer.
- Returns
- Returns true when any data are available in RX FIFO buffer.
◆ hasError()
bool HardwareSPI::hasError |
( |
void |
| ) |
|
|
inline |
Checks if instance has error.
- Returns
- Returns true if instance has any error.
◆ getError()
Gets error, that happens during begin, end or transaction.
To remove error
- Returns
- Returns error of instance.
- See also
- SPI_ErrorCode
◆ clearError()
void HardwareSPI::clearError |
( |
uint32_t |
clearMask = 0xFFFFFFFFUL | ) |
|
|
inline |
Gets error, that happens during begin, end or transaction.
To remove error
- Returns
- Returns error of instance.
- See also
- SPI_ErrorCode
◆ lastTransactionStatus()
virtual SPI_Status HardwareSPI::lastTransactionStatus |
( |
| ) |
|
|
inlinevirtual |