How do I have a Multicast tag in an Entity Multicast block that reads from a vector whose elements change over time rather than a fixed string?

1 view (last 30 days)
Striker121 on 24 Oct 2017
Answered: Julia Antoniou on 26 Oct 2017
Below I have attached a picture of the system I am trying to build. What I would like to achieve is the following:
I would like to send entities from the "Entity Multicast" block to one of two potential "Multicast Receive" blocks (which have tags "T1" and "T2" in the picture below).
I have declared a vector "ReworkTeamIDs" which changes over time during the simulation. It may be equal to the following at any given time: i) ["T1", "T2"], or ["T1"], or ["T2"]. The idea is that the "Entity Multicast" block would read the first entry of ReworkTeamIDs (ie ReworkTeamIDs(1,1)) and set that as the Multicast tag parameter. However, when I do this, I get the error seen in the screenshot below.
If there any way I can get the Multicast tag parameter to read from a vector which contains string elements that change over time? Any help would be greatly appreciated!
PS I run matlab 2017a

Answers (1)

Julia Antoniou
Julia Antoniou on 26 Oct 2017
I do not believe the "Entity Multicast" block can communicate with more than one "Multicast Receive Queue" block if those receivers have different tags. For example, in the MathWorks demo linked below, each transmitting block has its own receiving block. The multicast blocks in this example are within the blue "CAN" subsystems.

Community Treasure Hunt

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

Start Hunting!