Hi all,
I am making a trolly which is moved along a track with a belt. I made an opto encoder with a metal disk and the components from a ball mouse.
I read the other thread on opto encoders and have it working great when using it alone in itīs own little loop. The problem is I need to do many other things in the mean time.
The encoder is only 10 pulses per revolution and my motor at max goes at 10 RPM (it has a gearbox)
I am trying to use Darrel Taylors great instant interrupts with my 16F877A. I have used them successfully many times but I am definately doing something wrong this time.
It works only at very low speed (ie 10Hz) at 50Hz it just show A and B being permanently on.
Can anyone guide me to what my error is. I have attached both my codes in txt format, the working one without INTs and the INT one that does funny things?
Regards
Chris
Bookmarks