<< init_buff Data Buffers HIDAPI Library >>

USB Comunication Toolbox for Scilab >> Data Buffers > setBuffValue

setBuffValue

Set specific position of a buffer of data unsigned integer of 8 bits

Calling Sequence

_oBuff=setBuffValue(_iBuff,pos,value)

Parameters

_inBuff
: Input buffer. The type of the buffer has to be unsigned integer of 8 bits
pos
: Position in the buffer to be set.
value
: Value to set
_oBuff
: Output buffer with the data in the position pos set with value. The _oBuffer can be the same of _iBuffer.

Description

Set specific position of a buffer of data unsigned integer of 8 bits

This rutine its a scilab macro. The buffer is a matrix of 1 rows and n columns.

Examples

n=5;
txBuff=init_buff(n);
for i=1:n
    txBuff=setBuffValue(txBuff,i,i);
end
disp(txBuff);

See Also

Authors

<< init_buff Data Buffers HIDAPI Library >>