Is it possible to generate a Matlab script from a Simulink model?

27 visualizaciones (últimos 30 días)
Hawkeye
Hawkeye el 8 de Mzo. de 2024
Comentada: Walter Roberson el 15 de Dic. de 2025 a las 19:55
Matlab provides a method for programmatically modifying or generating Simulink models ( https://www.mathworks.com/help/simulink/ug/approach-modeling-programmatically.html ).
I have a large collection of Simulink models that I would like to convert into scripts which, when executed, would then re-generate the orginal (or functionally equivalent) model. In effect, I want a way to seemlessly convert between .slx files and a text-based representation. Does Matlab provide a utility that does this?
  4 comentarios
Paul
Paul el 15 de Dic. de 2025 a las 14:37
Editada: Paul el 15 de Dic. de 2025 a las 18:08
Is the .mdl format still supported? I thought that format was just a text file. Maybe .slx can be converted to or saved as mdl?
Walter Roberson
Walter Roberson el 15 de Dic. de 2025 a las 19:55
Indeed, .mdl file format is still supported (as of R2025b.) And that might satisfy the need as expressed by @Richard Crozier . It is not really clear to me, though, whether or not that would satisfy the original request by @Hawkeye

Iniciar sesión para comentar.

Respuesta aceptada

Mark McBroom
Mark McBroom el 14 de Mzo. de 2024
There is no such utility to do this.

Más respuestas (0)

Categorías

Más información sobre Simulink Environment Customization en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by