Acim Ttc

ACIM_TTC #

Brief #

The acim_ttc component is responsible for controlling an AC Induction Motor (ACIM) using Torque and Flux control strategies. It reads motor parameters and control settings, calculates derived parameters, updates the control algorithm in real-time, and supports different operating modes. The component ensures that the motor operates within safe and efficient boundaries by adjusting the velocity, position, and torque limits accordingly.

Component Explanation #

The acim_ttc component is designed for controlling an AC Induction Motor (ACIM) using Torque and Flux control strategies. This component operates within a hardware abstraction layer (HAL) framework, providing real-time control and non-real-time initialization functions.

  1. Input Reading and Initialization:
  • The component reads various motor parameters and control settings from input pins, including mode, sensorless, torque_n, cur_n, slip_n, polecount, freq_n, vel_n, u_n, u_boost, t_boost, and s_boost.
  • The torque command (torque) and measured velocity (vel_m) are also read from input pins.
  1. Parameter Calculation:
  • The component calculates several derived parameters based on the input values, such as poles, vel_n, t_n, freq_n, slip_n, and id_n.
  • These parameters are used in the control algorithm to adjust the motor’s operation.
  1. Scale Update:
  • The scale parameter is updated based on the error between the duty cycle setpoint and the actual duty cycle. This helps in adjusting the control parameters dynamically.
  • The scale parameter is clamped to ensure it stays within a valid range.
  1. Operating Modes:
  • The component supports different operating modes based on the mode input:
  • Slip Control: Adjusts the d-axis and q-axis currents based on the slip and torque commands.
  • MTPA (Maximum Torque Per Ampere): Optimizes the torque for a given current.
  • V/f (Voltage over Frequency) Control: Adjusts the voltage and frequency based on the slip and torque commands.
  • The appropriate control strategy is selected based on the mode input, and the corresponding commands are calculated.
  1. Torque Limits:
  • The component calculates the minimum and maximum torque limits (t_min and t_max) based on the operating conditions and the t_boost parameter.
  • These limits ensure that the motor operates within safe and efficient boundaries.
  1. Slip and Velocity Updates:
  • The slip and velocity are updated based on the sensorless control flag (sensorless).
  • If sensorless control is enabled, the velocity is adjusted by subtracting the slip. Otherwise, the velocity is adjusted by adding the slip.
  1. Output Updates:
  • The component updates the output pins with the calculated values, including cmd_mode, d_cmd, q_cmd, slip_n, slip, t_min, t_max, and pos.
  • The estimated position (pos) is updated by integrating the estimated velocity over time and wrapping it using the mod function.

Pins #

NameDescription
modeparameter, 0 = slip, 1 = mtpa, 2 = u/f
sensorlessparameter, Flag indicating whether sensorless control is enabled (1 = enabled, 0 = disabled)
torque_nparameter, Nominal torque of the motor (N/M)
cur_nparameter, Nominal current of the motor (A)
slip_nparameter, Nominal slip frequency of the motor (rad/s)
polecountparameter, Number of pole pairs in the motor
freq_nparameter, Nominal frequency of the motor (Hz)
vel_nparameter, Nominal velocity of the motor (rad/s)
u_nparameter, Nominal voltage of the motor (V)
u_boostparameter, Voltage boost factor for startup
t_boostparameter, Torque boost factor for startup
s_boostparameter, Slip boost factor for startup
torqueinput, Torque command (N/M)
vel_minput, Motor velocity, (rad/s)
vel_einput if Sensorless>0, output otherwise, synchronous speed (rad/s)
d_cmdoutput, D-axis current command
q_cmdoutput, Q-axis current command
cmd_modeoutput, Command mode (0 = voltage control, 1 = current control)
posoutput, Estimated position of the motor
slipoutput, Estimated slip of the motor
t_minMinimum torque limit
t_maxMaximum torque limit
scaleScaling factor for current commands
kiIntegral gain for scale adjustment
dutyCurrent duty cycle
duty_setpointDesired duty cycle setpoint

References #

Source: .c File