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.

TMS320F280025C: How to configure an encoder without index signal?

Part Number: TMS320F280025C
Other Parts Discussed in Thread: MOTORWARE

Hello, I use the TMS320F280025C development board. I enabled the ENC macro in the universal laboratory. My motor itself has an ABZ signal. Using the ENC encoder library that comes with the universal laboratory, I can drive the motor and enter a closed loop. Now, our The requirement is not to use the index signal of the motor. I browsed the encoder configuration code of General Laboratory, and it seems that encoders without index are not directly supported. Therefore, I have the following questions:

1. Is there a reference for the encoder configuration code that is suitable for 025C without index?

2. Is the initial calibration of the encoder with index signal different from that without index signal? In contrast, does an encoder without an index require forward and reverse rotation during initial calibration? Does calibration take longer than indexed encoder calibration?

3. Is there any calibration reference without index encoder? Please provide it.

  • Hi Luo,

    Can you expand on why you are required to not use the index signal?

    Is there a reference for the encoder configuration code that is suitable for 025C without index?

    It is possible to use the encoder without an index by simply configuring the eQEP position counter module maximum value to equal the number of notches on the encoder times the resolution of the QEP signals, and configuring the eQEP to reset on the maximum position. We do not have reference code for this.

    Is the initial calibration of the encoder with index signal different from that without index signal? In contrast, does an encoder without an index require forward and reverse rotation during initial calibration? Does calibration take longer than indexed encoder calibration?

    Yes, typically when you have the index signal, you can configure the eQEP to latch onto the first index pulse in which case you have synced your encoder to the eQEP module and the position of the encoder represents the deviation from this zero position. However, if you don't have the index pulse, you have nothing with which to reference other than the position of the encoder which it first starts rotating (which means it will not require any forward or reverse rotation to do any calibration). The position of the encoder should remain accurate though as long as there is no mechanical slippage. 

    Is there any calibration reference without index encoder? Please provide it.

    There is no reference

    Regards,

    Peter

  • Is there something similar to the SpinTAC position converter for the 025c? I didn't find it in generic lab, I need to know the location by enc

  • Hi Luo,

    Please allow me to refer to another expert on my team for this question to see if we have incorporated something similar into our newer devices

    Regards,

    Peter

  • I haven't heard from you for a long time

  • Hi Luo, 

    I was able to discuss this with another one of our experts. The SpinTAC software was not ported over to the 025c device or any of our current generation portfolio since SpinTAC is not owned by TI. That is only available on our older devices.

    As an alternative, the latest motor control SDK has our InstaSpin FOC, which may perform similar functions. I recommend you to look at the universal motor control project which has much information on this

    Regards,

    Peter

  • The purpose of using SpinTAC is because I need to get the position. Before, I could call the Pos_mrev multiplied by the perimeter through the SpinTAC component and add the current encoder position to easily get the current position of the motor. Now, in the general laboratory , I did not find a similar function, I can only check the overflow and underflow flags in the eqep module in the interrupt, record the addition and subtraction of the number of turns, and then calculate the final position by multiplying the circumference and adding the current motor position.

  • Hi Luo,

    Thanks for that information. Yes I think in the current version of the motor control lab, that is what is available to use as part of the software. We don't support this SpinTAC software or InstaSpin Motion on F280025C or devices after that, but it seems you may have further questions about the lab itself, allow me to pull in a different expert

    Regards,

    Peter

  • Hi Luo,

    I believe the older MotorWare example solutions are written to work without QEP index pulse, similar to what Peter has described with resetting on the MAX position count instead of using index pulse as a reference start point. However these are all for older Gen C2000 devices.

    You could adapt the Universal Motor Control Lab to not use index pulse too if you'd like. You need to re-write portions of the ENC_run() function routine in 'encoder.h' file.

    Best,

    Kevin

  • Yes, I performed manual alignment in the qep initialization. First, when the system is powered on, current will be injected into the D axis to make the α axis coincide with the D axis. Then, after letting it sit for a period of time, it will be used as the 0 point to control the motor to rotate forward. Half a turn and reverse half a turn, and then check whether the position read in the encoder is the reading when starting forward rotation. If so, it means the calibration is successful. I have successfully entered speed closed-loop control using this method.

  • Hi Luo,

    OK, you can use that method for calibration. Without the index pulse you may need to consider occasional re-calibration if the counting gets off while running.

    Best,

    Kevin

  • Hello, I would like to ask how to calibrate the encoder without index signal during operation?

  • Hi Luo,

    You mean without re-running the manual calibration routine you developed in your prior post? You want to be able to re-calibrate during run time?

    Best,

    Kevin

  • I still use manual calibration, but I feel that there will be a slight deviation after running for a period of time. I want to force calibration at runtime. Can I force the current position to return to 0 by setting the counter overflow flag?

  • Hi Luo,

    I want to force calibration at runtime. Can I force the current position to return to 0 by setting the counter overflow flag?

    By the above do you mean just resetting the QPOSCNT value to zero, or actually moving the motor back to the established "zero" position (where α axis coincide with the D axis)?

    One question I should have asked earlier, do you just need to perform speed control on the motor, or is position control required for your application as well?

    Best,

    Kevin

  • The pwm interrupt frequency of my motor is 20khz, I will handle ENC related issues at this frequency, so I can query whether the overflow or underflow flag is set at the frequency of 20khz, when an overflow occurs, I will the ENC angle at this time Forced to 0, the foc angle is also forced to 0. Do you think this is feasible?

    I ultimately need current loop control to use motors to simulate fitness products like dumbbells.

  • Hi Luo,

    when an overflow occurs, I will the ENC angle at this time Forced to 0, the foc angle is also forced to 0. Do you think this is feasible?

    I think that method will work OK, but you may just need to consider if the QEP QPOSCNT has counted between the overflow / underflow condition and your ISR code forcing the angle to zero. i.e. will there be any offset between those?

    Your product being for fitness dumbells, I assume the motor speed will remain fairly low. Is that right?

    Best,

    Kevin

  • I think that method will work OK, but you may just need to consider if the QEP QPOSCNT has counted between the overflow / underflow condition and your ISR code forcing the angle to zero. i.e. will there be any offset between those?

    I haven't tested this forced calibration method yet, but I think this is the best way when there is no Z signal.

    Your product being for fitness dumbells, I assume the motor speed will remain fairly low. Is that right?

    Yes, the speed is not too high

  • Hi Luo,

    It's been a little while.

    Do you have any further pending questions / issues on this topic? Were you able to test your force calibration method with your position sensor & eQEP module?

    Best,

    Kevin