Interface for SPI Master.
More...
#include <spi.h>
Interface for SPI Master.
Definition at line 20 of file spi.h.
◆ SPIInterface()
mrf::SPIInterface::SPIInterface |
( |
| ) |
|
◆ ~SPIInterface()
mrf::SPIInterface::~SPIInterface |
( |
| ) |
|
|
virtual |
◆ cycle()
virtual epicsUInt8 mrf::SPIInterface::cycle |
( |
epicsUInt8 |
in | ) |
|
|
pure virtual |
Perform a single SPI transaction
- Exceptions
-
std::runtime_error | on timeout |
Implemented in MRMSPI.
◆ cycles()
void mrf::SPIInterface::cycles |
( |
size_t |
nops, |
|
|
const Operation * |
ops |
|
) |
| |
|
virtual |
Definition at line 25 of file spi.cpp.
28 for(
size_t n=0; n<nops; n++)
30 const Operation& op = ops[n];
32 for(
size_t i=0; i<op.ncycles; i++) {
33 epicsUInt8 O = this->
cycle(op.in ? op.in[i] : 0);
virtual epicsUInt8 cycle(epicsUInt8 in)=0
◆ select()
void mrf::SPIInterface::select |
( |
unsigned |
id | ) |
|
|
pure virtual |
Select numbered device. 0 clears selection.
Implemented in MRMSPI.
Definition at line 21 of file spi.cpp.
◆ setTimeout()
void mrf::SPIInterface::setTimeout |
( |
double |
t | ) |
|
◆ timeout()
double mrf::SPIInterface::timeout |
( |
| ) |
const |
timeout in seconds for an individual cycle()
Definition at line 41 of file spi.cpp.
◆ mutex
epicsMutex mrf::SPIInterface::mutex |
|
mutableprotected |
Definition at line 46 of file spi.h.
The documentation for this struct was generated from the following files: