File tree Expand file tree Collapse file tree 7 files changed +39
-32
lines changed Expand file tree Collapse file tree 7 files changed +39
-32
lines changed Original file line number Diff line number Diff line change @@ -110,9 +110,10 @@ static const uint8_t D15 = PIN_D15;
110110
111111/****** WIRE CORE DEFINES ******/
112112
113- #define WIRE_HOWMANY 1
114- #define WIRE_SDA_PIN 18 /* A4 */
115- #define WIRE_SCL_PIN 19 /* A5 */
113+ #define WIRE_HOWMANY 1
114+ #define WIRE_INTERFACES_COUNT WIRE_HOWMANY
115+ #define WIRE_SDA_PIN 18 /* A4 */
116+ #define WIRE_SCL_PIN 19 /* A5 */
116117
117118static const uint8_t SDA = WIRE_SDA_PIN ;
118119static const uint8_t SCL = WIRE_SCL_PIN ;
Original file line number Diff line number Diff line change @@ -145,9 +145,10 @@ static const uint8_t A6 = PIN_A6;
145145
146146/****** WIRE CORE DEFINES ******/
147147
148- #define WIRE_HOWMANY 1
149- #define WIRE_SDA_PIN 20
150- #define WIRE_SCL_PIN 21
148+ #define WIRE_HOWMANY 1
149+ #define WIRE_INTERFACES_COUNT WIRE_HOWMANY
150+ #define WIRE_SDA_PIN 20
151+ #define WIRE_SCL_PIN 21
151152
152153// TODO: removeme
153154#ifdef __cplusplus
Original file line number Diff line number Diff line change @@ -117,11 +117,12 @@ static const uint8_t D15 = PIN_D15;
117117
118118/****** WIRE CORE DEFINES ******/
119119
120- #define WIRE_HOWMANY 2
121- #define WIRE_SDA_PIN 18 /* A4 */
122- #define WIRE_SCL_PIN 19 /* A5 */
123- #define WIRE1_SDA_PIN 27
124- #define WIRE1_SCL_PIN 26
120+ #define WIRE_HOWMANY 2
121+ #define WIRE_INTERFACES_COUNT WIRE_HOWMANY
122+ #define WIRE_SDA_PIN 18 /* A4 */
123+ #define WIRE_SCL_PIN 19 /* A5 */
124+ #define WIRE1_SDA_PIN 27
125+ #define WIRE1_SCL_PIN 26
125126
126127static const uint8_t SDA = WIRE_SDA_PIN ;
127128static const uint8_t SCL = WIRE_SCL_PIN ;
Original file line number Diff line number Diff line change @@ -74,10 +74,11 @@ extern "C" unsigned int PINCOUNT_fn();
7474#define UART1_RX_PIN UART_RX
7575/* ************************** WIRE CORE DEFINES **************************** */
7676#define WIRE_HOWMANY 1
77- #define WIRE_SDA_PIN I2C_SDA
78- #define WIRE_SCL_PIN I2C_SCL
77+ #define WIRE_INTERFACES_COUNT WIRE_HOWMANY
78+ #define WIRE_SDA_PIN I2C_SDA
79+ #define WIRE_SCL_PIN I2C_SCL
7980static const uint8_t SDA = WIRE_SDA_PIN ;
80- static const uint8_t SCL = WIRE_SDA_PIN ;
81+ static const uint8_t SCL = WIRE_SCL_PIN ;
8182/* *************************** SPI CORE DEFINES **************************** */
8283#define SPI_HOWMANY 1
8384#define PIN_SPI_MOSI SPI_MOSI
Original file line number Diff line number Diff line change @@ -138,12 +138,13 @@ static const uint8_t A15 = AN15;
138138#define UART1_RX_PIN UART_TX
139139
140140/****** WIRE CORE DEFINES ******/
141- #define WIRE_HOWMANY 1
142- #define WIRE_SDA_PIN I2C_SDA
143- #define WIRE_SCL_PIN I2C_SCL
141+ #define WIRE_HOWMANY 1
142+ #define WIRE_INTERFACES_COUNT WIRE_HOWMANY
143+ #define WIRE_SDA_PIN I2C_SDA
144+ #define WIRE_SCL_PIN I2C_SCL
144145
145146static const uint8_t SDA = WIRE_SDA_PIN ;
146- static const uint8_t SCL = WIRE_SDA_PIN ;
147+ static const uint8_t SCL = WIRE_SCL_PIN ;
147148
148149/****** SPI CORE DEFINES ******/
149150
Original file line number Diff line number Diff line change @@ -99,15 +99,16 @@ static const uint8_t D7 = PIN_D7;
9999
100100/****** WIRE CORE DEFINES ******/
101101
102- #define WIRE_HOWMANY 4
103- #define WIRE_SDA_PIN 11
104- #define WIRE_SCL_PIN 12
105- #define WIRE1_SDA_PIN 37
106- #define WIRE1_SCL_PIN 38
107- #define WIRE2_SDA_PIN 39
108- #define WIRE2_SCL_PIN 40
109- #define WIRE3_SDA_PIN 96
110- #define WIRE3_SCL_PIN 97
102+ #define WIRE_HOWMANY 4
103+ #define WIRE_INTERFACES_COUNT WIRE_HOWMANY
104+ #define WIRE_SDA_PIN 11
105+ #define WIRE_SCL_PIN 12
106+ #define WIRE1_SDA_PIN 37
107+ #define WIRE1_SCL_PIN 38
108+ #define WIRE2_SDA_PIN 39
109+ #define WIRE2_SCL_PIN 40
110+ #define WIRE3_SDA_PIN 96
111+ #define WIRE3_SCL_PIN 97
111112
112113/****** SPI CORE DEFINES ******/
113114
Original file line number Diff line number Diff line change @@ -113,11 +113,12 @@ static const uint8_t D15 = PIN_D15;
113113
114114/****** WIRE CORE DEFINES ******/
115115
116- #define WIRE_HOWMANY 2
117- #define WIRE_SDA_PIN 18 /* A4 */
118- #define WIRE_SCL_PIN 19 /* A5 */
119- #define WIRE1_SDA_PIN 27
120- #define WIRE1_SCL_PIN 26
116+ #define WIRE_HOWMANY 2
117+ #define WIRE_INTERFACES_COUNT WIRE_HOWMANY
118+ #define WIRE_SDA_PIN 18 /* A4 */
119+ #define WIRE_SCL_PIN 19 /* A5 */
120+ #define WIRE1_SDA_PIN 27
121+ #define WIRE1_SCL_PIN 26
121122
122123static const uint8_t SDA = WIRE_SDA_PIN ;
123124static const uint8_t SCL = WIRE_SCL_PIN ;
You can’t perform that action at this time.
0 commit comments