spi.h 304 B

12345678910111213141516
  1. #ifndef __SPI1_H
  2. #define __SPI1_H
  3. #include "interface.h"
  4. #define SPI1_REC_LEN 128
  5. #define SPI1_TX_LEN 128
  6. #define SPI1_DMA DMA_Channel_3
  7. #define SPI1_DMA_RXCH DMA2_Stream2
  8. #define SPI1_DMA_TXCH DMA2_Stream3
  9. void spi1_init(void);
  10. void SPI1DMA_Trans(const uint8_t *data, uint16_t count);
  11. #endif