|
88 | 88 | #undef OCR2_6 |
89 | 89 | #undef OCR2_7 |
90 | 90 |
|
91 | | -#define NUM_DIGITAL_PINS 30 |
| 91 | +#define NUM_DIGITAL_PINS 31 |
92 | 92 | #define NUM_ANALOG_INPUTS 12 |
93 | 93 |
|
94 | 94 | #define TX_RX_LED_INIT DDRD |= (1<<5), DDRB |= (1<<0) |
|
100 | 100 | static const uint8_t SDA = 2; |
101 | 101 | static const uint8_t SCL = 3; |
102 | 102 | #define LED_BUILTIN 13 |
| 103 | +#define LED_BUILTIN_RX 17 |
| 104 | +#define LED_BUILTIN_TX 30 |
103 | 105 |
|
104 | 106 | // Map SPI port to 'new' pins D14..D17 |
105 | 107 | static const uint8_t SS = 17; |
@@ -131,6 +133,8 @@ static const uint8_t A11 = 29; // D12 |
131 | 133 | extern const uint8_t PROGMEM analog_pin_to_channel_PGM[]; |
132 | 134 | #define analogPinToChannel(P) ( pgm_read_byte( analog_pin_to_channel_PGM + (P) ) ) |
133 | 135 |
|
| 136 | +#define digitalPinHasPWM(p) ((p) == 3 || (p) == 5 || (p) == 6 || (p) == 9 || (p) == 10 || (p) == 11 || (p) == 13) |
| 137 | + |
134 | 138 | #define digitalPinToInterrupt(p) ((p) == 0 ? 2 : ((p) == 1 ? 3 : ((p) == 2 ? 1 : ((p) == 3 ? 0 : ((p) == 7 ? 4 : NOT_AN_INTERRUPT))))) |
135 | 139 |
|
136 | 140 | #ifdef ARDUINO_MAIN |
@@ -171,8 +175,8 @@ extern const uint8_t PROGMEM analog_pin_to_channel_PGM[]; |
171 | 175 | // MOSI D16 PB2 MOSI,PCINT2 |
172 | 176 | // SS D17 PB0 RXLED,SS/PCINT0 |
173 | 177 | // |
174 | | -// TXLED PD5 |
175 | | -// RXLED PB0 |
| 178 | +// TXLED D30 PD5 XCK1 |
| 179 | +// RXLED D17 PB0 |
176 | 180 | // HWB PE2 HWB |
177 | 181 |
|
178 | 182 | // these arrays map port names (e.g. port B) to the |
@@ -243,6 +247,7 @@ const uint8_t PROGMEM digital_pin_to_port_PGM[] = { |
243 | 247 | PB, // D27 / D9 - A9 - PB5 |
244 | 248 | PB, // D28 / D10 - A10 - PB6 |
245 | 249 | PD, // D29 / D12 - A11 - PD6 |
| 250 | + PD, // D30 / TX Led - PD5 |
246 | 251 | }; |
247 | 252 |
|
248 | 253 | const uint8_t PROGMEM digital_pin_to_bit_mask_PGM[] = { |
@@ -280,6 +285,7 @@ const uint8_t PROGMEM digital_pin_to_bit_mask_PGM[] = { |
280 | 285 | _BV(5), // D27 / D9 - A9 - PB5 |
281 | 286 | _BV(6), // D28 / D10 - A10 - PB6 |
282 | 287 | _BV(6), // D29 / D12 - A11 - PD6 |
| 288 | + _BV(5), // D30 / TX Led - PD5 |
283 | 289 | }; |
284 | 290 |
|
285 | 291 | const uint8_t PROGMEM digital_pin_to_timer_PGM[] = { |
@@ -317,6 +323,7 @@ const uint8_t PROGMEM digital_pin_to_timer_PGM[] = { |
317 | 323 | NOT_ON_TIMER, |
318 | 324 | NOT_ON_TIMER, |
319 | 325 | NOT_ON_TIMER, |
| 326 | + NOT_ON_TIMER, |
320 | 327 | }; |
321 | 328 |
|
322 | 329 | const uint8_t PROGMEM analog_pin_to_channel_PGM[] = { |
|
0 commit comments