How to rename bus objects in the model explorer?

6 visualizzazioni (ultimi 30 giorni)
I am working with multiple busses objects in order to have a bus creator with a variable number of inputs, so I wanted to alter the name of the resulting bus as I add new bus objects with the same atributes (being able to receive a variable number of inputs). I am working with PostSaveFcn so every time a new bus is added to the bus creator, a new bus object is created.

Risposte (1)

Jesús Zambrano
Jesús Zambrano il 5 Dic 2019
Hi Guilherme,
I'm not sure if I understood your question, but here I give you some hints of possible workflow to check:
When you create a bus in the MATLAB workspace, I guess you know that you can see it in the Model Explorer. Once in there, when selecting the bus, you can change the name of the bus and also you will see the "Launch Bus Editor" button on the right-hand side, where you can edit (add/remove elements of the bus, nest buses, etec.).
From the Bus Editor, you can save the bus in a .m or .mat file, and then call it from the model callback.
Hope this answer can help you to solve your question.
Best,
Jesús

Categorie

Scopri di più su Simulink Functions in Help Center e File Exchange

Tag

Prodotti


Release

R2017b

Community Treasure Hunt

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

Start Hunting!

Translated by