Borrar filtros
Borrar filtros

PMSM controller doesn't work

15 visualizaciones (últimos 30 días)
frank
frank el 14 de Jul. de 2021
Comentada: frank el 3 de Ag. de 2021
Hi everyone,
I'm trying to implement my own PMSM model after reviewing the numerous examples inlcuded in Simulink and the simulink community. I think I have all the right components and settings, but the motor erratically oscillates for a constant commanded torque and speed.
Below is a plot of the commanded and measured torque. The speed response is just a negative divergence from zero (commanded speed is 1000 rpm or about 100 rad/s).
Can anybody point me in the right direction for debugging?
I've attached two files. Run the .m file first to load all the variables needed for the simulink .slx file. I'm using Simscape electrical components in MATLAB/Simulink 2021a. Note, I use 'M' to symbolize torque to avoid confusion with 'T' for sample periods.
I got my motor parameters from the Emrax 228 (datasheet link).
Thanks!

Respuesta aceptada

Joel Van Sickel
Joel Van Sickel el 3 de Ag. de 2021
Hello frank,
you don't have your pole pair parameter entered correctly in your machine. Go to where your mechanical parameters are and you will see that you have friction in the spot where pole pairs should be. Your parameters for that entry should read as follows "[J F n_pole M_fric]"
Regards,
Joel
  2 comentarios
frank
frank el 3 de Ag. de 2021
Wow! I can't believe it was something that trivial. Thanks Joel!
Any suggestions for my time-related variables, like Ts, T_spdCtrl, and T_vectCtrl? Or my controller gains?
By decreasing the simulation's discrete timestep to 2e-7 s, I greatly reduced the noise in my torque signal. However, I'm curious if I can get away with a shorter timestep or higher gains.
I know this is an open-ended question, so I would appreciate any rules of thumb that Mathworks recommends for discrete simulation of motors.
Thanks,
Farid
frank
frank el 3 de Ag. de 2021
Never mind. I got comparable results with Ts = 2e-6 s, T_vectCtrl = 5*Ts s (10e-6 s). Thanks again!

Iniciar sesión para comentar.

Más respuestas (0)

Productos


Versión

R2021a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by