AnyCPU
http://anycpu.org/forum/

Switch on computer with microcontroller
http://anycpu.org/forum/viewtopic.php?f=3&t=344
Page 1 of 1

Author:  Kendall [ Tue Dec 20, 2016 7:18 am ]
Post subject:  Switch on computer with microcontroller

I'm making a simple microcontroller based circuit to turn on a computer when certain events are triggered. I am interfacing it using the PCs soft power switch pins on the front panel header:
Image
There are two relevant pins on this header, I'll call them SW+ and SW-. SW- shares the PCs system ground, though I'm not sure this is always the case. SW+ is, in my test system, 3.3v above ground, although I suspect this could be more or less.
In a typical computer, a NO momentary switch on the front panel shorts these two pins when the power button is pressed. I want this to instead be controlled based on a logic level signal from a microcontroller.
My first attempt at a test circuit is as follows:
Image
I tested the polarity of my header and made sure SW+ really was the positive pin. My microcontroller(datasheet) was powered from USB, therefore sharing system ground, so connecting SW- and controller ground was not a problem.
The circuit worked as intended, but it's obviously not very great. I want to make this circuit as universal (not system dependent) as possible. This poses the following problems:

The polarity is not indicated - the user can not be relied on to insure a specific polarity.
The voltage is not exactly known - it's better to assume it will be somewhere between 2-12v.
The controller should be isolated - it might share the computer's ground, but this is not guaranteed.

The simplest solution that comes to mind is using a relay. I may end up doing this, but I really would like to avoid it due to reliability, size and price.
Is there any transistor based solution (essentially like a relay) meeting the criteria above?

Author:  Garth [ Tue Dec 20, 2016 10:07 am ]
Post subject:  Re: Switch on computer with microcontroller

What are the requirements for the computer you want to turn on? For example, will SW+ come down low enough with that 1K resistor in there? How much current does it need to get down to the required low voltage state, and what is that voltage? If you plug it in backwards, would it do anything more than just turn on the computer when you first try it out, before the transistor turns on?

Author:  robfinch [ Tue Dec 20, 2016 10:47 am ]
Post subject:  Re: Switch on computer with microcontroller

Welcome here.
Could you use a FET transistor rather than a bipolar ? Another thought is opto-isolators.

Author:  BigEd [ Tue Dec 20, 2016 1:39 pm ]
Post subject:  Re: Switch on computer with microcontroller

Welcome! There's some relevant info here:
http://electronics.stackexchange.com/a/97308

I think I'd go for a FET (or maybe even a pair of FETs if the ones you pick are not symmetrical) - but a relay would be a sure-fire way to do it. Or a a solid state relay, perhaps, like this:
http://docs-europe.electrocomponents.co ... 4ae593.pdf

Page 1 of 1 All times are UTC
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/