Skip to Main Content Skip to Search
Home |   Select Country  Choose Country  |  Contact Us  |  Cart Store 
Create Account | Log In
Products & Services Solutions Academia Support User Community Company
spacer spacer spacer spacer spacer spacer

Technical Solutions

How do I measure the code coverage in code generated from Real-Time Workshop® Embedded Coder?


Date Last Modified: Friday, June 26, 2009
Solution ID:   1-4ZHM02
Product:   Real-Time Workshop; Simulink; Stateflow; Stateflow Coder; Real-Time Workshop Embedded Coder
Reported in Release:   R2006a
Platform:   All Platforms
Operating System:   All OS
 

Subject:

How do I measure the code coverage in code generated from Real-Time Workshop® Embedded Coder?

Problem Description:

I generate code from my application model using Real-Time Workshop®. I want to find out the line coverage for the generated code using my Simulink test harness model.

Solution:

An example of determining the code coverage for generated code can be found at the link below. The example measures C statement coverage in code built as a Real-Time Workshop S-Function.

http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=14284

Note that The MathWorks does not guarantee or warrant the use or content of MATLAB Central submissions. Any questions, issues, or complaints should be directed to the contributing author.

In addition, model coverage can be obtained using Simulink® Verification and Validation:
http://www.mathworks.com/products/simverification/

 

Related Solutions:

Please provide feedback to help us improve this Solution
Contact support
E-mail this page
Print this page