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.

Instaspin BLDC Motor Control in 28035 device using BUILD LEVEL 2

Other Parts Discussed in Thread: DRV8301, CONTROLSUITE, INSTASPIN-BLDC

I'm using the 28035 device to implement the Instaspin sensorless motor control for a  BLDC motor.

I am using Level 2 system build diagram based on the InstaSPIN-BLDC Sensorless Control.PDF doc under C:\TI\controlSUITE\development_kits\DRV830x-HC-C2-KIT_v103\InstaSPIN_BLDC\~Doc, and i am not able to run the motor at build level 2.

Please clarify below points-:

1. In document it is written that 

"If the open loop commutation parameters are chosen properly then the motor will gradually speed up and finally run at a constant speed in open loop commutation mode."

what are these commutation parameters and how to choose them?

2. " At BUILD LEVEL 2, back emf  is not sensed at all, and any BLDC motor can be run,  to a constant speed ( No load ) with proper selection of commutation parameter." 

    Is above statement is correct?

                                                                                                                     OR

   Is it possible to run any BLDC motor without any feedback (no hall sensor, no back emf ), just to test is motor is fine or not?  

3. what is the way find out the values of DfuncStartup and CmtnPeriodTarget , to run different - different BLDC motor.


Note -: I am trying with BLDC motor used in our application.

regards

