Operator`s manual
45 Signametrics
Remarks Following the completion of long or complex polled commands, the scanner indicates it
is ready to accept a new command by issuing a task complete message. XXXXX
Functions requiring the use of the SCANReady() command include;
SCANSelectChannelCmd(), SCANAutoScan(), SCANTrigAutoScan(),
SCANTrigScan(), and SCANCleanRelays(). The SCANReady() function checks
returns TRUE if ready, and FALSE otherwise. Once a TRUE status is returned, the
SCANMMReady() function should not be used again until a new polled command
requires it.
Parameter
Type/Description
iScan
int Identifies the Scanner. Scanners are numbered starting with zero.
R
eturn Value The ret
urn value is one of the following constants.
Value
Meaning
TRUE
Scanner is done and ready to accept new commands.
FALSE
Scanner is not ready.
Negative Value
Error code
Example double Buffer[10];
SCANAutoScan(0,10);
while( ! SCANReady(0) );
for(i=0; i < 10 ; i++) Buffer[i] = SCANReadBuffer(0);
SCANSelectChannel
H/W access Command ; Polled Command
Description Select channel command.
#include “SM4040.H”
#include “ScanUser.H”
int SCANSel
ectChannel
(int iScan, int iChan)
Remarks This is th
e primary channel selection function for the multiplexed configurations of the
scanner. It opens currently closed channel(s) in a configured group and then closes
channel iChan. Depending on the current configuration, it will open and close a different
number of relays. In TwoWire configuration, all relays open prior to closing the iChan.
If the Scanner is in the FourWire configuration, the iChan value for an SM4042 can be
between 1 and 20, since there are twenty FourWire channels available. In addition to
opening the currently closed channels, it will close the two channel relays in accordance
with the FourWire switching scheme. Configuration relays will also be set as required for
accessing the selected channel. This command is applicable in the following
configurations: TwoWire, FourWire, SixWire, TwoGroups, and FourGroups. It opens
and closes all pertinent relays within one t-Actuation. Issuing this command will prevent
the execution of any other functions in the thread, for a period of t-Actuation.
Parameter
Type/Description
iScan
int Identifies the Scanner. Num
bered starting with zero.
iChan
int Channel num
ber Range: 1 to 40 depending on Scanner type and
set configuration. 0 causes opening of all channels in a group.
Return Value Inte
ger code.