Here we also need to mention that these 2 pins are not pulled to any voltage internally, so we should not leave them floating in our program. So that means that we don’t need any complex programming, phase sequence tables, frequency control lines and so on, because the built-in translator of the A4988 Driver takes care of everything. With the Step pin we control the mirosteps of the motor and with each pulse sent to this pin the motor moves one step.
The Direction pin controls the rotation direction of the motor and we need to connect it to one of the digital pins on our microcontroller, or in our case I will connect it to the pin number 4 of my Arduino Board.
The next two 2 pins, Step and Direction are the pins that we actually use for controlling the motor movements.