Arduino All-In-One Remote

Picture of Arduino All-In-One Remote

Now you can have all the remotes of your house in a device that fits in your hand with Arduino, never fight for who has the TV remote again!

To make it you will need:

  • Arduino (I used a cheap copy of the arduino UNO).
  • LCD keypad shield, (I bought mine from dealextreme)
  • 1x Infrared LED (standard ~940nm)
  • 1x Infrared sensor.
  • A computer. (That can run the arduino compiler program)


  • Program for gathering signals (download here)
  • Main program (download here)
  • Video program (download here)
Remove these adsRemove these ads by Signing Up

Step 1: Intro:

Infrared light has been used quite a lot for many different applications in many fields, one of them is communication, specifically between remotes and domestic devices, what allows us to control them without leaving the comfort of our sofa.

The process of communication between an emitter (the remote) and a receiver (the device) starts when the user presses any button of the remote, this device has an oscillator and a preconfigured chip that allow the signal to adopt a square waveform with a frequency of 39kHz, depending on the button pressed, the chip will use a determined signal code.
This signal travels through the circuit until it reaches the infrared LED, which transforms it into a series of pulses of invisible light (~940nm). If any sensor it's in it's range those pulses will be transformed into a quadratic wave that will indicate what to do according to the programming of the device.

To create a remote we want to capture those pulses, which will have a certain amplitude in time, we also want to know the time between those pulses so we can reproduce those pulses with voltage and time as the only variables.

Victor8o5 (author) 1 month ago

