-
Notifications
You must be signed in to change notification settings - Fork 10
Stepper Calibration
FireStep supports stepper calibration with commands that continuously exercise the stepper(s) using pulse trains that follow a smoothly accelerating PH5Curve. Since FireStep is pulsing smoothly, any roughness you hear or feel will be due to the stepper and/or stepper driver hardware.
IMPORTANT: Decouple your steppers from their drive belts when calibrating.
Stepper calibration ignores motion limits.
FPD | Comments |
---|---|
LooseCanon | Turn the tensioning gear to loosen the belt. Slip belt off the 16-tooth stepper drive gear |
TinWhiskers | Cut the cable tie that tightens the belt. Loosen the screw on the 16-tooth stepper drive gear and slip it off the stepper shaft. |
Other CNC | Consult your machine instructions |
Take advantage of your stepper driver microstep capability. Increase microsteps for smoothness at the cost of decreasing overall velocity. When in doubt, choose 16 microsteps, which is the recommended microstep value. If you need more accuracy, buy steppers with 400 steps per revolution.
Your steppers should be enabled and powered, which means they should not move when you try to turn them. If they rotate freely:
- Is your E-stop engaged by mistake?
- Is your motion board powered? (e.g., verify 12V at board)
- Is your motion board powering steppers? (e.g., verify EMC02 test point voltages)
If you have a supported stepper driver, set the initial VREF on your trimpot:
Driver | TrimPot | Comments |
---|---|---|
A4983 | 290-420mV | Optimal VREF differs with each stepper and/or driver |
A4988 | 290-420mV | Optimal VREF differs with each stepper and/or driver |
DRV8825 | 200-450mV | It's very difficult to tune low VREFS with the DRV8825 |
The EEPROM can contain arbitrary FireStep commands, which might cause your machine to behave in unexpected ways. We will start with an initial command sequence for your machine. This sequence sets the desired pin configuration and returns the FireStep version on system restart:
Board | EEPROM command |
---|---|
EMC02 | {"eep0":{"syspc":1,"sysv":""}} |
RAMPS1.4 | {"eep0":{"syspc":2,"sysv":""}} |
- Install FireStep
- Send the appropriate EEPROM command for your machine from the table above
- Restart your Arduino by closing/reopening the Serial Window
You should see something like this:
{"syspc":1,"sysv":1.12}
Verify that your steppers turn in the correct direction (clockwise advance) with the correct number of microsteps. The following command will continuously advance three steppers by a single revolution at a time away from home.
{"tstrv":[1,1,1]}
You will see/hear one of the following:
Stepper | Comments |
---|---|
Turns happily | Congratulations! |
Stepper beeps like a truck backing up | Stepper is choking on too much current and freezing in place. Each beep is a revolution attempt. |
Stepper turns quietly but skips | Stepper is starved for current |
Nothing happens | Stepper might be totally starved or you have wiring issues |
The tstrv command consults the current axis configuration for each mapped motor to determine the number of pulses to send. By default, it will send 3200 pulses (16 microsteps * 200 steps/revolution) for each revolution.
If your steppers don't move in the correct direction for the expected number of degrees, adjust your stepper wiring or stepper driver jumper configuration.
You can also change direction in FireStep.
Let's set the direction to go one way:
[{"xdh":false, "ydh":false, "zdh":false},{"tstrv":[1,1,1]}]
Or we can set the direction to go the other way:
[{"xdh":true, "ydh":true, "zdh":true},{"tstrv":[1,1,1]}]
If you decide to change the direction in FireStep, you will want to rewrite the EEPROM and save your configuration. There are eight possible combinations of direction. Choose the one that works.
Board | EEPROM command |
---|---|
EMC02 | {"eep0":[{"syspc":1}, {"xdh":false,"ydh":false,"zdh":false},{"sysv":""}]} |
EMC02 | {"eep0":[{"syspc":1}, {"xdh":false,"ydh":false,"zdh":true},{"sysv":""}]} |
EMC02 | {"eep0":[{"syspc":1}, {"xdh":false,"ydh":true,"zdh":false},{"sysv":""}]} |
EMC02 | {"eep0":[{"syspc":1}, {"xdh":false,"ydh":true,"zdh":true},{"sysv":""}]} |
EMC02 | {"eep0":[{"syspc":1}, {"xdh":true,"ydh":false,"zdh":false},{"sysv":""}]} |
EMC02 | {"eep0":[{"syspc":1}, {"xdh":true,"ydh":false,"zdh":true},{"sysv":""}]} |
EMC02 | {"eep0":[{"syspc":1}, {"xdh":true,"ydh":true,"zdh":false},{"sysv":""}]} |
EMC02 | {"eep0":[{"syspc":1}, {"xdh":true,"ydh":true,"zdh":true},{"sysv":""}]} |
RAMPS1_4 | {"eep0":[{"syspc":2}, {"xdh":false,"ydh":false,"zdh":false},{"sysv":""}]} |
RAMPS1_4 | {"eep0":[{"syspc":2}, {"xdh":false,"ydh":false,"zdh":true},{"sysv":""}]} |
RAMPS1_4 | {"eep0":[{"syspc":2}, {"xdh":false,"ydh":true,"zdh":false},{"sysv":""}]} |
RAMPS1_4 | {"eep0":[{"syspc":2}, {"xdh":false,"ydh":true,"zdh":true},{"sysv":""}]} |
RAMPS1_4 | {"eep0":[{"syspc":2}, {"xdh":true,"ydh":false,"zdh":false},{"sysv":""}]} |
RAMPS1_4 | {"eep0":[{"syspc":2}, {"xdh":true,"ydh":false,"zdh":true},{"sysv":""}]} |
RAMPS1_4 | {"eep0":[{"syspc":2}, {"xdh":true,"ydh":true,"zdh":false},{"sysv":""}]} |
RAMPS1_4 | {"eep0":[{"syspc":2}, {"xdh":true,"ydh":true,"zdh":true},{"sysv":""}]} |
Be sure to restart the Arduino and verify your EEPROM configuration using;
{"tstrv":[1,1,1]}
Most StepStick style stepper driver boards have trimpots that control drive current. Turning the trimpot clockwise generally increases the stepper current (CHECK YOUR STEPPER DRIVER DOCUMENTATION TO CONFIRM).
First DECREASE the trimpot current till each stepper stops moving:
{"tstph":""}
Then INCREASE the trimpot current till the each stepper moves continuously back and forth without jittering or losing steps. This is a low-velocity coarse adjustment.
As you adjust the trimpot, listen for a smooth sound
OPTIONAL: Make the test tougher by increasing stepper stroke duration/speed and repeat the above trimpot calibration. This is an extreme test, and you may even find that certain stepper/driver combinations work better than others. For ultimate performance, you may wish to replace steppers and or stepper drivers. Here is an example of such a test:
{"tstph":{"pu":32000,"mv":20000,"tv":0.35}}
If you are lucky, some of your steppers may spin accurately at 23kHz or higher (i.e., maximum velocity "mv":23000) with no load. However, most steppers seem to do fine with 20kHz. The default value for "mv" is an ultraconservative 12.8kHz, which should work for all steppers.
With the belts still disconnected, home the steppers. They will not stop until all three limit switches trip.
{"hom":""}
All steppers should turn counter-clockwise. If they don't, FirePick Delta will not be able to home.
Gently turn each of the delta arms so that the limit switches trip and stop the stepper. If the stepper keeps turning:
- Try using a credit card to trip the switch
- If the credit card works, the limit switch interruptor is not opaque or large enough. Use dark tape to fix this and continue.
- If the credit card does not work:
- verify limit switch connections and cabling
- verify connections
- verify cabling (manufacturers will sometimes send cabling with similar markings but different arrangements)
- replace the limit switch (first stop the homing operation by pressing ENTER to send an empty line to FireStep.)
Reconnect the pulley belts and tighten. Verify setup by homing or moving the effector.
For fastest speed, you'll want a LOWER current driver such as A4988. The DRV8825 drivers are very nice, but their trimpots are not designed for fine tuning lower currents. Typically driver currents are 0.5A-0.7A @12V for the fastest no-load revolutions.
Quite often you'll find that one of your steppers is rougher than the other two. If you have an extra stepper driver on hand, try swapping in the extra. Chances are it will run smoother.
Lastly, if you would like to experiment with higher voltages and currents, please do so and let us know how they work for you!
You can test each stepper in isolation by disabling the others. Here we disable Y and Z to test X in isolation:
{"yen":false,"zen":false}
If a stepper behaves differently in isolation than in combination
with the other steppers, then you've actually exceeded FireStep's
own capacity for your particular microcontroller. This can happen
with extremely high pulse rates (e.g., "mv":40000
). FireStep
on Arduino Mega2560 can reliably send 20-25kHz pulse trains
to 3 steppers simultaneously to drive a 400step/revolution stepper
using 16 microsteps. That's actually faster than most steppers
can move reliably under load.