SparkFun Forums 

Where electronics enthusiasts find answers.

Have questions about a SparkFun product or board? This is the place to be.
By randcv
#170592
I'm trying to build a MIDI controlled stepper which will spin at frequencies sent over a MIDI channel, e.g. so I can play the Mario theme song on the motor. I just bought the BigEasyDriver and this stepper motor (https://www.sparkfun.com/products/10846), and I'm having some trouble getting the motor to spin at certain speeds. Notes between C5 (~523 steps/seconds) and D6 (~1174 steps/second) seem to work just fine, and I can accelerate the motor into even higher speeds, but I cannot get the motor to run at low speeds. Below ~500 steps/second, the motor just buzzes and twitches, and when it sometimes does catch the rotation direction is random.

Power is supplied by a 12V@2A wall wart that I had laying around. I'm controlling everything with a Teensy 3.1 that is emulating a USB MIDI device, and I have my code on Github here https://github.com/randvoorhies/midimotor. I have played around with the current control pot, but it hasn't helped.

Here's a video I just recorded of the problem: https://www.youtube.com/watch?v=qb8tLPygMF0

Has anyone else had this kind of issue?
User avatar
By TS-John
#170638
Hello.

One of our engineers actually created example code for the Autodriver that is very similar to what you are trying to do with the BigEasyDriver:
https://learn.sparkfun.com/tutorials/ge ... driver/all

He notes on the example section in the code: "In a more general sense, it adds support for playing music with stepper motors. Not all notes can be played, of course- at too high a steps/sec rate, the motors will slip and dogs and cats will live together."

I am certain the said can be said about notes that are too low.

Perhaps the example code can give you a better idea on how you might be able to get everything working.

-John-
By lyndon
#170670
My guess (and it's a guess since I have never used the BED) is that you're running into a resonance state with the motor at that speed. Try adding a small mass (or removing some if it's already there) to the motor shaft and see if that makes a difference. Alternately, a different supply voltage to the motor may help.
By randcv
#170702
Thanks for the replies, guys. I'm actually unable to step the motor at even 1 step per second. I've tried adding and removing mass from the shaft, but it hasn't helped - I guess I didn't really expect it to at 1 step/second. Someone at the product comments section mentioned that they had the same issue with one of their boards, but another worked just fine: https://www.sparkfun.com/products/11876 ... 1b668b456a

I'll contact tech support and see if they can send me another one.