I've long lost track of how many failed attempts I've made to get this to work. Here's my successful EasyDriver wiring:
Here's some Python code that works for me.
Note: I had to install PWM -- see
# usage: sudo python this_file.py direction steps
More about the linear motor, see:
http://dicks-photon-arduino.blogspot.com/, post 46.
Not represented in the above code: I added a relay switch for the 5v power to the motor. Otherwise steppers draw current constantly (and the motor housing can get hot). Too bad that the EasyDriver doesn't work like the ULN2003 -- which allows you to turn the 4 motor leads off without an added switch. Re relays: I got 5 single-relay devices on the cheap from Amazon; they lack opto-isolation and have no mounting holes -- but cheap.