Quantcast
Channel: Kodi Community Forum - All Forums
Viewing all articles
Browse latest Browse all 84005

IR Controlled PC Power Switch

$
0
0
Hi Everyone,

I've looked around for a way to reliably turn on a PC using an IR remote that didn't cost too much money. I didn't find anything suitable so I hacked together my own solution. I hope someone else can find this useful.

Quick summary of my problem - I have XMBC 11 running on Ubuntu 10.04 controlled by a generic media center USB receiver and a Harmony remote. I wanted to be able to turn the PC on with the remote. I could never get suspend to work right, so after a lot of work I concluded I needed a device that would receive an IR code from the remote and switch the PC's power button. There are kits you can assemble yourself that are designed to do this, and a way to modify an Xbox DVD remote receiver, but they were honestly more money than I wanted to spend on something that should be simple.

After some searching I ran across this for $5: http://dx.com/p/ir-remote-controlled-ac-...220v-12902 Looking at the PCB inside you'll see that the device is basically an AC to DC rectifier, some IR logic that runs on 5V, and a relay that is switched by the IR logic to open and close the AC outlet. Knowing this, it's fairly simple to modify it to run off of USB power and switch the PC's power switch leads.

[Image: OutletSwitchwithHighlights.jpg]

0. First off be careful. This device is designed to run on mains voltage. Mains voltage is dangerous. This process is designed to make it run on USB power, so you shouldn't ever need to have it plugged into mains. Also, there's no guarantee that the PCB in the device you buy is identical to the photo, but it should be similar enough that you can figure out how to make it work even if they're a bit different. I'm sorry that I didn't have the foresight to take photos as I was doing this originally, I hope my descriptions are clear enough to be useful.

0.1 Break all the dangly metal bits and the wires connected to them off of the PCB. These are used for the mains connections, which won't be needed any longer.

1. Desolder the 5V power regulator circled in red. It has three leads - 30V in, 5V out, and ground. Work out where the 5V and ground pins went on the PCB based on the regulator's data sheet or by using a multimeter. Sacrifice a USB cable and solder its 5V and ground leads into the appropriate holes where the regulator was mounted. Check with a multimeter that there are no shorts.

2. You can now test that things are working correctly by plugging the USB cable you just soldered onto the board into a USB port. Push the button on the PCB, you should see the LED on the PCB turn on and hear the relay click.

3. Desolder the relay circled in blue. The relay has five pins so this process is a little fiddly.

4. The green arrow points at an orange diode (I think). Figure out which thru hole on the PCB (where the relay used to be) connects to this diode. This is where the + lead on the power switch coming from the PC will attach.

5. Now you need to take a look inside your PC. There is a 2 pin header where the power switch attaches to the motherboard. Of these two pins, one is a positive and the other is ground. Check which is which with a multimeter. Connect a wire to the positive pin, run it out of the PC, and be ready to attach it to the thru hole on the PCB you located in Step 4.

6. Nearly there now. Now you can program the device to recognize an IR remote button. With the USB cable plugged into an AC USB adapter or a PC USB port, push the button on the PCB momentarily - the LED should turn on. Now hold the button until the LED starts to blink. Aim your remote at the PCB and push the desired button on the remote. The LED on the PCB should blink at a different rate and turn off. Now the LED should turn on and off when you hit the proper button on the remote.

7. Now solder the wire that attaches to the PC's power switch header to the thru hole you located in Step 4. Plug the USB cable into a socket on the PC.

8. Press the button on the remote that you programmed in Step 6. The device's LED should light up and the PC should power on. Press the remote button again, the device LED should turn off and the PC should stay on. (You need to push the remote button twice - once to emulate pressing the button, and once to emulate releasing it.)

9. All done now, at this point you can tidy up the wires and put the PCB back into the ugly original enclosure. Or find a nice new enclosure to mount it into.

I hope this description has been clear and that someone else can find this useful. Mine works like a charm. If there are any questions, please reply in the thread and let me know.

Viewing all articles
Browse latest Browse all 84005

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>