set_io
Set or update Xcos block inputs and outputs
Syntax
[model, graphics, ok] = set_io(model, graphics, list(in, it), list(out, ot)) [model, graphics, ok] = set_io(model, graphics, list(in, it), list(out, ot), clkin, clkout) [model, graphics, ok] = set_io(model, graphics, list(in, it), list(out, ot), clkin, clkout, in_implicit, out_implicit)
Arguments
- model
Block scicos_model representing information passed to the simulation.
- graphics
Block scicos_graphics with graphical information used to display it.
- list(in, it)
define input port properties, where N is the input port count:
in: N-by-2 matrix, dimensions of the N-th input port.
it: N vector, Scilab type of the N-th input port.
- list(out, ot)
define output port properties, where N is the output port count:
out: N-by-2 matrix, dimensions of the N-th output port.
ot: N vector, type of the N-th output port.
- clkin
N vector where N is the clock input port count, index of each clock
- clkout
N vector where N is the clock output port count, index of each clock
- in_implicit
N vector where N is the input port count,
"I"
for implicit port,"E"
for explicit port.- out_implicit
N vector where N is the output port count,
"I"
for implicit port,"E"
for explicit port.
Description
Create or update block ports (through the model and graphics fields) with specified types, sizes. This function can be used to update all the port related properties of a block at once.
Example
blk = scicos_block(gui="MyBlock"); // set inputs to : // 1. double 2x2 matrix // 2. int32 scalar // set outputs to : // 1. double 2x1 vector [model, graphics, ok] = set_io(blk.model, blk.graphics, list([2 2 ; 1 1], [1 3]), list([2 1], 1)) blk.model = model; blk.graphics = graphics; blk
Report an issue | ||
<< scicosDiagramToScilab | Fonctions utilitaires Scilab | standard_define >> |