Skip to content

Commit c7f6b04

Browse files
Thomaz, MartinWalberg, Irun
authored andcommitted
Fixed bug that NUM_TOTAL_PINS was commented out, and removed hardcoded value.
1 parent 6d8476a commit c7f6b04

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

variants/uno2018/pins_arduino.h

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,9 @@
2727

2828
#define NUM_DIGITAL_PINS 20
2929
#define NUM_ANALOG_INPUTS 6
30-
#define NUM_TESTPOINT_PINS 9
30+
#define NUM_TESTPOINT_PINS 9
3131
#define NUM_OCCUPIED_PINS 6 // (TOSC1/2, VREF, RESET, DEBUG USART Rx/Tx)
32-
#define NUM_TOTAL_FREE_PINS (NUM_DIGITAL_PINS + NUM_ANALOG_INPUTS + NUM_TESTPOINT_PINS)
32+
#define NUM_TOTAL_FREE_PINS (NUM_DIGITAL_PINS + NUM_ANALOG_INPUTS + NUM_TESTPOINT_PINS)
3333
#define NUM_TOTAL_PINS (NUM_DIGITAL_PINS + NUM_ANALOG_INPUTS + NUM_TESTPOINT_PINS + NUM_OCCUPIED_PINS)
3434
#define ANALOG_INPUT_OFFSET 14
3535
#define analogInputToDigitalPin(p) ((p < NUM_ANALOG_INPUTS) ? (p) + ANALOG_INPUT_OFFSET : NOT_A_PIN)
@@ -82,16 +82,16 @@ static const uint8_t SCL = PIN_WIRE_SCL;
8282
#define PIN_WIRE_HWSERIAL2_RX (23)
8383
#define PIN_WIRE_HWSERIAL2_TX (24)
8484

85-
#define LED_BUILTIN 25
85+
#define LED_BUILTIN 25
8686

8787
#define PIN_A0 (14)
8888
#define PIN_A1 (15)
8989
#define PIN_A2 (16)
9090
#define PIN_A3 (17)
9191
#define PIN_A4 (18)
9292
#define PIN_A5 (19)
93-
#define PIN_A6 (20)
94-
#define PIN_A7 (21)
93+
#define PIN_A6 (20)
94+
#define PIN_A7 (21)
9595

9696
static const uint8_t A0 = PIN_A0;
9797
static const uint8_t A1 = PIN_A1;
@@ -114,15 +114,15 @@ static const uint8_t A7 = PIN_A7;
114114
// (A5*)(A4*) (7) (2) (R) (3~) (6~)
115115
// PA4 PA3 PA2 PA1 PA0 GND VDD UPDI PF6 PF5 PF4 PF3
116116
//
117-
// 48 47 46 45 44 43 42 41 40 39 38 37
117+
// 48 47 46 45 44 43 42 41 40 39 38 37
118118
// + ____ ____ ____ ____ ____ ____ ____ ____ ____ ____ ____ ____ +
119-
// PA5 1| |36 PF2
119+
// PA5 1| |36 PF2
120120
// PA6 2| |35 PF1 (TOSC2)
121121
// PA7 3| |34 PF0 (TOSC1)
122122
// (9~) PB0 4| |33 PE3 (8)
123-
// (10~) PB1 5| |32 PE2
124-
// (5~) PB2 6| |31 PE1
125-
// PB3 7| 48pin QFN |30 PE0
123+
// (10~) PB1 5| |32 PE2
124+
// (5~) PB2 6| |31 PE1
125+
// PB3 7| 48pin QFN |30 PE0
126126
// (Tx) PB4 8| |29 GND
127127
// (Rx) PB5 9| |28 AVDD
128128
// (11~) PC0 10| |27 PD7 (VREF)
@@ -199,11 +199,11 @@ const uint8_t PROGMEM digital_pin_to_port[] = {
199199
PA, //7 PA1
200200
PE, //8 PE3
201201
PB, //9 PB0
202-
PB, //10 PB1
202+
PB, //10 PB1
203203
PC, //11 PC0
204204
PC, //12 PC1
205205
PC, //13 PC2
206-
PD, //14 AI0 PD0
206+
PD, //14 AI0 PD0
207207
PD, //15 AI1 PD1
208208
PD, //16 AI2 PD2
209209
PD, //17 AI3 PD3

0 commit comments

Comments
 (0)