mirror of
https://github.com/Theaninova/Arduino-IRremote.git
synced 2026-01-17 23:02:48 +00:00
Fixed MATCH, MATCH_MARK, MATCH_SPACE when both IRremoteInt.h and IRremoteInt.h are included in sketch
This commit is contained in:
@@ -65,6 +65,11 @@ int MATCH_SPACE(int measured_ticks, int desired_us) {
|
||||
Serial.println(TICKS_HIGH(desired_us - MARK_EXCESS), DEC);
|
||||
return measured_ticks >= TICKS_LOW(desired_us - MARK_EXCESS) && measured_ticks <= TICKS_HIGH(desired_us - MARK_EXCESS);
|
||||
}
|
||||
#else
|
||||
int MATCH(int measured, int desired) {return measured >= TICKS_LOW(desired) && measured <= TICKS_HIGH(desired);}
|
||||
int MATCH_MARK(int measured_ticks, int desired_us) {return MATCH(measured_ticks, (desired_us + MARK_EXCESS));}
|
||||
int MATCH_SPACE(int measured_ticks, int desired_us) {return MATCH(measured_ticks, (desired_us - MARK_EXCESS));}
|
||||
// Debugging versions are in IRremote.cpp
|
||||
#endif
|
||||
|
||||
void IRsend::sendNEC(unsigned long data, int nbits)
|
||||
|
||||
Reference in New Issue
Block a user