|
virtual size_t | getSize () const =0 |
|
void | write (uint32_t address, const void *data, size_t len) |
| Write a block of data. More...
|
|
void | write (Request &req, uint32_t address, const void *data, size_t len, Callback callback=nullptr, void *param=nullptr) |
|
void | write8 (uint32_t address, uint8_t value) |
|
void | write8 (Request &req, uint32_t address, uint8_t value, Callback callback=nullptr, void *param=nullptr) |
|
void | write16 (uint32_t address, uint16_t value) |
|
void | write16 (Request &req, uint32_t address, uint16_t value, Callback callback=nullptr, void *param=nullptr) |
|
void | write32 (uint32_t address, uint32_t value) |
|
void | write32 (Request &req, uint32_t address, uint32_t value, Callback callback=nullptr, void *param=nullptr) |
|
void | writeWord (Request &req, uint32_t address, uint32_t value, unsigned byteCount) |
|
void | read (uint32_t address, void *buffer, size_t len) |
| Read a block of data. More...
|
|
uint8_t | read8 (uint32_t address) |
|
uint16_t | read16 (uint32_t address) |
|
uint32_t | read32 (uint32_t address) |
|
uint32_t | readWord (uint32_t address, unsigned byteCount) |
|
void | read (Request &req, uint32_t address, void *buffer, size_t len, Callback callback=nullptr, void *param=nullptr) |
|
| Device (Controller &controller) |
|
|
virtual void | prepareWrite (HSPI::Request &req, uint32_t address)=0 |
| Prepare request without data. More...
|
|
void | prepareWrite (HSPI::Request &req, uint32_t address, const void *data, size_t len) |
| Prepare request with data. More...
|
|
|
virtual void | prepareRead (HSPI::Request &req, uint32_t address)=0 |
| Prepare without buffer. More...
|
|
void | prepareRead (HSPI::Request &req, uint32_t address, void *buffer, size_t len) |
| Prepare with buffer. More...
|
|
| Device (Controller &controller) |
|
virtual | ~Device () |
|
bool | begin (PinSet pinSet, uint8_t chipSelect, uint32_t clockSpeed) |
| Register device with controller and prepare for action. More...
|
|
void | end () |
|
bool | isReady () const |
| Determine if the device is initialised. More...
|
|
PinSet | getPinSet () const |
|
uint8_t | getChipSelect () const |
|
uint32_t | getSpeed () const |
|
void | setBitOrder (BitOrder bitOrder) |
|
BitOrder | getBitOrder () const |
|
void | setClockMode (ClockMode mode) |
|
ClockMode | getClockMode () const |
|
virtual IoModes | getSupportedIoModes () const =0 |
| Return set of IO modes supported by a device implementation. More...
|
|
bool | isSupported (IoMode mode) const |
| Determine if the device/controller combination supports an IO mode Must be called after begin() as other settings (e.g. pinset) can affect support. More...
|
|
virtual bool | setIoMode (IoMode mode) |
|
IoMode | getIoMode () const |
|
size_t | getBitsPerClock () const |
|
void | execute (Request &request) |
|
void | onTransfer (Callback callback) |
| Set a callback to be invoked before a request is started, and when it has finished. More...
|
|
void | wait (Request &request) |
|
Base class for read/write addressable devices.