I am just not able to figure out how to proceed:
I am trying to build a model:
- It would have 4 Inputs ( Boolean i/p)
- It would have 1 output (Signed: 8 bit)
It would perform the following:
- Based on which input is 1, it would give a corresponding output reflecting the DataRate.
If I have to write in Matlab, I would write something like this :
if (portA==1)
PSDU_Data_Rate=1;
elseif(portB==1)
PSDU_Data_Rate=2;
elseif (portC==1)
PSDU_Data_Rate=5.5;
elseif(portD==1)
PSDU_Data_Rate=11;
end
I am attaching, the part of the model which I am developing for the same functionality:
Any idea on how to proceed or code correction or suggestion on how it can be improved would be really helpful.
Thanks