I have a Stateflow Chart that has to be executed when either of my two/three function calls is made (I can alter the model to make sure only one function call happens at a time.)
From what I gathered till now from my online reading, a statechart can only have one input event port. So, I tried using a Mux (a Merge and a Bus Creator too) as suggested here. Might be because that functionality being discontinued in R2021a or so (I am not sure), I wasn't able to make it work still. The test model image below describes the logic that I am trying to create.
Both the enabled subsystems just outputs a continuous function call throughout their active period.
The error I received from the above model:
Port width mismatch. Chart is expecting input events signal of length 1. The actual input events signal has length 2.
Component: Simulink | Category: Model error
Error occurred in 'test/Chart1'.
Component: Simulink | Category: Model error
NB: The model I am building is bound to be auto-converted into C code (Embedded Coder). So do mention if any of the stuff mentioned here or those in your solution affects that.