This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
I have a problem in the EQEP driver. EQEP is in Reset on Index Event mode (QEPCTL[PCRM]=00).
The encoder gives 1000 pulses. If I rotate it forward and backward around the index position, QPOSILAT will show 4 or 3995, not the correct vaule 0 or 3999. Then QEPSTS[PCEF] is set.
When i don't change the rotation, turns in the same direction, QPOSILAT value will be updated by Index 0 or 3999.
What do I wrong?
Hi Jan,
You did not comment on what device you are using.
Regardless, there is a device errata describing the problem that you are seeing. Please see the following advisory in your particular device's errata document:
eQEP: Position Counter Incorrectly Reset on Direction Change During Index
As described in the workarounds listed, and depending on the width of your index signal, it may be possible to use IEI to get around the issue.
For example, a good solution for the situation where the width of I is 1/4 the period of A may be the following: to set PCRM=2, IEI=2, and use the synchronization/qualification features inside the GPIO to delay I.
Thank you,
Brett