How to enable "Log Event Sequence" option programatically

2 visualizaciones (últimos 30 días)
Yuvaraj S
Yuvaraj S el 17 de Ag. de 2022
Respondida: Yukthi S el 24 de Jul. de 2024
How do I enable the highlighted option programatically ?

Respuestas (1)

Yukthi S
Yukthi S el 24 de Jul. de 2024
To programmatically toggle Log Events option under PREPARE section of Simulink toolstrip, you can follow these steps. I am using SimpleMessageModel for reference given in the documentation.
1. Enter the following command in command window and open the example model
openExample('simulink/ModelMessageBasedCommunicationFrameworkExample')
2. Get the path name of the current system using gcs.
gcs
More about gcs in the documentation given below:
3. Check the current status of EventLogging parameter using
get_param(gcs,'EventLogging')
4. To enable Log Events, use
set_param(gcs,'EventLogging', 'on')
5. To disable it, use
set_param(gcs,'EventLogging', 'off')
Hope this helps!

Categorías

Más información sobre Programmatic Model Editing en Help Center y File Exchange.

Productos


Versión

R2021b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by