dsPIC30F QEI to determine PPR of encoder

Author
cjswish
New Member
  • Total Posts : 25
  • Reward points : 0
  • Joined: 2015/12/23 09:11:23
  • Location: 0
  • Status: offline
2016/01/05 16:13:37 (permalink)
0

dsPIC30F QEI to determine PPR of encoder

I am trying to implement an encoder counter that is capable of displaying the resolution of a quadrature encoder with index onto a 7-segment display. The encoders I will be testing will be up to 65,536 pulses per revolution. I would like to be able to read them at about 1500-2000rpm if possible, which would equate to about 2MHz. Is this doable with the QEI function of the dsPIC30F2010? Has anyone tried something similar?
#1

2 Replies Related Threads

    Mike017
    Super Member
    • Total Posts : 2698
    • Reward points : 0
    • Joined: 2007/08/25 08:11:31
    • Location: Lincoln, RI, USA
    • Status: offline
    Re: dsPIC30F QEI to determine PPR of encoder 2016/01/12 14:56:33 (permalink)
    3 (1)
    Hi,
    Skipping the display implementation for now....
    - For the PIC, choose an oscillator and find it's clock speed "tcy".
    - Calculate the pulse width and period of the encoder.
    - In the PIC data sheet, down at the bottom there will be the electric specification section that includes the minimum period acceptable for the QEI encoder input in terms of tcy. Allow some margin.
    - There will also be specs in the min/max of the input voltage from the encoder circuit.
    The encoders I will be testing will be up to 65,536 pulses per revolution.
    That's quick. Which encoder are you using?
     
    Good Luck,
    Mike
    post edited by Mike017 - 2016/01/12 14:58:28
    #2
    cjswish
    New Member
    • Total Posts : 25
    • Reward points : 0
    • Joined: 2015/12/23 09:11:23
    • Location: 0
    • Status: offline
    Re: dsPIC30F QEI to determine PPR of encoder 2016/01/12 15:18:34 (permalink)
    3 (1)
    Hello Mike,
    Thank you for the valuable info. I will take a further look at the datasheet and see if it looks feasible. I work for an encoder company and we are working on encoder capable of up to 65,536 ppr. That is why I am hoping to come up with a setup to verify we are not getting extra/losing pulses. I have scoured the web and found no bi-directional counters capable of measuring resolution at freq. I do hope I can get this to work.
    #3
    Jump to:
    © 2019 APG vNext Commercial Version 4.5