teemuatlut / TMC2130Stepper

Arduino library for Trinamic TMC2130 Stepper driver
MIT License
159 stars 50 forks source link

TMC2130 with Accelstepper Library #33

Closed FlowBo closed 6 years ago

FlowBo commented 6 years ago

I'm trying to run a Stepper with TMC2130 in combination with the AccelStepper Library. The Stepper is making the correct sound (i can hear the acceleration and velocity etc) but the shaft is not turning. If I step it manually with digitalWrite() HIGH - LOW it is moving.

teemuatlut commented 6 years ago

Try using some simple example from the AccelStepper library and add the TMC2130 configuration parameters into that. As long as the driver has been configured and gets step pulses and enable is low the motor should move.

FlowBo commented 6 years ago

Hej i figured it out. Kinda my mistake. I forgot to set the micro stepping parameter. So it operated correctly but it had no information about stepping. Isn't it possible to have a default setting to prevent this from happening?

teemuatlut commented 6 years ago

The default is 0, which means 256 microsteps.

danielawd commented 6 years ago

@FlowBo I understand you got Accelstepper to work with 2130? Would you share some code, i am about to try it... Did you got it working in SPI mode and with multiple steppers?

Thanks Daniel