en ru

Docs

NAME

getSignals - read the signals from the abstract connectors

SYNOPSIS

function getSignals(connectorsId, baseIndex, count);

DESCRIPTION

The function is used to read the signals from the abstract connectors with id connectorsId. Argument count determines how many connectors will be examined, starting from baseIndex.

RETURN VALUES

getSignals returns an array of count values.

EXAMPLES

A simple case:

connectors = createAbstractConnectors(5);
setSignals(connectors, 0, {0.0, 2.0, 5.5, 1.0, 7.0});
signals = getSignals(connectors, 3, 0); -- {}
signals = getSignals(connectors, 0, 2); -- {0.0, 2.0}
signals = getSignals(connectors, 2, 1); -- {5.5}
signals = getSignals(connectors, 3, 2); -- {1.0, 7.0}
signals = getSignals(connectors, 0, 5); -- {0.0, 2.0, 5.5, 1.0, 7.0}

SEE ALSO

createAbstractConnectors, setSignals

Verbatim copying and distribution of this entire article are permitted in any medium, provided this notice is preserved.
Send suggestions, questions and bug reports to neurowombatmail@gmail.com
Copyright © 2009, 2010, 2011, 2012 Andrew Timashov