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.

MCF8329EVM: BASE_CURRENT and Current limits

Part Number: MCF8329EVM
Other Parts Discussed in Thread: MCF8329A, MOTORSTUDIO

Tool/software:

The Base Current I calculated using the Equation given in the MCF8329A Tuning guide (with RSENSE=1mOhm; CSA_GAIN=40 V/V as that was the value in the corresponding register then) was 1024 or 0x400 which from my understanding corresponds to 37.5A. 
I am driving my BLDC-Motor at a voltage of 18V and a max current of 10A (using current limiter of my bench power supply). In the default fault configuration ILIMIT=60%, HW_LOCK_LIMIT=80% and LOCK_LIMIT=65%, still when trying to start the motor I instantly get a HW_LOCK_LIMIT fault. The System can't draw (and isn't drawing) 80% of 37,5A which is the source of my confusion. 
Through trial and error I got the Motor running decently well by setting CSA_GAIN to 5 V/V but leaving the Base Current untouched. I think I am misunderstanding something about how the Base Current and current limit settings function.

Attached is my current configuration exported from MotorStudio as a txt file.
In this configuration the motor is spinning but very slow acceleration and high noise level which I couldn't improve using the provided tuning wizards.

Thank you for your time,

George

{
"signature":"oneui-register-data",
"data":[
[
{
"idx":0,
"id":"ISD_CONFIG",
"value":"0xE4A2D4A1",
"addr":"0x00000080"
},
{
"idx":1,
"id":"REV_DRIVE_CONFIG",
"value":"0x48300000",
"addr":"0x00000082"
},
{
"idx":2,
"id":"MOTOR_STARTUP1",
"value":"0x10A24CC0",
"addr":"0x00000084"
},
{
"idx":3,
"id":"MOTOR_STARTUP2",
"value":"0x92AF2002",
"addr":"0x00000086"
},
{
"idx":4,
"id":"CLOSED_LOOP1",
"value":"0x167D0138",
"addr":"0x00000088"
},
{
"idx":5,
"id":"CLOSED_LOOP2",
"value":"0x8AAD0501",
"addr":"0x0000008A"
},
{
"idx":6,
"id":"CLOSED_LOOP3",
"value":"0x1474182B",
"addr":"0x0000008C"
},
{
"idx":7,
"id":"CLOSED_LOOP4",
"value":"0x15A5688C",
"addr":"0x0000008E"
},
{
"idx":8,
"id":"REF_PROFILES1",
"value":"0x00000000",
"addr":"0x00000094"
},
{
"idx":9,
"id":"REF_PROFILES2",
"value":"0x00000000",
"addr":"0x00000096"
},
{
"idx":10,
"id":"REF_PROFILES3",
"value":"0x80000004",
"addr":"0x00000098"
},
{
"idx":11,
"id":"REF_PROFILES4",
"value":"0x00000000",
"addr":"0x0000009A"
},
{
"idx":12,
"id":"REF_PROFILES5",
"value":"0x00000000",
"addr":"0x0000009C"
},
{
"idx":13,
"id":"REF_PROFILES6",
"value":"0x00000000",
"addr":"0x0000009E"
}
],
[
{
"idx":0,
"id":"FAULT_CONFIG1",
"value":"0x46483186",
"addr":"0x00000090"
},
{
"idx":1,
"id":"FAULT_CONFIG2",
"value":"0x71402888",
"addr":"0x00000092"
}
],
[
{
"idx":0,
"id":"INT_ALGO_1",
"value":"0x0946027D",
"addr":"0x000000A0"
},
{
"idx":1,
"id":"INT_ALGO_2",
"value":"0x02008163",
"addr":"0x000000A2"
}
],
[
{
"idx":0,
"id":"PIN_CONFIG",
"value":"0x40032300",
"addr":"0x000000A4"
},
{
"idx":1,
"id":"DEVICE_CONFIG1",
"value":"0x00100001",
"addr":"0x000000A6"
},
{
"idx":2,
"id":"DEVICE_CONFIG2",
"value":"0x03E8C00C",
"addr":"0x000000A8"
},
{
"idx":3,
"id":"PERI_CONFIG1",
"value":"0x0006984F",
"addr":"0x000000AA"
},
{
"idx":4,
"id":"GD_CONFIG1",
"value":"0x80008078",
"addr":"0x000000AC"
},
{
"idx":5,
"id":"GD_CONFIG2",
"value":"0x80000400",
"addr":"0x000000AE"
}
],
[
{
"idx":0,
"id":"GATE_DRIVER_FAULT_STATUS",
"value":"0x00000000",
"addr":"0x000000E0"
},
{
"idx":1,
"id":"CONTROLLER_FAULT_STATUS",
"value":"0x00000000",
"addr":"0x000000E2"
}
],
[
{
"idx":0,
"id":"ALGO_STATUS",
"value":"0x00000004",
"addr":"0x000000E4"
},
{
"idx":1,
"id":"MTR_PARAMS",
"value":"0x00000000",
"addr":"0x000000E6"
},
{
"idx":2,
"id":"ALGO_STATUS_MPET",
"value":"0x0A000000",
"addr":"0x000000E8"
}
],
[
{
"idx":0,
"id":"ALGO_CTRL1",
"value":"0x20000000",
"addr":"0x000000EA"
}
],
[
{
"idx":0,
"id":"ALGO_DEBUG1",
"value":"0x80000000",
"addr":"0x000000EC"
},
{
"idx":1,
"id":"ALGO_DEBUG2",
"value":"0x00000000",
"addr":"0x000000EE"
},
{
"idx":2,
"id":"CURRENT_PI",
"value":"0x030503A0",
"addr":"0x000000F0"
},
{
"idx":3,
"id":"SPEED_PI",
"value":"0x02950195",
"addr":"0x000000F2"
},
{
"idx":4,
"id":"DAC_1",
"value":"0x00000000",
"addr":"0x000000F4"
}
],
[
{
"idx":0,
"id":"ALGORITHM_STATE",
"value":"0x00000000",
"addr":"0x00000196"
},
{
"idx":1,
"id":"FG_SPEED_FDBK",
"value":"0x7FFFFFFF",
"addr":"0x0000019C"
},
{
"idx":2,
"id":"BUS_CURRENT",
"value":"0x00000000",
"addr":"0x0000040E"
},
{
"idx":3,
"id":"PHASE_CURRENT_A",
"value":"0x00000000",
"addr":"0x0000043C"
},
{
"idx":4,
"id":"PHASE_CURRENT_B",
"value":"0x00000000",
"addr":"0x0000043E"
},
{
"idx":5,
"id":"PHASE_CURRENT_C",
"value":"0x00000000",
"addr":"0x00000440"
},
{
"idx":6,
"id":"CSA_GAIN_FEEDBACK",
"value":"0x00000000",
"addr":"0x00000450"
},
{
"idx":7,
"id":"VOLTAGE_GAIN_FEEDBACK",
"value":"0x00000000",
"addr":"0x00000458"
},
{
"idx":8,
"id":"VM_VOLTAGE",
"value":"0x02658000",
"addr":"0x0000045C"
},
{
"idx":9,
"id":"PHASE_VOLTAGE_VA",
"value":"0x028B4047",
"addr":"0x00000460"
},
{
"idx":10,
"id":"PHASE_VOLTAGE_VB",
"value":"0x0288A72C",
"addr":"0x00000462"
},
{
"idx":11,
"id":"PHASE_VOLTAGE_VC",
"value":"0x028C1DFB",
"addr":"0x00000464"
},
{
"idx":12,
"id":"SIN_COMMUTATION_ANGLE",
"value":"0x00000000",
"addr":"0x000004AA"
},
{
"idx":13,
"id":"COS_COMMUTATION_ANGLE",
"value":"0x00000000",
"addr":"0x000004AC"
},
{
"idx":14,
"id":"IALPHA",
"value":"0x00000000",
"addr":"0x000004CC"
},
{
"idx":15,
"id":"IBETA",
"value":"0x00000000",
"addr":"0x000004CE"
},
{
"idx":16,
"id":"VALPHA",
"value":"0x00000000",
"addr":"0x000004D0"
},
{
"idx":17,
"id":"VBETA",
"value":"0x00000000",
"addr":"0x000004D2"
},
{
"idx":18,
"id":"ID",
"value":"0x00000000",
"addr":"0x000004DC"
},
{
"idx":19,
"id":"IQ",
"value":"0x00000000",
"addr":"0x000004DE"
},
{
"idx":20,
"id":"VD",
"value":"0x00000000",
"addr":"0x000004E0"
},
{
"idx":21,
"id":"VQ",
"value":"0x00000000",
"addr":"0x000004E2"
},
{
"idx":22,
"id":"IQ_REF_ROTOR_ALIGN",
"value":"0x00000000",
"addr":"0x0000051A"
},
{
"idx":23,
"id":"SPEED_REF_OPEN_LOOP",
"value":"0x00000000",
"addr":"0x00000532"
},
{
"idx":24,
"id":"IQ_REF_OPEN_LOOP",
"value":"0x00000000",
"addr":"0x00000542"
},
{
"idx":25,
"id":"SPEED_REF_CLOSED_LOOP",
"value":"0x00000000",
"addr":"0x000005D0"
},
{
"idx":26,
"id":"ID_REF_CLOSED_LOOP",
"value":"0x00000000",
"addr":"0x0000060A"
},
{
"idx":27,
"id":"IQ_REF_CLOSED_LOOP",
"value":"0x00000000",
"addr":"0x0000060C"
},
{
"idx":28,
"id":"ISD_STATE",
"value":"0x00000000",
"addr":"0x000006B0"
},
{
"idx":29,
"id":"ISD_SPEED",
"value":"0x00000000",
"addr":"0x000006BA"
},
{
"idx":30,
"id":"IPD_STATE",
"value":"0x00000000",
"addr":"0x000006E4"
},
{
"idx":31,
"id":"IPD_ANGLE",
"value":"0x00000000",
"addr":"0x0000071A"
},
{
"idx":32,
"id":"ED",
"value":"0x00000000",
"addr":"0x0000075C"
},
{
"idx":33,
"id":"EQ",
"value":"0x00000000",
"addr":"0x0000075E"
},
{
"idx":34,
"id":"SPEED_FDBK",
"value":"0x00000000",
"addr":"0x0000076E"
},
{
"idx":35,
"id":"THETA_EST",
"value":"0x00000000",
"addr":"0x00000774"
}
]
]
}

  • Additionally another oddity I have noticed is that when trying to run MPET measuring both BEMF constant and the Mechanical Parameters the MPET doesn't finish, the motor spins continuously (see the log below). MPET measuring only BEMF constant works fine and takes less then a minute.

     

    Some additional information of the motor I am driving:
       -phase resistance: 5,5mOhm
       -phase inductance: 3,15uH
       -pole pairs: 21
       -Max_speed: 1730Hz

  • Hi George,

    Could you please share your MCF8329 EVM top side picture? We had an accuracy issue with the shunt resister which was used in the older version of the EVM, will be able to confirm the issue by looking at the EVM picture.

    For MPET problem, please increase the MPET open loop speed reference from 25 to 50% and try to run both BEMF and mechanical parameters.

    Thanks,

    Dhinesh

  • Here is a picture of the board:

    Changing the open loop speed reference did not change anything. How long does the MPET usually take?

  • Hi George,

    Thanks for sharing the picture.

    Shunt resister that is used in this particular EVM version has accuracy issue. We changed the shunt resister in the latest EVM.

    Please change the shunt resister in the EVM.

    MPET usually takes a minute to complete.

    Are you running MPET in motor loaded condition? if yes, what type of load attached to the motor?

    Thanks,

    Dhinesh

  • Hello Dinesh,
    To what resistor should we change the shunt?

    No I'm running it without a load.

  • Hi George,

    You can replace the EVM shunt resister with same 0.001ohm value. Choose higher value (ex: 5mohms) if your motor max. current is 10A.

    Please try MPET after changing the shunt resister.

    Thanks,

    Dhinesh

  • Hi Dinesh,
    I replaced the Shunt resistor both with a new 1mOhm resistor and with a 3mOhm Resistor. 
    The behavior of the motor did not change much. What would you expect to change when upping the shunt resistor?
    I measured the voltage across both resistor values:
    1mOhm:

    3mOhm:

    Any recommendations on what we should try next.

    Thanks,

    George

  • Hi George,

    Thanks for sharing the scope captures. 

    I reviewed your JSON once again and found that configured digital dead time is 0. This configuration located at PERI_CONFIG1 -> DIG_DEAD_TIME. Please change it to 300ns and reverify your test.

    Hope you have changed the CSA_GAIN and BASE_CURRENT parameters as per the shunt resister value. 

    Thanks,

    Dhinesh

  • Hello Dhinesh,

    Thanks for the info on the deadtime, the voltage peaks are much lower and current draw is down from 2.7A to 0.8A.

    (back to using the 1mOhm Shunt resistor)

    But the original question still remains. I am currently running the motor with the Base Current calculated using a shunt of 1mOhm and CSA_GAIN of 40 V/V (result is 0x400).
    But if CSA_GAIN is actually set to 40 V/V in the register I always instantly get a HW_LOCK_FAULT. With CSA_GAIN set to 5 V/V the Motor spins but I do not understand why.

    Additionally MPET still isn't working reliably is there any documentation you could provide on MPET and under what conditions it should be performed.

    Here is my current JSON file:

    {
    "signature":"oneui-register-data",
    "data":[
    [
    {
    "idx":0,
    "id":"ISD_CONFIG",
    "value":"0xE4A2D4A1",
    "addr":"0x00000080"
    },
    {
    "idx":1,
    "id":"REV_DRIVE_CONFIG",
    "value":"0x48300000",
    "addr":"0x00000082"
    },
    {
    "idx":2,
    "id":"MOTOR_STARTUP1",
    "value":"0x74A44CC0",
    "addr":"0x00000084"
    },
    {
    "idx":3,
    "id":"MOTOR_STARTUP2",
    "value":"0x92AF2062",
    "addr":"0x00000086"
    },
    {
    "idx":4,
    "id":"CLOSED_LOOP1",
    "value":"0x167D0138",
    "addr":"0x00000088"
    },
    {
    "idx":5,
    "id":"CLOSED_LOOP2",
    "value":"0x8AAD0501",
    "addr":"0x0000008A"
    },
    {
    "idx":6,
    "id":"CLOSED_LOOP3",
    "value":"0x1474182B",
    "addr":"0x0000008C"
    },
    {
    "idx":7,
    "id":"CLOSED_LOOP4",
    "value":"0x15A5688C",
    "addr":"0x0000008E"
    },
    {
    "idx":8,
    "id":"REF_PROFILES1",
    "value":"0x00000000",
    "addr":"0x00000094"
    },
    {
    "idx":9,
    "id":"REF_PROFILES2",
    "value":"0x00000000",
    "addr":"0x00000096"
    },
    {
    "idx":10,
    "id":"REF_PROFILES3",
    "value":"0x80000004",
    "addr":"0x00000098"
    },
    {
    "idx":11,
    "id":"REF_PROFILES4",
    "value":"0x00000000",
    "addr":"0x0000009A"
    },
    {
    "idx":12,
    "id":"REF_PROFILES5",
    "value":"0x00000000",
    "addr":"0x0000009C"
    },
    {
    "idx":13,
    "id":"REF_PROFILES6",
    "value":"0x00000000",
    "addr":"0x0000009E"
    }
    ],
    [
    {
    "idx":0,
    "id":"FAULT_CONFIG1",
    "value":"0x46483186",
    "addr":"0x00000090"
    },
    {
    "idx":1,
    "id":"FAULT_CONFIG2",
    "value":"0x71402888",
    "addr":"0x00000092"
    }
    ],
    [
    {
    "idx":0,
    "id":"INT_ALGO_1",
    "value":"0x0946027D",
    "addr":"0x000000A0"
    },
    {
    "idx":1,
    "id":"INT_ALGO_2",
    "value":"0x02008163",
    "addr":"0x000000A2"
    }
    ],
    [
    {
    "idx":0,
    "id":"PIN_CONFIG",
    "value":"0x40032308",
    "addr":"0x000000A4"
    },
    {
    "idx":1,
    "id":"DEVICE_CONFIG1",
    "value":"0x00100001",
    "addr":"0x000000A6"
    },
    {
    "idx":2,
    "id":"DEVICE_CONFIG2",
    "value":"0x03E8C00C",
    "addr":"0x000000A8"
    },
    {
    "idx":3,
    "id":"PERI_CONFIG1",
    "value":"0x1806984F",
    "addr":"0x000000AA"
    },
    {
    "idx":4,
    "id":"GD_CONFIG1",
    "value":"0x80008078",
    "addr":"0x000000AC"
    },
    {
    "idx":5,
    "id":"GD_CONFIG2",
    "value":"0x80000400",
    "addr":"0x000000AE"
    }
    ],
    [
    {
    "idx":0,
    "id":"GATE_DRIVER_FAULT_STATUS",
    "value":"0x00000000",
    "addr":"0x000000E0"
    },
    {
    "idx":1,
    "id":"CONTROLLER_FAULT_STATUS",
    "value":"0x00000001",
    "addr":"0x000000E2"
    }
    ],
    [
    {
    "idx":0,
    "id":"ALGO_STATUS",
    "value":"0x14260004",
    "addr":"0x000000E4"
    },
    {
    "idx":1,
    "id":"MTR_PARAMS",
    "value":"0x00000000",
    "addr":"0x000000E6"
    },
    {
    "idx":2,
    "id":"ALGO_STATUS_MPET",
    "value":"0x0A000000",
    "addr":"0x000000E8"
    }
    ],
    [
    {
    "idx":0,
    "id":"ALGO_CTRL1",
    "value":"0x00000000",
    "addr":"0x000000EA"
    }
    ],
    [
    {
    "idx":0,
    "id":"ALGO_DEBUG1",
    "value":"0x00000000",
    "addr":"0x000000EC"
    },
    {
    "idx":1,
    "id":"ALGO_DEBUG2",
    "value":"0x00000000",
    "addr":"0x000000EE"
    },
    {
    "idx":2,
    "id":"CURRENT_PI",
    "value":"0x030503A0",
    "addr":"0x000000F0"
    },
    {
    "idx":3,
    "id":"SPEED_PI",
    "value":"0x00000000",
    "addr":"0x000000F2"
    },
    {
    "idx":4,
    "id":"DAC_1",
    "value":"0x00000000",
    "addr":"0x000000F4"
    }
    ],
    [
    {
    "idx":0,
    "id":"ALGORITHM_STATE",
    "value":"0x00000000",
    "addr":"0x00000196"
    },
    {
    "idx":1,
    "id":"FG_SPEED_FDBK",
    "value":"0x00CA4BAA",
    "addr":"0x0000019C"
    },
    {
    "idx":2,
    "id":"BUS_CURRENT",
    "value":"0x00000000",
    "addr":"0x0000040E"
    },
    {
    "idx":3,
    "id":"PHASE_CURRENT_A",
    "value":"0x00100000",
    "addr":"0x0000043C"
    },
    {
    "idx":4,
    "id":"PHASE_CURRENT_B",
    "value":"0x00000000",
    "addr":"0x0000043E"
    },
    {
    "idx":5,
    "id":"PHASE_CURRENT_C",
    "value":"0xFFF00000",
    "addr":"0x00000440"
    },
    {
    "idx":6,
    "id":"CSA_GAIN_FEEDBACK",
    "value":"0x00000003",
    "addr":"0x00000450"
    },
    {
    "idx":7,
    "id":"VOLTAGE_GAIN_FEEDBACK",
    "value":"0x00010001",
    "addr":"0x00000458"
    },
    {
    "idx":8,
    "id":"VM_VOLTAGE",
    "value":"0x026D8000",
    "addr":"0x0000045C"
    },
    {
    "idx":9,
    "id":"PHASE_VOLTAGE_VA",
    "value":"0x02A3EECC",
    "addr":"0x00000460"
    },
    {
    "idx":10,
    "id":"PHASE_VOLTAGE_VB",
    "value":"0x02A2A23F",
    "addr":"0x00000462"
    },
    {
    "idx":11,
    "id":"PHASE_VOLTAGE_VC",
    "value":"0x02A37FF3",
    "addr":"0x00000464"
    },
    {
    "idx":12,
    "id":"SIN_COMMUTATION_ANGLE",
    "value":"0x072E460C",
    "addr":"0x000004AA"
    },
    {
    "idx":13,
    "id":"COS_COMMUTATION_ANGLE",
    "value":"0xFC7EE448",
    "addr":"0x000004AC"
    },
    {
    "idx":14,
    "id":"IALPHA",
    "value":"0xFB100000",
    "addr":"0x000004CC"
    },
    {
    "idx":15,
    "id":"IBETA",
    "value":"0xFD5DA7A7",
    "addr":"0x000004CE"
    },
    {
    "idx":16,
    "id":"VALPHA",
    "value":"0xFFA1A522",
    "addr":"0x000004D0"
    },
    {
    "idx":17,
    "id":"VBETA",
    "value":"0xFFE06A5E",
    "addr":"0x000004D2"
    },
    {
    "idx":18,
    "id":"ID",
    "value":"0xFEB1A16A",
    "addr":"0x000004DC"
    },
    {
    "idx":19,
    "id":"IQ",
    "value":"0x056F16FC",
    "addr":"0x000004DE"
    },
    {
    "idx":20,
    "id":"VD",
    "value":"0x000D035B",
    "addr":"0x000004E0"
    },
    {
    "idx":21,
    "id":"VQ",
    "value":"0x0062C4EA",
    "addr":"0x000004E2"
    },
    {
    "idx":22,
    "id":"IQ_REF_ROTOR_ALIGN",
    "value":"0x00000000",
    "addr":"0x0000051A"
    },
    {
    "idx":23,
    "id":"SPEED_REF_OPEN_LOOP",
    "value":"0x00000000",
    "addr":"0x00000532"
    },
    {
    "idx":24,
    "id":"IQ_REF_OPEN_LOOP",
    "value":"0x09997560",
    "addr":"0x00000542"
    },
    {
    "idx":25,
    "id":"SPEED_REF_CLOSED_LOOP",
    "value":"0x00000000",
    "addr":"0x000005D0"
    },
    {
    "idx":26,
    "id":"ID_REF_CLOSED_LOOP",
    "value":"0x00000000",
    "addr":"0x0000060A"
    },
    {
    "idx":27,
    "id":"IQ_REF_CLOSED_LOOP",
    "value":"0x00000000",
    "addr":"0x0000060C"
    },
    {
    "idx":28,
    "id":"ISD_STATE",
    "value":"0x00000005",
    "addr":"0x000006B0"
    },
    {
    "idx":29,
    "id":"ISD_SPEED",
    "value":"0x0000091D",
    "addr":"0x000006BA"
    },
    {
    "idx":30,
    "id":"IPD_STATE",
    "value":"0x00000000",
    "addr":"0x000006E4"
    },
    {
    "idx":31,
    "id":"IPD_ANGLE",
    "value":"0x00000000",
    "addr":"0x0000071A"
    },
    {
    "idx":32,
    "id":"ED",
    "value":"0x00000000",
    "addr":"0x0000075C"
    },
    {
    "idx":33,
    "id":"EQ",
    "value":"0x00000000",
    "addr":"0x0000075E"
    },
    {
    "idx":34,
    "id":"SPEED_FDBK",
    "value":"0x00000000",
    "addr":"0x0000076E"
    },
    {
    "idx":35,
    "id":"THETA_EST",
    "value":"0x00000000",
    "addr":"0x00000774"
    }
    ]
    ]
    }

    Thanks,

    George

  • Hi George,

    Please find my answer below

    I am currently running the motor with the Base Current calculated using a shunt of 1mOhm and CSA_GAIN of 40 V/V (result is 0x400).
    But if CSA_GAIN is actually set to 40 V/V in the register I always instantly get a HW_LOCK_FAULT. With CSA_GAIN set to 5 V/V the Motor spins but I do not understand why.

    Dhinesh>> Are you not changing the base current value based on the new CSA_GAIN - 5V/V setting? if not, then the device interpretation of all current settings can go wrong.

    Changing only CSA gain from 40V/V to 5V/V without changing the base current setting, you are indirectly limiting the current limit by 8 times.

    Please confirm the motor electrical parameters (Motor phase resistance, Inductance, BEMF constant and Maximum speed) that you have entered are correct.

    Can you share the motor current waveform during the fault scenario? We may get HW_LOCK_LIMIT fault if the entered speed loop proportional gain (Kp) is high. To check this, please try to spin the motor in current control mode by changing this setting PERI_CONFIG1->CTRL_MODE.

    Additionally MPET still isn't working reliably is there any documentation you could provide on MPET and under what conditions it should be performed.

    Dhinesh> Please confirm the entered motor electrical parameters are correct.

    Do you have any load connected to the motor while running the MPET? if not, what is the motor phase current that you observe while it is running continuously? MPET algorithm reduces the motor phase current gradually and try to sense this change in current level, if the motor phase current is very low during the MPET operation then it may fail to detect this current change and continue to run.

    Thanks,

    Dhinesh

  • Hello Dinesh,

    Here is the Voltage across the shunt resistor (1mOhm) at the time of the HW_LOCK_LIMIT fault.

    This was measured with CSA of 40 V/V and a BASE_CURRENT of 0x400.
    There is no short circuit between phases and changing the SPD_LOOP_KP, SPD_LOOP_KI, CURR_LOOP_KP, and
    CURR_LOOP_KI to zero also did not resolve the issue. As is suggested in the tuning guide. Using CTRL_MODE I also wasn't able to get the motor running.

    Thanks George

  • Hello Dhinesh,

    I don't think that I am understanding the BASE_CURRENT calculations and CSA_GAIN correctly.
    To my understanding the base current is the maximum current that the ADC can measure. So the CSA is multiplied before the ADC input. From that follows that if the Base current is set to 0x400 (37.5A) calculated with 40 V/V CSA but instead I use 5 V/V CSA the actual current flowing is 8 times higher than the value measured by the ADC.
    And if the Base current is set to 0x2000 (300A) calculated with 5V/V the actual current and measured current are equal.
    From that logic a current limit set to 80% of the Base current corresponds to the same actual current. In the second case 80% is measured 240A which is the real current. In the first case 80% is 30A measured but the ADC systematically undervalues by a factor of 8 so the real current flowing is also 240A.

    But something doesn't add up here because in the first case (with the wrong base current) the motor works perfectly and in the second there is an immediate HW_LOCK_LIMIT fault. 
    If you could please clear up my misunderstanding about the calculations.

    Another idea of ours was maybe the fault gets triggered because the voltage spikes are higher than the recommended ADC Voltage of 3.3V. So we changed the shunt resistor to 0.5mOhm and changed the Base Current accordingly which reduced the voltage spikes but it still gave a HW_LOCK_LIMIT fault.

    Thank you for your time 
    George

  • Hi George,

    Yes, your understanding is correct. only changing the CSA gain from 40V/V to 5V/V will increase the current flow 8 times higher than the actual one.  Fault is not getting triggered with this setting because the device is trying to regulate the motor speed in the closed loop operation. When you start the motor, Initially, you will see higher current during motor startup operations (Align and open loop operations) where we do current control then current will drop after it entered into close loop operation. 

    Can you please confirm the entered motor parameters are correct?

    Thanks,

    Dhinesh

  • Hello Dhinesh,

    Yes the Motor parameters are correct. 

    Phase Resistance = 5.5mOhm
    BEMF konstant = 7mv/Hz (measured with MPET)
    MAX_SPEED = 1730Hz

    The measured Phase Inductance is 3uH but Motorstudio doesn't let me change Lq lower than 6uH so Lq is set to 6uH and Ld to 3uH

    Thanks

    George

  • I have received additional information about the motor. The Max Phase Current is 180A so I set the Base Current and limits according to the tuning guide.
    RSENSE = 0.5mOhm; CSA_GAIN = 5 V/V => BASE_CURRENT = 600A with HW_LOCK_LIMIT, LOCK_LIMIT = 60% and ILIMT set to 180A => 30%.
    Still triggers the same clicking sound and HW_LOCK_LIMIT.

    I am still waiting for the Motor Parameters form the Supplier to check if my measurements are correct.

    Additionally I have noticed that when running the Motor with the mismatched Base_CURRENT and CSA_GAIN I am unable to the spin the motor up to the maximum Speed. It's capped at about 3200 rpm even though MAX_SPEED is set to 4230. Changing MAX_SPEED has no effect on the cap.

    Thanks

    George

  • Hi George,

    Please check the device fault status, it might have reached speed or current loop saturation.

    Motor speed will not increase with any of these saturation faults.

    For HW lock limit fault, did you try running the motor in current control mode?

    Also, please note that device calculates current loop kp and Ki internally when you make those parameters as 0, however this is not the case for speed loop constants. 

    Reduce the current loop gain (CURR_LOOP_KP) from 0x3a0 to 0x310 and check the motor operation.

     

    Thanks,

    Dhinesh

  • Hello Dhinesh,

    Reducing current loop gain changed the behavior. The Motor starts spinning for a short time then suddenly stops and I get a ABN_BEMF fault.
    Could this be related to the current sensing issue when using small shunt resistors, described here: 
    e2e.ti.com/.../5949237

    Using current control mode did not change the Motors behavior.

    Attached is my current Register Setup.

    {
    "signature":"oneui-register-data",
    "data":[
    [
    {
    "idx":0,
    "id":"ISD_CONFIG",
    "value":"0xE4A234A1",
    "addr":"0x00000080"
    },
    {
    "idx":1,
    "id":"REV_DRIVE_CONFIG",
    "value":"0x48300000",
    "addr":"0x00000082"
    },
    {
    "idx":2,
    "id":"MOTOR_STARTUP1",
    "value":"0x34044CC4",
    "addr":"0x00000084"
    },
    {
    "idx":3,
    "id":"MOTOR_STARTUP2",
    "value":"0xBEDF2062",
    "addr":"0x00000086"
    },
    {
    "idx":4,
    "id":"CLOSED_LOOP1",
    "value":"0x267D013C",
    "addr":"0x00000088"
    },
    {
    "idx":5,
    "id":"CLOSED_LOOP2",
    "value":"0x8AAD0505",
    "addr":"0x0000008A"
    },
    {
    "idx":6,
    "id":"CLOSED_LOOP3",
    "value":"0x1D62182B",
    "addr":"0x0000008C"
    },
    {
    "idx":7,
    "id":"CLOSED_LOOP4",
    "value":"0x15A5688C",
    "addr":"0x0000008E"
    },
    {
    "idx":8,
    "id":"REF_PROFILES1",
    "value":"0x00000000",
    "addr":"0x00000094"
    },
    {
    "idx":9,
    "id":"REF_PROFILES2",
    "value":"0x00000000",
    "addr":"0x00000096"
    },
    {
    "idx":10,
    "id":"REF_PROFILES3",
    "value":"0x80000004",
    "addr":"0x00000098"
    },
    {
    "idx":11,
    "id":"REF_PROFILES4",
    "value":"0x00000000",
    "addr":"0x0000009A"
    },
    {
    "idx":12,
    "id":"REF_PROFILES5",
    "value":"0x00000000",
    "addr":"0x0000009C"
    },
    {
    "idx":13,
    "id":"REF_PROFILES6",
    "value":"0x00000000",
    "addr":"0x0000009E"
    }
    ],
    [
    {
    "idx":0,
    "id":"FAULT_CONFIG1",
    "value":"0x64403186",
    "addr":"0x00000090"
    },
    {
    "idx":1,
    "id":"FAULT_CONFIG2",
    "value":"0x71402888",
    "addr":"0x00000092"
    }
    ],
    [
    {
    "idx":0,
    "id":"INT_ALGO_1",
    "value":"0x0946027D",
    "addr":"0x000000A0"
    },
    {
    "idx":1,
    "id":"INT_ALGO_2",
    "value":"0x02008163",
    "addr":"0x000000A2"
    }
    ],
    [
    {
    "idx":0,
    "id":"PIN_CONFIG",
    "value":"0x40032308",
    "addr":"0x000000A4"
    },
    {
    "idx":1,
    "id":"DEVICE_CONFIG1",
    "value":"0x00100001",
    "addr":"0x000000A6"
    },
    {
    "idx":2,
    "id":"DEVICE_CONFIG2",
    "value":"0x03E8C00C",
    "addr":"0x000000A8"
    },
    {
    "idx":3,
    "id":"PERI_CONFIG1",
    "value":"0x18069840",
    "addr":"0x000000AA"
    },
    {
    "idx":4,
    "id":"GD_CONFIG1",
    "value":"0x80008078",
    "addr":"0x000000AC"
    },
    {
    "idx":5,
    "id":"GD_CONFIG2",
    "value":"0x80004000",
    "addr":"0x000000AE"
    }
    ],
    [
    {
    "idx":0,
    "id":"GATE_DRIVER_FAULT_STATUS",
    "value":"0x00000000",
    "addr":"0x000000E0"
    },
    {
    "idx":1,
    "id":"CONTROLLER_FAULT_STATUS",
    "value":"0x00000000",
    "addr":"0x000000E2"
    }
    ],
    [
    {
    "idx":0,
    "id":"ALGO_STATUS",
    "value":"0x0F610004",
    "addr":"0x000000E4"
    },
    {
    "idx":1,
    "id":"MTR_PARAMS",
    "value":"0x00000000",
    "addr":"0x000000E6"
    },
    {
    "idx":2,
    "id":"ALGO_STATUS_MPET",
    "value":"0x02000000",
    "addr":"0x000000E8"
    }
    ],
    [
    {
    "idx":0,
    "id":"ALGO_CTRL1",
    "value":"0x20000000",
    "addr":"0x000000EA"
    }
    ],
    [
    {
    "idx":0,
    "id":"ALGO_DEBUG1",
    "value":"0x00000000",
    "addr":"0x000000EC"
    },
    {
    "idx":1,
    "id":"ALGO_DEBUG2",
    "value":"0x00000000",
    "addr":"0x000000EE"
    },
    {
    "idx":2,
    "id":"CURRENT_PI",
    "value":"0x030503A0",
    "addr":"0x000000F0"
    },
    {
    "idx":3,
    "id":"SPEED_PI",
    "value":"0x00000000",
    "addr":"0x000000F2"
    },
    {
    "idx":4,
    "id":"DAC_1",
    "value":"0x00000000",
    "addr":"0x000000F4"
    }
    ],
    [
    {
    "idx":0,
    "id":"ALGORITHM_STATE",
    "value":"0x00000000",
    "addr":"0x00000196"
    },
    {
    "idx":1,
    "id":"FG_SPEED_FDBK",
    "value":"0x00C896A4",
    "addr":"0x0000019C"
    },
    {
    "idx":2,
    "id":"BUS_CURRENT",
    "value":"0x00000000",
    "addr":"0x0000040E"
    },
    {
    "idx":3,
    "id":"PHASE_CURRENT_A",
    "value":"0x00080000",
    "addr":"0x0000043C"
    },
    {
    "idx":4,
    "id":"PHASE_CURRENT_B",
    "value":"0xFFF80000",
    "addr":"0x0000043E"
    },
    {
    "idx":5,
    "id":"PHASE_CURRENT_C",
    "value":"0x00000000",
    "addr":"0x00000440"
    },
    {
    "idx":6,
    "id":"CSA_GAIN_FEEDBACK",
    "value":"0x00000003",
    "addr":"0x00000450"
    },
    {
    "idx":7,
    "id":"VOLTAGE_GAIN_FEEDBACK",
    "value":"0x00010001",
    "addr":"0x00000458"
    },
    {
    "idx":8,
    "id":"VM_VOLTAGE",
    "value":"0x026CC000",
    "addr":"0x0000045C"
    },
    {
    "idx":9,
    "id":"PHASE_VOLTAGE_VA",
    "value":"0x02A31119",
    "addr":"0x00000460"
    },
    {
    "idx":10,
    "id":"PHASE_VOLTAGE_VB",
    "value":"0x02A077FD",
    "addr":"0x00000462"
    },
    {
    "idx":11,
    "id":"PHASE_VOLTAGE_VC",
    "value":"0x02A2A23F",
    "addr":"0x00000464"
    },
    {
    "idx":12,
    "id":"SIN_COMMUTATION_ANGLE",
    "value":"0xF805428C",
    "addr":"0x000004AA"
    },
    {
    "idx":13,
    "id":"COS_COMMUTATION_ANGLE",
    "value":"0x00645A50",
    "addr":"0x000004AC"
    },
    {
    "idx":14,
    "id":"IALPHA",
    "value":"0x02980000",
    "addr":"0x000004CC"
    },
    {
    "idx":15,
    "id":"IBETA",
    "value":"0xFD7DFC8C",
    "addr":"0x000004CE"
    },
    {
    "idx":16,
    "id":"VALPHA",
    "value":"0x004BFB4B",
    "addr":"0x000004D0"
    },
    {
    "idx":17,
    "id":"VBETA",
    "value":"0x000258DA",
    "addr":"0x000004D2"
    },
    {
    "idx":18,
    "id":"ID",
    "value":"0x023B7EA8",
    "addr":"0x000004DC"
    },
    {
    "idx":19,
    "id":"IQ",
    "value":"0x02D560B3",
    "addr":"0x000004DE"
    },
    {
    "idx":20,
    "id":"VD",
    "value":"0x000162C8",
    "addr":"0x000004E0"
    },
    {
    "idx":21,
    "id":"VQ",
    "value":"0x004C1BF4",
    "addr":"0x000004E2"
    },
    {
    "idx":22,
    "id":"IQ_REF_ROTOR_ALIGN",
    "value":"0x00000000",
    "addr":"0x0000051A"
    },
    {
    "idx":23,
    "id":"SPEED_REF_OPEN_LOOP",
    "value":"0x00000000",
    "addr":"0x00000532"
    },
    {
    "idx":24,
    "id":"IQ_REF_OPEN_LOOP",
    "value":"0x1FFF8740",
    "addr":"0x00000542"
    },
    {
    "idx":25,
    "id":"SPEED_REF_CLOSED_LOOP",
    "value":"0x00000000",
    "addr":"0x000005D0"
    },
    {
    "idx":26,
    "id":"ID_REF_CLOSED_LOOP",
    "value":"0x00000000",
    "addr":"0x0000060A"
    },
    {
    "idx":27,
    "id":"IQ_REF_CLOSED_LOOP",
    "value":"0x00000000",
    "addr":"0x0000060C"
    },
    {
    "idx":28,
    "id":"ISD_STATE",
    "value":"0x00000005",
    "addr":"0x000006B0"
    },
    {
    "idx":29,
    "id":"ISD_SPEED",
    "value":"0x0000017F",
    "addr":"0x000006BA"
    },
    {
    "idx":30,
    "id":"IPD_STATE",
    "value":"0x00000000",
    "addr":"0x000006E4"
    },
    {
    "idx":31,
    "id":"IPD_ANGLE",
    "value":"0x00000000",
    "addr":"0x0000071A"
    },
    {
    "idx":32,
    "id":"ED",
    "value":"0x00000000",
    "addr":"0x0000075C"
    },
    {
    "idx":33,
    "id":"EQ",
    "value":"0x00000000",
    "addr":"0x0000075E"
    },
    {
    "idx":34,
    "id":"SPEED_FDBK",
    "value":"0x00000000",
    "addr":"0x0000076E"
    },
    {
    "idx":35,
    "id":"THETA_EST",
    "value":"0x00000000",
    "addr":"0x00000774"
    }
    ]
    ]
    }

    Thanks

    George

  • Hi George,

    Are you able to confirm the motor electrical parameters? Incorrect motor BEMF parameter entry can trigger the Abnormal BEMF fault,

    Also, it could be related to current sensing issue. could you please try with higher shut resister? Try using parallel shunt resisters when you use lower value one to minimize the parasitic inductance.

    Please accept my friend request to discuss this topic in detail.

    Thanks,

    Dhinesh

  • Hello Dhinesh,

    I accepted your request and messaged you privately.

    George