-
Notifications
You must be signed in to change notification settings - Fork 638
Adding Custom IR Codes
Darsh Patel edited this page May 2, 2018
·
3 revisions
- Open
general.h
in your favourite text editor - make a copy of any IR code set and paste it, iterating the parameter
IR_BUTTON_SET
- Use IRrecvDumpV2 to get IR Codes , You'd get something like this :
Timestamp : 002222.937
Encoding : NEC
Code : FFE01F (32 bits)
Library : v2.3.2
Raw Timing[71]:
10816, - 4494, + 674, - 572, + 674, - 572, + 672, - 572,
672, - 572, + 672, - 600, + 646, - 572, + 672, - 572,
672, - 572, + 676, - 1678, + 668, - 1680, + 666, - 1708,
644, - 1682, + 670, - 1682, + 672, - 1680, + 678, - 1682,
674, - 1682, + 676, - 1704, + 658, - 1680, + 682, - 1682,
686, - 574, + 684, - 574, + 682, - 574, + 744, - 518,
670, - 570, + 668, - 570, + 672, - 572, + 676, - 572,
676, - 1678, + 678, - 1680, + 676, - 1680, + 676, - 1680,
680, - 1682, + 746, - 40008, + 10806, - 2228, + 668
uint16_t rawData[71] = {10816, 4494, 674, 572, 674, 572, 672, 572, 672, 572, 672, 600, 646, 572, 672, 572, 672, 572, 676, 1678, 668, 1680, 666, 1708, 644, 1682, 670, 1682, 672, 1680, 678, 1682, 674, 1682, 676, 1704, 658, 1680, 682, 1682, 686, 574, 684, 574, 682, 574, 744, 518, 670, 570, 668, 570, 672, 572, 676, 572, 676, 1678, 678, 1680, 676, 1680, 676, 1680, 680, 1682, 746, >40008, 10806, 2228, 668}; // NEC FFE01F
uint32_t address = 0x0;
uint32_t command = 0x7;
uint64_t data = 0xFFE01F;
the uint64_t data value is useful to us.
5. Change IR_BUTTON_COUNT
to number of buttons defined
4. replace the codes inside the new IR codes set you created
- change the
IR_BUTTON_SET' of the board of your choice in
hardware.h`
- Done!
If you're looking for support:
- Issues: this is the most dynamic channel at the moment, you might find an answer to your question by searching open or closed issues.
- Wiki pages: might not be as up-to-date as we all would like (hey, you can also contribute in the documentation!).
- Gitter channel: you have better chances to get fast answers from project contributors or other ESPurna users. (also available with any Matrix client!)
- Issue a question: as a last resort, you can open new question issue on GitHub. Just remember: the more info you provide the more chances you'll have to get an accurate answer.
- Backup the stock firmware
- Flash a pre-built binary image
- Flash a virgin Itead Sonoff device without opening
- Flash TUYA-based device without opening
- Flash Shelly device without opening
- Using PlatformIO
- from Visual Studio Code
- Using Arduino IDE
- Build the Web Interface
- Over-the-air updates
- Two-step updates
- ESPurna OTA Manager
- NoFUSS
- Troubleshooting
- MQTT
- REST API
- Domoticz
- Home Assistant
- InfluxDB
- Prometheus metrics
- Thingspeak
- Alexa
- Google Home
- Architecture
- 3rd Party Plugins
- Coding style
- Pull Requests