|
|
|
|
85
|
// A majority of the pins are NOT PCINTs, SO BE WARNED (i.e. you cannot use them as receive pins)
|
85
|
// A majority of the pins are NOT PCINTs, SO BE WARNED (i.e. you cannot use them as receive pins)
|
86
|
// Only pins available for RECEIVE (TRANSMIT can be on any pin):
|
86
|
// Only pins available for RECEIVE (TRANSMIT can be on any pin):
|
87
|
// (I've deliberately left out pin mapping to the Hardware USARTs - seems senseless to me)
|
87
|
// (I've deliberately left out pin mapping to the Hardware USARTs - seems senseless to me)
|
88
|
-// Pins: 10, 11, 12, 13, 50, 51, 52, 53, 62, 63, 64, 65, 66, 67, 68, 69
|
|
|
|
|
88
|
+// Pins: 10, 11, 12, 13, 50, 51, 52, 53, 62, 63, 64, 65, 66, 67, 68, 69, 72, 73, 75, 76, 77
|
89
|
|
89
|
|
90
|
#define digitalPinToPCICR(p) ( (((p) >= 10) && ((p) <= 13)) || \
|
90
|
#define digitalPinToPCICR(p) ( (((p) >= 10) && ((p) <= 13)) || \
|
91
|
(((p) >= 50) && ((p) <= 53)) || \
|
91
|
(((p) >= 50) && ((p) <= 53)) || \
|
92
|
- (((p) >= 62) && ((p) <= 69)) ? (&PCICR) : nullptr )
|
|
|
|
|
92
|
+ (((p) >= 62) && ((p) <= 69)) || \
|
|
|
93
|
+ (((p) >= 72) && ((p) <= 73)) || \
|
|
|
94
|
+ (((p) >= 75) && ((p) <= 77)) ? (&PCICR) : nullptr )
|
93
|
|
95
|
|
94
|
#define digitalPinToPCICRbit(p) ( (((p) >= 10) && ((p) <= 13)) || (((p) >= 50) && ((p) <= 53)) ? 0 : \
|
96
|
#define digitalPinToPCICRbit(p) ( (((p) >= 10) && ((p) <= 13)) || (((p) >= 50) && ((p) <= 53)) ? 0 : \
|
95
|
( (((p) >= 62) && ((p) <= 69)) ? 2 : \
|
97
|
( (((p) >= 62) && ((p) <= 69)) ? 2 : \
|
96
|
- 0 ) )
|
|
|
|
|
98
|
+ ( (((p) >= 72) && ((p) <= 73)) || (((p) >= 75) && ((p) <= 77)) ? 1 : \
|
|
|
99
|
+ 0 ) ) )
|
97
|
|
100
|
|
98
|
#define digitalPinToPCMSK(p) ( (((p) >= 10) && ((p) <= 13)) || (((p) >= 50) && ((p) <= 53)) ? (&PCMSK0) : \
|
101
|
#define digitalPinToPCMSK(p) ( (((p) >= 10) && ((p) <= 13)) || (((p) >= 50) && ((p) <= 53)) ? (&PCMSK0) : \
|
99
|
( (((p) >= 62) && ((p) <= 69)) ? (&PCMSK2) : \
|
102
|
( (((p) >= 62) && ((p) <= 69)) ? (&PCMSK2) : \
|
100
|
- nullptr ) )
|
|
|
|
|
103
|
+ ( (((p) >= 72) && ((p) <= 73)) || (((p) >= 75) && ((p) <= 77)) ? (&PCMSK1) : \
|
|
|
104
|
+ nullptr ) ) )
|
101
|
|
105
|
|
102
|
#define digitalPinToPCMSKbit(p) ( (((p) >= 10) && ((p) <= 13)) ? ((p) - 6) : \
|
106
|
#define digitalPinToPCMSKbit(p) ( (((p) >= 10) && ((p) <= 13)) ? ((p) - 6) : \
|
103
|
( ((p) == 50) ? 3 : \
|
107
|
( ((p) == 50) ? 3 : \
|
|
|
|
|
105
|
( ((p) == 52) ? 1 : \
|
109
|
( ((p) == 52) ? 1 : \
|
106
|
( ((p) == 53) ? 0 : \
|
110
|
( ((p) == 53) ? 0 : \
|
107
|
( (((p) >= 62) && ((p) <= 69)) ? ((p) - 62) : \
|
111
|
( (((p) >= 62) && ((p) <= 69)) ? ((p) - 62) : \
|
108
|
- 0 ) ) ) ) ) )
|
|
|
|
|
112
|
+ ( (((p) >= 72) && ((p) <= 73)) ? ((p) - 69) : \
|
|
|
113
|
+ ( (((p) >= 75) && ((p) <= 77)) ? ((p) - 70) : \
|
|
|
114
|
+ 0 ) ) ) ) ) ) ) )
|
109
|
|
115
|
|
110
|
#define digitalPinToInterrupt(p) ((p) == 2 ? 0 : ((p) == 3 ? 1 : ((p) >= 18 && (p) <= 21 ? 23 - (p) : NOT_AN_INTERRUPT)))
|
116
|
#define digitalPinToInterrupt(p) ((p) == 2 ? 0 : ((p) == 3 ? 1 : ((p) >= 18 && (p) <= 21 ? 23 - (p) : NOT_AN_INTERRUPT)))
|
111
|
|
117
|
|