Use PMSM Block and Motor Parameters to Design Plant Model

You can use the surface mount or interior PMSM blocks from Motor Control Blockset™ in two ways to create a plant model.

  • Estimate motor parameters by using Motor Control Blockset and open a Simulink® model with PMSM motor block (auto-populated with estimated parameters):

    The Motor Control Blockset parameter estimation workflow helps you to determine the motor parameters by performing a series of tests on the motor. For details, see Estimate Motor Parameters by Using Motor Control Blockset Parameter Estimation Tool. After successfully estimating the motor parameters, click Open Model in the parameter estimation host model. A new model opens with the Interior PMSM block updated with the estimated motor parameters.

  • Create a new model and add PMSM motor block manually from the Motor Control Blockset library:

    Create a new Simulink model and add the Surface Mount PMSM block from the Motor Control Blockset library in the Simulink library browser. Open the block mask and enter the motor parameters manually. You can obtain these parameters by using:

    In Surface Mount PMSM block, set the Simulation type parameter to Discrete and the Sample Time (Ts) parameter to 25e-6 (half of the control frequency). Discrete simulation improves the simulation speed.

    If parameters are available in a MAT-file, click the Browse button on the block mask to locate the MAT-file and then click Load from file to load the parameters.

    The files containing the default motor parameters are available in the location <matlabroot>\toolbox\autoblks\autoblksshared\mcbtemplates for your reference.

    In the Surface Mount PMSM block mask, you can also represent the motor parameters as workspace variables and use the m-script to automatically update these variables using the model initialization callback. For reference parameters of some commercially available motors, see the file mcb_SetPMSMMotorParameter.m. For details about this m-script file, see Estimate Control Gains from Motor Parameters)