Power on the AC or DC power supply, gradually increase output voltage at power supply to get an appropriate DC-bus voltage.
Disable the data cache by unchecking the
Data Cache Enabled in Tools > ARM Advanced Features.
Run the project by clicking on Resume button, or
click Run → Resume in the Debug tab. The systemVars.flagEnableSystem
must be set to 1 after a fixed time, that means the offsets calibration have been
done. The fault flags motorVars_M1.faultMtrUse.all are equal to 0 , if not,
the user have to check the current and voltage sensing circuit as described in Section 4.4.1.
To verify run the motor with current closed-loop
control, set the variable motorVars_M1.flagEnableRunAndIdentify to 1 in the
Expressions window as shown in Figure 4-23. The motor runs with a closed-loop control using the angle from the angle generator at
a setting speed in the variable motorVars_M1.speedRef_Hz. Check the value of
motorVars_M1.speed_Hz in Expressions window. The values of both variables are
very close.
Connect oscilloscope probes to the EPWMDAC (for
HV kit) outputs and motor phase line to probe the angles and current signals, and current.
These waveforms on the oscilloscope appear as shown in Figure 4-24. Change the motorVars_M1.Idq_set_A.value[1] in the Expressions window to set the
reference torque current, the motor phase current increases with the same percentage
accordingly.
If the motor cannot run with current-closed loop control and an over current fault appears, check if the sign of motorVars_M1.adcData.current_sf and the value of userParams_M1.current_sf are set correctly according to the hardware board. The values of both variables are related to the definition constant USER_M1_ADC_FULL_SCALE_CURRENT_A in the user_mtr1.h file.
Set the variables motorVars_M1.flagEnableRunAndIdentify to 0 to stop run the motor.
Once complete, the controller can now be halted
and the debug connection terminated. Fully halting the controller by first clicking the
Suspend button on the toolbar or by clicking Target → Halt. Finally, reset
the controller by clicking on CPU Reset button or clicking Run → Reset.
Close CCS debug session by clicking on Terminate
Debug Session button or clicking Run → Terminate.
Figure 4-23 Build Level 3: Variables in
Expressions Window
Figure 4-24 Build Level 3: Motor Rotor Angle and
Phase Current Waveforms Monitoring by EPMWDAC