We received our ESP8266 NodeMCU several months ago it has been difficult to find a working example of Hardware PWM to generate crisp Infrared carrier signals. Most posts we have read suggest that there is no PWM readily available on any of the supported platforms. As we have already shown with Arduinos and the Particle Photon we figured it would be possible to use a spare UART pin on the ESP8266 NodeMCU to achieve our goal. After some initial success we encountered some watchdog timeouts/resets and it seemed like the uPWM hack would not be possible on the ESP8266 Node MCU platform. For a few weeks we ‘parked’ the effort and today we decided to try again with all of the latest and updated firmware available from the ESP8266 community via the Arduino IDE. This time we were successful and the ESP8266 NodeMCU Backdoor uPWM Hack for IR signals using works!

One of the most popular projects involving Infrared remote control, is to use an Arduino to control an Air conditioner (AC) system. However, AC signals are usually very long and take up a lot of SRAM on a standard Arduino. Experienced users will go about reverse engineering the AC protocol to make the sketch fit within the 2K Bytes of SRAM. Many hobbyists will struggle, even with the help of tools like AnalysIR to guide them. In this post we cover sending long AC Signals from Flash with IRremote. IRremote (along with IRLib) is a popular open-source library for sending and receiving IR remote control signals with Arduino. The demo code covered in this sketch extends our previous sendRAW example by demonstrating how to store many long AC signals in Flash with little or no SRAM overhead.

AnalysIR screen-shot showing the signals captured from the sendRAW_Flash sketch (click or more detail)

Marco is a volunteer for an organization (NSW Australia) that builds custom aids for people with disability, and has recently been looking at a project to create a ‘very large button’ IR remote control for a cable TV Set Top Box (STB). The custom unit needed basic functions (Channel Up/Down, Volume Up/Down and Power On/Off). Commercially available large button remotes have buttons that are still too small and/or they have too many buttons. Soon he hit a roadblock trying to capture some difficult Foxtel signals and searched all over the web looking for a solution. Needless to say, nothing worked out for him until he came across AnalysIR via Google. Once he started Troubleshooting the Big Button Infrared remote control with AnalysIR the root cause of his problems became obvious.

One of our users from Italy, Guido, was tasked with upgrading an old in-house WRC system to allow the team of Sport’s Journalists to access the rack of satellite receivers relaying the various sports events around the building. The challenge is that all of the STB (Set Top Boxes) are located in a dedicated room away from the Journalist’s desks and it is impractical for them to manually change the stations when working to tight deadlines. Previously there was a system in place to remotely switch feeds, but Guido needed to upgrade the system to handle the ever growing number of devices and Infrared protocols. Luckily, he found AnalysIR during his research to implement ‘a hack for Hacks using AnalysIR‘.

In this blog post we follow up on our recent article about generation of infrared PWM from the Photon’s UART where we suggested that it may be possible to achieve something similar with the Arduino. In our previous attempt the Arduino was only able to generate PWM at 40 kHz and 33 kHz using the same approach. After some investigations we discovered a new approach which provides an even better set of results using the Arduino’s USART. Yes, we were able to generate 30, 33, 36, 38, 40 , 56 and surprisingly the illusive 455 kHz which was not possible on the Photon (using this approach). Read on for the details. Readers should also study our original series of articles on ‘softPWM‘ for a better understanding of the source code which can be downloaded below.

This post is the second in a two-part series about Reverse Engineering AC Infrared protocols. This time we look at the Mitsubishi Air Conditioner IR Protocol. The project was undertaken by two of our users in France (Vincent & Mathieu), with the help of AnalysIR, who collaborated to reverse engineer this Mitsubishi and previously the Panasonic AC Infrared protocol, both examples of the more challenging AC Infrared protocols. Not only did they identify the individual field codes & checksum but also provided some impressive documentation. Detailed information is available via GitHub which is linked below. This 288 data bit Mitsubishi AC Infrared protocol is composed of two consecutive frames. Both frames are always identical for each signal sent. In common with most AC units the complete settings are sent with every IR signal (temperature, fan, swing etc…). AnalysIR was used to record and turn the signal into HEX/Binary format from which the reverse engineering of the individual fields was tackled.

