Filter löschen
Filter löschen

how do I "cast" the output of a find entity block in simevents?

1 Ansicht (letzte 30 Tage)
Javier Baliosian
Javier Baliosian am 17 Okt. 2018
Beantwortet: Krishna Akella am 4 Dez. 2018
I am using the Find Entity block from SimEvents. from my model I am sure about which Entity Type the block will extract so I want to use the found entity after is found. However, if I connect it to a input switch, it complains with an error message "All input ports of block 'xxxx/Entity Input Switch' must have the same entity structure."

Antworten (1)

Krishna Akella
Krishna Akella am 4 Dez. 2018
Hi Javier,
I am not sure what is causing the error. If all the inputs coming to your 'Input Switch' block are of the same type, then you should not see this error. To ensure that entities are of the same type, you have to give them the same 'Entity type name' to all of them and they all should have the same attributes.
Please see the attached model, where I have the 'Entity Find' block that outputs the extracted entities to an 'Input Switch'. Both the extracted entities and the other stream of entities going to the Input Switch are of type 'Entity'. You can see the output type of the blocks by going to the menu bar and turning on 'Display' -> 'Signals & Ports' -> 'Port Data Types'.
- Krishna

Kategorien

Mehr zu Discrete-Event Simulation finden Sie in Help Center und File Exchange

Produkte


Version

R2018b

Community Treasure Hunt

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

Start Hunting!

Translated by