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.
Tool/software: Code Composer Studio
hello,
I am currently working on lab 13b. after positition control application is there any way to access the encoder counts that my encoder made?
safwat
Read the QEP position counter register (QPOSCNT) as the HAL_getQepPosnCounts() function which returns the counts you want.
hello,
Thanks for the reply. I checked the QPOSCNT register. it is counting upto 4096 for 1 revolution and then restarting the count. is there any way to know how many times the counter is going from 0 to 4096. for example if motors position control is set to 5 revolutions then the counter would go from 0 to 4096 five times so that i can multiply 4096 x 5 to get the overall pulse edge count. is there any way to know that?
safwat
No such register to count the coming times of index from encoder, you have to write a function to count the rotation times of the motor by yourself.