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.

CCS/DRV8312: Problem in running in lab12-a in instaspin motion

Part Number: DRV8312


Tool/software: Code Composer Studio

Hello, 

I am trying to run the lab12-a, I have online recalibration of Rs value but later on, my motor is not running. I have tried to check the problem of encoder but encoder runs fine. The other problem which I notice is, gMotorVars.SpinTAC.VelIdRun” should be set to 1. But when I run the lab, this value automatically goes to zero.  Can u eloborate how to work on this problem.  

  • 1. Please use lab02b or lab02c to identify motor parameters and set the identified parameters in user.h for lab12a.
    2. Please check the connection of encoder and its lines in user.h again.
    3. Check gMotorVars.SpinTAC.VelIdErrorID and gMotorVars.SpinTAC.PosConvErrorID in the watch window as the lab guide, and follow the error ID code to solve the question. You might find the information about error ID in instaSPIN User's guide(SPRUHJ1G).
  • Hello Luo,

    1. I have identified parameters, that's not an issue.
    2. I always get error 2004, the motor doesn't start to rotate . This means according to guide that I don't have enough torque. They refer to change the OutPos parameter. I am not able to find where exactly the parameter is.
    3. I have tried running with different speeds and different gMotorVars.SpinTAC.VelIdTorqueRampTime_sec time steps, after all these I still don't get the motor to be running.
  • Please try lab05c to see if the inertia can be identified well. If yes, that means the encoder setting is not correct. if no, you have to tune the configuration parameters for spinTAC per the running state.

  • Can you elobarate what exactly what exactly you mean by the encoder settings here, I was able to find the inertia and the friction values in lab 5C. Can u also suggest me how to check for the encoder settings.
  • 1. The physical connections of motor and encoder wires and the order are correct. You might try to change the order of motor wires if the motor can't run well.
    2. The number of the encoder lines is correctly set in user.h.
  • Hello Yanming, 

    I have check the connections of both motor and encoder, they are correct. But the motor doesn't run yet. I don't really understand what's the problem. 

  • Hello Yanming,


    I have disabled the force angle in the expressions, this made my lab 12b and 12a running. The motor vibrates a lot when I disable the Forceangle, I have a couple of questions, they are:

    1. Disabling Forceangle mean that I am still running with the estimator rather than the encoder?
    2. When my board identifies the parameters in 12a, they are different from the intially identified parameters can you explain why?
  • 1. Force angle is only for starting with low speed, lab12a or lab12b use the angle from the encoder, not from the estimator. As mentioned above, you need to check the setting again if the lab05 worked well, but the lab12a can't work.
    2. As replied to question 1, please confirm if the lab12a work well. And please have a detailed description of this question, what identified parameters are diffence? What do you mean the initially identified parameters?