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.

RM57L843: eQEP module

Part Number: RM57L843

Hi All,

I need help in eQEP module in RM57L843 device.

I am operating QEP in quadrature mode,given the signals to QEPA and QEPB.

Input freq is varied from 0.5Hz to 35Khz. For testing purpose I am giving the input signal of frequency 1.350 Khz.

My final requirements are:

1.Need to find the time taken to complete one rotation.For one rotation there are 60 teeth or pulses.

2..If any of the inputs QEPA or QEPB is disconnected or removed I should display fault on serial terminal.

3.If both the inputs QEPA/B are removed I should detect the loss of input and display the time taken to detect this loss.

4.If QEPA and QEPB are interchanged which means motor direction is reversed,in this case also need to find the time taken to complete one rotation.

From the final requirements I could able to do are 1 and 3 points.

I need suggestion or inputs to solve the  points 2 and 4.

 

Thanking you.

With regards,

Praveen Palaparthi

  • Hello Praveen,

    Praveen P said:
    2..If any of the inputs QEPA or QEPB is disconnected or removed I should display fault on serial terminal.

    If you make use of the eQEP watch dog, it will monitor for any absence or failure in the generation of the QCLK signal which is derived from the rising edges eQEPA and eQEPB. The absence of either will result in missing pulses in the QCLK signal.

    Praveen P said:
    4.If QEPA and QEPB are interchanged which means motor direction is reversed,in this case also need to find the time taken to complete one rotation.

    QEPA and QEPB signals are arbitrary to the MCU but would need to be calibrated on start up in order to identify the initial direction and if QEPA and QEPB connections are swapped. If it is discovered that QEPA and QEPB are swapped, it is possible to logically swap them back using the QDECCTL register. Regardless if the inputs are swapped, similar methodologies for calculating index pulses and or capturing index pulses to count revolutions is still possible.