diff options
author | JF <jf@codingfield.com> | 2020-01-19 19:47:49 +0100 |
---|---|---|
committer | JF <jf@codingfield.com> | 2020-01-19 19:47:49 +0100 |
commit | b4bd41cd562f89bcd320ac0985e9b33c766babe1 (patch) | |
tree | e64c79bd4f61452c93ee45b75aa26bbf8252d731 /src/drivers/SpiMaster.h | |
parent | 9dc4e32e36eb1167ee241cdf8027089cad593cf1 (diff) |
Implement the SPI driver using DMA.
Diffstat (limited to 'src/drivers/SpiMaster.h')
-rw-r--r-- | src/drivers/SpiMaster.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/drivers/SpiMaster.h b/src/drivers/SpiMaster.h index 073501a8..5376ac8e 100644 --- a/src/drivers/SpiMaster.h +++ b/src/drivers/SpiMaster.h @@ -24,12 +24,17 @@ namespace Pinetime { SpiMaster(const SpiModule spi, const Parameters& params); bool Init(); bool Write(const uint8_t* data, size_t size); + bool WriteFast(const uint8_t* data, size_t size); + void setup_workaround_for_ftpan_58(NRF_SPIM_Type *spim, uint32_t ppi_channel, uint32_t gpiote_channel); void Sleep(); void Wakeup(); + bool GetStatusEnd(); + bool GetStatusStarted(); + private: - NRF_SPI_Type * spiBaseAddress; + NRF_SPIM_Type * spiBaseAddress; uint8_t pinCsn; SpiMaster::SpiModule spi; |