Control Stepper Motor By Time

Hi All,

I am looking to control a stepper motor by time, so it turns 120 degrees every 6 hours. Is this possible?

I am new to Arduino and coding so I thought I would seek some help!

Thanks!

Andy

Yes / No / Maybe

The timing is no problem.

But most stepper motors do 200 steps per revolution which means they can turn 118.8 deg or 120.6 degrees, but not exactly 120 deg.

If you can live with that then 67 steps in 6x60x60 = 21600 seconds would require 1 step every 322.389 seconds (Please check my maths).

One thing to keep in mind is that an Arduino is not good at keeping time over a long period. You may need to use Real Time Clock (RTC) module if you want to keep to clock time.

Another thing to keep in mind is that stepper motors are very inefficient. They need full power even when stationary.

...R
Stepper Motor Basics
Simple Stepper Code

Hi Robin,

Basically I am trying to make a trivision display, so it could potentially work with 120.6 deg.

If I was to use a RTC module, would this need seperate code to the stepper motor?

Thanks!

Studiomakebelieve:
If I was to use a RTC module, would this need seperate code to the stepper motor?

I don't know what was in your mind when you wrote that. A house has doors and beds. They are very different but they are both parts of the house.

Similarly the code for the RTC will be different from the stepper code but both will need to be part of your program.

For the purposes of learning it is a good idea to keep the tasks separate - i.e. make a short stepper program and a separate short RTC program. When you know how to make both work you can merge them. Have a look at Planning and Implementing a Program

...R