# Automatic Timed Polarity Switch and Shutoff

#### Josh Kompa

Joined Mar 24, 2015
3
First off thank you to anyone who is able to point me in the right direction. I am a mechanical guy and have confused myself trying to dig into circuit development.

I am looking to keep the circuit as simple as possible. I will be powering system using a wall adapter for 110V AC however I have found wall adapters to convert this to 6V DC for me which I will use in order to simplify my circuit unless someone lets me know a reason not to. The 6V DC is what is specified for the two components I am trying to run, a Micro Stepper Motor and a UV Light.

My system needs are as follows:
- External Contact Switch
- Used to connect the system (like a button to turn on)
- this contact will be separated and reapplied manually to start cycle again when need be
- System needs to run for 60 seconds and then turn off automatically
- Micro Stepper Motor (specs 6V DC and 200mA (assuming this is start-up amps) down to 20mA (assuming this is continuous running amps)
- Run oscillating while system is on as stated by the external contact switch above (60 seconds)
- approximately 6 seconds forward followed by 6 seconds reverse
- exact time isn't necessary but looking to have approximately 5 full cycles for the 60 seconds run time
- UV Light (specs indicate 6V DC and 6mA)
- Run continuously while system is is on as started by the external contact switch above (60 seconds)​

I believe I am going to need a 555 timer, possibly 2. One to control the total time till shutoff and one to control the time to polarity switch on the motor which I also believe would require an H-bridge to switch the polarity. All of the samples I have seen show additional resistors, etc. which I am uncertain what are for and seem to be over complicating the circuit, so that probably just shows how clueless I am. Also I am thinking that polarity switch for the motor may negatively affect the light so does that mean I need another switch for polarity at the light?

Comments to point me in the right direction or a sample circuit diagram would be greatly appreciated.

Thanks again.

Joined Jan 15, 2015
5,719
Would this be a 4 wire stepper motor and do you have a link to the stepper motor data sheet?

The reason I ask is before you start buying parts and soldering components there may be some very easy ways to go about this using an Arduino (or like similar) micro-controller and some easy code samples. An Arduino Uno for example runs about $26 USD and a motor shield (if its even needed) is about$15 USD.

Ron

#### Josh Kompa

Joined Mar 24, 2015
3

Joined Jan 15, 2015
5,719
High Quality 3v 6v 9v 12mm micro metal dc gear motor for electric door lock. The motor you linked to is not a stepper motor, it looks to be a plain everyday two wire DC gear motor, not a Micro Stepper Motor. For direction reversal I would just use a basic H Bridge module. Start with a H Bridge chip like this one . Then to keep things small the timing and control could be done using a small 4 pin uC (Micro-Controller) if you have someone who could write your programming code. Regardless I don't see the motor you linked to as a stepper motor so if you require a stepper motor I don't believe that is it.

Ron

#### Josh Kompa

Joined Mar 24, 2015
3
Ron, you are correct this is just a DC gear motor. Sorry about the confusion, I was looking at stepper but not necessary for my project.

I am not familiar with the micro-controller. I am assuming this could handle the 2 timed switches, first to switch direction through the H-bridge and second to ultimately shut off the system? Would I need 2 H-bridges in order to allow for direction reversal of the motor but keeping proper polarity on the light?