Recently, two of our users in France (Vincent & Mathieu) collaborated to reverse engineer the Panasonic AC Infrared protocol, one of the more challenging AC Infrared protocols using AnalysIR. Not only did they identify the codes & checksum but also provided some impressive documentation and full source code to help others. Detailed information is available via GitHub which is linked below. This 216 data bit Panasonic AC Infrared protocol is composed of two consecutive frames. The first frame remains constant for every command sent to the AC unit. In common with most AC units the complete configuration is sent with every IR signal (temperature, fan, swing etc…). AnalysIR was used to record and turn the signal into HEX/Binary format from which the reverse engineering of the individual fields was tackled.

Anyone who has tried controlling an Air Conditioner unit using an Arduino, USB IR Toy, RPi or any MCU will know how difficult it can be to record the longer infrared signals they use. Typical TV systems use IR signals circa 32 bits long, while this Chigo AC unit uses a signal with 197 marks & spaces (or 97 data bits). One of our users, Sertunc – from Istanbul in Turkey, reported his success using AnalysIR to easily record the signal timings for his AC unit and sent us the details along with some nice photos. After testing the validity of the recorded signals using an Arduino, he then set about loading the signals onto his Samsung smart phone (models S4, s4 mini, S5 and more supported). This was helped by installing the free ‘Samsung IR – Universal Remote‘ app onto his phone via Google Play.

A while ago we came across a website on infrared remote controls which suggested a simple way to view IR signals using an Oscilloscope. The idea is to use a standard IR Led mounted into a BNC/RCA plug using a spare channel making an Oscilloscope infrared receiver. So we set about ordering the connectors, which arrived in the post today. Another way of looking at this device is as a ‘poor-mans’ IR receiver, but if you have an Oscilloscope to plug it into then maybe you are not so poor after all.

Recently we have been helping several members on the Arduino forum to record and playback their remote control signals from their Air Conditioners. These signals are typically much longer than those of TVs or common media devices. The 2 most popular libraries for Arduino, IRremote & IRlib are excellent, but have some limitations which we have covered in a previous post. In this post we address one particular issue that is proving challenging to users.

AnalysIR decodes over 75 of the most common base CIR protocols formats, including TVs, STBs, Air Conditioners & other variants/devices, and boasts a comprehensive range of features to help you as a Maker or Professional. This translates into many 10,000s of actual devices. It also analyzes 99.9%+ of all infrared remote control signals.

Well, I actually managed to sort it out,…Thanks to AnalysIR, I have determined the {Steering wheel} controls send in the Disney{Serial} format, and that the signals get repeated. Before AnalysIR, all I had was basic output from a soundcard oscilloscope…

Arduino User, Australia

In a few minutes I was able to record & replay Hitachi RAF/RAK AC signals…

IR Toy User, France

Great product! The firmware for Arduino worked perfectly the first time and I’ve been able to decode all the equipment of interest. This has been a real timesaver.

Arduino User, NC USA

I do like the new Batch Export feature. It allowed me to export a bunch of signals from another NEC protocol remote {directly} to an IRremote sketch.

Arduino IRremote User, CT USA

I’m very happy your software works fine and I found the IR protocol of my Optik IPTV remote control, it’s RCMM, this protocol is new for me…. ….Thank you very much, AnalysIR will be a good tool for my next small robot project.

USB IR Toy User, QC Canada

Awesome thanks for the quick reply and great product!!

AnalysIR User, Taiwan

I am so glad I found AnalysIR…

Arduino Student, Egypt

I think you are the only company in the world that sell equipment like this.

AnalysIR User, Israel

Wow. You guys have great customer service! It’s a rare thing these days. Thanks.

USB IR Toy User, NY USA

I have downloaded AnalysIR and used it. There is one word I can say about it – AWESOME!!! It took me 10 minutes to decode required parts of an AC protocol.I highly recommend it.

Arduino User

….and thanks for devoloping this great software! It is very easy and straight forward to use it !

NodeMCU/WemOS user, Turkey

Just to say that i am very happy with the program. I Can decode a Toshiba aircon and transmit via arduino.

