Oc_getinputimage, Updatecounter -25 – Rockwell Automation 1747-PCINT API Software for 1746 I/O User Manual

Page 79

Advertising
background image

OC_GetInputImage UpdateCounter

Library of Routines

6–25

Publication 1747-6.5.3 June 1998

OC_GetInputImage
UpdateCounter

OC_GetInputImageUpdateCounter reads the value of the input image update
counter from the scanner and places it into

count

.

Syntax:

int

OC_GetInputImageUpdateCounter(HANDLE handle, BYTE *count);

Parameters:

Description:

The input image update counter is incremented by the scanner after each input scan.

The input image update counter is only incremented if the scanner is in Scan mode, input scans are enabled,
and inputs are present. Use the counter to determine whether a change occurred; the value of the counter is
not important. It is possible to configure a system with no inputs; in this case, the input image update counter
would not be incremented.

Return Value:

Considerations:

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

Example:

HANDLE

Handle;

BYTE

count;

int

retcode;

retcode = OC_GetInputImageUpdateCounter( Handle, &count );

Parameter:

Description:

handle

Must be a valid handle returned from OC_OpenScanner

count

Contains the value of the input image update counter

Name:

Value:

Description:

SUCCESS

0

input image update counter was read successfully

ERR_OCACCESS

2

handle

does not have access to scanner

ERR_OCINIT

5

scanner has not been initialized, see OC_InitScanner

Advertising
This manual is related to the following products: