AnsweredAssumed Answered

MCUs and MATLAB / Simulink

Question asked by phil74 Employee on Jan 31, 2019
Latest reply on Jan 31, 2019 by dumitru-daniel.popa



We are currently in the process of setting up a development platform (consisting of MCU Eval Kit, motor driver, motor and encoder) for a field-oriented control (FOC) of a stepping motor (NEMA 8).

The following chip fits very well for our requirements:
Kinetis KV4x-168MHz High Performance Motor / Power Conversion MCUs based on Arm® Cortex®-M4
We use the following Eval Kit: TWR-KV46F150M: Kinetis KV4x Family Tower System Module

The FOC is created in Simulink and then played on the target platform (TWR-KV46F150M - Kinetis KV4x Family) using the Motor Control Toolbox for Kinetis V Series.

Previous experience:
- Using MATLAB 2017b, a hotfix (see had to be run first to use the "Motor Control Toolbox for Kinetis V Series".
- Unfortunately, only the commercial compiler from IAR Systems works to generate executable code for the target platform. The GCC compiler does not work as expected despite the hotfix (see Meaning that the generated code can not be played on the target platform.
- It seems (my judgment) as if no further developments for the "Motor Control Toolbox for Kinetis V Series" are planned for MATLAB / Simulink. By comparison, the equivalent "Model-Based Design Toolbox" for the S32K144 Evaluation Board is always kept up to date.
- Currently we are able to load the generated code directly to the target platform via OpenSDA. However, we have not been able to present the signals in Simulink in real time, for example with scopes. For this it would have to be possible to switch to the external or the processor in the loop (PIL) mode.

I would be interested to know if, according to their experience, there are alternative MCUs that can be used in combination with MATLAB / Simulink.