control a stepper motor with rotary encodeer

The section headed "Protocol/Library Explantion" does not seem to be complete. For example I could not see an explanation for move().

I'm afraid I can't make sense of your code without complete documentation.

I'm not even sure exactly what you want to happen. For example should be motor move one step for every pulse from the encoder?

It would also be a BIG help if you use the AutoFormat tool to indent your code consistently - it makes it much easier to see what parts go together.

...R