2022-01-20 01:10 AM
我用的是MCSDK5.Y.2的电出库,�?如何通过直接修改�?代�?,改�?�电机的电�?�?�数?(�?用�?新�?用STM32Cube�?次生�?)我修改了M1_ApplicationConfig_reg.maxMotorCurrent的值,但是�?�有界�?�显示�?�化,实际电�?并没有�?�化。我修改了M1_MotorConfig_reg.maxCurrent值,什么没有�?�化。
2022-01-31 05:01 AM
In the file pmsm_motor_parameters.h you can change the nominal current of your motor:
/* When using Id = 0, NOMINAL_CURRENT is utilized to saturate the output of the
PID for speed regulation (i.e. reference torque).
Transformation of real currents (A) into int16_t format must be done accordingly with
formula:
Phase current (int16_t 0-to-peak) = (Phase current (A 0-to-peak)* 32767 * Rshunt *
*Amplifying network gain)/(MCU supply voltage/2)
*/
#define NOMINAL_CURRENT 3394