I've just added a video of it working, I know that feel when you view an instructable of a cool thing just to realize there's no video :(

If you want to download the code the Arduino was using while I was recording the video I've added another link at the beginning.

amr3212 days ago

what kind of infared sensor you use? is it IR Sensor Set or

Digital Infrared Sensor
Victor8o5 (author)  amr325 days ago

It's this one, these kind of sensors are widely used in household appliances, they have one lead for 5 volts and one for ground. When an infrared beam hits it the first pin goes HIGH (talking about logic), they are very fast, allowing to capture remote signals by a series of HIGHs and LOWs.

Sorry for the delay.

niqueryptic1 month ago

fantastic! i'm about to try it out. but what is the black box at the bottom of the arduino? where can i get it? thank you!

Victor8o5 (author)  niqueryptic1 month ago
It's a home made case made out of wood, it has a hollow space inside to store two 9v batteries and a switch to control the power, here's a pic of it. Sadly I didn't take any photos when making it so I can't do an instructable about it.

Also thank you guys for your support!

thanks! is there anywhere i can your complete codes for this project? i'm really having a hard time figuring it out. it would be really helpful to have some guidance. thanks!

Victor8o5 (author)  niqueryptic1 month ago

Codes are at the beginning of the instructable, just before the "Intro" step, at the "To make it you will need:" list.

I'll make it more visible since some people have also asked about the program.

mrfixit631 month ago

Hello, I was wondering, How can I use this idea to control something that I don't have the remote for? I'm having great difficulty finding proper code, and ways to get code from the internet and use them on my Arduino. I was using with which gave me no results after weeks of trying. (It doesn't help that I'm not a skilled programmer, either.) The device that i'm trying to control is a Sony BDV-E370 blue ray home theater system that I picked up at a yard sale for 5 bucks :D Anyways, I want to use it properly, without having to buy a replacement remote (Which won't sell to me, because I live in Canada, and don't have it.). Thanks for reading, I really hope you look into this, keep in touch with me, and have a nice day! :)

Best way to find a code for a device with no remote is to search the web. Doing a google search with Sony BDV-E370 ir codes shows this page as first result, which actually contains the whole list of codes for the remote:

Hope it helps!

I've searched high and low on google for codes, but none of them worked on the arduino.

Victor8o5 (author)  mrfixit631 month ago

As sourcery said you can find the codes on the internet, the bad thing is they come with rare formats to be used with universal remotes, usually this codes are contained in hexadecimal formats, I'm unaware about the possible interpretation and implementation to use with the Arduino program I've made since it's designed to work with natural numbers.

It would be better to buy an universal remote and upload the files, if you wanted to use the Arduino you would have to pass the hex code to integers that represent the times of the signal and then encase them into the functions of the program, what would be a very tedious task.

Thank you for some feedback, i'm probably just going to go for the universal remote, because that's Waaaaaaay too advanced for me to do. I've tried to use the hex codes in the code, but no luck. I gave up on trying it.

dorton1 month ago

Hi Victor,

I'd suggest putting those codes in ROM, then just loop through them. It will reduce you program length and make it easier to read.


const int IRCmd1[] = {4440, 4400, 540, 1660, 520, 1660, 540, 1660,520, 560, 540, 560, 520, 560, 540, 560,520, 580, 520, 1660, 540, 1660, 520, 1660,540, 560, 520, 560, 540, 560, 520, 560,540, 560, 520, 580, 520, 1660, 540, 560,520, 560, 540, 560, 520, 560, 540, 560,520, 580, 520, 1660, 520, 580, 520, 1660,540, 1660, 520, 1660, 540, 1660, 520, 1660,520, 1680, 520, 0};

case x: i=0;

do {



} while IRCmd[i];

Victor8o5 (author)  dorton1 month ago

Thanks, I thought about that when I was programming the remote program, I've been breaking my head to make something alike because when you run the code the operations that have to be made (++, finding and reading the array...) add time to the whole operation of sending a signal I still don't know if that delay caused by these operations could be negligible or it could cause the remote to malfunction, C is one of the fastest programming languages but taking into account the speed of the processor I'm not sure about if that code could cause problems.

I thought about counting the time with millis() between the beginning and the end of the operation and then subtract it from the delays.

Another thing I had in mind was some sort of conversion to an hexadecimal format to save space. At this point this would require libraries to keep it all clean and neat and to avoid going insane.

Space is not too much of a problem since a charged remote program doesn't takes more than 1/3 or to 1/2 of the memory of the Arduino, but I must say it's a very good habit to think wisely and try to minimize the weight of the program whenever it's possible.

I'll work on it and I'll try to upload a new version with new features, maybe even recording code on the go.

Thanks for bringing this up.

Had another look, (clearly I'm having fun). If you look at the IR libs on the Arduino site, they use an int on change interrupt and a timer to measure the pulse width. This is a good way to measure the incoming pulse widths.

To send pulses out, setup your LED output (ie pin D2) with "tone(PIN2, 38000);" then just use "DDRD |= ~4" to turn it on and "DDRD |= 4" to turn it off.

Victor8o5, I think this is a great Instructible and wonder if you could attach the complete code that you used ? I would like to see the menus and sub menus with your IR commands . Your code description sounds logical I have tried using a menu system before , but with my limited skills I was not able to get it to run.

Thank you so much for sharing ,


I just found the link to the code ...I will start looking through it now .

Thanks again !


DoItOrDie1 month ago

Excellent! This is just what I have been needing.

jgall21 month ago
Just finished making this project just have to put it in a box and all done. Excellent instructable, great project. If anyone is wanting to do this project I would recommend just using Victor8o5's code and pasting in the ir code gathered in the spots where it is supposed to go.
wilgubeast1 month ago

You individually read the IR signals from all of your remotes??? You win the remote control patience award. A device designed for the lazy, turned into something worthy of a monk. A lazy monk, but a monk nonetheless.

As someone who gets frustrated programming my Logitech Harmonies, this is glorious. The remote control singularity. Now it just needs a case.

Victor8o5 (author)  wilgubeast1 month ago

Yeah, It might be a bit tedious, but it's the simplest way, I guess it's not that bad, you just point the remote to the sensor, press a button and the code gathering program will encase the times in functions for you, so you just have to copy and paste that block of functions in its corresponding case.

It's quite fast actually, recording 10 buttons doesn't takes you more than 3 minutes.

And yes, I can feel the irony, just the main code took me several weeks of programming.

amr32 Victor8o51 month ago

what kind of arduino you use?

Victor8o5 (author)  amr321 month ago

Its a copy of the Arduino UNO, called "freaduino" it works exactly the same, same pins, same disposition, same power, same code... but is has the chip embedded on the pcb and some extra features like a 3.3 to 5 switch to chose the output of the digital pins, it also has svg pins.

You won't have any problem if you use the code with your original Arduino UNO.

I love it. Anyone with the patience to fully solve this problem deserves a medal. Like the guy who made an end grain coffee table in his apartment without clamps. Or the girl who made a chainmaille shirt with needlenose pliers and poptabs. You rock, dude.

Enjoy the year of pro membership that comes with the feature, and I'm setting you up with 3 bonus months of pro to gift to someone else. Or for yourself, as I won't be following up. :D

^ like
Ok I'm 8 and I know how to program so come to me
Victor8o5 (author)  jack 8 years old1 month ago

Wow! I was 16 when I started programming.

simotoni1 month ago

Bravissimo !!!