Build Your Own Arcade Controls Forum

Main => Main Forum => Topic started by: brock.sampson on February 25, 2008, 11:01:34 pm

Title: Single Power Switch - Solved
Post by: brock.sampson on February 25, 2008, 11:01:34 pm
I know this has been discussed several times but I can't find exactly what I'm looking for.  I'm building a cabinet for my friend and I want to have a single button to power everything up and everything turn off when the computer shuts down.  I'll most likely buy a smart strip or hack a power strip with a relay.  The problem I have is the tv I'm using doesn't remember the power state so it needs to be turned on independently.  I will not be cracking the tv open and soldering directly to the board I don't feel comfortable doing that so that is off the table.  In my current setup I bought a cheapo universal remote and wired a momentary switch to the power button so I can turn it off and on easily without having to use an external remote.  I'm trying to figure out a way to power up the tv when the smart strip kicks in.  I have another cheapo remote that I was going to hack but I'm open to any ideas.  I'm not real familiar with building circuits, using relays, etc but this may be a good opportunity to learn.  I have been doing some reading about winlirc and serial ir blasters that seem like a good possibility.  Is there another kind of relay switch I can hang off the pc power supply to act as a momentary switch to power up the tv?  I was thinking about having the tv drive the smart strip which would work fine for powering up but when you turn the monitor the power is cut to the pc and hard shutdowns like that will eventually corrupt your file system.  I don't know if I could make a lpt cable fire a switch for the tv?  I have read quite a few posts about people controlling motors for rotating monitor setups that way.  I'm open to pretty much any idea short of opening up the case on the tv.
Title: Re: Single Power Switch
Post by: Neverending Project on February 26, 2008, 01:57:25 am
Some people have gone hack-style on their tvs, and simply used something to jam the power button in an always-depressed state. When the tv gets power, the on button is pressed, and hence turns on.

It would be easy to test... hold the power button in while you turn the power strip off then on.
Title: Re: Single Power Switch
Post by: Green Giant on February 26, 2008, 04:11:31 pm
Some people have gone hack-style on their tvs, and simply used something to jam the power button in an always-depressed state. When the tv gets power, the on button is pressed, and hence turns on.

It would be easy to test... hold the power button in while you turn the power strip off then on.


Outside of the above idea, you will not have an all in one solution with a remote.  Mainly cause pressing a remote control power button is not alway perfect, unless you can wire up something to hold it down for a predetermined amount of time and power the remote with a DC converter. 

On my cab I have two switches, one powers the tv and the other the computer.  Even though this is for a friend and you want it really easy, I think a 3 year old could figure out to press two buttons to power up.
Title: Re: Single Power Switch
Post by: brock.sampson on February 26, 2008, 07:59:07 pm
I tested holding the power button in while plugging and unplugging which works but it displays some message about losing power and the clock might not be set correctly.  Any other ideas for trying to hit that remote control button?  :dunno
Title: Re: Single Power Switch
Post by: brock.sampson on February 29, 2008, 12:27:03 am
I think I got something automated working for powering on the tv when the computer powers up.  I was looking at this post (http://forum.arcadecontrols.com/index.php?topic=72638.0) by Koz319 trying to get some inspiration on using the lpt port to trip the switch on my hacked remote.  I stopped by the shack and picked up a 25 pin male connector and soldered a wire to pin 2 and one to pin 25.  Temporarily connected those leads to the wires coming from my hacked remote.  Using his rotate command I could turn on the tv but it wouldn't turn it back off.  I noticed during several reboots that on boot the bios polls the lpt port turning the tv on.  When windows started it would poll the device again and turn it off and then back on.  I was close at this point.  I disabled the lpt port in windows and shutdown.  When I start up the computer the tv turns on and since its disabled windows doesn't poll it again when it starts.  Using this (http://support.microsoft.com/kb/311272) little program from Microsoft you can enable and disable devices from the command line.  When I enable the lpt port from the command line the tv shuts off.  When I disable it again tv remains off.  I just need to make a little batch file to enable and disable the lpt port and run it when the computer is shutting down.  Viola single button start for tv that doesn't remember it's power state and I only had to sacrifice a $5 remote and a $3 parallel connector.  Sorry this is getting long winded but it's late and I'm pumped I got this to work without blowing anything up.

:woot
Title: Re: Single Power Switch
Post by: BASS! on February 29, 2008, 12:38:58 am
Im proud of you for this, now what you need to do is post your batch file and some pictures so we can see your work :cheers:
Title: Re: Single Power Switch - Solved
Post by: brock.sampson on February 29, 2008, 09:08:34 am
I don't have any pictures yet, I need to clean up my work a little bit first ;).  Batch file is really simple

C:\DEVCON\I386\DEVCON.EXE ENABLE ACPI\PNP0401
C:\DEVCON\I386\DEVCON.EXE DISABLE ACPI\PNP0401

The device number may vary from computer to computer.  Go to device manager right click lpt port and go to properties and the details tab it will give you the correct device number to use.  If you are using 2000 or XP you can add a shutdown script to run this batch file everytime windows shuts down cleanly.  Run gpedit.msc, go to Windows Settings, Scripts, Shutdown and add your batch file.  I'll try and add some pics over the weekend.