NXP Model-Based Design Tools Knowledge Base

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

NXP Model-Based Design Tools Knowledge Base

Discussions

Sort by:
This page summarizes all Model-Based Design Toolbox topics related to the S32K3 Product Family. Model-Based Design Toolbox for S32K3 - Release Notes: Rev 1.6.0 - Model-Based Design Toolbox for S32K3 Automotive MCU rev 1.6.0   Rev 1.5.0 - Model-Based Design Toolbox for S32K3xx Automotive MCU rev 1.5.0   Rev 1.4.0 - Model-Based Design Toolbox for S32K3xx Automotive MCU rev 1.4.0  Rev 1.3.0 - Model-Based Design Toolbox for S32K3xx Automotive MCU rev 1.3.0  Rev 1.2.0 - Model-Based Design Toolbox for S32K3xx Automotive MCU rev 1.2.0   Rev 1.1.0 - Model-Based Design Toolbox for S32K3xx Automotive MCU rev 1.1.0  Rev 1.0.0 - Model-Based Design Toolbox for S32K3xx Automotive MCU rev 1.0.0 
View full article
    Product Release Announcement Automotive Processing NXP Model-Based Design Toolbox for S32K3xx – version 1.0.0 RTM       The Automotive Processing, Model-Based Design Tools Team at NXP Semiconductors, is pleased to announce the release of the Model-Based Design Toolbox for S32K3xx version 1.0.0. This release supports automatic code generation for S32K3xx peripherals and applications prototyping from MATLAB/Simulink for NXP S32K3xx Automotive Microprocessors. This new product adds support for S32K344 MCU and part of its peripherals, based on RTD MCAL components (ADC, PWM, MCL, DIO, CAN, SPI, GPT). It also adds support for FreeMASTER, AMMCLib, and Simulink simulation modes – Software-in-Loop, Processor-in-Loop, and External mode. Moreover, this release adds the option to configure everything (pins/peripherals/clock) via an external configuration tool - S32 Configuration Tools or EB Tresos. The product comes with over 70 examples, covering everything that is supported, including a motor control application demo. FlexNet Location: https://nxp.flexnetoperations.com/control/frse/download?element=12747097 Technical Support: NXP Model-Based Design Toolbox for S32K3xx issues will be tracked through the NXP Model-Based Design Tools Community space. https://community.nxp.com/community/mbdt   Release Content Automatic C code generation from MATLAB® for NXP S32K3xx derivatives: S32K344 Support for the following peripherals (MCAL components): ADC PWM MCL CAN SPI GPT DIO Support for profiling execution times Support for register R\W and memory R\W operations Provides 2 modes of operation: Basic User Mode – using pre-configured configurations for peripherals; useful for quick hardware evaluation and testing Advanced User Mode – using S32Configuration Tool or EB Tresos to configure peripherals/pins/clocks Integrates the Automotive Math and Motor Control Library release 1.1.24 for: All functions in the Automotive Math and Motor Control Functions Library v1.1.24 are supported as blocks for simulation and embedded target code generation.   FreeMASTER Integration We provide several Simulink example models and associated FreeMASTER projects to demonstrate how our toolbox interacts with the real-time data visualization tool and how it can be used for tuning embedded software applications.   Support for MATLAB versions We added support for the following MATLAB versions: R2020a R2020b R2021a S32Design Studio Integration We added a simple mechanism to provide users the opportunity to export the generated code from Simulink and import it directly into S32Design Studio. This functionality can be useful if the model needs to be integrated into an already existing project, as well as for debugging purposes.   Simulation modes: We provide support for the following simulation modes (each of them being useful for validation and verification): Software-in-Loop (SIL) Processor-in-Loop (PIL) External mode   Examples for every peripheral/function supported: We have added over 70 new examples, including: Motor control application Communication (SPI, CAN) AMMCLib Timer control (GPT) DIO FreeMASTER SIL / PIL / External mode MATLAB® Integration The NXP Model-Based Design Toolbox extends the MATLAB® and Simulink® experience by allowing customers to evaluate and use NXP’s S32K3xx MCUs and evaluation board solutions out-of-the-box with: NXP Model-Based Design Toolbox for S32K3xx version 1.0.0 is fully integrated with MATLAB® environment in terms of installation: Target Audience This release (1.0.0) is intended for technology demonstration, evaluation purposes, and prototyping S32K3xx MCUs and Evaluation Boards.    Useful Resources Examples, Training, and Support: https://community.nxp.com/community/mbdt    
View full article
This page summarizes all Model-Based Design Toolbox tutorials and articles related to i.MX RT Product Family Facial Recognition Application in Co-Simulation mode for IMXRT117X Sensor application for IMXRT1060
View full article
This page summarizes all Model-Based Design Toolbox videos related to i.MX RT Product Family
View full article
Introduction This article is going to show how to use the IMXRT117X board in co-simulation mode to run a Deep Learning application of facial recognition. Given that a development board has limited resources, the deployment of a Deep Learning application should be done as efficiently as possible. For now, since the latest version of Matlab (2021a) does not offer support for CNN optimization for Arm Cortex-M processors, we will restrict to developing an application in co-simulation mode. That means that while the data will be provided by the target board, the actual processing will take place in a Matlab environment. By running in co-simulation mode, we will exploit both hardware and the Matlab software capabilities.  The goal of this article is for the user to be able to: use a pre-trained CNN model from Matlab; use the MBDT IMXRT Board Object for co-simulation; develop a standard facial recognition application; Hardware overview For the development of this application, the i.MX RT1170 Evaluation board was used with a MIMXRT1176 CPU, and the attached ON Semiconductor OV5640 camera. Additionally, the RK055AHD091 LCD panel can be used to visualize the frames from the camera. The i.MX RT1170 EVK provides a high-performance solution in a highly integrated board. It consists of a 6-layer PCB with through hole design for better EMC performance at a low cost, and it includes key components and interfaces. Some of the i.MX RT1170 EVK main features are: MIPI camera sensor connector and MIPI LCD connector JTAG connector and On-board DAP-Link debugger Connectivity: 2x Micro-USB OTG connectors, Ethernet (10/100/1000M) connector, Ethernet (10/100M) connector, SIM card slot, CAN transceivers 5V Power Supply connector For a more comprehensive view and a more detailed description regarding hardware specifications and user guides, please check the documentation here. For this example, we are going to make use of the following peripherals and components hence make sure you have all of them available and you are familiar with their intended scope: ON Semiconductor OV5640 camera used for capturing the frames from the board; A CAT-5 ethernet cable will be used for getting video frames from the IMXRT on-board camera to be processed in MATLAB; Mini/micro USB cable for downloading the executable on the target; (Optional, if LCD is used) 5V power supply Software overview Software delivered by MathWorks: MATLAB (version 2021a) (we assume you have already installed and configure this). As a hint, please make sure the MATLAB is installed in a path with empty spaces; MATLAB Embedded Coder is the key component that allows us to generate the C code that will be cross-compiled to be executed on the target; Deep Learning Toolbox allows us to use pre-trained networks or re-train and re-purpose them for other scenarios; Image Processing Toolbox for preprocessing the images before training the network; Computer Vision Toolbox for performing face detection using the Viola-Jones algorithm; Software delivered by NXP: NXP MBDT IMXRT Toolbox as IMXRT embedded target support and plug-in for MATLAB environment to allow code generation and deployment. Make sure you install this toolbox in MATLAB 2021a. Deep Learning – Facial recognition Facial recognition is the process of verifying a person’s identity through their facial features in order to grant access to a service, application, or system. Recognition needs to be performed in 2 steps: 1) face detection – so identifying and isolating the face area from an image and 2) face recognition – analyzing the features of the image and classifying them. In this example, face detection is performed with the CascadeObjectDetector, from the Matlab Computer Vision Toolbox, which is based on the Viola-Jones algorithm, and face recognition will be performed with AlexNet, a pre-trained neural network specialized for object classification. source: https://test.neurohive.io/en/popular-networks/alexnet-imagenet-classification-with-deep-convolutional-neural-networks/ 1.Datasets In order to train the network for our application, custom datasets will need to be generated containing the faces of the people we want to recognize. A challenge that arises regarding the dataset are the changes that occur to a person’s appearance: during the day the mood of a person can change, which may affect their facial expressions; also, the lighting of the room can affect the features, by enhancing or diminishing them; nevertheless, the appearance of a person might vary depending on make-up, hairstyle, accessories, facial hair, etc. Thus, this is something that needs to be taken into consideration when creating the dataset used in training. A recommendation for better performance would be to take samples of a person's appearance multiple times during the day and in different lighting conditions. Another challenge is dealing with the category of unknown people since it is impossible to have and use a picture of every unknown person. A possible approach is to use a threshold value for classifying the pictures so that a person is accepted as “known” only over a certain probability.  Another solution would be to create an additional dataset for the “Unknown” category, which should contain various faces of different people. This way the model should be able to generalize and differentiate between known and unknown people. One of the datasets that can be used for this purpose is the Flickr-Faces-HQ Dataset (FFHQ) which contains over 70,000 images with a high variety in terms of ethnicity, age, emotions, and background. For this example, 6 classes were used, 5 of them representing known people and 1 for unknown people. In order to generate a dataset using the attached OV5640 camera, the Matlab client will connect to the Board Object on the target, it will request frames from the camera and it will save them as BMP files. %% Establish communication with the target board board_imxrt = nxpmbdt.boardImxrt('162.168.0.102', 'Video', 'GET'); %% Request frames from the camera and save them as bmp images count = 0; while (1) % Camera snapshot img = board_imxrt.step(); imwrite(img, [num2char(count) '.bmp']) end The next step is to extract the face area from an image and resize it to 227x227x3 so that it can be given as input to AlexNet. For that, we can create a directory with all the images that we want to train/test the network with and run the following script, which will perform face detection, then crop and resize the images to the desired dimensions. All the scripts and code snippets presented are also included in the attached archive. % Create Face Detector Object faceDetector = vision.CascadeObjectDetector; inputFolder = 'datastorage/to_process'; outputFolder = 'datastorage/processed/'; pictures = dir(inputFolder); for j = 3 : length(pictures) imgName = pictures(j).name; img = imread([inputFolder '/' imgName]); % Perform face detection bboxes = step(faceDetector, img); if(sum(sum(bboxes)) ~= 0) detectedFace = imcrop(img, bboxes(1, :)); % Resize image to fit AlexNet requirements detectedFace = imresize(detectedFace, [227 227]); imwrite(detectedFace, [outputFolder imgName]); end end       2.Training the network For training the network, we need to modify the output layer of the AlexNet network to match the number of classes we use, in this example 6. To improve the results for the case where we might not have enough input data, we can augment the images, and for that, we use the imageDataAugmenter from Matlab, where we set the images to be flipped horizontally and/or vertically, and rotated with a random angle between -90 and 90 degrees. This will help the model to avoid overfitting and generalize better. allImages = imageDatastore('datastorage', 'IncludeSubfolders', true,... 'LabelSource','foldernames'); % Split into train and validation sets [imgSetTrain, imgSetTest] = splitEachLabel(allImages, 0.7, 'randomized'); augmenter = imageDataAugmenter('RandXReflection', true,... 'RandYReflection', true,... 'RandRotation', [-90 90]); augimds_train = augmentedImageDatastore([227 227], imgSetTrain,... 'DataAugmentation', augmenter); augimds_test = augmentedImageDatastore([227 227], imgSetTest,... 'DataAugmentation', augmenter); Set the training options, these can be configured by the user as they wish, for this example, we have used a learning rate of 0.001 and batch size of 64, and have run the model for 7 epochs. opts = trainingOptions('sgdm', 'InitialLearnRate', 0.001,... 'Shuffle', 'every-epoch', ... 'MaxEpochs', 7, 'MiniBatchSize', 64,... 'ValidationData', augimds_test, ... 'Plots', 'training-progress'); trained = trainNetwork(augimds_train, layers, opts); save('trained_50_50_ep7_6classes', 'trained'); Save the trained network into a .mat file. It will be used for classifying the frames received from the camera. 3.Setup For the installation and usage of the MBDT IMXRT Toolbox please refer to this article. Running in co-simulation mode means that the target board is able to communicate with the host (in this case, Matlab) through the TCP/IP protocol, thus exploiting both hardware and Matlab software capabilities. The logic of the application is presented in the following figure: the attached camera will send the captured frames to the computer through an Ethernet connection; there, the frame will be processed using a Matlab script, which will perform Face detection and be further sent to the AlexNet trained classifier, which will return a label and the probability of that label being correct. Then, based on whether the person was recognized or not, a signal will be sent to the IMXRT board to toggle the USER LED. In order to create the executable that will act as the server part of our application, we will create a new Simulink model containing the IMXRT Board Object. For this example, the Board Object is sufficient for creating the co-simulation environment and running the application, for it makes use of both Camera and LWIP functionalities: The next step would be to configure the Board Object in order to be able to communicate with the host: open the Block Parameters window and input the IP address and port number you want to use. In the case of the server, it does not matter whether it is configured in SEND or GET mode, because it will wait for commands from the client. Then the model’s Ethernet parameters need to be configured. Open the Configuration Parameters window from Simulink, select Hardware Implementation from the left menu and then go to the Ethernet tab: here insert the values of the board IP address, subnet mask, and the gateway address.   Connect the board through USB to the computer. Go to the Download tab and select the drive you want to download the executable to. More information about this process is presented here. Also, please make sure that you have selected the NXP MIMXRT117Xxxxxx Hardware Board. The selection of the MIMXRT117X Hardware Board should copy the default ConfigTool MEX file which you can modify, but you can also create or use another MEX file as long as it has the name <model_name>_<core>Config.mex. In the MEX file are configured the peripherals and pins settings, in this case the Camera peripheral and the GPIO User LED. For better performance, we recommend using a low-resolution for the Camera. Build the model and the generated executable will be copied on the target board. Restart the board. Next step is to connect to the target board from Matlab and start receiving frames from the attached camera. For this, we will use a Matlab script that will create a board object configured to request frames from the target. The nxpmbdt.boardImxrt object is the same type as the one used in the previous Simulink model: here we can use it as a function call in a script, so we need to configure it accordingly. For information about how to use the Board Object, use the following command:  The Matlab script that will run in co-simulation and will connect to the target board: load trained_50_50_ep7_6classes.mat trained; faceDetector = vision.CascadeObjectDetector; board_imxrt = nxpmbdt.boardImxrt('162.168.0.102', ... 'Video', 'GET'); while (1) img = board_imxrt.step(); bboxes = step(faceDetector,uint8(img)); if (sum(sum(bboxes)) ~= 0) es = imcrop(img, bboxes(1,:)); es = imresize(es, [227 227]); [label, ~] = classify(trained, es); if ~strcmp(char(label), 'Unknown') board_imxrt.led_on(); else board_imxrt.led_off(); end else board_imxrt.led_off(); end end When running simulation mode from a Matlab script, please make sure that the configuration structure (the script mscripts\target\imxrt_code_gen_config) is configured accordingly with the desired hardware. After the application has received the camera frame from the board, it can start the preprocessing required for classification. We create a face detector object using the CascadeObjectDetector, to which we will input the camera frame and we receive in exchange the margins of the box where it detected a face. In the case a face was detected, we crop the image and resize it to 227x227x3, which is the size the AlexNet network requires, and we classify the image using the loaded model. The USER LED on the board will be switched on if the person was identified. The script also provides a Matlab UI Figure for better visualization.   Conclusions The NXP MBDT Toolbox provides a solution for developing Computer Vision applications targeted for Arm Cortex-M processors. This aims to be a temporary approach until the Matlab support required for generating CNN optimized C code is added.
View full article
1.  Introduction The NXP i.MX RT1xxx Toolbox enables automatic code generation for peripherals and applications prototyping from MATLAB/Simulink for NXP’s i.MX RT 117x, 106x & 101x Series of crossover MCUs. The toolbox can be installed from Matlab add-ons page:   The novelty of this NXP toolbox is the integration with MCUX Configuration Tool for platform initialization. This configuration tool is being leveraged for pins settings, clock configuration and peripheral initialization. The toolbox is also integrated with the MCU SDK and will use the SDK API for code generation. This article details the steps to start building new models and deploy them on the i.MX RT106x, i.MX RT1010 & i.MX RT 117x MCU, showcasing also the integration with the MCUX Configuration Tool. 2.  Start creating your model Below are the steps to start creating a Simulink model that will be deployed on the i.MX RT1xxx boards. Step 1: Better to start on clean so first lets create folder to be used as workspace and switch MATLAB current folder to point to this workspace location:   Step 2: Create a Simulink Blank Model.   Step 3: Save and name your new model (E.g. mytest.slx). Step 4 : Choose the NXP IMXRT hardware board from the Model Settings in the MODELING tab.         Step 4.1: Open  Model Settings -> Hardware Implementation menu         Step 4.2: Select the NXP target from Hardware Board. This selection should match the             evaluation kit you plan to test the code for. After the selection is made, press the Apply button. After the target is set, the workspace will be populated with new files and folders: A file with extension <model_name>Config.mex – this is the file created with MCUX Configuration Tool that is used for pins, clock, and peripherals initialization. This configuration file will have enabled the peripherals that are supported by the toolbox. Starting from this, the user can change the default configuration for any of the peripheral instances (add new instances, disable instances, etc.) and also any of the configured pins.   A folder with naming pattern <model_name>Config -  this folder will have a structure that is similar to the MCUXpresso IDE projects, and will contain the SDK files that are needed to build the model and generate a binary application that will run on the board. The user can now add Simulink blocks in the model from the NXP i.MXRT1xxx Simulink library from Simulink Library Browser:   Choose the desired block to add to the model:   Alternatively, if the user will add in his/her model a peripheral block without configuring the target, a default one will be set that the user can change it afterwards.  3.  Modify default platform initializations and settings values As mentioned at the beginning of this article, the platform initialization, including pins, clock and peripherals settings is done using the MCUX Configuration Tool. As seen in the previous chapter, when a Simulink model is being created with one of the NXP IMXRT targets, the workspace will be populated with a file having the extension .mex – this is the configuration file that will be used in the initialization code of the platform. The user has the option to modify the default selections found in the .mex file. For this, open any peripheral block within the model and press the Configure button. This action will open the MCUX Configuration Tool.   From MCUX Configuration Tool, the user can change default settings of the peripherals – enable or disable instances, from Pins view, it can configure/update pins settings of the platform. After the user is done with configuration in MCUX Configuration Tool, he/she must go back in Simulink and press the Update button in the same block, for the changes to be visible in Simulink also. The new initialization settings, will be included in the Build Model step. The Toolbox will trigger a code generation starting from the .mex file. The generated files will be saved in the <model_name>Config folder, in board folder.   Note, that is not a prerequisite for the user to have MCUX Configuration Tool installed, the toolbox incorporates all the tools that are need for the user to create, configure,  build and deploy the model.  The default MCUX Configuration Tool used can be changed from Model Settings/Hardware Parameters / Tools Path, and the user can provide his/her own installation of the tool. Same approach is used with the SDK platform. The toolbox incorporates the release version of the SDK for the IMXRT1xxx targets. Also this path can be changed by the user, but it must consider possible integration issues of the toolbox with the user specified SDK.     4.  Deploy on NXP Hardware After the Simulink model is completed, follows the build and deployment of the model on the target board. Before Build and Deploy, the user must set the download method of the application. Step 1: Select the Download method from Hardware Implementation in Model Settings.   The default Download method (without the need for additional software and/or hardware probes) is OpenSDA. For this, the user must select the Drive on his/her machine where the OpenSDA firmware of the board is mapped after the NXP evaluation board is plugged in via USB. Step 2: Build & Deploy Model Step 3: After the code is generated and downloaded on the board a window will pop up and tell you to restart the evaluation board. Restart the board and then press OK. Congratulations! You have successfully created and deployed your Simulink model to the hardware.
View full article
Speed up development time with NXP Model-Based Design Toolboxes
View full article
Product Release Announcement EDGE PROCESSING  NXP Model-Based Design Toolbox for i.MX RT Crossover MCUs – version 1.2.0     The Edge Processing Tools Team at NXP Semiconductors is pleased to announce the release of the Model-Based Design Toolbox for i.MX RT 1xxx Series version 1.2.0. This release supports automatic code generation for peripherals and applications prototyping from MATLAB/Simulink for NXP’s i.MX RT 117x, 106x & 101x Series of crossover MCUs.   NXP Download Location https://www.nxp.com/webapp/swlicensing/sso/downloadSoftware.sp?catid=MCTB-EX   MATHWORKS Download Location https://www.mathworks.com/matlabcentral/fileexchange/81051-nxp-support-package-imxrt1xxx   Version 1.2.0 Release Content Automatic C code generation based on MCUXpresso SDK 2.9.1/2.9.2 drivers and MCUXpresso Configuration Tools 9.0 initializations from MATLAB®/Simulink® for: i.MX RT 1176: MIMXRT1176DVMAA,MIMXRT1176AVM8A,MIMXRT1176CVM8A i.MX RT 1175: MIMXRT1175DVMAA,MIMXRT1175AVM8A,MIMXRT1175CVM8A i.MX RT 1173: MIMXRT1173CVM8A i.MX RT 1172: MIMXRT1172DVMAA,MIMXRT1172AVM8A,MIMXRT1172CVM8A i.MX RT 1171: MIMXRT1171DVMAA,MIMXRT1171AVM8A,MIMXRT1171CVM8A i.MX RT 1061: MIMXRT1061CVJ5A,MIMXRT1061CVL5A,MIMXRT1061DVJ6A,MIMXRT1061DVL6A i.MX RT 1062: MIMXRT1062CVJ5A,MIMXRT1062CVL5A,MIMXRT1062DVJ6A,MIMXRT1062DVL6A i.MX RT 1064: MIMXRT1064CVJ5A,MIMXRT1064CVL5A,MIMXRT1064DVJ6A,MIMXRT1064DVL6A i.MX RT 1011: MIMXRT1011CAE4A,MIMXRT1011DAE5A   Multiple options for configuration of MCU packages, Build Toolchain and embedded Target Connections are available via Simulink Model Configuration UI       Multiple MCU peripherals and Drivers supported. The following subsystems highlighted in red as supported in Simulink environments in various forms: blocks, files, options i.MX RT 117x derivatives   i.MX RT 106x derivatives i.MX RT 101x derivatives     Basic and Advanced Simulink Block configuration modes via MCUXpresso Configuration Tools 9.0 UIs for Pins, Clocks, and Peripherals       MATLAB/Simulink versions 2019a – 2021b are supported for Design, Simulation, Code Generation, and Deployment of applications on i.MX RT 117x,106x & 101x Series. Other i.MX RT devices will be supported in future versions of the toolbox. Support for Software-in-Loop (SiL), Processor-in-Loop (PiL), and External Mode; RTCESL – Real-Time Control Embedded Software Motor Control and Power Conversion Libraries (limited support designed for Motor Control applications). A future update will enhance the number of functionalities supported by Simulink.     Simulink Example library with more than 190 models to showcase various functionalities:   Integrated PMSM Motor Control Sensor/Sensor-less application for both IMXRT1060-EVK and IMXRT1170-EVK:     Target Applications with MATLAB/Simulink This release of the Model-Based Design Toolbox can be used to design, build, and test applications from multiple domains: INDUSTRIAL AC Meters Motion Control Robotics HMI SMART CITY/HOME Video Surveillance Identification Appliances Speakers   AUTOMOTIVE HVAC ECU     Target Audience This release is intended for technology demonstration, evaluation purposes, and prototyping for i.MX RT 1xxx MCUs and their corresponding Evaluation Boards: EVK-MIMXRT1170 EVK-MIMXRT1060 EVK-MIMXRT1064 EVK-MIMXRT1010   Useful Resources Examples, Training, and Support: https://community.nxp.com/community/mbdt Technical by System Tools: https://web.microsoftstream.com/channel/618ab630-c8da-4fa8-ade8-5aa70a353124    
View full article
Model-Based Design Toolbox supporting i.MX RT Crossover MCU. System modeling, simulations, automatic code generation, validation, and verification MATLAB & Simulink workflows are now available on the i.MX RT microcontroller by reusing MCUXpresso ecosystem: MCUXpresso SDK MCUXpresso Configuration Tool MCUXpresso IDE,GCC
View full article
Model-Based Design Toolbox supporting Kinetis-V Series. System modeling, simulations, automatic code generation, validation, and verification MATLAB & Simulink workflows are now available on the Kinetis V microcontrollers by reusing MCUXpresso ecosystem: MCUXpresso SDK MCUXpresso Configuration Tool MCUXpresso IDE,GCC
View full article
      Product Release Announcement Automotive Processing   NXP Model-Based Design Toolbox   for S12ZVMx – version 1.4.0     Austin, Texas, USA September 9, 2020 The Automotive Processing, Model-Based Design Tools Team at NXP Semiconductors, is pleased to announce the release of the Model-Based Design Toolbox for S12ZVMx version 1.4.0. This release supports automatic code generation for S12ZVM peripherals and applications prototyping from MATLAB/Simulink for NXP S12ZVMx Automotive Microprocessors. This new release adds extended MATLAB version support (R2015a-R2020a), integrates with AMMCLib v1.1.21, is compatible with MathWorks Automotive Advisory Board checks, adds over 50 new examples and more.   FlexNet Location: https://www.nxp.com/webapp/swlicensing/sso/downloadSoftware.sp?catid=MCTB-EX   Activation link: https://www.nxp.com/webapp/swlicensing/sso/downloadSoftware.sp?catid=MCTB-EX   Technical Support: NXP Model-Based Design Toolbox for S12ZVMx issues are tracked through NXP Model-Based Design Tools Community space. https://community.nxp.com/community/mbdt   Release Content Automatic C code generation from MATLAB® for NXP S12ZVMx derivatives: S12ZVM 32/L31/16: MC9S12ZVM16 MC9S12ZVML31 MC9S12ZVM32 S12ZVML/C 128/64/32: MC9S12ZVML32 MC9S12ZVML64 MC9S12ZVMC64 MC9S12ZVML128 MC9S12ZVMC128 S12ZVMC256: MC9S12ZVMC256   Integrates the Automotive Math and Motor Control Library release 1.1.21: All functions in the Automotive Math and Motor Control Functions Library v1.1.21 are supported as blocks for simulation and embedded target code generation for: Bit Accurate Model for 16-bit fixed-point implementation Bit Accurate Model for 32-bit fixed-point implementation Bit Accurate Model for floating-point single precision implementation             Extended support for MATLAB versions We extended support for our toolbox to cover a wider range of MATLAB releases – starting from R2015a and going up to R2020a. This way we want to avoid locking out users that have constraints regarding MATLAB versions. Motor control examples We have added new motor control examples – BLDC (closed loop) and PMSM (closed loop, sensorless):   MAAB Checks (MathWorks Automotive Advisory Board) The toolbox is compatible with MathWorks Automotive Advisory Board checks – reports can be generated from Model Advisor:   Updated examples: We have added over 50 new examples, including: Motor control (both BLDC and PMSM) AMMCLib GDU (Gate Drive Unit) Profiler For more details, features and how to use the new functionalities, please refer to the Release Notes document attached.   MATLAB® Integration The NXP Model-Based Design Toolbox extends the MATLAB® and Simulink® experience by allowing customers to evaluate and use NXP’s S12ZVMx MCUs and evaluation boards solutions out-of-the-box with: NXP Support Package for S12ZVMx  Online Installer Guide Add-on allows users to install NXP solution directly from the Mathwork’s website or directly from MATLAB IDE. The Support Package provide a step-by-step guide for installation and verification. NXP Model-Based Design Toolbox for S12ZVM version 1.4.0 is fully integrated with MATLAB® environment in terms of installation: Target Audience This release (1.4.0) is intended for technology demonstration, evaluation purposes and prototyping S12ZVMx MCUs and Evaluation Boards.   Useful Resources Examples, Trainings and Support: https://community.nxp.com/community/mbdt                                                    
