Challenge

Project 1 - Wiper control system and Vehicle speed calculation for ABS using Wheel Speed sensor

1)Ans:

Main Model:

SLDD file:

Requirement Tagging:

We can see the Requirement Tagging in Report:

Report:

JMAAB check:

Fixed Point Tool:

After the data type will be changed

MIL & SIL Functional Test cases:

MIL Harness:

Signal Builder Output:

Scope Output:

Coverage:

SIL Harness.

At first Build the model , and generate .mex file. to Build the model. now select the coding option as embedded coder.

Scope Output:

SIL Coverage:

SLDV Report And Analysis:

Click on Run button , which gives design verifier as compatible.

Now select the Test Generation Mode:

Advisor Report:

Auto Code Generation:

Polyspace Bug report:-

As we dont have the polyspace licence, only steps to find out the polyspace bug finder report is written below.

Polyspace Bug Finder is a static code analysis tool that can help you identify potential bugs in your MATLAB code. To generate a Polyspace Bug Finder report, you can follow these steps:

  1. Open MATLAB and navigate to the directory where your code is located.

  2. Open the Polyspace Bug Finder interface by typing "polyspace" in the MATLAB command window.

  3. In the Polyspace Bug Finder interface, select "Create New Project" and give your project a name.

  4. Select "MATLAB" as the programming language for your project.

  5. In the "Project Settings" window, select the files you want to analyze and specify any additional analysis options.

  6. Click "Run Analysis" to start the analysis process.

  7. Once the analysis is complete, Polyspace Bug Finder will generate a report that lists any potential bugs it has identified in your code.

  8. To view the report, select "View Report" in the Polyspace Bug Finder interface.

  9. The report will display a list of potential bugs, along with detailed information about each bug and recommendations for how to fix it.

  10. You can save the report in various formats, such as PDF, HTML, or XML, by selecting "Export Report" in the Polyspace Bug Finder interface.

  11. Review the report and fix any potential bugs identified by Polyspace Bug Finder to improve the quality and reliability of your MATLAB code.

Polyspace code prover output:-

Polyspace Code Prover is a static analysis tool that can help you verify the absence of run-time errors in your MATLAB code. To generate a Polyspace Code Prover output, you can follow these steps:

  1. Open MATLAB and navigate to the directory where your code is located.

  2. Open the Polyspace Code Prover interface by typing "psrun" in the MATLAB command window.

  3. In the Polyspace Code Prover interface, select "Create New Project" and give your project a name.

  4. Select "MATLAB" as the programming language for your project.

  5. In the "Project Settings" window, select the files you want to analyze and specify any additional analysis options.

  6. Click "Run Analysis" to start the analysis process.

  7. Once the analysis is complete, Polyspace Code Prover will generate an output that indicates whether your code is free of run-time errors.

  8. To view the output, select "View Results" in the Polyspace Code Prover interface.

  9. The output will indicate whether your code is free of run-time errors or if any errors were detected.

  10. You can save the output in various formats, such as PDF, HTML, or XML, by selecting "Export Results" in the Polyspace Code Prover interface.

  11. Review the output and address any errors identified by Polyspace Code Prover to ensure the correctness and reliability of your MATLAB code.

Baseline and BacktoBack Test:-

Go to apps and click apps-> simulink test->Test Manager

BaseLine Report:

Back to Back Testing:

To select the Test for Model component

Report:

2.Vehicle speed calculation for ABS using Wheel Speed sensor:

Aim : Develop Simulink/state flow model for the vehicle speed calculation unit inside the ABS system for the below conditions.

1) Simulink Model :

Subsystem:

Simulink DataDictionary:

3)Requirement Tagging:

Create the Functional and SwReq into the .xls files.

Linking the Requirement:

Requirement Report:

4)Model Advisor JMAAB Report:

5) Fixed-Point Tool :

Run the model Error Free then Goto the >> App>> Click on the Fixed point Tool.

Simulink Model :

6) SLDV Design Error Detection Report :

Goto the Model >> Click on the App>> Select the Design Verifier >> Design Error Detection>> Design Error Detection Setting.

Simulink Model :

7) Functional Test Cases, MIL,SIL Harness, Coverage Report :

Functional Test cases:

MIL Model:

Signal Builder:

MIL Scope Output:

MIL Coverage Report:

SIL Model:

SIL Output:

SIL Coverage Report:

code generated after running the model:

8)SLDV Test Generation Report:

9):Advisor Report:

10) Polyspace Analysis Report/Output :

Procedure to Analysis the Polyspace Report

Bug Finder :

  • Firstly Generated the .C code
  • Initially, open the Polyspace in that new project click on start new project.
  • The Project Properties dialogue box will open in that give the project name as we saved in the MATLAB,then select the location where it we need to save after that click Next or use the default location.
  • Then ,it asks for the Projrct source,click on browserand select the folder where th .c file are generated then optionally we can add the include folder then clock on finish,the polyspace environment will open.
  • In the configuraton settings option called Target & compiler select the source code language as c,change the target processor as X86_64.
  • In the coding standards & code Metrics in that enable the check MISRA C:2004 also select the calculate the code metrics option
  • After that go to bug finder analysis under that select the default one.
  • Go to reporting enable the generate report option and ouput formet as PDF or any file we need
  • Finally save the polyspace and run the Bug Finder.

Code Prover :

  • Befour going to the Code Prover First setup the Configration setting.
  • In Configuration go to the Code prover verification and under code prover verification option.
  • Click on the Check Behavior and Enable the option (i,e Allow Negative Operand for left shifts).
  • and also click on the Consider Non-Finite floats.
  • Then After you go to the Precision
  • In Precision Select the Precision level -2 and Verification Level is Software Safety Analysis Level-2.
    then After Click on Save Botton the Configration setting will be save.
    then After We Run the Code Prover.
  • And After Click on the Dashboard option and see the Results.

12) Test Manager Report-Baseline & Back to Back Testing :

Baseline Testing :

Run the model>> goto the Simulink Test >>Click on the Simulink Test Manager >> then Click on New >> Test File>> Create Test Name.

BACK TO BACK Testing:

Your portfolio, next

Ship work like this
in your own course.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.