so i recently jumped into the wonderful world of micro controlers. iv built a few kit projects and got to thiunking about things i could make from scratch. my first "from scratch" project is an RFID deadbolt for my front door. Im using an Arduino Diecimila board. It has 14 digital IO pins (12 usable, 2 used for serial communication) and 6 analog inputs. iv already planed on using 6 of the digital IO pins. i have the 7th planned for using to control a servo. but i got to thinking, if i still want to use the physical key for the deadbolt then using a servo to control the locking and unlock of the deadbolt isnt really posable because if the servo has power you can free spin the servo. so i thought about using a stepper motor. so theres the background. here come the questions. will i face the same problem with the stepper motor? are stepper motors bi-directional? will i need a controller for the stepper motor or can i used the micro-controller for that directly? if i need a controller what kind of controller will i need to buy/build? thanks guys
Both servos and stepper motors can be made to hold in their position and resist movement. Stepper motors can rotate in both directions, and can easily be controlled from a microcontroller, however you'll most likely need 4 pins and possible some circuitry to provide some real current, steppers can easily consume > 2 amps. What type of deadbolt do you have in mind?
If it's just the deadbolt, why not use a solenoid instead? Or are you wanting to leave the original lock intact?
id like to leave the original lock intact. and solenoids are a little noisy if i remember correctly. since the door will be unlocked the majority of the time the last thing i want to listen to is a "bzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz" because the door isnt locked. If im wrong about the noise issue then id consider it but still gets in the way of keeping the lock intact
I havn't found any noise issues with solenoids? Thats what i'd go with for something like this anyway. Infact if I was pretty sure most servos keep position provided you don't just tell it to move to a position and power it off. What i'm saying here is avoid using steppers with all your life, they're god damn irritating to get working and will set your chips on fire with their current draw. If you're going with stepper, you'll need a bare minimum of 2 outputs to control a stepper bi-directionally and in the 2 output set up, you'll need one of the hundreds of possible stepper driver circuits/chips. Even then you have to make sure your data output is not skewed or the motor wont turn correctly. Also here is a pro-tip: Design it so that it's rest unpowered state = unlocked, or else your locked out when you lose power.
Another vote for servos. Because their control circuit is independent of their main power supply, chips with totally unremarkable power-handling capabilities can drive extremely powerful servos. Solenoids aren't a great idea, because they're really only intended to hold their active position for a few seconds at a time. This would mean you could only unlock (or lock) the door as needed, rather than continuously throughout the day.
well because you are using an arduino, there are many different shields available for them. This motor shield from Adafruit industries has all the circuitry to run stepper motors and servos. Sparkfun also sells some in their development/ arduino section.