Base class for SPI abstraction.
More...
#include <spi.hpp>
|
using | Impl = SPIImpl< Context > |
|
template<auto Context, template< auto > typename SPIImpl>
struct bsp::drv::SPI< Context, SPIImpl >
Base class for SPI abstraction.
- Template Parameters
-
Context | SPI context |
SPIImpl | SPI implementation |
◆ Impl
template<auto Context, template< auto > typename SPIImpl>
◆ SPI()
template<auto Context, template< auto > typename SPIImpl>
◆ deinit()
template<auto Context, template< auto > typename SPIImpl>
static auto bsp::drv::SPI< Context, SPIImpl >::deinit |
( |
auto ... |
args | ) |
|
|
inlinestatic |
SPI deinitialization.
- Parameters
-
args | Platform specific arguments |
- Returns
- Success
◆ init()
template<auto Context, template< auto > typename SPIImpl>
static auto bsp::drv::SPI< Context, SPIImpl >::init |
( |
auto ... |
args | ) |
|
|
inlinestatic |
SPI initialization.
- Parameters
-
args | Platform specific arguments |
- Returns
- Success
◆ read()
template<auto Context, template< auto > typename SPIImpl>
template<typename T >
SPI read function.
- Template Parameters
-
- Returns
- Read data
◆ setMode()
template<auto Context, template< auto > typename SPIImpl>
Set the spi mode (CPOL and CPHA)
- Parameters
-
- Note
- This function wait until the SPI is not busy anymore and then the mode change will take place
◆ write()
template<auto Context, template< auto > typename SPIImpl>
template<typename T >
static void bsp::drv::SPI< Context, SPIImpl >::write |
( |
const T & |
value | ) |
|
|
inlinestatic |
SPI write function.
- Template Parameters
-
- Parameters
-
The documentation for this struct was generated from the following file: