Code covered by the BSD License  

Highlights from
Export a complete simulink diagram

4.0

4.0 | 2 ratings Rate this file 22 Downloads (last 30 days) File Size: 1.9 KB File ID: #35751

Export a complete simulink diagram

by

 

This function exports an image for every subsystem in your model. Eps, png, etc

| Watch this File

File Information
Description

This function goes through your model, and exports every subsystem to a separate image. This is very handy when writing reports, you can have your script update your figures-folder for your TeX file automatically.

It can also be used together with the "LaTeX publish" option in Matlab.

When the second argument is 1 (boolean true), the function generates a file called simulink_images.m, which includes your images for you. Just run this file at the end of the file your wish to publish.

Hope somebody else find this useful, comments are appreciated

Required Products Simulink
MATLAB release MATLAB 7.11 (R2010b)
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (4)
06 Jul 2012 Daniel Armyr

My bad. Works now :D

05 Jul 2012 Kristian

Hello, thanks for your reply!

I can't seem to reproduce your error.
I downloaded this file, created a simple .mdl file, and executed my script with print_simulink('myModel'); The images where exported as expected.

What system are you on (win, *nix), and which Matlab Version?

I hope we can get it working for you :)

03 Jul 2012 Daniel Armyr

Oh, the error was on line 30. Forgot to say that.

03 Jul 2012 Daniel Armyr

Tried to use this very nifty function, but I get an error. I have a model called temp.mdl. I run your function like so:
>>find_system( 'temp.mdl' )
And I get the following error:
"Error in specification of object or property name and value pairs"

Contact us