Configuration
1. Select motorBench® Development Suite in Project Resources under Libraries.
The sample projects already have the motorBench library added.
If the motorBench library is not present in Project Resources (for example, starting from a new MCC project), you will first have to add it by locating it in Device Resources
under Libraries, and double-clicking on it.
2. If you haven't registered, you will be given the option to register motorBench, or enter a 30 day trial period. You will not be able to use motorBench after 30 days. For registration
3. motorBench® Development Suite has three separate views
a. Composer view : This allows users to define and measure the system characteristics, tune the system characteristics and customize MCAF generation parameters. In
composer view, the user can
i. Configure the system: Allows user to configure the motor, board and estimator details. Users have the option to measure the electrical and mechanical parameters.
Users can export new motors.
ii. Tune the system: Once a motor has been imported, you can tune the system.
iii. Customize the MCAF parameters: Allows users to customize MCAF parameters that are used in code generation.
b. Pin Manager View: This allows users to see the various pins that are being used by the system.
c. Summary View: This allows users to see the various settings that are made by the user in the system.
4. Once you register, the "Home" page of the Composer view would show "Registered", otherwise it would show "Not yet Registered"
5. You can navigate between the “Configure”, “Tune” and “Customize” stages using their respective buttons.
6. Once all the components fully defined and there are no configuration errors, a puzzle icon will appear with status as "Ready to Generate". If the puzzle icon doesn’t appear
complete, check if there are any messages present in the “Notifications[MCC]” tab below that prevent completion, and resolve them.
Motor Import and Export
Each motor has a different characteristics, motorBench® Development Suite ships with two standard motor definitions: Hurst300 and Leadshine400.
You can Import either of these motors and modify if needed for the specific motor. Once modified you can export the changes as a different motor and use that later or share it with others
if needed.
The process of selecting a standard motor shipped with motorBench® Development Suite or created using export is called Import. Modifying and persisting it called Export.
Importing a motor
When the project is started for the first time, there would be no motor selected. Users have to click on the Import Motor button to select one of the exported motors or one of the
motorBench® Development Suite standard motors.
Begin by importing an existing motor. Clicking the 'Import Motor' button automatically takes you to the location on your machine where the default motors are stored.
Select your desired motor, and click 'Open'. The motor will be imported into motorBench® Development Suite.
motorBench® Development Suite is now ready to generate code. If you don't have any modifications to make to the project, you can generate code.
Exporting a motor
Once you have imported an existing motor, you may choose to change its parameter values.
All the motor parameters currently displayed in the composer view are editable, except the 'Measured Values' column in the 'Electrical and Mechanical Parameters' section. 'Measured
Values' are automatically calculated by the motor parameter measurement process discussed separately.
All numeric values are shown in Engineering Notation, but if you hover over them, you will be able to see their exact 'double' representations. This is the value that you will be editing.
Currently, we only support entering motor values in the units shown by default beside each parameter.
If you want to save the changes that you made to the motor parameters, you have two choices -
1. If you exit MCC, MPLAB X, or close the project, you will be asked whether you want to save the current MCC configuration. If you click 'Yes', all the changes will be preserved for
this project. The next time you open MCC for this project, you will find all your values intact. This will not export the motor file.
2. If you want to use your motor parameters for other/new projects, you can choose to export the motor. Clicking the 'Export Motor' button will bring up a dialog box that will allow you
to create your own motor with a new name. In a different project, you may choose to import this file instead of the default files provided with this installation.
Motor parameter measurement
After importing a motor, click on the "Measure Now" button in the Motor's Electrical and Mechanical Parameters group to open up the motor parameter measurement window.
1. Before you begin measurement, make sure that you have selected an ICD tool and a compiler.
2. Select the appropriate COM port from the combo-box. If you are unsure of the right COM port, you can look under the ‘Ports (COM & LPT)’ list in the Device Manager on
Windows, or type “ls /dev/*” on Mac. If you connected the board and ICD tool after you landed on the Measure page, you would want to hit ‘Refresh’ to update the list of COM
ports.
3. Acknowledge the heat-warning. You will not be able to proceed without it.
Location of default motors on Windows
C:\Users\<username>\.mcc\libraries\<versioned motorBench® Development Suite folder>\motors
Motor and your project
Note that once you import a motor into motorBench® Development Suite, there is no link between your project, and the file from which it was imported. You can see the file from
which the motor was imported in the 'Output - MPLAB® Code Configurator' window, but any changes you make are local to your project and do not affect the file.
Note that only the 'Active Values' in the 'Electrical and Mechanical Parameters' section are exported. 'Measured Values' cannot be exported. Measured values will, however, be
preserved for that specific project. If you have measured values generated by the motor parameter measurement process, you may choose to copy them to the 'Active Values'
column by clicking the or 'Use all' buttons.
Editing exported files
We do not recommend manually editing exported files. Using the UI to export motors is the best way of making any changes to the parameters you desire. If you still do edit the
file manually, there is a possibility that importing that motor into a project might fail without any warning or notification.