Skip to content

Commit bd78652

Browse files
committed
SPI1 for Bast Frontier
1 parent 991c1c3 commit bd78652

File tree

1 file changed

+9
-10
lines changed

1 file changed

+9
-10
lines changed

variants/BAST_FRONTIER/pins_arduino.h

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ static const uint8_t A5 = PIN_A5;
103103
/*
104104
* SPI Interfaces
105105
*/
106-
#define SPI_INTERFACES_COUNT 2 //SPI on pins
106+
#define SPI_INTERFACES_COUNT 1 //SPI on pins
107107

108108
#define PIN_SPI_MISO (32u)
109109
#define PIN_SPI_MOSI (33u)
@@ -114,17 +114,16 @@ static const uint8_t SS = PIN_SPI_SS; // SPI Slave SS not used. Set here onl
114114
static const uint8_t MOSI = PIN_SPI_MOSI;
115115
static const uint8_t MISO = PIN_SPI_MISO;
116116
static const uint8_t SCK = PIN_SPI_SCK;
117-
/*
117+
118118
#define PIN_SPI1_MISO (8u)
119119
#define PIN_SPI1_MOSI (7u)
120120
#define PIN_SPI1_SCK (4u)
121121
#define PIN_SPI1_SS (10u)
122122

123-
static const uint8_t SS1 = PIN_SPI_SS;
124-
static const uint8_t MOSI1 = PIN_SPI_MOSI;
125-
static const uint8_t MISO1 = PIN_SPI_MISO;
126-
static const uint8_t SCK1 = PIN_SPI_SCK;
127-
*/
123+
static const uint8_t SS1 = PIN_SPI1_SS;
124+
static const uint8_t MOSI1 = PIN_SPI1_MOSI;
125+
static const uint8_t MISO1 = PIN_SPI1_MISO;
126+
static const uint8_t SCK1 = PIN_SPI1_SCK;
128127

129128
// Wire
130129
#define PIN_WIRE_SDA (17u)
@@ -189,9 +188,9 @@ static const uint8_t SCK1 = PIN_SPI_SCK;
189188
#define SPI_MOSI (digitalPinToPinName(PIN_SPI_MOSI))
190189
#define SPI_SCK (digitalPinToPinName(PIN_SPI_SCK))
191190

192-
//#define SPI1_MISO (digitalPinToPinName(PIN_SPI1_MISO))
193-
//#define SPI1_MOSI (digitalPinToPinName(PIN_SPI1_MOSI))
194-
//#define SPI1_SCK (digitalPinToPinName(PIN_SPI1_SCK))
191+
#define SPI1_MISO (digitalPinToPinName(PIN_SPI1_MISO))
192+
#define SPI1_MOSI (digitalPinToPinName(PIN_SPI1_MOSI))
193+
#define SPI1_SCK (digitalPinToPinName(PIN_SPI1_SCK))
195194

196195

197196
#define digitalPinToPort(P) (digitalPinToPinName(P)/24)

0 commit comments

Comments
 (0)