Step motor not working! ESP8266, Curtain Project

joeltetava:
200 Steps working, 400 not.

Which is correct for the motor you are using?

Post a link to the motor's datasheet.

Perhaps you are storing the number of steps in a byte variable (which has a max value of 255) and if so you should use an int.

...R