Velocity control: heat and vibration issues

Hi everyone,

I am currently driving an cubemars GL35 motor with b-g431-esc1. It works correctly fine with torque control mode. However there are 2 issues about velocity mode; it is probably due to PID but no I could not handle with combinations I tried so I wanted to ask you.

-First, It gets hot while target 0, the motor vibrate and get hot increadibly fast. the vibration is not that strong but it is vibrating I assume if I fix this the heat problem also solve.

-Second, increasing the speed is okey but when I reduce it motor goes to reverse or stop for a moment. Is it overshooting that much? You can check the video.

The phase current wave seems fine in oscilloscop during a high velocities but it also vibrating little.

image

there is my PID values, P value my bit much but when I decrease it It start to oscilating. I also tried to start with giving all values 0 and increasing little but I could not find a sweet spot.

Any idea to solve? Thanks for your help.

Yes - this can be a sensor precision problem, if the sensor readings are not stable, or a PID tuning problem, in that there is a small oscillation caused by the PID. One way to stop it could be just to turn the windings off using motor.disable() when in the zero position.

I’m not 100% sure what’s going on there.
But I think your I value is quite high at 10.0, this will tend to make corrections quite “sudden”. And the low pass filter value of 0.2 is very high - it will make it slow to react to changes…
Setting the output limit to 1.0 seems incorrect to me also - I think this value is best left unchanged, or set equal to the motor.voltage_limit.

I would set P a little lower, and I a lot lower, but raise the PID.output_limit back up. See if this helps any?