View full article
This article details the TPL communication setup between S32K1xx boards and MC3377xBTPL Battery Cell Controllers.  It covers both hardware and software setup for the Battery Management System models designed using Model-Based Design Toolbox for battery packs of more than 14 cells in series.  At the end of this article, the user will be able to setup the Battery Cell Controller hardware and to design a Simulink model that reads the cell and pack voltages, current, temperatures and faults status. The measured values will be displayed on the host PC using FreeMaster. 
View full article
In the following articles, we are going to detail the capabilities of our BMS blocks and how to use them on the NXP battery cell controller DevKits.
View full article
Having fun with MBDT for MPC57xx 3.1.0 and MPC5744P for Xmas tree by controlling the lights and sounds
View full article
This video shows the overall motor control application developed with Model Based Design Toolbox. We are going to assemble all the blocks developed throughout this course and we will have the motor running under Speed Controller supervision. We also discuss about the FreeMASTER and you can easily create nice control panels for the applications and how you can validate the Speed Controller and overall Motor Control application. We discuss about: - Speed Controller implementation in Simulink for real time systems; - Motor and Inverter protection for over-current, over- and under-voltage; - FreeMASTER control panel using HTML and Java Script; - Various tests on the MPC5744P DevKit and MotorGD DevKit;   NOTE: Chinese viewers can watch the video on YOUKU using this link 注意:中国观众可以使用此链接观看YOUKU上的视频
View full article
Short unedited video - showing the Model Based Design at work on our custom demo platform created with the scope of supporting various scenarios testing.
View full article
Check this short video to see the cool stuff you can do with an S32K144 DevKit. NOTE: Chinese viewers can watch the video on YOUKU using this link 注意:中国观众可以使用此链接观看YOUKU上的视频
View full article
In this video we show the hall pattern identification procedure that can be applied to any motor in case you have no datasheet available. We will read the hall sensors outputs via the microprocessor and save the information for later use.   We show: - How to prepare the Hardware setup - How to go over each identification table - row by row - to apply DC voltage and rotate the rotor in different sectors 360 degrees. NOTE: Chinese viewers can watch the video on YOUKU using this link 注意:中国观众可以使用此链接观看YOUKU上的视频
View full article
This video is part of the https://community.nxp.com/thread/467938  Workshop module and shows how to implement a simple V/F (V/Hz) scalar control to spin the PMSM in open loop using Space Vector Modulation and trapezoidal speed profile.
View full article
In this video we discuss about how the motor phase commutation works. This is an essential topic to understand how the motor rotates based on 6-step commutation technique.   We discuss about: - How to build the commutation table based on hall pattern identification  - How to control the PWM sequence to implement a 6-step/trapezoidal commutation NOTE: Chinese viewers can watch the video on YOUKU using this link 注意:中国观众可以使用此链接观看YOUKU上的视频
View full article