| Products & Services | Solutions | Academia | Support | User Community | Company |
| Download Product Updates | | | Get Pricing | | | Trial Software |
| Documentation → SimEvents |
| Contents | Index |
| Learn more about SimEvents |
Customize debugger simulation log in discrete-event simulation
detail('none')
detail('default')
detail('all')
prev = detail(...)
detail(struc)
detail(paramname1, paramvalue1, paramname2, paramvalue2,...)
detail
curr = detail
detail('none') configures the debugger to omit all simulation log messages, except upon reaching breakpoints. This syntax is the same as detail('en',0,'ev',0,'cal',0). You cannot use the step function to step to anything other than breakpoints when the debugger omits all simulation log messages.
detail('default') resets the detail settings to their default values. This syntax is the same as detail('en',1,'ev',1,'cal',0).
detail('all') configures the debugger to show all simulation log messages. This syntax is the same as detail('en',1,'ev',1,'cal',1).
prev = detail(...) configures the debugger based on the inputs, and also returns a structure that describes the previous detail settings.
detail(struc) uses the structure struc to establish detail settings.
detail(paramname1, paramvalue1, paramname2, paramvalue2,...) configures the debugger to show or omit certain kinds of messages in the simulation log. You can specify one, two, or three pairs of parameter names, paramnameN, and parameter values, paramvalueN.
detail displays the current detail settings.
curr = detail returns a structure that describes the current detail settings.
paramnameN |
Name of detail setting.
| ||||||
paramvalueN |
Value of detail setting.
| ||||||
struc |
Structure having three fields describing the detail settings that you want. Field names are the same as the names in the table that describes the paramnameN input. Field values are the same as the values in the table that describes the paramvalueN input. |
curr |
Structure that describes the current detail settings. Field names are the same as the names in the table that describes the paramnameN input. Field values are the same as the values in the table that describes the paramvalueN input. |
prev |
Structure that describes the previous detail settings before changing them. Field names are the same as the names in the table that describes the paramnameN input. Field values are the same as the values in the table that describes the paramvalueN input. |
Configure displays for breakpoints and stepping:
Begin a debugger session for a particular model. At the MATLAB command prompt, enter:
sedebug('sedemo_timeout')Proceed in the simulation, suppressing the simulation log until the debugger reaches a breakpoint. At the sedebug>> prompt, enter:
tbreak 2
prev = detail('none')
contThe output ends with the context of the simulation at T=2:
Set b1 : Breakpoint for first operation at or after time 2.000000
prev =
ev: 1
en: 1
cal: 0
Hit b1 : Breakpoint for first operation at or after time 2.000000
%==============================================================================%
Executing EntityGeneration Event (ev10) Time = 2.000000000000000
: Entity = <none> Priority = 1
: Block = Time-Based Entity GeneratorNow that the simulation is at a point of interest, configure the debugger to show the simulation log. This configuration makes subsequent step operations more informative. Then move forward in the simulation:
detail(prev) step over
The output confirms the change in detail settings and then shows the result of enabling the simulation log:
Event Operations (ev) : on
Entity Operations (en) : on
Event Calendar (cal) : off
%..........................................................................%
Generating Entity (en4)
: Block = Time-Based Entity Generator
%..........................................................................%
Entity Advancing (en4)
: From = Time-Based Entity Generator
: To = Schedule Timeout
%..........................................................................%
Scheduling Timeout Event (ev11)
: EventTime = 3.000000000000000
: Priority = 1700
: Entity = en4
: Block = Schedule Timeout
%..........................................................................%
Entity Advancing (en4)
: From = Schedule Timeout
: To = Infinite Server
%..........................................................................%
Scheduling ServiceCompletion Event (ev12)
: EventTime = 2.581301297500028
: Priority = 1
: Entity = en4
: Block = Infinite Server
%..........................................................................%
Scheduling EntityGeneration Event (ev13)
: EventTime = 2.500000000000000
: Priority = 1
: Block = Time-Based Entity Generator
%==============================================================================%
Executing Timeout Event (ev5) Time = 2.000000000000000
: Entity = en2 Priority = 1700
: Block = Infinite ServerEnd the debugger session. At the sedebug>> prompt, enter:
sedb.quit
sedb.cont | sedb.evbreak | sedb.tbreak
![]() | sedb.currentop | sedb.disable | ![]() |

Learn more about Simulink through this collection of videos, articles, technical literature and the Getting Started with Simulink Guide.
| © 1984-2009- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |