0

In the first part of my Simulink model I created a bus array as described in the official documentation from n separate, but equally defined busses.

For the second part I need to get one of the bus signals from each bus in the array. I managed to do so with a MATLAB Function block by iterating through the array elements and copying the data to new arrays. Unfortunately I have to implement it without MATLAB Function blocks.

Is there a way to extract a single signal from all n busses in the bus array without using n selector blocks like in the documentation (image below: Selector4 and Selector5)?

Consider n arbitrarily large so that an implementation with selector blocks is unacceptable.

MATLAB Documentation

asked Jun 22, 2018 at 10:25

1 Answer 1

0

I found a solution myself. It is possible to put a bus selector inside a For Each subsystem:

enter image description here

This will result in n-dimensional output arrays.

answered Jun 22, 2018 at 13:13
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.