Hi,
I am using an 18F4431 with a QEI and an incremental encoder.
On it's own it works perfectly, and I use it for degrees so 0 to 359 then over to 0 again.
I've now added a second section for reading a GPS module, which also works ok, but when the QEI goes over 359, then it stalls the program.
Any ideas please?
Cheers, Camerart
Hi M,
The only CODE I copy is what is offered to me by forum members.
While I don't consider myself as a 'good' programmer, I do understand most of what I do, accepting that I forget some of it until dug out of my memeory again.
Over the years this has been developed, others have tidied it up for me, with Procedures, Functions and includes. In this case:
ADCON0
ADCON1
were in an include, which stopped the QEI working, but once returned to the main program it now works. I suspect timing or similar.
As for commercial use, I started this because I could't tell which way round my Tricoper was (even with coloured light) So it may be good in some ways
C