Main Content

stopProfiler

Stop profiling service on target computer

Since R2020b

Description

example

stopProfiler(target_object) stops the profiler from running on the target computer.

If the profiler collected data, the data is available for download to the development computer.

If the profiler did not collect data, the profiler is ready to restart.

If you stop execution of the real-time application, the profiler stops.

When the profiler starts and stops, there is an increase in task execution time (TET) that can cause a CPU overload condition. If using profiler causes CPU overload, you can increase the sample time in order to use the profiler.

Examples

collapse all

Start the profiler, and then start the real-time application. After collecting execution profile data, stop the profiler.

  1. tg = slrealtime('TargetPC1');
    slbuild('slrt_ex_mds_and_tasks');
    load(tg,'slrt_ex_mds_and_tasks');
    startProfiler(tg);
    
    % start profiler before starting application
    
    start(tg);
    
    % let application run until its stop time
    % or stop the profiler by calling stopProfiler
    
    stopProfiler(tg);
  2. At this point, call either the getProfilerData function or the resetProfiler function.

Input Arguments

collapse all

Provides access to methods that manipulate the target computer properties.

Example: tg

Version History

Introduced in R2020b