Using Arduino digitalpin as a standalone switch

Hi,

I'm trying to use one of the Arduino I/O pins to function as a switch by itself... basically not have a push button or physical switch, but just sending HIGH/LOW signals to turn it on/off.

The thing is, this switch is meant to control a "power source". My current circuit diagram looks like this:

DC GND ---- - 17V DC Power Supply + ---- 10 kOhm Resistor ---- Double throw switch ---- DC GND

Basically the Double throw switch functions as an ON/OFF switch at the moment, and has to be manually "flipped". What I'm trying to do is to make it all "automated" by having it turn on/off after a certain period of time automatically instead of me flicking the switch.

What would be the best way to do this? I know i can't just plug a 17V DC terminal into an Arduino pin without frying my Arduino... I should probably use a transistor, but I'm not quite sure what kind and how to wire it up...

If anyone could help me with this, I'll be so grateful!

Cheers

Have a look at this Transistor as a Switch

peich:
What would be the best way to do this? I know i can't just plug a 17V DC terminal into an Arduino pin without frying my Arduino... I should probably use a transistor, but I'm not quite sure what kind and how to wire it up...

Common example http://www.ermicro.com/blog/wp-content/uploads/2008/12/trsw03.jpg

The transistor model depends on how much current needs the load, and must have a drain current compatible with Arduino pin level.

Thank you so much for the links guys! Really helped me out there!

peich:
What would be the best way to do this? I know i can't just plug a 17V DC terminal into an Arduino pin without frying my Arduino... I should probably use a transistor, but I'm not quite sure what kind and how to wire it up...

If anyone could help me with this, I'll be so grateful!

Google "resistor divider"