Why a delay after digitalWrite(PUL,LOW) during stepper motor control?

When I comment out the delay, i.e.:

digitalWrite(PUL,HIGH); delayMicroseconds(374); digitalWrite(PUL,LOW); //delayMicroseconds(374);// Is the needed?, works fine without

The motor works just fine without it. (speeds up of course, but if I double the Write delay it goes back to its orginal speed as expected).

Is it really needed?

Thanks for your help.

Driver: DFRobot TB6600, https://www.dfrobot.com/product-1547.html Motor: https://www.omc-stepperonline.com/download/17HS15-1684S-HG100.pdf 4 wire bipolar

maxmach: When I comment out the delay, i.e.:

digitalWrite(PUL,HIGH); delayMicroseconds(374); digitalWrite(PUL,LOW); //delayMicroseconds(374);// Is the needed?, works fine without

The motor works just fine without it. (speeds up of course, but if I double the Write delay it goes back to its orginal speed as expected).

Is it really needed?

Thanks for your help.

Driver: DFRobot TB6600, https://www.dfrobot.com/product-1547.html Motor: https://www.omc-stepperonline.com/download/17HS15-1684S-HG100.pdf 4 wire bipolar

You have probably studied the data sheets longer than I did. Nowhere do I see the time parameter for the "pulse". So, I guess you may time it anyway you like, even with no program delay at all.

Paul

The digitalWrite() command is slow and a pair of them gives a pulse that is long enough for most stepper drivers. Have a look at this Simple Stepper Code. I hope the variable names are self-explanatory.

If you need more performance there is a digitalWriteFast library. With it you would need to create a interval for the pulse.

...R

Stepper Motor Basics

AccelStepper library