Driving a 12V door strike from 3V3 BeagleBone?

I'm trying to control a 12V electronic door strike lock from my 3V3 BeagleBone.

Here's a diagram of my circuit:

My circuit probably needs a NPN transisor of some sort, but I'm not sure which one would work. Also, because the strike lock is a solenoid, do I need any diodes/other protection in my circuit to prevent over-voltage/other bad things?

Thanks. Your help is much appreciated!

• I don't know what your power source for the Beaglebone is, but I'd probably use a separate supply for the solenoid. The BB has/needs information level power, not do-mechanical-things power. Why force that through it? Plus, you may be able to avoid needing the step up circuit. Nor does the solenoid need highly regulated power at a precise tolerance. Yes, a reverse connected protection diode across the solenoid to deal with the jolt when power is removed and its magnetic field collapses is always a Good Idea. (Better qualified persons will answer your which transistor question.) Jun 27, 2012 at 3:18
• Do you have 12V available? GPI01 via 1k resistor to transistor base. Emitter to ground. collector to strike terminal 1 (either). 12V+ to strike terminal 2. 1N400x diode across strike coil - Cathode = line side to =!2V. Transistor BC337-40. Many others work but if you have none that's as good as most. Available Digikey and w=elsewhere. Jun 27, 2012 at 4:56

The BC337-40 suggested by Russell is a good choice; it has a high $H_{FE}$, and can draw up to 500 mA.