Return value: considerations, Example – Rockwell Automation 1747-PCIS API Software - Open Controller User Manual
Page 141
Advertising

Publication 1747-UM002A-US-P - June 2000
Library of Routines 6-81
Return Value:
Considerations:
Supported in the Windows NT API library only.
Example:
Byte
buf[100];/*buffer of important data*/
Word crc;
HANDLE handle;
/* Save 100 bytes of data to offset 0 in SRAM */
OC_WriteSRAM(handle, buf, 0, 100);
/* Calculate CRC */
OC_CalculateCRC(buf, 100, &crc);
/* Write data CRC to offset 100 in SRAM */
OC_WriteSRAM(handle, &crc, 100, 2);
Name:
Description:
SUCCESS
data was written successfully
ERR_OCACCESS
handle
does not have access to scanner
ERR_OCPARAM
offset+length
points past the end of the memory
Advertising
This manual is related to the following products: