PDA

View Full Version : Could really use some help on a project.



mkockx12
03-17-2010, 07:40 AM
Hello,

It's been a while since I've used this board and don't really want to learn it all over again. I need a program that, when a magnetic sensor is triggered, starts the program. This program will complete and stay dormant until the sensor is disconnected and then it will rerun the program when triggered again. The program needs to initiate a servo to go to a certain position, stop; turn a relay on for a given period of time, stop; return the servo to a home position. It would be nice if in the event the power is interrupted, the program will put the servo into the home position and check for the magnetic connection when power is restored. I would be eternally grateful if somebody is willing to work with me on this. I can do it through the forum or if you live in sac we could meet up to make things easier.

$WMc%
03-17-2010, 07:50 AM
mkockx12

How will the servos move to home if the power is lost?

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
The Truth is out there············___$WMc%___······················ ······ BoogerWoods, FL. USA

mkockx12
03-17-2010, 08:04 AM
I want it to return home as soon as it is plugged back in. That way the attachment to the servo is out of the way.

silverback
03-17-2010, 08:19 AM
Use a initiation sequence that checks and resets the servo to your home position before it starts looking for the sensor.

You might want to include, in the reset initialization sequence, something the makes sure that if the sensor is engaged at the time power is restored, it waits for the sensor be disconnected before it starts the routine again. That way you don't have to worry about it starting up·unattended (after a power up).

What kind of sensor are you going to use? A Reed switch or a Hall effect transistor?

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
If you convince yourself that something is impossible before you even try; you are sure to prove yourself right.

mkockx12
03-17-2010, 08:33 AM
I was thinking of a read switch unless somebody thinks that wouldn't work better