Arduino User, Denmark

Truly a wonderful tool! I can’t imagine going back to how I did this before. If only I had this back when I did home automation all the time. Geez what a cluster that was…Without your excellent tool I couldn’t have done {my AC} project;Keep up the GREAT work!later – L.

USB IR Toy User, KY USA

The link you sent me cured my trouble. Your instructions were easy to follow. Thank you again for wonderful support. All tools are lined up and ready to go.

Arduino User, Spain

Once again thank you for your wonderful support

Win8 user, Singapore

Thank you for quick and super service!

AnalysIR User, Norway

Adding the networking capability to AnalysIR is great for me.

IR Professional - CO, USA

Great bit of software BTW – really easy to use.

Spark Core user, UK

Again, thanks a lot for your great support!

LearnIR User, Sweden

Now i can figure out the correct {AC signal} checksum. (SUM, ignore 1 bytes @ end.) Finally i found it! Thanks for your great software.

Truly a wonderful tool! I can’t imagine going back to how I did this before. If only I had this back when I did home automation all the time. Geez what a cluster that was…Without your excellent tool I couldn’t have done {my AC} project;Keep up the GREAT work!later – L.

USB IR Toy User, KY USA

{re: Silver Bullet IR Receiver} And I must (again) state: The bullet is just a beautiful design. J

Oscilloscope User, WA - USA

Thanks again you guys rock customer service.

AnalysIR User, CT USA

Again, thanks a lot for your great support!

LearnIR User, Sweden

…the IR is Hitachi184_264_296AC. right out of the box…..What a great piece of software.

ESP8266 User - UK

In a few minutes I was able to record & replay Hitachi RAF/RAK AC signals…

IR Toy User, France

I am so glad I found AnalysIR…

Arduino Student, Egypt

I received the package with the LearnIR and the single Vishay LED, many thanks for the quick service. Within an hour or so I had the LearnIR working, and controlling my AC unit!

I love AnalysIR and it helped me to solve an issue with a defunct firmware on a home automation controller.

USB IR Toy User, Tx USA

I am writing to let you know that I just used AnalysIR to decode one of my Aircon and I was able to get workable on/off codes in just one try (and that too in 5 minutes). AnalysIR is superb and a huge time saver, I wish I had purchased it weeks earlier instead of trying to decode myself. Amazed and delighted by your product.

IoT User, Singapore

Got it working. Thanks a lot for your support. Its a great software and my codes were recognised. {Air-Conditioner project}

Arduino User, Uttar Pradesh - India

Just 2 lines to let you know I am now sending IR codes to my AC from JeeNode with IRremote and everything is working fine. IR codes are stored in flash with PROGMEM and copied to a buffer in RAM each time before calling irSend(). Thanks again for your help.

JeeNode User, Italy

The link you sent me cured my trouble. Your instructions were easy to follow. Thank you again for wonderful support. All tools are lined up and ready to go.

Arduino User, Spain

Just to make you aware that everything is working fine. I’ve been finally able to use my IR Toy!

USB IR Toy user, Italy

What can I say? I’m not a programmer, I’m skilled in hardware, but with AnalysIR software and 2/3 hours, my Samsung AR9000 series AC system is now controlled by Arduino!!! Also tested NodeMCU to acquire the signal and also in this case all works very well! …..Thanks, thanks, thanks!!! A fantastic software!

Arduino User, Italy

I went thru’ your superbly written intro guide and used AnalysIR last night and finally solve my AC IR mystery. Nice piece of SW and well written documentation makes it a pleasure to use.Thank You.

Arduino User, KL - Malaysia

… extremely happy with my purchase of AnalysIR, have been able to decode and reproduce all remotes I have in my home.

USB IR Toy User, Netherlands

My main interest in your project was your ability to detect {modulation} frequencies.

Arduino User, IN USA

AnalysIR has proved to be extremely valuable, not least as a learning tool for me.

AnalysIR Coupon & New Products

Use coupon code 10offanalysir during checkout to get 10% off purchases of AnalysIR software (Maker & Pro Editions only), for a limited time only. Also check out our newly released MakeIR modules & shieldsvia our webshop.