Browse Source

SPIFIFO is deprecated

main
PaulStoffregen 7 years ago
parent
commit
c01f2292c8
1 changed files with 3 additions and 1 deletions
  1. +3
    -1
      teensy3/SPIFIFO.h

+ 3
- 1
teensy3/SPIFIFO.h View File



#ifdef KINETISK #ifdef KINETISK


// The preferred way to set SPI speed is with SPI.beginTransaction()

#if F_BUS == 120000000 #if F_BUS == 120000000
#define HAS_SPIFIFO #define HAS_SPIFIFO
#define SPI_CLOCK_24MHz (SPI_CTAR_PBR(3) | SPI_CTAR_BR(0) | SPI_CTAR_DBR) //(120 / 5) * ((1+1)/2) #define SPI_CLOCK_24MHz (SPI_CTAR_PBR(3) | SPI_CTAR_BR(0) | SPI_CTAR_DBR) //(120 / 5) * ((1+1)/2)
class SPIFIFOclass class SPIFIFOclass
{ {
public: public:
inline void begin(uint8_t pin, uint32_t speed, uint32_t mode=SPI_MODE0) __attribute__((always_inline)) {
inline void begin(uint8_t pin, uint32_t speed, uint32_t mode=SPI_MODE0) __attribute__((always_inline, deprecated)) {
uint32_t p, ctar = speed; uint32_t p, ctar = speed;
SIM_SCGC6 |= SIM_SCGC6_SPI0; SIM_SCGC6 |= SIM_SCGC6_SPI0;



Loading…
Cancel
Save