Turn Your HTPC on From Your Couch

Introduction: Turn Your HTPC on From Your Couch

About: Hacker, maker and fixer on electrical, electronic and woodworking projects.

Do you already have the amazing Mele F10 remote and wonder why the Power Button does not work? It is actually designed to work only with the Mele Set-top box but with this IR receiver you can turn not only OFF but also ON almost any HTPC within reach without having to get up from your warm couch!

The circuit is very simple.

Linkit ONE is used as the microcontroller to read the IR code for the power button (0xC9D1F64D) from the IR module HX1838.

If the right code is detected a simple 1ch relay module is activated for a second to send the power off signal to the Motherboard. If at the end of the 1 second the power button is still pressed on the remote and remains pressed for 4 more seconds the relay stays activated for all that time causing a hard reset. That is very useful if you have a problematic HTPC that locks some times and requires to remove the power or press the power hard button for 5 seconds to trigger a forced reboot. All that AFTER you get up from your cosy couch, you couch potato you!

Step 1: The Circuit

The circuit is very simple (attached).

As I couldn't find the symbol for the HX1838 in Fritzing I used a simple IR LED as a placeholder. The pinout is the same but please use the actual board with the 2 resistors for the HX1838 with Vcc, GND and IN pins. IN pin goes to D11 of Linkit.

The schematic shows a simple 5V relay controlled by an NPN transistor. If you decide you use a 1 channel relay module, you don't need R1, Q1 and U1. Connect Linkit's D12 to the relay's input signal.

Switch S1 is the actual switch of the motherboard. Look up the pinout from your motherboard's user manual and connect the relay contacts to the contacts that go to the power switch of your PC.

As the board is powered by 5V use one of the spare on-board USB pin headers to steal that 5V. Make sure from BIOS that power to that pin-header remains on while the motherboad is off (S3 or whatever you choose to sleep to)

Step 2: Load the Code

Load the code to your Linkit ONE and you are ready.

Power up your project from a USB port.

Test by pressing the power button in front of the HX1838.

Watch for that click-click sound of the relay!

If nothing happened enable debugging in serial port by uncommenting

Serial.println(results.value, HEX);

If you get stuck, feel free to ask me here!

Good Luck!

Arduino All The Things! Contest

Participated in the
Arduino All The Things! Contest

Be the First to Share


    • Trash to Treasure Contest

      Trash to Treasure Contest
    • Origami Speed Challenge

      Origami Speed Challenge
    • Make It Modular: Student Design Challenge

      Make It Modular: Student Design Challenge



    4 years ago

    Hello again,

    I got the Arduino and got your code working pretty easily. I added the extra serial prints to see the results, and what I found with my remote is that the NEC protocol was used, but actually my power code was different. Code 0xF9EA15 is used instead as the command value.

    results.decode_type = 3
    results.address = 0
    results.value = F9EA15

    I've got two remotes - one older one, and one newer one. Both used F9EA15 as the power code however there was a difference with my older one in that it doesn't do long presses either - to get the hard reset to work, holding the button didn't work but pressing 4 times rapidly does. On the newer one the long press does keep receiving codes, subsequent codes were FFFFFFFF instead.

    I'm not planning to use the hard reset - quite nicely my HTPC actually never needs it!

    I'm going to try and do a PIC version and I'll update on that but anyway, this has been fantastic to get me started and will be useful for decoding other remotes in future.

    Thanks very much,


    Reply 4 years ago

    Hmmm... that is strange but glad you found the workaround. This is actually better from an educational point of view because if my code would simply work for you straight away you might not even look at any line and try to understand what it does.

    Congrats and enjoy your movies now even easier!


    4 years ago

    Thanks very much. I have ordered an Arduino anyway (good excuse to learn them too) and I'll have a go at using those libraries to decode the remote. I'll post here the results. Thanks again,


    Question 4 years ago

    Hi there. Interesting work. I also have a Mele F10 and want to do the exact same thing. I would like to use PIC microprocessors instead though, since I have the hardware already. I see that you managed to identify the code 0xC9D1F64D from the remote - but do you have any idea what protocol it uses? For example RC5, RC6, NEC, Sony, Panasonic etc? It looks like you can find out via the library using results.decode_type. If you know at all, this would be very useful!

    Many Thanks,


    Answer 4 years ago

    The reading function was using raw format so, no, I don't know the protocol I'm afraid. (I think) if it was to be referring to an, say, RC5 code the value would be considerably shorted intead of 0xC9D1F64D. I am actually using an arduino nano, not the (expensive) board shown here.