Oc_demandinputscan -9 – Rockwell Automation 1747-PCINT API Software for 1746 I/O User Manual

Page 63

Advertising
background image

OC_DemandInputScan

Library of Routines

6–9

Publication 1747-6.5.3 June 1998

OC_DemandInputScan

OC_DemandInputScan forces the scanner to immediately perform an input scan.

Syntax:

int

OC_DemandInputScan(HANDLE handle, int mode);

Parameters:

Description:

If an I/O scan is in progress when this function is called, the input scan is performed after the current scan
has completed.

The scanner updates the input image with data read from the modules. Use OC_ReadInputImage to read
data from the input image.

Return Value:

Considerations:

Supported in the DOS API library and the Windows NT API library

Example:

HANDLE

Handle;

int

retcode;

retcode = OC_DemandInputScan( Handle, OCWAIT );

Parameter:

Description:

handle

Must be a valid handle returned from OC_OpenScanner

mode

If

mode

is:

OCWAIT

OC_DemandInputScan waits for the input scan to be
completed before returning to the caller.

OCNOWAITOC_DemandInputScan returns immediately.

Name:

Value:

Description:

SUCCESS

0

demand input request was successful

ERR_OCACCESS

2

handle

does not have access to scanner

ERR_OCRESPONSE

10

scanner did not respond to request

ERR_OCSCANCFG

14

scanner has not been configured

Advertising
This manual is related to the following products: