Chapter 8
Remote control using FreeMASTER
This section provides information about the tools and recommended procedures to control the sensor/sensorless PMSM Field-
Oriented Control (FOC) application using FreeMASTER. The application contains the embedded-side driver of the FreeMASTER
real-time debug monitor and data visualization tool for communication with the PC. It supports non-intrusive monitoring, as
well as the modification of target variables in real time, which is very useful for the algorithm tuning. Besides the target-side
driver, the FreeMASTER tool requires the installation of the PC application as well. You can download FreeMASTER 3.0 at
. To run the FreeMASTER application including the MCAT tool, double-click the
pmsm_float_enc.pmp
file located in the
pack_motor_imxrt1xxx\middleware\motor_control\freemaster
folder. The FreeMASTER application starts and
the environment is created automatically, as defined in the
*.pmp
file.
In MCUXpresso can be FreeMASTER application run directly from IDE in
motor_control/freemaster folder
NOTE
8.1 Establishing FreeMASTER communication
The remote operation is provided by FreeMASTER via the USB interface. Perform the following steps to control a PMSM motor
using FreeMASTER:
1. Download the project from your chosen IDE to the MCU and run it.
2. Open the FreeMASTER file
pmsm_x.pmp
. The PMSM project uses the TSA by default, so it is not necessary to select a
symbol file for FreeMASTER.
3. Click the communication button (the red “STOP” button in the top left-hand corner) to establish the communication.
Figure 11. Red “STOP” button placed in top left-hand corner
4. If the communication is established successfully, the FreeMASTER communication status in the bottom right-hand corner
changes from “Not connected” to “RS232 UART Communication; COMxx; speed=19200”. Otherwise, the FreeMASTER
warning popup window appears.
Figure 12. FreeMASTER—communication is established successfully
5. Press
F5
to reload the MCAT HTML page and check the App ID.
6. Control the PMSM motor using the MCAT “Control structure” tab, the MCAT “Application demo control” tab, or by directly
writing to a variable in a variable watch.
7. If you rebuild and download the new code to the target, turn the FreeMASTER application off and on.
If the communication is not established successfully, perform the following steps:
1. Go to the “Project -> Options -> Comm” tab and make sure that the correct COM port is selected and the communication
speed is set to 19200 bps.
NXP Semiconductors
MCUXpresso SDK Field-Oriented Control (FOC) of 3-Phase PMSM and BLDC motors, Rev. 0, 01/2022
User Guide
21 / 50