The One-Shot IR Helper Automatically Activates Gadgets and Appliances

Based on the Raspberry Pi Pico development board, the One-Shot IR Helper sends out a specific infrared command to a specific appliance.

The old way of doing things

In Gregory Sanders' project, the One-Shot IR Helper, he describes how his setup of five monitors worked extremely well, except for one annoying issue that kept cropping up. Many HDMI-equipped displays and outputs support a feature called HDMI-CEC, or consumer electronics control, which lets the host communicate back-and-forth with its connected peripheral devices. For example, turning on a gaming console might cause the TV to switch to that input automatically. Likewise, waking up a connected PC will, in turn, wake up the display. But one of Sanders' five televisions did not support this ultra convenient feature, so he decided to automate it himself with a bit of extra hardware.

Decoding infrared signals

Before he could start emulating the TV's remote control and power it on from a distance, Sanders first had to know the exact command(s) being sent to the receiver by the remote. To do this, he attached an IR receiver module to an Arduino board, pressed the 'On' button on the remote, and recorded which values were outputted into the serial monitor. The resulting Python script reflects this list of values by using Peter Hinch's micropython_ir library to send the value of the 'On' key to the TV's address.

Setting up the Pico

The hardware involved in this project is quite simple, as it consists of the Raspberry Pi Pico board, a couple of resistors, a transistor, and most important, an IR LED emitter. This circuit enables the Pico's X1 pin to quickly modulate the LED's signal at around 2V and 25mA. An additional pushbutton switch was added between the ground and reset pins to allow for a user to manually reset the Pico for testing.

Switching something on

With the code now uploaded to the Pico and the circuit assembled, Sanders tested his new creation by positioning the IR LED next to the television's receiver. Because the firmware only runs once when the Pico boots, it receives its power from an unpowered USB hub attached to the PC. This way, powering on the computer causes the circuit to receive power at the same time, thus turning on the TV. You can read more about this project here on Hackaday.io.


gatoninja236

Embedded Software Engineer II @ Amazon's Project Kuiper. Contact me for product reviews or custom project requests.

Latest Articles