You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[](https://github.com/z3t0/Arduino-IRremote/commits/master)
@@ -18,20 +18,29 @@ Click on the LibraryManager badge above to see the [instructions](https://www.ar
Protocols can be switched off and on by changing the lines in *IRremote.h*:
21
+
Protocols can be switched off and on by definining macros like [here]((https://github.com/Arduino-IRremote/Arduino-IRremote/blob/master/examples/SimpleReceiver/SimpleReceiver.ino#L18):
22
22
23
23
```
24
-
#define DECODE_<PROTOCOL_NAME> 1
25
-
#define SEND_<PROTOCOL_NAME> 1
24
+
#define DECODE_NEC
25
+
//#define DECODE_DENON
26
+
#incude <IRremote.h>
26
27
```
28
+
or by activating the lines in [IRremote.h]((https://github.com/Arduino-IRremote/Arduino-IRremote/blob/master/src/IRremote.h#L54):
This is a quite old but maybe useful wiki for this library.
29
38
30
39
# Converting your 2.x program to the 3.x version
31
40
- Now there is an **IRreceiver** and **IRsender** object like the well known Arduino **Serial** object.
32
41
- Just remove the line `IRrecv IrReceiver(IR_RECEIVE_PIN);` and/or `IRsend IrSender;` in your program, and replace all occurrences of `IRrecv.` or `irrecv.` with `IrReceiver`.
33
42
- Since the decoded values are now in `IrReceiver.decodedIRData` and not in `results` any more, remove the line `decode_results results` or similar.
34
-
-Like for the Serial object, call [`IrReceiver.begin(IR_RECEIVE_PIN, ENABLE_LED_FEEDBACK);`](https://github.com/Arduino-IRremote/Arduino-IRremote/blob/master/examples/IRreceiveDemo/IRreceiveDemo.ino#L38) or `IrReceiver.begin(IR_RECEIVE_PIN, DISABLE_LED_FEEDBACK);` instead of the `IrReceiver.enableIRIn();` or `irrecv.enableIRIn();` in setup().
43
+
-ike for the Serial object, call [`IrReceiver.begin(IR_RECEIVE_PIN, ENABE_ED_FEEDBACK);`](https://github.com/Arduino-IRremote/Arduino-IRremote/blob/master/examples/IRreceiveDemo/IRreceiveDemo.ino#L38) or `IrReceiver.begin(IR_RECEIVE_PIN, DISABLE_LED_FEEDBACK);` instead of the `IrReceiver.enableIRIn();` or `irrecv.enableIRIn();` in setup().
35
44
- Old `decode(decode_results *aResults)` function is replaced by simple `decode()`. So if you have a statement `if(irrecv.decode(&results))` replace it with `if (IrReceiver.decode())`.
36
45
- The decoded result is now in in `IrReceiver.decodedIRData` and not in `results` any more, therefore replace any occurrences of `results.value` and / or `results.decode_type` (and similar) to `IrReceiver.decodedIRData.decodedRawData` and / or `IrReceiver.decodedIRData.decodedRawData`.
37
46
- Overflow, Repeat and other flags are now in [`IrReceiver.receivedIRData.flags`](https://github.com/Arduino-IRremote/Arduino-IRremote/blob/master/src/IRremote.h#L126).
@@ -84,15 +93,13 @@ Modify it by commenting them out or in, or change the values if applicable. Or d
84
93
|`USE_OLD_DECODE`| IRremoteInt.h | disabled | Enables the old decoder in order to be version 2.x compatible, where all protocols were MSB first. |
85
94
|`EXCLUDE_EXOTIC_PROTOCOLS`| Before `#include <IRremote.h>`| disabled | If activated, BOSEWAVE, MAGIQUEST,WHYNTER and LEGO_PF are excluded in `decode()` and in sending with `IrSender.write()`. Saves up to 900 bytes program space. |
86
95
|`MARK_EXCESS_MICROS`| Before `#include <IRremote.h>`| 20 | MARK_EXCESS_MICROS is subtracted from all marks and added to all spaces before decoding, to compensate for the signal forming of different IR receiver modules. |
96
+
|`USE_NO_SEND_PWM`| Before `#include <IRremote.h>`| disabled | Use no carrier PWM, just simulate an active low receiver signal. |
97
+
|`SEND_PWM_BY_TIMER`| Before `#include <IRremote.h>`| disabled | Disable carrier PWM generation in software and use (restricted) hardware PWM. |
87
98
|`IR_INPUT_IS_ACTIVE_HIGH`| IRremoteInt.h | disabled | Enable it if you use a RF receiver, which has an active HIGH output signal. |
0 commit comments