template<uint16_t KBYTE, BOARD::pin_t SS_PIN, uint32_t FREQ = 16000000L>
class MC23LCXXX< KBYTE, SS_PIN, FREQ >
Storage device driver for Microchip 23LCXXX, SPI Serial SRAM.
- Parameters
-
[in] | KBYTE | size. |
[in] | SS_PIN | slave select board pin. |
[in] | FREQ | max bus frequency for device (default 16 MHz). |
Definition at line 32 of file MC23LCXXX.h.
template<uint16_t KBYTE, BOARD::pin_t SS_PIN, uint32_t FREQ = 16000000L>
virtual int MC23LCXXX< KBYTE, SS_PIN, FREQ >::read |
( |
void * |
dst, |
|
|
uint32_t |
src, |
|
|
size_t |
count |
|
) |
| |
|
inlinevirtual |
Read given count number of bytes from SRAM source address to destination buffer. Returns number of bytes read, or negative error code.
- Parameters
-
[in] | dst | destination buffer pointer. |
[in] | src | source memory address on device. |
[in] | count | number of bytes to read from device. |
- Returns
- number of bytes read or negative error code.
Implements Storage.
Definition at line 59 of file MC23LCXXX.h.
template<uint16_t KBYTE, BOARD::pin_t SS_PIN, uint32_t FREQ = 16000000L>
virtual int MC23LCXXX< KBYTE, SS_PIN, FREQ >::write |
( |
uint32_t |
dst, |
|
|
const void * |
src, |
|
|
size_t |
count |
|
) |
| |
|
inlinevirtual |
Write given count number of bytes to SRAM destination address from source buffer. Returns number of bytes written, or negative error code.
- Parameters
-
[in] | dst | destination memory address on device. |
[in] | src | source buffer pointer. |
[in] | count | number of bytes to write to device. |
- Returns
- number of bytes written or negative error code.
Implements Storage.
Definition at line 93 of file MC23LCXXX.h.