2025-01-05 04:59 PM
Board: Nucleo-STM32F401 + Nucleo-IMH021A
Motor: PKP246D15A2-R2FL
Firmware: X-CUBE-SPN2 V1.1.1
Power supply: 24V 2A
Test condition: No load to motor
Steps:
1) Change the Params.c file (see below)
2) Compile and load image
3) Send Initialization commands:
M1.HARDHIZ
M1.SETPARAM.ABS_POS.0
M1.SETPARAM.EL_POS.0
M1.SETPARAM.ACC.100
M1.SETPARAM.DEC.100
M1.SETPARAM.MAX_SPEED.600
M1.SETPARAM.MIN_SPEED.0
M1.SETPARAM.KVAL_HOLD.41
M1.SETPARAM.KVAL_RUN.41
M1.SETPARAM.KVAL_ACC.41
M1.SETPARAM.KVAL_DEC.41
M1.SETPARAM.INT_SPEED.1032
M1.SETPARAM.ST_SLP.25
M1.SETPARAM.FN_SLP_ACC.41
M1.SETPARAM.FN_SLP_DEC.41
M1.SETPARAM.K_THERM.0
M1.SETPARAM.OCD_TH.8
M1.SETPARAM.STALL_TH.64
M1.SETPARAM.FS_SPD.1023
M1.SETPARAM.STEP_MODE.7
4) Run command with different speed:
a. M1.RUN.FWD.50000
It is about 745steps/s or 230 RPM. Everything is good. It takes about 80mA
b. M1.RUN.FWD.60000
I can use my hand to add some load to make big noise, and cannot recover. It takes 86mA, and it take 210mA when making noise.
c. M1.RUN.FWD.65000
It makes noise right away without load.
I am expecting to run the motor to 800 RPM or higher. Please advise what I can do.
Thanks,
Frank
// Updated motor parameters for PKP246D15 motor
// Motor Parameter Data
const MotorParameterData_t MotorParameterInitData[EXPBRD_MOUNTED_NR_MAX][L6470DAISYCHAINSIZE] = {
{
{
24.0, // Motor supply voltage in V (matches the driver power supply)
200, // Minimum number of steps per revolution (1.8 degrees per step)
1.5, // Maximum motor phase current in A
4.4, // Maximum motor phase voltage in V (from datasheet)
300.0, // Motor initial speed [steps/s] (moderate starting speed)
400.0, // Motor acceleration [steps/s^2] (ensure stable ramp-up)
400.0, // Motor deceleration [steps/s^2] (ensure stable ramp-down)
3000.0, // Motor maximum speed [steps/s] (~900 RPM equivalent))
0.0, // Motor minimum speed [steps/s]
1000.0, // Motor full-step speed threshold [steps/s] (matches torque-to-speed region)
1.8, // Holding torque KVAL (based on motor specs)
2.7, // Constant speed KVAL (based on motor specs)
2.7, // Acceleration starting KVAL (based on motor specs)
2.7, // Deceleration starting KVAL (based on motor specs)
1000.0, // Intersect speed for BEMF compensation curve slope changing [steps/s]
392.1569e-6, // Start slope [s/step]
392.1569e-6, // Acceleration final slope [s/step]
392.1569e-6, // Deceleration final slope [s/step]
0, // Thermal compensation factor (0 for now)
1600.0, // Overcurrent detection threshold [mA] (1.5A max per phase)
1400.0, // Stall detection threshold [mA] (set just below max phase current)
MICROSTEP_1_128, // Step mode selection (use 1/128 microstepping for smooth motion)
0xFF, // Alarm conditions enable
0x2E88 // IC configuration
},
{
24.0, 200, 1.5, 4.4, 300.0, 400.0, 400.0, 3000.0, 0.0, 1000.0, 1.8, 2.7, 2.7, 2.7, 1000.0, 392.1569e-6, 392.1569e-6, 392.1569e-6, 0, 1600.0, 1400.0, MICROSTEP_1_128, 0xFF, 0x2E88
},
},
};