Documentation Home Page ◇ OPAL-RT Schematic Editor Home Page
Pour la documentation en FRANÇAIS, utilisez l'outil de traduction de votre navigateur Chrome, Edge ou Safari. Voir un exemple.
JMAG-RT RTT File Generation Recommendation for Use with OPAL-RT PMSM SH block
JMAG-RT Version
The JMAG-RT version to use for generating the RTT file is any version higher than JMAG-RT 10.5. No backward compatibility issues have been identified at this point.
What is an RTT file?
The RTT file contains electrical parameters that define the motor model. These parameters are calculated from the JMAG CAD design using Finite Element Analysis.
It can contain two sets of parameters:
- Parameters for the Spatial harmonics model (3D tables of Phase inductance, phase flux, and torque)
- Parameters for the Variable DQ model (2D tables of Ld Lq inductances and magnet flux, torque is computed using the textbook equation)
Generating the RTT-File for use With the OPAL-RT Simulator
Generate the right data
It is important to generate Spatial harmonics data or/and DQ data depending on the final use of the model. The advice would be to always generate both in order to avoid any issue in the future.
Spatial Harmonics Data Generation
Description
The tables available in the Spatial Harmonics format are displayed in the table below:
Description | Number of tables | Theta axis recommendation | Beta axis recommendation | lamp axis recommendation |
---|---|---|---|---|
Phase inductance | 9 | 65 samples or more [0 ... 180/Number Of Pole Pair] | 33 samples or more [0 ... 360] | 32 samples or more [0 ... 3*maximum peak phase current] |
Phase total flux | 3 | 129 samples or more [0 ... 360/Number Of Pole Pair] | 33 samples or more [0 ... 360] | 32 samples or more [0 ... 3*maximum peak phase current] |
Torque | 1 | 65 samples or more [0 ... 180/Number Of Pole Pair] | 33 samples or more [0 ... 360] | 32 samples or more [0 ... 3*maximum peak phase current] |
- Theta = mechanical angle of the rotor
- Beta = polar angle of the (Id,Iq) vector in the DQ reference frame. JMAG use the power invariant DQ transform convention with D axis aligned with A phase at theta = 0.
- Iamp = amplitude of the (Id, Iq) vector in the DQ reference frame.
Generation Recommendations
Number of samples
To obtain accuracy, it is important to have a sufficient number of samples per axis and to respect the recommendations above.
Axis boundaries
It is also important to respect the recommended boundaries of these axes since lack of table section may lead to unexpected model behavior.
The Spatial Harmonics PMSM model in particular can demonstrate noticeable stiffness if the currents exceed the axis limit and the LUT output is being saturated.
Use of phase symmetry
During the generation of the data, we recommend not using any symmetry options (generating a 3rd of the data since phase A is symmetrical in regards to B with a 120deg electrical difference).
It might be tempting to use this option to save generation time, but the OPAL-RT model does not support it. This is valid for inductance/flux and torque (slot symmetry for torque).
Table post-process performed by OPAL-RT's PMSM SH model implementation
Before simulation
Before the real-time simulation, since the FPGA size is limited, the OPAL-RT's PMSM block will reshape the RTT file table data to match the size reserved in the FPGA following the specification in the tables below.
The space reserved depends on the version of the PMSM SH block and the number of machine simulated in a FPGA model instance.
Table reshape method
The FPGA models expects equally spaced samples for each axis. Before the simulation, we perform an tri-linear interpolation on the user's table data to find the table for the FPGA. Since the samples are equally spaced the resolution can be found by dividing the maximum value of each axis by the number of samples that are used.
Single machine mode
The memory space of the PMSM model core is shared with the two machine models. When only one machine is used, the full size of the table is available to model the machine.
This table shows the default settings.
PMSM SH v2 | |||
---|---|---|---|
Axis | Theta (Electrical angle) | Beta | Iamp |
L | 65 samples per half-electrical turn (Resolution 2.77 deg) | 33 (Resolution 10.9 deg) | 32 (Resolution IampMax / 32 Amps) |
Flux | 65 samples per full-electrical turn (Resolution 5.54 deg) | 33 (Resolution 10.9 deg) | 32 (Resolution IampMax / 32 Amps) |
Torque | 65 samples per slot (1/6 of electrical turn) (Resolution 0.92 deg) | 33 (Resolution 10.9 deg) | 32 (Resolution IampMax / 32 Amps) |
PMSM SH v1 | |||
---|---|---|---|
Axis | Theta (Electrical angle) | Beta | Iamp |
L | 33 samples per half-electrical turn (Resolution 5.45 deg) | 33 (Resolution 10.9 deg) | 16 (Resolution IampMax / 16 Amps) |
Flux | 65 samples per full-electrical turn (Resolution 5.54 deg) | 33 (Resolution 10.9 deg) | 16 (Resolution IampMax / 16 Amps) |
Torque | 33 samples per half-electrical turn (Resolution 5.45 deg) | 33 (Resolution 10.9 deg) | 16 (Resolution IampMax / 16 Amps) |
Dual machine mode
We split the total allocated FPGA memory between the two machine model.
This table shows the default settings.
PMSM SH v2 | |||
---|---|---|---|
Axis | Theta (Electrical angle) | Beta | Iamp |
L | 33 samples per half-electrical turn (Resolution 5.45 deg) | 33 (Resolution 10.9 deg) | 32 (Resolution IampMax / 32 Amps) |
Flux | 33 samples per full-electrical turn (Resolution 10.9 deg) | 33 (Resolution 10.9 deg) | 32 (Resolution IampMax / 32 Amps) |
Torque | 33 samples per slot (1/6 of electrical turn) (Resolution 1.98 deg) | 33 (Resolution 10.9 deg) | 32 (Resolution IampMax / 32 Amps) |
PMSM SH v1 | |||
---|---|---|---|
Axis | Theta (Electrical angle) | Beta | Iamp |
L | 33 samples per half-electrical turn (Resolution 5.45 deg) | 17 (Resolution 21.17 deg) | 16 (Resolution IampMax / 16 Amps) |
Flux | 65 samples per full-electrical turn (Resolution 5.54 deg) | 17 (Resolution 21.17 deg) | 16 (Resolution IampMax / 16 Amps) |
Torque | 33 samples per half-electrical turn (Resolution 5.45 deg) | 17 (Resolution 21.17 deg) | 16 (Resolution IampMax / 16 Amps) |
During simulation
During the simulation, the tables are accessed using a 18bits Tri-linear interpolation. The effective resolution on a linear segment will be 1/2^18 * resolution values provided in the tables.
OPAL-RT TECHNOLOGIES, Inc. | 1751, rue Richardson, bureau 1060 | Montréal, Québec Canada H3K 1G6 | opal-rt.com | +1 514-935-2323
Follow OPAL-RT: LinkedIn | Facebook | YouTube | X/Twitter