Simulink.SimulationData.LoggingInfo
Signal logging override settings
Description
This object specifies a set of signal logging override settings.
Use a Simulink.SimulationData.LoggingInfo
object
to specify the signal logging override settings for a signal. You can use this object for the LoggingInfo
property
of a Simulink.SimulationData.SignalLoggingInfo
object.
Property Summary
Name | Description |
---|---|
Signal logging mode. | |
Source of signal logging name. | |
Custom signal logging name. | |
Use subset of sample points. | |
Decimation value ( | |
Limit number of data points to log. | |
Maximum number of data points to log ( |
Method Summary
Name | Description |
---|---|
Create a set of signal logging override settings for a signal. |
Properties
DataLogging
Signal logging mode.
Indicates whether logging is enabled for this signal.
logical value — {true} | false
RW
NameMode
Source of signal logging name.
Indicates whether the signal logging name is a custom name ('true'
)
or whether the signal logging name is the same as the signal name
('false'
).
logical value — true | {false}
RW
LoggingName
Custom signal logging name
The custom signal logging name to use for this signal, if the NameMode
property
is true
.
character vector
RW
DecimateData
Log a subset of sample points, selecting data points at a specified interval. The first sample point is always logged.
logical value — true | {false}
RW
Decimation
Decimation value (n
). If the DecimateData
property
is true
, then Simulink logs every n
th data point.
positive integer
RW
LimitDataPoints
Limit the number of data points to log.
logical value — true | {false}
RW
MaxPoints
Maximum number of data points to log (N
).
If the LimitDataPoints
property is true
,
then the set of logged data points includes the last N
data
points generated by the simulation.
positive integer
RW
Methods
LoggingInfo
Create a Simulink.SimulationData.LoggingInfo
object.
logging_info_object = Simulink.SimulationData.LoggingInfo() logging_info_object = Simulink.SimulationData.LoggingInfo(object)
object
A signal logging override settings object whose property values the constructor uses for the new
Simulink.SimulationData.LoggingInfo
object. The signal logging override object that you specify must be one of the following types of objects:Simulink.SimulationData.LoggingInfo
objectSimulink.LoggingInfo
object
logging_info_object
A
Simulink.SimulationData.LoggingInfo
object.
logging_info_object = Simulink.SimulationData.LoggingInfo()
creates
a Simulink.SimulationData.LoggingInfo
object that
has default property values.
logging_info_object = Simulink.SimulationData.LoggingInfo(object)
creates
a Simulink.SimulationData.LoggingInfo
object that
copies the property values from the signal logging override object
that you specify with the object
argument.
The following example creates a Simulink.SimulationData.LoggingInfo
object
with default settings, changes the DecimateData
and Decimation
properties,
and uses the object for the LoggingInfo
property
of a Simulink.SimulationData.SignalLoggingInfo
object mi
.
open_system(docpath(fullfile(docroot, 'toolbox', 'simulink', 'examples', 'ex_mdlref_counter_bus'))); open_system(docpath(fullfile(docroot, 'toolbox', 'simulink', 'examples', 'ex_bus_logging'))); log_info = Simulink.SimulationData.LoggingInfo(); log_info.DecimateData = true; log_info.Decimation = 2; mi = Simulink.SimulationData.SignalLoggingInfo('ex_bus_logging'); mi.LoggingInfo = log_info
Simulink.SimulationData.SignalLoggingInfo Package: Simulink.SimulationData BlockPath: 'ex_bus_logging' OutputPortIndex: 1 LoggingInfo: DataLogging: 1 NameMode: 0 LoggingName: '' DecimateData: 1 Decimation: 2 LimitDataPoints: 0 MaxPoints: 5000
Version History
Introduced in R2012b