vssSetOutputData
Set block's signal output.
Syntax
vssSetOutputData(block,varidx,out,datatype)
Inputs
- block
- Handle of the block used in the evaluation, compilation and simulation phases. The handle refers to an engine/core block structure.
- varidx
- Variable index according to the port number.
- out
- Output variable.
- datatype
- Datatype of the output. 1 is scalar or matrix, 2 complex and 9 is boolean.
Example
Set Position variable as the output data of the first port of an OML custom block, with the same datatype as the one from the first output port.
function OmlBlockFunction(block,flag)
...
vssSetOutputData(block,1,Position,vssGetOutputDataType(block,1));
end