File tree 3 files changed +10
-8
lines changed
SampleProjects/TestSomething/test 3 files changed +10
-8
lines changed Original file line number Diff line number Diff line change @@ -34,6 +34,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
34
34
- Now using the recommended "stable" URL for the ` esp32 ` board family
35
35
- ` esp8266:huzzah ` options updated as per upstream
36
36
- Errors about ` '_NOP' was not declared in this scope ` (test added)
37
+ - ` pinMode() ` and ` analogReference() ` are now functions (no longer macros), because that conflicted with actual function names in the wild
38
+ - ` analogReadResolution() ` and ` analogWriteResolution() ` are also no longer macros
37
39
38
40
### Security
39
41
Original file line number Diff line number Diff line change @@ -279,10 +279,10 @@ unittest(shift_out) {
279
279
}
280
280
281
281
unittest (no_ops) {
282
- pinMode ();
283
- analogReference ();
284
- analogReadResolution ();
285
- analogWriteResolution ();
282
+ pinMode (1 , INPUT );
283
+ analogReference (3 );
284
+ analogReadResolution (4 );
285
+ analogWriteResolution (5 );
286
286
}
287
287
288
288
#ifdef HAVE_HWSERIAL0
Original file line number Diff line number Diff line change @@ -160,15 +160,15 @@ class GodmodeState {
160
160
};
161
161
162
162
// io pins
163
- # define pinMode (...) _NOP()
164
- # define analogReference (...) _NOP()
163
+ inline void pinMode (uint8_t pin, uint8_t mode) { _NOP (); }
164
+ inline void analogReference (uint8_t mode) { _NOP (); }
165
165
166
166
void digitalWrite (uint8_t , uint8_t );
167
167
int digitalRead (uint8_t );
168
168
int analogRead (uint8_t );
169
169
void analogWrite (uint8_t , int );
170
- # define analogReadResolution (...) _NOP()
171
- # define analogWriteResolution (...) _NOP()
170
+ inline void analogReadResolution (uint8_t bits) { _NOP (); }
171
+ inline void analogWriteResolution (uint8_t bits) { _NOP (); }
172
172
void attachInterrupt (uint8_t interrupt, void ISR (void ), uint8_t mode);
173
173
void detachInterrupt (uint8_t interrupt);
174
174
You can’t perform that action at this time.
0 commit comments