Hi I want to draw graphs of position of 2-phased QEI versus time. so I want to capture QEI position every time period. time gap between to position pulses is at least 7.2 microseconds. I think I have to choose one of these methods:
1-send position to USB during time overflow interrupt(TIM_INT)
2-send content of the timer when the situation changes. (I don't know if it is possible to sense the changes as an interrupt?)
I think there are some restrictions due to interrupt latancy. so what is the highest resolution for my system. and which method is better? How can I define interrupt for 2nd method? can i send data to buffer and send batch buffer to USB? Is it help me Reduce interrupt latancy effects? HOW? Please Help me Best Regards
>The time constant of the passive input RC (LC) filter is determined by the PCLK frequency of QEI. It's much less than (1/8 - 1/16) of PCLK
So, if i want to filter pulses less than 2us, what should i write?(clk=100mhz) LPC_QEI->FILTER =0xc8; /*200*/ Is it correct?
>When the buffer holds 512 bytes (sector size) or more, one sector of data is written to the USB drive.
Oh, I am a beginner! I don't know how to access to the buffer. How can i get access to this Buffer? what should i write instead of *UserBuffer=LPC_QEI->QEITIME; ?? can you help me with the codes? thanks