I'm trying to teach myself stepper motor control and need some input. The TB6600 controller accepts a pulse stream as input while taking care of micro-stepping, current limiting, etc. I'm experimenting the different methods to generate the pulse stream from a Propeller activity board programming with BlocklyProp.
I started experimenting with a loop containing makepin blocks with pause statements to create a pulse stream. That was unsuccessful as the pause values are in milliseconds and the controller expects micro seconds.
I then experimented with a simple loop using pulse-out blocks to generate the pulse string. Using that approach, I can control the motor speed and direction and send a fixed number of steps to control the rotational position.
My next thought is to try the PWM blocks sending 50% duty cycle pulses.
Ultimately, what I want is a stepper motor control library that allows me to specify motor enable/disable, motor speed, motor direction, steps or displacement in degrees, and acceleration/deceleration. I've seen references to arduino based libraries with this functionality. Is there anything available for the Propeller? Is it worth it to convert the arduino library? Anyone got any better ideas for generating the pulse stream? Is there a better approach than using the TB6600?