mirror of
https://github.com/Theaninova/Arduino-IRremote.git
synced 2026-01-01 03:02:48 +00:00
Compare commits
283 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e12557b813 | ||
|
|
a4cf8bc43e | ||
|
|
3b41130ff9 | ||
|
|
98d6a2cf3f | ||
|
|
96efb5930a | ||
|
|
9a74475c8d | ||
|
|
7c14514beb | ||
|
|
20b6e3b8a2 | ||
|
|
fe27a84d26 | ||
|
|
ccbaca5acc | ||
|
|
74594847b7 | ||
|
|
85f8aa1e25 | ||
|
|
9ae0239fb7 | ||
|
|
0d69a1a9ed | ||
|
|
05cc3e683c | ||
|
|
c0dda82685 | ||
|
|
0d398731b2 | ||
|
|
e72008adf6 | ||
|
|
2d1b0f4737 | ||
|
|
bb0323bd7c | ||
|
|
b26b64f871 | ||
|
|
13df9e5632 | ||
|
|
a9385b92d8 | ||
|
|
5bd251fa22 | ||
|
|
8a767328df | ||
|
|
1a05ac08a5 | ||
|
|
b27398de74 | ||
|
|
76e23159f2 | ||
|
|
75960b95f6 | ||
|
|
9bf00849b3 | ||
|
|
ec5a82bd93 | ||
|
|
d28b6f985c | ||
|
|
2343bee2fa | ||
|
|
e5dc3e108e | ||
|
|
de3d723574 | ||
|
|
978284d55f | ||
|
|
e6b839c34f | ||
|
|
bb1470a029 | ||
|
|
f9a41c99c8 | ||
|
|
bc15ded405 | ||
|
|
38c1e017a2 | ||
|
|
d5658f4488 | ||
|
|
e7e5465b74 | ||
|
|
44f801d55c | ||
|
|
92c7f00138 | ||
|
|
d0f1d0d33d | ||
|
|
34e5cd87ca | ||
|
|
d064c7dd5b | ||
|
|
33c2e36033 | ||
|
|
b8ef1c3e92 | ||
|
|
f04b014da5 | ||
|
|
fa2f5f9352 | ||
|
|
864ed3ad4d | ||
|
|
fc96667673 | ||
|
|
7d30c2ff78 | ||
|
|
ebbefa835f | ||
|
|
fba0ee0ae5 | ||
|
|
0221081f25 | ||
|
|
cf7b49389c | ||
|
|
3aebf42ca8 | ||
|
|
0486c4f25a | ||
|
|
25de5b79d6 | ||
|
|
17628525af | ||
|
|
cb01593db0 | ||
|
|
9e2c41230c | ||
|
|
3bdc6a65a6 | ||
|
|
841e77a642 | ||
|
|
bd1a2e05a0 | ||
|
|
3a906217d2 | ||
|
|
9697752f4e | ||
|
|
c471e2816d | ||
|
|
ec356c951b | ||
|
|
1c3275f228 | ||
|
|
376301228a | ||
|
|
96c40f63f0 | ||
|
|
86e20db36c | ||
|
|
e4933e809e | ||
|
|
92092df7a0 | ||
|
|
ed1a2a2153 | ||
|
|
e3ec11d696 | ||
|
|
8bde9ee628 | ||
|
|
711ebd7d92 | ||
|
|
a9706375c0 | ||
|
|
e1957629d3 | ||
|
|
9293d2fcba | ||
|
|
c41f506cc1 | ||
|
|
3c4fc7bf37 | ||
|
|
26560e5755 | ||
|
|
d7a4c4e0c8 | ||
|
|
9a57b2aead | ||
|
|
c90d6788a1 | ||
|
|
2da6aeaf27 | ||
|
|
2fd83bbb00 | ||
|
|
702a064251 | ||
|
|
f5071daac8 | ||
|
|
5b82539954 | ||
|
|
55f3e27866 | ||
|
|
f985c4b318 | ||
|
|
cdd783ce7e | ||
|
|
a237a0e393 | ||
|
|
27777e89b2 | ||
|
|
0ef30ed227 | ||
|
|
d87707d0ec | ||
|
|
d8bdbb1a44 | ||
|
|
3fcb071d36 | ||
|
|
b4c8e6b22c | ||
|
|
e6bcf89664 | ||
|
|
df34396969 | ||
|
|
bce86bf8ed | ||
|
|
0bf5993a5b | ||
|
|
77fd51e891 | ||
|
|
22e64f144c | ||
|
|
61f00b8dc5 | ||
|
|
bd72084b7f | ||
|
|
cd02daf27c | ||
|
|
339a7969c9 | ||
|
|
0abc9f0908 | ||
|
|
61d0263c5b | ||
|
|
e9d43f7751 | ||
|
|
79d951896d | ||
|
|
d433744ec7 | ||
|
|
ec371483ac | ||
|
|
072ab7f048 | ||
|
|
f83fe2b70f | ||
|
|
1fd88cd308 | ||
|
|
028cc2e649 | ||
|
|
9b21a7fdbd | ||
|
|
f1dc505249 | ||
|
|
1e72064557 | ||
|
|
24d20e3231 | ||
|
|
7aee7fcf89 | ||
|
|
11cb3fe442 | ||
|
|
c058f3f336 | ||
|
|
879b06b1c4 | ||
|
|
cd9fb53520 | ||
|
|
5c920bd31d | ||
|
|
c9e8ab555e | ||
|
|
a1a4538200 | ||
|
|
2efeef446e | ||
|
|
f1e1fd0a59 | ||
|
|
114fe2ccd6 | ||
|
|
295cdf2e15 | ||
|
|
6a10861a44 | ||
|
|
b6c04cde1a | ||
|
|
197ff26f68 | ||
|
|
e794c747db | ||
|
|
86a1e93b23 | ||
|
|
9fe9551705 | ||
|
|
b473429939 | ||
|
|
0c298aaf39 | ||
|
|
29826d01f4 | ||
|
|
e23aa5eb32 | ||
|
|
3cc9956f97 | ||
|
|
107b8c249c | ||
|
|
1e519b1bf3 | ||
|
|
dcd06fa0ef | ||
|
|
ee1b44de3f | ||
|
|
2280c963a7 | ||
|
|
b79c04f11c | ||
|
|
df6f2003ef | ||
|
|
1e85b4a058 | ||
|
|
555a600acc | ||
|
|
2e4538bac8 | ||
|
|
360ca6ffb9 | ||
|
|
503225635e | ||
|
|
ec5e1bd5f9 | ||
|
|
0cacdf1ccb | ||
|
|
23fa23ada2 | ||
|
|
4429c773ce | ||
|
|
5d5479adbd | ||
|
|
4e5608f25f | ||
|
|
845e912e9f | ||
|
|
2e163ae3f4 | ||
|
|
3dec997391 | ||
|
|
6a1222d180 | ||
|
|
78e9b87a34 | ||
|
|
593e0a3ee3 | ||
|
|
ae477413de | ||
|
|
07df68af9d | ||
|
|
05e688a961 | ||
|
|
aa32e8f048 | ||
|
|
eb0360e758 | ||
|
|
66dee2fa16 | ||
|
|
5e7a1c1f12 | ||
|
|
8afb3e73a6 | ||
|
|
dfd14d437c | ||
|
|
5d994880b9 | ||
|
|
7b8444a305 | ||
|
|
813a3038ab | ||
|
|
a1cf782c44 | ||
|
|
88e243fe06 | ||
|
|
04e2cfbdad | ||
|
|
5f92834a12 | ||
|
|
a338d5525a | ||
|
|
001ccf9425 | ||
|
|
6af9a1b485 | ||
|
|
7d926499b4 | ||
|
|
7f1387278f | ||
|
|
c45b84f65c | ||
|
|
64698fd24b | ||
|
|
942dcf4051 | ||
|
|
66395a5daa | ||
|
|
8e043b5bb4 | ||
|
|
9170c0b4a1 | ||
|
|
f9faf98048 | ||
|
|
5cf1e45002 | ||
|
|
0cb77d3c5b | ||
|
|
d336bc541a | ||
|
|
675f9fe042 | ||
|
|
4caca675ff | ||
|
|
96fa0f557a | ||
|
|
04420c9f5c | ||
|
|
66d82da532 | ||
|
|
117059a17f | ||
|
|
ce1c79baa5 | ||
|
|
549d92d2f5 | ||
|
|
c2bf981fe7 | ||
|
|
2ad1487c8d | ||
|
|
c1c6bd4199 | ||
|
|
2768ddc676 | ||
|
|
7b08532e47 | ||
|
|
3b16c12b59 | ||
|
|
9c2064c5b4 | ||
|
|
3256c847b2 | ||
|
|
2c6067eb30 | ||
|
|
c35f7219dd | ||
|
|
18f5aa639b | ||
|
|
a87d558b73 | ||
|
|
bed4cc5c97 | ||
|
|
c0446fd659 | ||
|
|
12f7ef1d28 | ||
|
|
9235051c6a | ||
|
|
4610e7eb0e | ||
|
|
13f207d863 | ||
|
|
7c67cc5c59 | ||
|
|
4fed49fca6 | ||
|
|
9d94115974 | ||
|
|
b3e3ced302 | ||
|
|
0fce321c94 | ||
|
|
02f206e19c | ||
|
|
a881523044 | ||
|
|
a3cdf402d7 | ||
|
|
e947f0924e | ||
|
|
f2dafe5030 | ||
|
|
b04b31232f | ||
|
|
5719e7c00f | ||
|
|
95f93e639e | ||
|
|
24ba950f5c | ||
|
|
18591b037c | ||
|
|
6c7e2e0f72 | ||
|
|
66c3b1f47c | ||
|
|
0af9c5a9e9 | ||
|
|
3c89676bab | ||
|
|
fba55fb843 | ||
|
|
0de2d18bdb | ||
|
|
1c57c6a9b0 | ||
|
|
46b4e1084e | ||
|
|
e22a691164 | ||
|
|
a6bf23d71d | ||
|
|
acc1b6b86e | ||
|
|
9ba6628f04 | ||
|
|
3f70ad2e4c | ||
|
|
107fa6cf4d | ||
|
|
9dae9393f3 | ||
|
|
e03a593847 | ||
|
|
072b2c3db6 | ||
|
|
b25accfdd1 | ||
|
|
ade7cb6c29 | ||
|
|
11a43ec5b6 | ||
|
|
937ce48832 | ||
|
|
c48f817593 | ||
|
|
a2af9e32a6 | ||
|
|
96eedde481 | ||
|
|
753e52efe7 | ||
|
|
fb741e9893 | ||
|
|
4131d5bbb6 | ||
|
|
ccb4ac32c2 | ||
|
|
2eb19be290 | ||
|
|
0fc224a81e | ||
|
|
114d8afe67 | ||
|
|
9bc832ec55 | ||
|
|
31d80abc3f | ||
|
|
da2a0d8f9d |
@@ -3,6 +3,7 @@ These are the active contributors of this project that you may contact if there
|
|||||||
|
|
||||||
- [z3t0](https://github.com/z3t0) : Active Contributor and currently also the main contributor.
|
- [z3t0](https://github.com/z3t0) : Active Contributor and currently also the main contributor.
|
||||||
* Email: zetoslab@gmail.com
|
* Email: zetoslab@gmail.com
|
||||||
|
* Skype: polarised16
|
||||||
- [shirriff](https://github.com/shirriff) : An amazing person who worked to create this awesome library and provide unending support
|
- [shirriff](https://github.com/shirriff) : An amazing person who worked to create this awesome library and provide unending support
|
||||||
- [AnalysIR](https:/github.com/AnalysIR): Active contributor and is amazing with providing support!
|
- [AnalysIR](https:/github.com/AnalysIR): Active contributor and is amazing with providing support!
|
||||||
- [Informatic](https://github.com/Informatic) : Active contributor
|
- [Informatic](https://github.com/Informatic) : Active contributor
|
||||||
@@ -15,8 +16,7 @@ These are the active contributors of this project that you may contact if there
|
|||||||
- [Sebazzz](https://github.com/sebazz): Contributor
|
- [Sebazzz](https://github.com/sebazz): Contributor
|
||||||
- [lumbric](https://github.com/lumbric): Contributor
|
- [lumbric](https://github.com/lumbric): Contributor
|
||||||
- [ElectricRCAircraftGuy](https://github.com/electricrcaircraftguy): Active Contributor
|
- [ElectricRCAircraftGuy](https://github.com/electricrcaircraftguy): Active Contributor
|
||||||
- [philipphenkel](https://github.com/philipphenkel): Active Contributor
|
- [henkel](https://github.com/henkel): Contributor
|
||||||
- [MCUdude](https://github.com/MCUdude): Contributor
|
- [MCUdude](https://github.com/MCUdude): Contributor
|
||||||
- [marcmerlin](https://github.com/marcmerlin): Contributor (ESP32 port)
|
|
||||||
|
|
||||||
Note: This list is being updated constantly so please let [z3t0](https://github.com/z3t0) know if you have been missed.
|
Note: This list is being updated constantly so please let [z3t0](https://github.com/z3t0) know if you have been missed.
|
||||||
|
|||||||
11
IRremote.cpp
11
IRremote.cpp
@@ -18,17 +18,14 @@
|
|||||||
// Whynter A/C ARC-110WD added by Francesco Meschia
|
// Whynter A/C ARC-110WD added by Francesco Meschia
|
||||||
//******************************************************************************
|
//******************************************************************************
|
||||||
|
|
||||||
|
#include <avr/interrupt.h>
|
||||||
|
|
||||||
// Defining IR_GLOBAL here allows us to declare the instantiation of global variables
|
// Defining IR_GLOBAL here allows us to declare the instantiation of global variables
|
||||||
#define IR_GLOBAL
|
#define IR_GLOBAL
|
||||||
# include "IRremote.h"
|
# include "IRremote.h"
|
||||||
# include "IRremoteInt.h"
|
# include "IRremoteInt.h"
|
||||||
#undef IR_GLOBAL
|
#undef IR_GLOBAL
|
||||||
|
|
||||||
#ifndef IR_TIMER_USE_ESP32
|
|
||||||
#include <avr/interrupt.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
//+=============================================================================
|
//+=============================================================================
|
||||||
// The match functions were (apparently) originally MACROs to improve code speed
|
// The match functions were (apparently) originally MACROs to improve code speed
|
||||||
// (although this would have bloated the code) hence the names being CAPS
|
// (although this would have bloated the code) hence the names being CAPS
|
||||||
@@ -123,11 +120,7 @@ int MATCH_SPACE (int measured_ticks, int desired_us)
|
|||||||
// As soon as first MARK arrives:
|
// As soon as first MARK arrives:
|
||||||
// Gap width is recorded; Ready is cleared; New logging starts
|
// Gap width is recorded; Ready is cleared; New logging starts
|
||||||
//
|
//
|
||||||
#ifdef IR_TIMER_USE_ESP32
|
|
||||||
void IRTimer()
|
|
||||||
#else
|
|
||||||
ISR (TIMER_INTR_NAME)
|
ISR (TIMER_INTR_NAME)
|
||||||
#endif
|
|
||||||
{
|
{
|
||||||
TIMER_RESET;
|
TIMER_RESET;
|
||||||
|
|
||||||
|
|||||||
12
IRremote.h
12
IRremote.h
@@ -79,9 +79,6 @@
|
|||||||
#define DECODE_LEGO_PF 0 // NOT WRITTEN
|
#define DECODE_LEGO_PF 0 // NOT WRITTEN
|
||||||
#define SEND_LEGO_PF 1
|
#define SEND_LEGO_PF 1
|
||||||
|
|
||||||
#define DECODE_NERF_LOP 0 // NOT WRITTEN
|
|
||||||
#define SEND_NERF_LOP 1
|
|
||||||
|
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
// When sending a Pronto code we request to send either the "once" code
|
// When sending a Pronto code we request to send either the "once" code
|
||||||
// or the "repeat" code
|
// or the "repeat" code
|
||||||
@@ -122,7 +119,6 @@ typedef
|
|||||||
DENON,
|
DENON,
|
||||||
PRONTO,
|
PRONTO,
|
||||||
LEGO_PF,
|
LEGO_PF,
|
||||||
NERF_LOP,
|
|
||||||
}
|
}
|
||||||
decode_type_t;
|
decode_type_t;
|
||||||
|
|
||||||
@@ -255,10 +251,6 @@ class IRrecv
|
|||||||
# if DECODE_LEGO_PF
|
# if DECODE_LEGO_PF
|
||||||
bool decodeLegoPowerFunctions (decode_results *results) ;
|
bool decodeLegoPowerFunctions (decode_results *results) ;
|
||||||
# endif
|
# endif
|
||||||
//......................................................................
|
|
||||||
# if DECODE_NERF_LOP
|
|
||||||
bool decodeNerfLOP (decode_results *results) ;
|
|
||||||
# endif
|
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
@@ -347,10 +339,6 @@ class IRsend
|
|||||||
# if SEND_LEGO_PF
|
# if SEND_LEGO_PF
|
||||||
void sendLegoPowerFunctions (uint16_t data, bool repeat = true) ;
|
void sendLegoPowerFunctions (uint16_t data, bool repeat = true) ;
|
||||||
# endif
|
# endif
|
||||||
//......................................................................
|
|
||||||
# if SEND_NERF_LOP
|
|
||||||
void sendNerfLOP (uint16_t data, bool repeat = true) ;
|
|
||||||
# endif
|
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -15,12 +15,10 @@
|
|||||||
//
|
//
|
||||||
// JVC and Panasonic protocol added by Kristian Lauszus (Thanks to zenwheel and other people at the original blog post)
|
// JVC and Panasonic protocol added by Kristian Lauszus (Thanks to zenwheel and other people at the original blog post)
|
||||||
// Whynter A/C ARC-110WD added by Francesco Meschia
|
// Whynter A/C ARC-110WD added by Francesco Meschia
|
||||||
|
|
||||||
// Sparkfun Pro Micro support by Alastair McCormack
|
|
||||||
//******************************************************************************
|
//******************************************************************************
|
||||||
|
|
||||||
#ifndef boarddefs_h
|
#ifndef IRremoteBoardDefs_h
|
||||||
#define boarddefs_h
|
#define IRremoteBoardDefs_h
|
||||||
|
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
// Defines for blinking the LED
|
// Defines for blinking the LED
|
||||||
@@ -41,14 +39,9 @@
|
|||||||
# define BLINKLED_ON() (PORTD |= B00000001)
|
# define BLINKLED_ON() (PORTD |= B00000001)
|
||||||
# define BLINKLED_OFF() (PORTD &= B11111110)
|
# define BLINKLED_OFF() (PORTD &= B11111110)
|
||||||
|
|
||||||
// No system LED on ESP32, disable blinking
|
|
||||||
#elif defined(ESP32)
|
|
||||||
# define BLINKLED 255
|
|
||||||
# define BLINKLED_ON() 1
|
|
||||||
# define BLINKLED_OFF() 1
|
|
||||||
#else
|
#else
|
||||||
# define BLINKLED 13
|
# define BLINKLED 13
|
||||||
# define BLINKLED_ON() (PORTB |= B00100000)
|
#define BLINKLED_ON() (PORTB |= B00100000)
|
||||||
# define BLINKLED_OFF() (PORTB &= B11011111)
|
# define BLINKLED_OFF() (PORTB &= B11011111)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -72,14 +65,8 @@
|
|||||||
// switch IRremote to use a different timer.
|
// switch IRremote to use a different timer.
|
||||||
//
|
//
|
||||||
|
|
||||||
// Sparkfun Pro Micro
|
|
||||||
#if defined(ARDUINO_AVR_PROMICRO)
|
|
||||||
//#define IR_USE_TIMER1 // tx = pin 9
|
|
||||||
#define IR_USE_TIMER3 // tx = pin 5
|
|
||||||
//#define IR_USE_TIMER4_HS // tx = pin 5
|
|
||||||
|
|
||||||
// Arduino Mega
|
// Arduino Mega
|
||||||
#elif defined(__AVR_ATmega1280__) || defined(__AVR_ATmega2560__)
|
#if defined(__AVR_ATmega1280__) || defined(__AVR_ATmega2560__)
|
||||||
//#define IR_USE_TIMER1 // tx = pin 11
|
//#define IR_USE_TIMER1 // tx = pin 11
|
||||||
#define IR_USE_TIMER2 // tx = pin 9
|
#define IR_USE_TIMER2 // tx = pin 9
|
||||||
//#define IR_USE_TIMER3 // tx = pin 5
|
//#define IR_USE_TIMER3 // tx = pin 5
|
||||||
@@ -138,17 +125,15 @@
|
|||||||
|
|
||||||
// ATtiny84
|
// ATtiny84
|
||||||
#elif defined(__AVR_ATtiny84__)
|
#elif defined(__AVR_ATtiny84__)
|
||||||
#define IR_USE_TIMER1 // tx = pin 6
|
#define IR_USE_TIMER1 // tx = pin 6
|
||||||
|
|
||||||
//ATtiny85
|
//ATtiny85
|
||||||
#elif defined(__AVR_ATtiny85__)
|
#elif defined(__AVR_ATtiny85__)
|
||||||
#define IR_USE_TIMER_TINY0 // tx = pin 1
|
#define IR_USE_TIMER_TINY0 // tx = pin 1
|
||||||
|
|
||||||
#elif defined(ESP32)
|
|
||||||
#define IR_TIMER_USE_ESP32
|
|
||||||
#else
|
|
||||||
// Arduino Duemilanove, Diecimila, LilyPad, Mini, Fio, Nano, etc
|
// Arduino Duemilanove, Diecimila, LilyPad, Mini, Fio, Nano, etc
|
||||||
// ATmega48, ATmega88, ATmega168, ATmega328
|
// ATmega48, ATmega88, ATmega168, ATmega328
|
||||||
|
#else
|
||||||
//#define IR_USE_TIMER1 // tx = pin 9
|
//#define IR_USE_TIMER1 // tx = pin 9
|
||||||
#define IR_USE_TIMER2 // tx = pin 3
|
#define IR_USE_TIMER2 // tx = pin 3
|
||||||
|
|
||||||
@@ -254,18 +239,19 @@
|
|||||||
# define TIMER_PWM_PIN CORE_OC1A_PIN // Teensy
|
# define TIMER_PWM_PIN CORE_OC1A_PIN // Teensy
|
||||||
#elif defined(__AVR_ATmega1280__) || defined(__AVR_ATmega2560__)
|
#elif defined(__AVR_ATmega1280__) || defined(__AVR_ATmega2560__)
|
||||||
# define TIMER_PWM_PIN 11 // Arduino Mega
|
# define TIMER_PWM_PIN 11 // Arduino Mega
|
||||||
|
#elif defined(__AVR_ATmega64__) || defined(__AVR_ATmega128__)
|
||||||
|
# define TIMER_PWM_PIN 13 // MegaCore
|
||||||
#elif defined(__AVR_ATmega1284__) || defined(__AVR_ATmega1284P__) \
|
#elif defined(__AVR_ATmega1284__) || defined(__AVR_ATmega1284P__) \
|
||||||
|| defined(__AVR_ATmega644__) || defined(__AVR_ATmega644P__) \
|
|| defined(__AVR_ATmega644__) || defined(__AVR_ATmega644P__) \
|
||||||
|| defined(__AVR_ATmega324P__) || defined(__AVR_ATmega324A__) \
|
|| defined(__AVR_ATmega324P__) || defined(__AVR_ATmega324A__) \
|
||||||
|| defined(__AVR_ATmega324PA__) || defined(__AVR_ATmega164A__) \
|
|| defined(__AVR_ATmega324PA__) || defined(__AVR_ATmega164A__) \
|
||||||
|| defined(__AVR_ATmega164P__) || defined(__AVR_ATmega32__) \
|
|| defined(__AVR_ATmega164P__) || defined(__AVR_ATmega32__) \
|
||||||
|| defined(__AVR_ATmega16__) || defined(__AVR_ATmega8535__) \
|
|| defined(__AVR_ATmega16__) || defined(__AVR_ATmega8535__)
|
||||||
|| defined(__AVR_ATmega64__) || defined(__AVR_ATmega128__)
|
# define TIMER_PWM_PIN 13 // MightyCore
|
||||||
# define TIMER_PWM_PIN 13 // MightyCore, MegaCore
|
|
||||||
#elif defined(__AVR_ATtiny84__)
|
#elif defined(__AVR_ATtiny84__)
|
||||||
# define TIMER_PWM_PIN 6
|
# define TIMER_PWM_PIN 6
|
||||||
#else
|
#else
|
||||||
# define TIMER_PWM_PIN 9 // Arduino Duemilanove, Diecimila, LilyPad, Sparkfun Pro Micro etc
|
# define TIMER_PWM_PIN 9 // Arduino Duemilanove, Diecimila, LilyPad, etc
|
||||||
#endif // ATmega48, ATmega88, ATmega168, ATmega328
|
#endif // ATmega48, ATmega88, ATmega168, ATmega328
|
||||||
|
|
||||||
//---------------------------------------------------------
|
//---------------------------------------------------------
|
||||||
@@ -298,8 +284,8 @@
|
|||||||
//-----------------
|
//-----------------
|
||||||
#if defined(CORE_OC3A_PIN)
|
#if defined(CORE_OC3A_PIN)
|
||||||
# define TIMER_PWM_PIN CORE_OC3A_PIN // Teensy
|
# define TIMER_PWM_PIN CORE_OC3A_PIN // Teensy
|
||||||
#elif defined(__AVR_ATmega1280__) || defined(__AVR_ATmega2560__) || defined(ARDUINO_AVR_PROMICRO)
|
#elif defined(__AVR_ATmega1280__) || defined(__AVR_ATmega2560__)
|
||||||
# define TIMER_PWM_PIN 5 // Arduino Mega, Sparkfun Pro Micro
|
# define TIMER_PWM_PIN 5 // Arduino Mega
|
||||||
#elif defined(__AVR_ATmega1284__) || defined(__AVR_ATmega1284P__)
|
#elif defined(__AVR_ATmega1284__) || defined(__AVR_ATmega1284P__)
|
||||||
# define TIMER_PWM_PIN 6 // MightyCore
|
# define TIMER_PWM_PIN 6 // MightyCore
|
||||||
#else
|
#else
|
||||||
@@ -312,21 +298,12 @@
|
|||||||
#elif defined(IR_USE_TIMER4_HS)
|
#elif defined(IR_USE_TIMER4_HS)
|
||||||
|
|
||||||
#define TIMER_RESET
|
#define TIMER_RESET
|
||||||
|
#define TIMER_ENABLE_PWM (TCCR4A |= _BV(COM4A1))
|
||||||
#if defined(ARDUINO_AVR_PROMICRO) // Sparkfun Pro Micro
|
#define TIMER_DISABLE_PWM (TCCR4A &= ~(_BV(COM4A1)))
|
||||||
#define TIMER_ENABLE_PWM (TCCR4A |= _BV(COM4A0)) // Use complimentary O̅C̅4̅A̅ output on pin 5
|
|
||||||
#define TIMER_DISABLE_PWM (TCCR4A &= ~(_BV(COM4A0))) // (Pro Micro does not map PC7 (32/ICP3/CLK0/OC4A)
|
|
||||||
// of ATmega32U4 )
|
|
||||||
#else
|
|
||||||
#define TIMER_ENABLE_PWM (TCCR4A |= _BV(COM4A1))
|
|
||||||
#define TIMER_DISABLE_PWM (TCCR4A &= ~(_BV(COM4A1)))
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#define TIMER_ENABLE_INTR (TIMSK4 = _BV(TOIE4))
|
#define TIMER_ENABLE_INTR (TIMSK4 = _BV(TOIE4))
|
||||||
#define TIMER_DISABLE_INTR (TIMSK4 = 0)
|
#define TIMER_DISABLE_INTR (TIMSK4 = 0)
|
||||||
#define TIMER_INTR_NAME TIMER4_OVF_vect
|
#define TIMER_INTR_NAME TIMER4_OVF_vect
|
||||||
|
|
||||||
|
|
||||||
#define TIMER_CONFIG_KHZ(val) ({ \
|
#define TIMER_CONFIG_KHZ(val) ({ \
|
||||||
const uint16_t pwmval = SYSCLOCK / 2000 / (val); \
|
const uint16_t pwmval = SYSCLOCK / 2000 / (val); \
|
||||||
TCCR4A = (1<<PWM4A); \
|
TCCR4A = (1<<PWM4A); \
|
||||||
@@ -355,8 +332,6 @@
|
|||||||
//-----------------
|
//-----------------
|
||||||
#if defined(CORE_OC4A_PIN)
|
#if defined(CORE_OC4A_PIN)
|
||||||
# define TIMER_PWM_PIN CORE_OC4A_PIN // Teensy
|
# define TIMER_PWM_PIN CORE_OC4A_PIN // Teensy
|
||||||
#elif defined(ARDUINO_AVR_PROMICRO)
|
|
||||||
# define TIMER_PWM_PIN 5 // Sparkfun Pro Micro
|
|
||||||
#elif defined(__AVR_ATmega32U4__)
|
#elif defined(__AVR_ATmega32U4__)
|
||||||
# define TIMER_PWM_PIN 13 // Leonardo
|
# define TIMER_PWM_PIN 13 // Leonardo
|
||||||
#else
|
#else
|
||||||
@@ -563,28 +538,6 @@
|
|||||||
|
|
||||||
#define TIMER_PWM_PIN 1 /* ATtiny85 */
|
#define TIMER_PWM_PIN 1 /* ATtiny85 */
|
||||||
|
|
||||||
//---------------------------------------------------------
|
|
||||||
// ESP32 (ESP8266 should likely be added here too)
|
|
||||||
//
|
|
||||||
|
|
||||||
// ESP32 has it own timer API and does not use these macros, but to avoid ifdef'ing
|
|
||||||
// them out in the common code, they are defined to no-op. This allows the code to compile
|
|
||||||
// (which it wouldn't otherwise) but irsend will not work until ESP32 specific code is written
|
|
||||||
// for that -- merlin
|
|
||||||
// As a warning, sending timing specific code from an ESP32 can be challenging if you need 100%
|
|
||||||
// reliability because the arduino code may be interrupted and cause your sent waveform to be the
|
|
||||||
// wrong length. This is specifically an issue for neopixels which require 800Khz resolution.
|
|
||||||
// IR may just work as is with the common code since it's lower frequency, but if not, the other
|
|
||||||
// way to do this on ESP32 is using the RMT built in driver like in this incomplete library below
|
|
||||||
// https://github.com/ExploreEmbedded/ESP32_RMT
|
|
||||||
#elif defined(IR_TIMER_USE_ESP32)
|
|
||||||
#define TIMER_RESET
|
|
||||||
#define TIMER_ENABLE_PWM
|
|
||||||
#define TIMER_DISABLE_PWM Serial.println("IRsend not implemented for ESP32 yet");
|
|
||||||
#define TIMER_ENABLE_INTR
|
|
||||||
#define TIMER_DISABLE_INTR
|
|
||||||
#define TIMER_INTR_NAME
|
|
||||||
|
|
||||||
//---------------------------------------------------------
|
//---------------------------------------------------------
|
||||||
// Unknown Timer
|
// Unknown Timer
|
||||||
//
|
//
|
||||||
@@ -592,4 +545,4 @@
|
|||||||
# error "Internal code configuration error, no known IR_USE_TIMER# defined\n"
|
# error "Internal code configuration error, no known IR_USE_TIMER# defined\n"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // ! boarddefs_h
|
#endif // ! IRremoteBoardDefs_h
|
||||||
@@ -108,6 +108,6 @@ EXTERN volatile irparams_t irparams;
|
|||||||
#define SPACE 1
|
#define SPACE 1
|
||||||
|
|
||||||
// All board specific stuff has been moved to its own file, included here.
|
// All board specific stuff has been moved to its own file, included here.
|
||||||
#include "boarddefs.h"
|
#include "IRremoteBoardDefs.h"
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -14,12 +14,8 @@
|
|||||||
Use [a gist](gist.github.com) if the code exceeds 30 lines
|
Use [a gist](gist.github.com) if the code exceeds 30 lines
|
||||||
|
|
||||||
**checklist:**
|
**checklist:**
|
||||||
- [] I have **read** the README.md file thoroughly
|
|
||||||
- [] I have searched existing issues to see if there is anything I have missed.
|
|
||||||
- [] The latest [release](https://github.com/z3t0/Arduino-IRremote/releases/latest) is used
|
- [] The latest [release](https://github.com/z3t0/Arduino-IRremote/releases/latest) is used
|
||||||
- [] Any code referenced is provided and if over 30 lines a gist is linked INSTEAD of it being pasted in here
|
- [] Any code referenced is provided
|
||||||
- [] The title of the issue is helpful and relevant
|
- [] The title of the issue is helpful and relevant
|
||||||
|
|
||||||
** We will start to close issues that do not follow these guidelines as it doesn't help the contributors who spend time trying to solve issues if the community ignores guidelines!**
|
The above is a short template allowing you to make detailed issues!
|
||||||
|
|
||||||
The above is a short template allowing you to make detailed issues!
|
|
||||||
21
README.md
21
README.md
@@ -8,7 +8,7 @@ This library enables you to send and receive using infra-red signals on an Ardui
|
|||||||
|
|
||||||
Tutorials and more information will be made available on [the official homepage](http://z3t0.github.io/Arduino-IRremote/).
|
Tutorials and more information will be made available on [the official homepage](http://z3t0.github.io/Arduino-IRremote/).
|
||||||
|
|
||||||
## Version - 2.2.3
|
## Version - 2.2.1
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
1. Navigate to the [Releases](https://github.com/z3t0/Arduino-IRremote/releases) page.
|
1. Navigate to the [Releases](https://github.com/z3t0/Arduino-IRremote/releases) page.
|
||||||
@@ -17,12 +17,6 @@ Tutorials and more information will be made available on [the official homepage]
|
|||||||
4. Move the "IRremote" folder that has been extracted to your libraries directory.
|
4. Move the "IRremote" folder that has been extracted to your libraries directory.
|
||||||
5. Make sure to delete Arduino_Root/libraries/RobotIRremote. Where Arduino_Root refers to the install directory of Arduino. The library RobotIRremote has similar definitions to IRremote and causes errors.
|
5. Make sure to delete Arduino_Root/libraries/RobotIRremote. Where Arduino_Root refers to the install directory of Arduino. The library RobotIRremote has similar definitions to IRremote and causes errors.
|
||||||
|
|
||||||
|
|
||||||
## FAQ
|
|
||||||
- IR does not work right when I use Neopixels (aka WS2811/WS2812/WS2812B)
|
|
||||||
Whether you use the Adafruit Neopixel lib, or FastLED, interrupts get disabled on many lower end CPUs like the basic arduinos. In turn, this stops the IR interrupt handler from running when it needs to. There are some solutions to this on some processors, [see this page from Marc MERLIN](http://marc.merlins.org/perso/arduino/post_2017-04-03_Arduino-328P-Uno-Teensy3_1-ESP8266-ESP32-IR-and-Neopixels.html)
|
|
||||||
|
|
||||||
|
|
||||||
## Supported Boards
|
## Supported Boards
|
||||||
- Arduino Uno / Mega / Leonardo / Duemilanove / Diecimila / LilyPad / Mini / Fio / Nano etc.
|
- Arduino Uno / Mega / Leonardo / Duemilanove / Diecimila / LilyPad / Mini / Fio / Nano etc.
|
||||||
- Teensy 1.0 / 1.0++ / 2.0 / 2++ / 3.0 / 3.1 / Teensy-LC; Credits: @PaulStoffregen (Teensy Team)
|
- Teensy 1.0 / 1.0++ / 2.0 / 2++ / 3.0 / 3.1 / Teensy-LC; Credits: @PaulStoffregen (Teensy Team)
|
||||||
@@ -31,9 +25,6 @@ Whether you use the Adafruit Neopixel lib, or FastLED, interrupts get disabled o
|
|||||||
- ATmega8535, 16, 32, 164, 324, 644, 1284,
|
- ATmega8535, 16, 32, 164, 324, 644, 1284,
|
||||||
- ATmega64, 128
|
- ATmega64, 128
|
||||||
- ATtiny 84 / 85
|
- ATtiny 84 / 85
|
||||||
- ESP32 (receive only)
|
|
||||||
- ESP8266 is supported in a fork based on an old codebase that isn't as recent, but it works reasonably well given that perfectly timed sub millisecond interrupts are different on that chip. See https://github.com/markszabo/IRremoteESP8266
|
|
||||||
- Sparkfun Pro Micro
|
|
||||||
|
|
||||||
We are open to suggestions for adding support to new boards, however we highly recommend you contact your supplier first and ask them to provide support from their side.
|
We are open to suggestions for adding support to new boards, however we highly recommend you contact your supplier first and ask them to provide support from their side.
|
||||||
|
|
||||||
@@ -51,20 +42,12 @@ We are open to suggestions for adding support to new boards, however we highly r
|
|||||||
| [ATmega8535 ATmega16, ATmega32](https://github.com/MCUdude/MightyCore) | **13** | **1** |
|
| [ATmega8535 ATmega16, ATmega32](https://github.com/MCUdude/MightyCore) | **13** | **1** |
|
||||||
| [ATmega64, ATmega128](https://github.com/MCUdude/MegaCore) | **13** | **1** |
|
| [ATmega64, ATmega128](https://github.com/MCUdude/MegaCore) | **13** | **1** |
|
||||||
| ATmega1280, ATmega2560 | 5, 6, **9**, 11, 46 | 1, **2**, 3, 4, 5 |
|
| ATmega1280, ATmega2560 | 5, 6, **9**, 11, 46 | 1, **2**, 3, 4, 5 |
|
||||||
| [ESP32](http://esp32.net/) | N/A (not supported) | **1** |
|
|
||||||
| [Sparkfun Pro Micro](https://www.sparkfun.com/products/12640) | 9, **5**, 5 | 1, **3**, 4_HS |
|
|
||||||
| [Teensy 1.0](https://www.pjrc.com/teensy/) | **17** | **1** |
|
| [Teensy 1.0](https://www.pjrc.com/teensy/) | **17** | **1** |
|
||||||
| [Teensy 2.0](https://www.pjrc.com/teensy/) | 9, **10**, 14 | 1, 3, **4_HS** |
|
| [Teensy 2.0](https://www.pjrc.com/teensy/) | 9, **10**, 14 | 1, 3, **4_HS** |
|
||||||
| [Teensy++ 1.0 / 2.0](https://www.pjrc.com/teensy/) | **1**, 16, 25 | 1, **2**, 3 |
|
| [Teensy++ 1.0 / 2.0](https://www.pjrc.com/teensy/) | **1**, 16, 25 | 1, **2**, 3 |
|
||||||
| [Teensy 3.0 / 3.1](https://www.pjrc.com/teensy/) | **5** | **CMT** |
|
| [Teensy 3.0 / 3.1](https://www.pjrc.com/teensy/) | **5** | **CMT** |
|
||||||
| [Teensy-LC](https://www.pjrc.com/teensy/) | **16** | **TPM1** |
|
| [Teensy-LC](https://www.pjrc.com/teensy/) | **16** | **TPM1** |
|
||||||
|
|
||||||
|
|
||||||
### Experimental patches
|
|
||||||
The following are strictly community supported patches that have yet to make it into mainstream. If you have issues feel free to ask here. If it works well then let us know!
|
|
||||||
|
|
||||||
[Arduino 101](https://github.com/z3t0/Arduino-IRremote/pull/481#issuecomment-311243146)
|
|
||||||
|
|
||||||
The table above lists the currently supported timers and corresponding send pins, many of these can have additional pins opened up and we are open to requests if a need arises for other pins.
|
The table above lists the currently supported timers and corresponding send pins, many of these can have additional pins opened up and we are open to requests if a need arises for other pins.
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
@@ -82,7 +65,7 @@ Check [here](Contributing.md) for some guidelines.
|
|||||||
|
|
||||||
## Contact
|
## Contact
|
||||||
Email: zetoslab@gmail.com
|
Email: zetoslab@gmail.com
|
||||||
Please only email me if it is more appropriate than creating an Issue / PR. I **will** not respond to requests for adding support for particular boards, unless of course you are the creator of the board and would like to cooperate on the project. I will also **ignore** any emails asking me to tell you how to implement your ideas. However, if you have a private inquiry that you would only apply to you and you would prefer it to be via email, by all means.
|
Please only email me if it is more appropriate than creating an Issue / PR. I **will** not respond to requests for adding support for particular boards, unless of course you are the creator of the board and would like to cooperate on the project. I will also **ignore** any emails asking me to tell you how to implement your ideas. However, if you have a private inquiry that you would only apply to you and you would prefer it to be via email, by all means.
|
||||||
|
|
||||||
## Contributors
|
## Contributors
|
||||||
Check [here](Contributors.md)
|
Check [here](Contributors.md)
|
||||||
|
|||||||
@@ -1,10 +1,5 @@
|
|||||||
## 2.3.3 - 2017/03/31
|
|
||||||
- Added ESP32 IR receive support [PR #427](https://github.com/z3t0/Arduino-IRremote/pull/425)
|
|
||||||
|
|
||||||
## 2.2.3 - 2017/03/27
|
|
||||||
- Fix calculation of pause length in LEGO PF protocol [PR #427](https://github.com/z3t0/Arduino-IRremote/pull/427)
|
|
||||||
|
|
||||||
## 2.2.2 - 2017/01/20
|
## 2.2.2 - 2017/01/20
|
||||||
|
- Renamed "boarddefs.h" [ISSUE #375](https://github.com/z3t0/Arduino-IRremote/issues/375)
|
||||||
- Fixed naming bug [PR #398](https://github.com/z3t0/Arduino-IRremote/pull/398)
|
- Fixed naming bug [PR #398](https://github.com/z3t0/Arduino-IRremote/pull/398)
|
||||||
|
|
||||||
## 2.2.1 - 2016/07/27
|
## 2.2.1 - 2016/07/27
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ int toggle = 0; // The RC5/6 toggle state
|
|||||||
// Most of this code is just logging
|
// Most of this code is just logging
|
||||||
void storeCode(decode_results *results) {
|
void storeCode(decode_results *results) {
|
||||||
codeType = results->decode_type;
|
codeType = results->decode_type;
|
||||||
//int count = results->rawlen;
|
int count = results->rawlen;
|
||||||
if (codeType == UNKNOWN) {
|
if (codeType == UNKNOWN) {
|
||||||
Serial.println("Received unknown code, saving as raw");
|
Serial.println("Received unknown code, saving as raw");
|
||||||
codeLen = results->rawlen - 1;
|
codeLen = results->rawlen - 1;
|
||||||
|
|||||||
@@ -17,11 +17,7 @@ decode_results results;
|
|||||||
void setup()
|
void setup()
|
||||||
{
|
{
|
||||||
Serial.begin(9600);
|
Serial.begin(9600);
|
||||||
// In case the interrupt driver crashes on setup, give a clue
|
|
||||||
// to the user what's going on.
|
|
||||||
Serial.println("Enabling IRin");
|
|
||||||
irrecv.enableIRIn(); // Start the receiver
|
irrecv.enableIRIn(); // Start the receiver
|
||||||
Serial.println("Enabled IRin");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void loop() {
|
void loop() {
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
* You can change this to another available Arduino Pin.
|
* You can change this to another available Arduino Pin.
|
||||||
* Your IR receiver should be connected to the pin defined here
|
* Your IR receiver should be connected to the pin defined here
|
||||||
*/
|
*/
|
||||||
int RECV_PIN = 11;
|
int RECV_PIN = 11;
|
||||||
|
|
||||||
IRrecv irrecv(RECV_PIN);
|
IRrecv irrecv(RECV_PIN);
|
||||||
|
|
||||||
|
|||||||
@@ -61,7 +61,7 @@ void setup()
|
|||||||
// Wait for the gap between tests, to synchronize with
|
// Wait for the gap between tests, to synchronize with
|
||||||
// the sender.
|
// the sender.
|
||||||
// Specifically, wait for a signal followed by a gap of at last gap ms.
|
// Specifically, wait for a signal followed by a gap of at last gap ms.
|
||||||
void waitForGap(unsigned long gap) {
|
void waitForGap(int gap) {
|
||||||
Serial.println("Waiting for gap");
|
Serial.println("Waiting for gap");
|
||||||
while (1) {
|
while (1) {
|
||||||
while (digitalRead(RECV_PIN) == LOW) {
|
while (digitalRead(RECV_PIN) == LOW) {
|
||||||
@@ -125,7 +125,7 @@ void dump(decode_results *results) {
|
|||||||
// The motivation behind this method is that the sender and the receiver
|
// The motivation behind this method is that the sender and the receiver
|
||||||
// can do the same test calls, and the mode variable indicates whether
|
// can do the same test calls, and the mode variable indicates whether
|
||||||
// to send or receive.
|
// to send or receive.
|
||||||
void test(const char *label, int type, unsigned long value, int bits) {
|
void test(char *label, int type, unsigned long value, int bits) {
|
||||||
if (mode == SENDER) {
|
if (mode == SENDER) {
|
||||||
Serial.println(label);
|
Serial.println(label);
|
||||||
if (type == NEC) {
|
if (type == NEC) {
|
||||||
@@ -175,7 +175,7 @@ void test(const char *label, int type, unsigned long value, int bits) {
|
|||||||
|
|
||||||
// Test raw send or receive. This is similar to the test method,
|
// Test raw send or receive. This is similar to the test method,
|
||||||
// except it send/receives raw data.
|
// except it send/receives raw data.
|
||||||
void testRaw(const char *label, unsigned int *rawbuf, int rawlen) {
|
void testRaw(char *label, unsigned int *rawbuf, int rawlen) {
|
||||||
if (mode == SENDER) {
|
if (mode == SENDER) {
|
||||||
Serial.println(label);
|
Serial.println(label);
|
||||||
irsend.sendRaw(rawbuf, rawlen, 38 /* kHz */);
|
irsend.sendRaw(rawbuf, rawlen, 38 /* kHz */);
|
||||||
|
|||||||
@@ -192,12 +192,12 @@ void loop()
|
|||||||
ac_activate(AC_TEMPERATURE, AC_FLOW);
|
ac_activate(AC_TEMPERATURE, AC_FLOW);
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
if ( b == 0 || b == 1 ) {
|
if ( b == 0 | b == 1 ) {
|
||||||
ac_change_air_swing(b);
|
ac_change_air_swing(b);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 3: // 1 : clean on, power on
|
case 3: // 1 : clean on, power on
|
||||||
if ( b == 0 || b == 1 ) {
|
if ( b == 0 | b == 1 ) {
|
||||||
ac_air_clean(b);
|
ac_air_clean(b);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
/*
|
/*
|
||||||
* LegoPowerFunctionsTest: LEGO Power Functions Tests
|
* LegoPowerFunctionsTest: LEGO Power Functions Tests
|
||||||
* Copyright (c) 2016, 2017 Philipp Henkel
|
* Copyright (c) 2016 Philipp Henkel
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <ir_Lego_PF_BitStreamEncoder.h>
|
#include <ir_Lego_PF_BitStreamEncoder.h>
|
||||||
@@ -78,14 +78,14 @@ void testMessageBitCount(LegoPfBitStreamEncoder& bitStreamEncoder) {
|
|||||||
logTestResult(bitCount == 18);
|
logTestResult(bitCount == 18);
|
||||||
}
|
}
|
||||||
|
|
||||||
boolean check(LegoPfBitStreamEncoder& bitStreamEncoder, unsigned long markDuration, unsigned long pauseDuration) {
|
boolean check(LegoPfBitStreamEncoder& bitStreamEncoder, int markDuration, int pauseDuration) {
|
||||||
bool result = true;
|
bool result = true;
|
||||||
result = result && bitStreamEncoder.getMarkDuration() == markDuration;
|
result = result && bitStreamEncoder.getMarkDuration() == markDuration;
|
||||||
result = result && bitStreamEncoder.getPauseDuration() == pauseDuration;
|
result = result && bitStreamEncoder.getPauseDuration() == pauseDuration;
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
boolean checkNext(LegoPfBitStreamEncoder& bitStreamEncoder, unsigned long markDuration, unsigned long pauseDuration) {
|
boolean checkNext(LegoPfBitStreamEncoder& bitStreamEncoder, int markDuration, int pauseDuration) {
|
||||||
bool result = bitStreamEncoder.next();
|
bool result = bitStreamEncoder.next();
|
||||||
result = result && check(bitStreamEncoder, markDuration, pauseDuration);
|
result = result && check(bitStreamEncoder, markDuration, pauseDuration);
|
||||||
return result;
|
return result;
|
||||||
@@ -129,16 +129,16 @@ void testMessage407Repeated(LegoPfBitStreamEncoder& bitStreamEncoder) {
|
|||||||
bool result = true;
|
bool result = true;
|
||||||
result = result && check(bitStreamEncoder, 158, 1026);
|
result = result && check(bitStreamEncoder, 158, 1026);
|
||||||
result = result && checkDataBitsOfMessage407(bitStreamEncoder);
|
result = result && checkDataBitsOfMessage407(bitStreamEncoder);
|
||||||
result = result && checkNext(bitStreamEncoder, 158, 1026L + 5L * 16000L - 10844L);
|
result = result && checkNext(bitStreamEncoder, 158, 1026 + 5 * 16000 - 10844);
|
||||||
result = result && checkNext(bitStreamEncoder, 158, 1026);
|
result = result && checkNext(bitStreamEncoder, 158, 1026);
|
||||||
result = result && checkDataBitsOfMessage407(bitStreamEncoder);
|
result = result && checkDataBitsOfMessage407(bitStreamEncoder);
|
||||||
result = result && checkNext(bitStreamEncoder, 158, 1026L + 5L * 16000L - 10844L);
|
result = result && checkNext(bitStreamEncoder, 158, 1026 + 5 * 16000 - 10844);
|
||||||
result = result && checkNext(bitStreamEncoder, 158, 1026);
|
result = result && checkNext(bitStreamEncoder, 158, 1026);
|
||||||
result = result && checkDataBitsOfMessage407(bitStreamEncoder);
|
result = result && checkDataBitsOfMessage407(bitStreamEncoder);
|
||||||
result = result && checkNext(bitStreamEncoder, 158, 1026L + 8L * 16000L - 10844L);
|
result = result && checkNext(bitStreamEncoder, 158, 1026 + 8 * 16000 - 10844);
|
||||||
result = result && checkNext(bitStreamEncoder, 158, 1026);
|
result = result && checkNext(bitStreamEncoder, 158, 1026);
|
||||||
result = result && checkDataBitsOfMessage407(bitStreamEncoder);
|
result = result && checkDataBitsOfMessage407(bitStreamEncoder);
|
||||||
result = result && checkNext(bitStreamEncoder, 158, 1026L + 8L * 16000L - 10844L);
|
result = result && checkNext(bitStreamEncoder, 158, 1026 + 8 * 16000 - 10844);
|
||||||
result = result && checkNext(bitStreamEncoder, 158, 1026);
|
result = result && checkNext(bitStreamEncoder, 158, 1026);
|
||||||
result = result && checkDataBitsOfMessage407(bitStreamEncoder);
|
result = result && checkDataBitsOfMessage407(bitStreamEncoder);
|
||||||
result = result && checkNext(bitStreamEncoder, 158, 1026);
|
result = result && checkNext(bitStreamEncoder, 158, 1026);
|
||||||
@@ -191,3 +191,7 @@ void testGetMessageLengthAllLow(LegoPfBitStreamEncoder& bitStreamEncoder) {
|
|||||||
bitStreamEncoder.reset(0x0, false);
|
bitStreamEncoder.reset(0x0, false);
|
||||||
logTestResult(bitStreamEncoder.getMessageLength() == 9104);
|
logTestResult(bitStreamEncoder.getMessageLength() == 9104);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
22
irRecv.cpp
22
irRecv.cpp
@@ -1,11 +1,6 @@
|
|||||||
#include "IRremote.h"
|
#include "IRremote.h"
|
||||||
#include "IRremoteInt.h"
|
#include "IRremoteInt.h"
|
||||||
|
|
||||||
#ifdef IR_TIMER_USE_ESP32
|
|
||||||
hw_timer_t *timer;
|
|
||||||
void IRTimer(); // defined in IRremote.cpp
|
|
||||||
#endif
|
|
||||||
|
|
||||||
//+=============================================================================
|
//+=============================================================================
|
||||||
// Decodes the received IR message
|
// Decodes the received IR message
|
||||||
// Returns 0 if no data ready, 1 if data ready.
|
// Returns 0 if no data ready, 1 if data ready.
|
||||||
@@ -89,11 +84,6 @@ int IRrecv::decode (decode_results *results)
|
|||||||
DBG_PRINTLN("Attempting Lego Power Functions");
|
DBG_PRINTLN("Attempting Lego Power Functions");
|
||||||
if (decodeLegoPowerFunctions(results)) return true ;
|
if (decodeLegoPowerFunctions(results)) return true ;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if DECODE_NERF_LOP
|
|
||||||
DBG_PRINTLN("Attempting Nerf Laser Ops Pro Functions");
|
|
||||||
if (decodeNerfLOP(results)) return true ;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// decodeHash returns a hash on any input.
|
// decodeHash returns a hash on any input.
|
||||||
// Thus, it needs to be last in the list.
|
// Thus, it needs to be last in the list.
|
||||||
@@ -127,17 +117,6 @@ IRrecv::IRrecv (int recvpin, int blinkpin)
|
|||||||
//
|
//
|
||||||
void IRrecv::enableIRIn ( )
|
void IRrecv::enableIRIn ( )
|
||||||
{
|
{
|
||||||
// Interrupt Service Routine - Fires every 50uS
|
|
||||||
#ifdef ESP32
|
|
||||||
// ESP32 has a proper API to setup timers, no weird chip macros needed
|
|
||||||
// simply call the readable API versions :)
|
|
||||||
// 3 timers, choose #1, 80 divider nanosecond precision, 1 to count up
|
|
||||||
timer = timerBegin(1, 80, 1);
|
|
||||||
timerAttachInterrupt(timer, &IRTimer, 1);
|
|
||||||
// every 50ns, autoreload = true
|
|
||||||
timerAlarmWrite(timer, 50, true);
|
|
||||||
timerAlarmEnable(timer);
|
|
||||||
#else
|
|
||||||
cli();
|
cli();
|
||||||
// Setup pulse clock timer interrupt
|
// Setup pulse clock timer interrupt
|
||||||
// Prescale /8 (16M/8 = 0.5 microseconds per tick)
|
// Prescale /8 (16M/8 = 0.5 microseconds per tick)
|
||||||
@@ -151,7 +130,6 @@ void IRrecv::enableIRIn ( )
|
|||||||
TIMER_RESET;
|
TIMER_RESET;
|
||||||
|
|
||||||
sei(); // enable interrupts
|
sei(); // enable interrupts
|
||||||
#endif
|
|
||||||
|
|
||||||
// Initialize state machine variables
|
// Initialize state machine variables
|
||||||
irparams.rcvstate = STATE_IDLE;
|
irparams.rcvstate = STATE_IDLE;
|
||||||
|
|||||||
@@ -54,8 +54,6 @@ void IRsend::space (unsigned int time)
|
|||||||
//
|
//
|
||||||
void IRsend::enableIROut (int khz)
|
void IRsend::enableIROut (int khz)
|
||||||
{
|
{
|
||||||
// FIXME: implement ESP32 support, see IR_TIMER_USE_ESP32 in boarddefs.h
|
|
||||||
#ifndef ESP32
|
|
||||||
// Disable the Timer2 Interrupt (which is used for receiving IR)
|
// Disable the Timer2 Interrupt (which is used for receiving IR)
|
||||||
TIMER_DISABLE_INTR; //Timer2 Overflow Interrupt
|
TIMER_DISABLE_INTR; //Timer2 Overflow Interrupt
|
||||||
|
|
||||||
@@ -68,7 +66,6 @@ void IRsend::enableIROut (int khz)
|
|||||||
// CS2 = 000: no prescaling
|
// CS2 = 000: no prescaling
|
||||||
// The top value for the timer. The modulation frequency will be SYSCLOCK / 2 / OCR2A.
|
// The top value for the timer. The modulation frequency will be SYSCLOCK / 2 / OCR2A.
|
||||||
TIMER_CONFIG_KHZ(khz);
|
TIMER_CONFIG_KHZ(khz);
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//+=============================================================================
|
//+=============================================================================
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
// L E E O O
|
// L E E O O
|
||||||
// L EEEE E EEE O O
|
// L EEEE E EEE O O
|
||||||
// L E E E O O LEGO Power Functions
|
// L E E E O O LEGO Power Functions
|
||||||
// LLLLLL EEEEEE EEEE OOOO Copyright (c) 2016, 2017 Philipp Henkel
|
// LLLLLL EEEEEE EEEE OOOO Copyright (c) 2016 Philipp Henkel
|
||||||
//==============================================================================
|
//==============================================================================
|
||||||
|
|
||||||
//+=============================================================================
|
//+=============================================================================
|
||||||
@@ -14,25 +14,25 @@ class LegoPfBitStreamEncoder {
|
|||||||
private:
|
private:
|
||||||
uint16_t data;
|
uint16_t data;
|
||||||
bool repeatMessage;
|
bool repeatMessage;
|
||||||
uint8_t messageBitIdx;
|
int messageBitIdx;
|
||||||
uint8_t repeatCount;
|
int repeatCount;
|
||||||
uint16_t messageLength;
|
int messageLength;
|
||||||
|
|
||||||
public:
|
|
||||||
// HIGH data bit = IR mark + high pause
|
// HIGH data bit = IR mark + high pause
|
||||||
// LOW data bit = IR mark + low pause
|
// LOW data bit = IR mark + low pause
|
||||||
static const uint16_t LOW_BIT_DURATION = 421;
|
static const int LOW_BIT_DURATION = 421;
|
||||||
static const uint16_t HIGH_BIT_DURATION = 711;
|
static const int HIGH_BIT_DURATION = 711;
|
||||||
static const uint16_t START_BIT_DURATION = 1184;
|
static const int START_BIT_DURATION = 1184;
|
||||||
static const uint16_t STOP_BIT_DURATION = 1184;
|
static const int STOP_BIT_DURATION = 1184;
|
||||||
static const uint8_t IR_MARK_DURATION = 158;
|
static const int IR_MARK_DURATION = 158;
|
||||||
static const uint16_t HIGH_PAUSE_DURATION = HIGH_BIT_DURATION - IR_MARK_DURATION;
|
static const int HIGH_PAUSE_DURATION = HIGH_BIT_DURATION - IR_MARK_DURATION;
|
||||||
static const uint16_t LOW_PAUSE_DURATION = LOW_BIT_DURATION - IR_MARK_DURATION;
|
static const int LOW_PAUSE_DURATION = LOW_BIT_DURATION - IR_MARK_DURATION;
|
||||||
static const uint16_t START_PAUSE_DURATION = START_BIT_DURATION - IR_MARK_DURATION;
|
static const int START_PAUSE_DURATION = START_BIT_DURATION - IR_MARK_DURATION;
|
||||||
static const uint16_t STOP_PAUSE_DURATION = STOP_BIT_DURATION - IR_MARK_DURATION;
|
static const int STOP_PAUSE_DURATION = STOP_BIT_DURATION - IR_MARK_DURATION;
|
||||||
static const uint8_t MESSAGE_BITS = 18;
|
static const int MESSAGE_BITS = 18;
|
||||||
static const uint16_t MAX_MESSAGE_LENGTH = 16000;
|
static const int MAX_MESSAGE_LENGTH = 16000;
|
||||||
|
|
||||||
|
public:
|
||||||
void reset(uint16_t data, bool repeatMessage) {
|
void reset(uint16_t data, bool repeatMessage) {
|
||||||
this->data = data;
|
this->data = data;
|
||||||
this->repeatMessage = repeatMessage;
|
this->repeatMessage = repeatMessage;
|
||||||
@@ -43,9 +43,9 @@ class LegoPfBitStreamEncoder {
|
|||||||
|
|
||||||
int getChannelId() const { return 1 + ((data >> 12) & 0x3); }
|
int getChannelId() const { return 1 + ((data >> 12) & 0x3); }
|
||||||
|
|
||||||
uint16_t getMessageLength() const {
|
int getMessageLength() const {
|
||||||
// Sum up all marks
|
// Sum up all marks
|
||||||
uint16_t length = MESSAGE_BITS * IR_MARK_DURATION;
|
int length = MESSAGE_BITS * IR_MARK_DURATION;
|
||||||
|
|
||||||
// Sum up all pauses
|
// Sum up all pauses
|
||||||
length += START_PAUSE_DURATION;
|
length += START_PAUSE_DURATION;
|
||||||
@@ -75,9 +75,9 @@ class LegoPfBitStreamEncoder {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
uint8_t getMarkDuration() const { return IR_MARK_DURATION; }
|
int getMarkDuration() const { return IR_MARK_DURATION; }
|
||||||
|
|
||||||
uint32_t getPauseDuration() const {
|
int getPauseDuration() const {
|
||||||
if (messageBitIdx == 0)
|
if (messageBitIdx == 0)
|
||||||
return START_PAUSE_DURATION;
|
return START_PAUSE_DURATION;
|
||||||
else if (messageBitIdx < MESSAGE_BITS - 1) {
|
else if (messageBitIdx < MESSAGE_BITS - 1) {
|
||||||
@@ -88,13 +88,13 @@ class LegoPfBitStreamEncoder {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
uint16_t getDataBitPause() const {
|
int getDataBitPause() const {
|
||||||
const int pos = MESSAGE_BITS - 2 - messageBitIdx;
|
const int pos = MESSAGE_BITS - 2 - messageBitIdx;
|
||||||
const bool isHigh = data & (1 << pos);
|
const bool isHigh = data & (1 << pos);
|
||||||
return isHigh ? HIGH_PAUSE_DURATION : LOW_PAUSE_DURATION;
|
return isHigh ? HIGH_PAUSE_DURATION : LOW_PAUSE_DURATION;
|
||||||
}
|
}
|
||||||
|
|
||||||
uint32_t getStopPause() const {
|
int getStopPause() const {
|
||||||
if (repeatMessage) {
|
if (repeatMessage) {
|
||||||
return getRepeatStopPause();
|
return getRepeatStopPause();
|
||||||
} else {
|
} else {
|
||||||
@@ -102,12 +102,12 @@ class LegoPfBitStreamEncoder {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
uint32_t getRepeatStopPause() const {
|
int getRepeatStopPause() const {
|
||||||
if (repeatCount == 0 || repeatCount == 1) {
|
if (repeatCount == 0 || repeatCount == 1) {
|
||||||
return STOP_PAUSE_DURATION + (uint32_t)5 * MAX_MESSAGE_LENGTH - messageLength;
|
return STOP_PAUSE_DURATION + 5 * MAX_MESSAGE_LENGTH - messageLength;
|
||||||
} else if (repeatCount == 2 || repeatCount == 3) {
|
} else if (repeatCount == 2 || repeatCount == 3) {
|
||||||
return STOP_PAUSE_DURATION
|
return STOP_PAUSE_DURATION
|
||||||
+ (uint32_t)(6 + 2 * getChannelId()) * MAX_MESSAGE_LENGTH - messageLength;
|
+ (6 + 2 * getChannelId()) * MAX_MESSAGE_LENGTH - messageLength;
|
||||||
} else {
|
} else {
|
||||||
return STOP_PAUSE_DURATION;
|
return STOP_PAUSE_DURATION;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,89 +0,0 @@
|
|||||||
#include "IRremote.h"
|
|
||||||
#include "IRremoteInt.h"
|
|
||||||
|
|
||||||
//==============================================================================
|
|
||||||
//
|
|
||||||
//
|
|
||||||
// NERF LASER OPS PRO
|
|
||||||
//
|
|
||||||
//
|
|
||||||
//==============================================================================
|
|
||||||
|
|
||||||
#define BITS 15 // The number of bits in the command
|
|
||||||
|
|
||||||
#define HDR_MARK 2800 // The length of the Header:Mark
|
|
||||||
#define HDR_SPACE 6000 // The lenght of the Header:Space
|
|
||||||
|
|
||||||
#define ONE_MARK 1800 // The length of a Bit:Mark for 1's
|
|
||||||
#define ZERO_MARK 800 // The length of a Bit:Mark for 0's
|
|
||||||
#define ALL_SPACE 2100 // The length of a Bit:Space
|
|
||||||
|
|
||||||
#define purpule 0x440
|
|
||||||
#define red 0x400
|
|
||||||
#define blue 0x420
|
|
||||||
|
|
||||||
//+=============================================================================
|
|
||||||
//
|
|
||||||
#if SEND_NERF_LOP
|
|
||||||
void IRsend::sendNerfLOP (unsigned long data, int nbits)
|
|
||||||
{
|
|
||||||
// Set IR carrier frequency
|
|
||||||
enableIROut(40);
|
|
||||||
|
|
||||||
// Header
|
|
||||||
mark (HDR_MARK);
|
|
||||||
space(HDR_SPACE);
|
|
||||||
mark (HDR_MARK);
|
|
||||||
|
|
||||||
// Data
|
|
||||||
for (unsigned long mask = 1UL << (nbits - 1); mask; mask >>= 1) {
|
|
||||||
if (data & mask) {
|
|
||||||
space(ALL_SPACE);
|
|
||||||
mark (ONE_MARK);
|
|
||||||
} else {
|
|
||||||
space(ALL_SPACE);
|
|
||||||
mark (ZERO_MARK);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
space(0); // Always end with the LED off
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
//+=============================================================================
|
|
||||||
//
|
|
||||||
#if DECODE_NERF_LOP
|
|
||||||
bool IRrecv::decodeNerfLOP (decode_results *results)
|
|
||||||
{
|
|
||||||
//NOT IMPLEMENTED YET
|
|
||||||
return false;
|
|
||||||
unsigned long data = 0; // Somewhere to build our code
|
|
||||||
int offset = 1; // Skip the Gap reading
|
|
||||||
|
|
||||||
// Check we have the right amount of data
|
|
||||||
if (irparams.rawlen != 1 + 2 + (2 * BITS) + 1) return false ;
|
|
||||||
|
|
||||||
// Check initial Mark+Space match
|
|
||||||
if (!MATCH_MARK (results->rawbuf[offset++], HDR_MARK )) return false ;
|
|
||||||
if (!MATCH_SPACE(results->rawbuf[offset++], HDR_SPACE)) return false ;
|
|
||||||
|
|
||||||
// Read the bits in
|
|
||||||
for (int i = 0; i < SHUZU_BITS; i++) {
|
|
||||||
// Each bit looks like: MARK + SPACE_1 -> 1
|
|
||||||
// or : MARK + SPACE_0 -> 0
|
|
||||||
if (!MATCH_MARK(results->rawbuf[offset++], BIT_MARK)) return false ;
|
|
||||||
|
|
||||||
// IR data is big-endian, so we shuffle it in from the right:
|
|
||||||
if (MATCH_SPACE(results->rawbuf[offset], ONE_SPACE)) data = (data << 1) | 1 ;
|
|
||||||
else if (MATCH_SPACE(results->rawbuf[offset], ZERO_SPACE)) data = (data << 1) | 0 ;
|
|
||||||
else return false ;
|
|
||||||
offset++;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Success
|
|
||||||
results->bits = BITS;
|
|
||||||
results->value = data;
|
|
||||||
results->decode_type = SHUZU;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
@@ -7,7 +7,7 @@
|
|||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/z3t0/Arduino-IRremote.git"
|
"url": "https://github.com/z3t0/Arduino-IRremote.git"
|
||||||
},
|
},
|
||||||
"version": "2.3.3",
|
"version": "2.2.1",
|
||||||
"frameworks": "arduino",
|
"frameworks": "arduino",
|
||||||
"platforms": "atmelavr",
|
"platforms": "atmelavr",
|
||||||
"authors" :
|
"authors" :
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
name=IRremote
|
name=IRremote
|
||||||
version=2.2.3
|
version=2.2.1
|
||||||
author=shirriff
|
author=shirriff
|
||||||
maintainer=shirriff
|
maintainer=shirriff
|
||||||
sentence=Send and receive infrared signals with multiple protocols
|
sentence=Send and receive infrared signals with multiple protocols
|
||||||
|
|||||||
@@ -1,97 +0,0 @@
|
|||||||
## IRremote Library
|
|
||||||
|
|
||||||
|
|
||||||
Cette bibliothèque vous permet d'envoyer et de recevoir des signaux infrarouges sur un Arduino.
|
|
||||||
Des tutoriels et plus d'informations seront disponibles sur la page d'accueil officielle.
|
|
||||||
|
|
||||||
## Version - 2.2.3
|
|
||||||
|
|
||||||
## Installation
|
|
||||||
1. Allez à la [Releases](https://github.com/z3t0/Arduino-IRremote/releases) page.
|
|
||||||
2. Téléchargez la dernière version.
|
|
||||||
3. Extraire le fichier zip
|
|
||||||
4. Déplacez le dossier "IRremote" vers vos bibliothèques.
|
|
||||||
5. Assurez-vous de supprimer Arduino_Root / libraries / RobotIRremote. Où Arduino_Root fait référence au répertoire d'installation d'Arduino. La bibliothèque RobotIRremote a des définitions similaires à IRremote et provoque des erreurs.
|
|
||||||
|
|
||||||
|
|
||||||
## FAQ
|
|
||||||
Je ne travaille pas correctement en utilisant Neopixels (aka WS2811 / WS2812 / WS2812B)
|
|
||||||
Que vous utilisiez la librairie Adafruit Neopixel ou FastLED, les interruptions sont désactivées sur de nombreux processeurs bas de gamme comme les arduinos de base. À son tour, cela empêche le gestionnaire IR de s'exécuter quand il le faut. Il y a quelques solutions à ce processus, voir cette page de Marc MERLIN
|
|
||||||
[cette page de Marc MERLIN](http://marc.merlins.org/perso/arduino/post_2017-04-03_Arduino-328P-Uno-Teensy3_1-ESP8266-ESP32-IR-and-Neopixels.html)
|
|
||||||
|
|
||||||
|
|
||||||
## Conseils pris en charge
|
|
||||||
|
|
||||||
- Teensy 1.0 / 1.0++ / 2.0 / 2++ / 3.0 / 3.1 / Teensy-LC; Crédits: @PaulStoffregen (Teensy Team)
|
|
||||||
- Sanguino
|
|
||||||
- ATmega8, 48, 88, 168, 328
|
|
||||||
- ATmega8535, 16, 32, 164, 324, 644, 1284,
|
|
||||||
- ATmega64, 128
|
|
||||||
- ATtiny 84 / 85
|
|
||||||
- ESP32 (recevoir seulement)
|
|
||||||
- ESP8266 est basé sur un ancien code qui n'est pas très récent, mais cela fonctionne raisonnablement bien. Voir https://github.com/markszabo/IRremoteESP8266
|
|
||||||
Sparkfun Pro Micro
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Nous sommes ouverts aux suggestions d'ajout de support pour les nouveaux tableaux, cependant, nous vous recommandons fortement de contacter votre fournisseur et de fournir un soutien de leur côté.
|
|
||||||
|
|
||||||
|
|
||||||
## Spécifications matérielles
|
|
||||||
|
|
||||||
|
|
||||||
| Carte/CPU | Envoyer Pin | Compteurs |
|
|
||||||
|--------------------------------------------------------------------------|---------------------|-------------------|
|
|
||||||
| [ATtiny84](https://github.com/SpenceKonde/ATTinyCore) | **6** | **1** |
|
|
||||||
| [ATtiny85](https://github.com/SpenceKonde/ATTinyCore) | **1** | **TINY0** |
|
|
||||||
| [ATmega8](https://github.com/MCUdude/MiniCore) | **9** | **1** |
|
|
||||||
| Atmega32u4 | 5, 9, **13** | 1, 3, **4** |
|
|
||||||
| [ATmega48, ATmega88, ATmega168, ATmega328](https://github.com/MCUdude/MiniCore) | **3**, 9 | 1, **2** |
|
|
||||||
| [ATmega1284](https://github.com/MCUdude/MightyCore) | 13, 14, 6 | 1, **2**, 3 |
|
|
||||||
| [ATmega164, ATmega324, ATmega644](https://github.com/MCUdude/MightyCore) | 13, **14** | 1, **2** |
|
|
||||||
| [ATmega8535 ATmega16, ATmega32](https://github.com/MCUdude/MightyCore) | **13** | **1** |
|
|
||||||
| [ATmega64, ATmega128](https://github.com/MCUdude/MegaCore) | **13** | **1** |
|
|
||||||
| ATmega1280, ATmega2560 | 5, 6, **9**, 11, 46 | 1, **2**, 3, 4, 5 |
|
|
||||||
| [ESP32](http://esp32.net/) | N/A (insupporté) | **1** |
|
|
||||||
| [Sparkfun Pro Micro](https://www.sparkfun.com/products/12640) | 9, **5**, 5 | 1, **3**, 4_HS |
|
|
||||||
| [Teensy 1.0](https://www.pjrc.com/teensy/) | **17** | **1** |
|
|
||||||
| [Teensy 2.0](https://www.pjrc.com/teensy/) | 9, **10**, 14 | 1, 3, **4_HS** |
|
|
||||||
| [Teensy++ 1.0 / 2.0](https://www.pjrc.com/teensy/) | **1**, 16, 25 | 1, **2**, 3 |
|
|
||||||
| [Teensy 3.0 / 3.1](https://www.pjrc.com/teensy/) | **5** | **CMT** |
|
|
||||||
| [Teensy-LC](https://www.pjrc.com/teensy/) | **16** | **TPM1** |
|
|
||||||
|
|
||||||
|
|
||||||
## Patchs expérimentaux
|
|
||||||
|
|
||||||
Voici les correctifs strictement pris en charge qui n'ont pas encore été intégrés. Si vous avez des questions, n'hésitez pas à demander ici. Si cela fonctionne, faites le nous savoir!
|
|
||||||
|
|
||||||
[Arduino 101](https://github.com/z3t0/Arduino-IRremote/pull/481#issuecomment-311243146)
|
|
||||||
|
|
||||||
Le tableau ci-dessus répertorie les temporisations actuellement supportées et les broches d'envoi correspondantes, beaucoup de ces broches supplémentaires sont ouvertes.
|
|
||||||
|
|
||||||
|
|
||||||
## Utilisation
|
|
||||||
- À faire TODO (Vérifier les exemples pour l'instant)
|
|
||||||
|
|
||||||
|
|
||||||
## Contribution
|
|
||||||
Si vous voulez contribuer à ce projet:
|
|
||||||
- Signaler les bogues et les erreurs
|
|
||||||
- Demander des améliorations
|
|
||||||
- Créer des problèmes et tirer des requêtes
|
|
||||||
- Parlez de cette bibliothèque à d'autres personnes
|
|
||||||
- Contribuer de nouveaux protocoles
|
|
||||||
Vérifiez ici [ici](Contributing.md) pour quelques guidelines
|
|
||||||
|
|
||||||
|
|
||||||
## Contact
|
|
||||||
Email: zetoslab@gmail.com
|
|
||||||
Please only email me if it is more appropriate than creating an Issue / PR. I **will** not respond to requests for adding support for particular boards, unless of course you are the creator of the board and would like to cooperate on the project. I will also **ignore** any emails asking me to tell you how to implement your ideas. However, if you have a private inquiry that you would only apply to you and you would prefer it to be via email, by all means.
|
|
||||||
|
|
||||||
## Contributeurs
|
|
||||||
Check [here](Contributors.md)
|
|
||||||
@Lsuperman735 French translation
|
|
||||||
|
|
||||||
## Copyright
|
|
||||||
Copyright 2009-2012 Ken Shirriff
|
|
||||||
Reference in New Issue
Block a user