vinod

  • vinod,

    1.  the parameters you can change in Build 2 are

    RampDelay (Q0 format): for changing the ramping time.
    CmtnPeriodTarget (Q0 format): for changing the targeted commutation interval.
    CmtnPeriodSetpt (Q0 format): for changing the initial startup commutation interval.
    DfuncStartup: for changing the PWM duty cycle in per-unit.

    2. You are correct that in Build Level 2 you are running open loop w/o any motor feedback. I wouldn't say ANY motor, but many can. Where you will have issues is with lower inductance motors that have a large di/dt (current spikes).  Using a slow ramp is the best way to handle these but even then they won't always spin in open loop.

    3. It is really trial and error. In build 2 you are just trying to verify general open loop operation of the motor and that all of the blocks feeding the PWM controller are working correctly.  You want to set a general speed target (I keep it under 50%) and in general ramp slowly to avoid over current situations.

     

    if you are looking for even more automated capability I highly recommend you look at IntaSPIN-FOC or InstaSPIN-MOTION.  You can order TMDSCNCD28069MISO controlCARD and use with your same DRV8301 board.  It will automatically identiry al needed motor parameters and give you a tuned and stable commutation and torque controller for your motor.

     

     

  • Hi chris,

    Thanks for clarifications!

    At above point 2 , as you said " not any motor , but many can", i would like to know

     If i provide feedback from hall senosor or backemf at starting (till motor ramp up and reached set point rpm), at this point pwm's has attained some xyz values, then can i remove feedback?

    Will motor run (No load ) at constant speed, without feedback, just using PWM controller only ? If yes then what about commutation time interval.

     

    also please calrify-:

    1. Can Insta Spin GUI help me to find out commutation parmeter for my motor?

    2. I am able run BLDC motor with Insta Spin GUI in duty cycle, velocity, current mode, but i am not able to run from code at any BUILD LEVEL, can you suggest what could be the problem?

     

    regards

    vinod

    Mob-: +919899595954

  • In build 2 you can't provide additional feedback. Move on to the next builds and you will then see that the Bemf is sampled and used for the commutation.

    1. Yes, the GUI is very useful for helping you find the Threshold Bemf Voltage used for the commutation trigger. And apparently you used it to also tune the current and velocity controllers. Very good!

    2.  You should be able to move ahead in the build levels and use the values you got from the GUI directly in the CCS code.

     

  • Hi chris,  I am able to run the motor in open loop mode with some jerk/vibration at BUILD LEVEL2. 

    I took the commutation parameter from INSTA SPIN GUI code in debug mode.

    Now i will  move on to further build level, before that  please tell me how base frequency is selected in code 

    #define BASE_FREQ       200           // Base electrical frequency (Hz)

    regards

    vinod

  • Choose a value slightly larger than your maximum speed, where BASE_FREQ = RPM_MAX * POLES / 120

     

  • Hi chris,

    I am working at build level 5 now, please tell where is function defination of " InstaSPIN_BLDC" . I am able to find out only this

    void InstaSPIN_BLDC(H_INSTASPIN_BLDC i);

    I want to know  how " Comm_trig " and " V_int " and other o/p are updating in this function?

    regards

    vinod

  • Unfortunately the InsaSPIN-BLDC library is not well documented like it should be (and like we do for all the other motor control libraries).

    you can look at

    C:\ti\controlSUITE\libs\app_libs\motor_control\libs\InstaSPIN-BLDC\v100\include\InstaSPIN_BLDC_Lib.h

    and see the inputs/outputs to the module

    {
     int32  Vag;    // Internal: Vag input -- contains real Va + VaOffset --> referenced to ground (_iq)
     int32  Vbg;    // Internal: Vbg input -- contains real Vb + VbOffset --> referenced to ground (_iq)
     int32  Vcg;    // Internal: Vcg input -- contains real Vc + VcOffset --> referenced to ground (_iq)
     int32  Van;    // Internal: Va to neutral (_iq)
     int32  Vbn;    // Internal: Vb to neutral (_iq)
     int32  Vcn;    // Internal: Vc to neutral (_iq)
     int32  VaOffset;   // VaOffset (_iq)
     int32  VbOffset;   // VbOffset (_iq)
     int32  VcOffset;   // VcOffset (_iq)
     int32  Int_Threshold;  // Input: Integration threshold where a commutate happens (_iq)
     Eintbool Vint_lockout;  // Internal: Flyback voltage lockout flag
     int32  *Vphase;   // Internal: Pointer to the Phase voltage to count (_iq)
     int32  V_int;    // Output: Integrator (_iq)
     Eintbool Comm_Trig;   // Output:  Commutation trigger impulse  
     Uint16  State;     // Input: Values 0 to 5
    } INSTASPIN_BLDC;

     

  • Hi chris,

    Function i/p and o/p are OK. But i would like to know how i/p are processed and converted in to o/p.

    what is the logic to calculate Comm_Trig, V_int.

    regards

    vinod

  • Vinod,

    Have you reviewed any of the InstaSPIN-BLDC videos or worked through the Lab write-up?

    These will help you understand V_int (threshold voltage). This is the value you "tune" to match the value of the Bemf samples that are being integrated. When this value is reached a commutation trigger (Comm_Trig) output is created.

     

  • Hi chris,

    I want to know where all this is happening in software , in which function. Where we are integrating back emf sample and comparing with V_int in code.

    From code at level 5, below are some lines that show input to InstaSPIN_BLDC function.


    // ------------------------------------------------------------------------------
    // Connect inputs of the INSTASPIN_BLDC module and call the INSTASPIN_BLDC function.
    // ------------------------------------------------------------------------------
    InstaSPIN_BLDC1.Vag = iqVaIn - InstaSPIN_BLDC1.VaOffset; // Adjust for offset of Va_in
    InstaSPIN_BLDC1.Vbg = iqVbIn - InstaSPIN_BLDC1.VbOffset; // Adjust for offset of Vb_in
    InstaSPIN_BLDC1.Vcg = iqVcIn - InstaSPIN_BLDC1.VcOffset; // Adjust for offset of Vc_in
    InstaSPIN_BLDC1.State = mod_dir1.Counter; // Update the state
    InstaSPIN_BLDC(&InstaSPIN_BLDC1);
    mod_dir1.TrigInput = InstaSPIN_BLDC1.Comm_Trig;

    but want to know how these i/p are processed and converted in to o/p in code?

    To summarize

    i want to know , how and where the below block in implemented in software.

     

    regards

    vinod

  • Vinod,

    In the code snippet shown you are passing the variables to the inputs of the InstaSPIN-BLDC block, executing the block, and then using the InstaSPIN-BLDC block's Comm_Trig output variable in your control loop.

    It seems like you are asking us to reveal the algorithms inside the InstasSPIN-BLDC block, is that correct?  If we were going to do that we wouldn't have put it in an object library. The whole purpose of that is to obscure the algorithm.

    I will agree that this block's operation should be documented better - similar to all the blocks in the DMC_MATH library - but even when we do so we will never release the equations.