Generating 800Hz square wave with Maestro 12

I’m trying to spin a stepper at 240rpm with a Maestro 12 and A4988 stepper driver and a 200steps/rev motor. This is for a clock motor, so I need decent accuracy.

So, 240rpm = 4rps, and with a 200step/rev motor needs a pulse frequency of 800Hz. Unfortunately, the PWM output of the Micro 12 only goes down to 2.9KHz, and the max servo pulse frequency is 333Hz, so I’m stuck in the middle.

With the scripting language I can only specify a delay in milliseconds, but each pulse width needs to be 0.625ms so I’d need much better resolution.

Is there a way of using delay command in microseconds, or of slowing the PWM down to 800Hz?

I’m trying to generate an 800Hz square wave to control a 200step stepper at 240rpm for a clock project.

My problem is I just found out the PWM output on the Maestro 12 only goes as low as 2.9kHz, and the servo outputs only go as high as 333Hz. Furthermore, the delay function in the scripting language is only in milliseconds, and I will need around half a millisecond timing.

Is there a way to do microsecond commands on a Maestro?

Sorry for the duplicate post, the moderators moved the additional post that I had put in the motor controller forum into this one, which makes more sense.

Anyway, I think the problem is solved after discussing with someone else. By using the microstepping function of the stepper motor driver I should be able to bring my pulse rate into the range of the minimum PWM pulse frequency.

If that fails, it sounds like I should be able to achieve the same think using a P-Star and some minor programming. This is also a cheaper solution, the Maestro was a little overkill but the GUI was a nice perk.


Unfortunately, there is no command for the Maestro to delay in microseconds, but I am glad that you were able to find a few possible solutions; thank you for letting us know what they are.

By the way, your clock project sounds really cool. If you feel like sharing it when you are finished, it would be nice to see how it turns out. Good luck!

- Amanda