control dc motor position

Please post the complete program. Problems are usually in the other part.

...R