Rockwell Automation 1747-PCIS API Software - Open Controller User Manual
Page 162
Publication 1747-UM002A-US-P - June 2000
C-14 Header File
#define OCSTSFILEWSIZE 25 /* Status file size in words */
#define OCRTCSRAMSIZE 0x1000 /* size of real-time clock SRAM */
#define OCSEGMENTSIZELIMIT 0x1A00 /* size of dual-port RAM available for I/O and host partitions */
/* **** Device Type Definitions **** */
/* Returned by OC_GetDeviceInfo(). */
#define OCDEVTYPE_OC 1 /* 1747-PCIL */
#define OCDEVTYPE_PCIS 2 /* 1747-PCIS */
/* ************************************ */
/* ** STRUCTURES ** */
/* ************************************ */
/* ensure structures are byte-aligned */
#ifdef _BORLANDC_
#pragma option -a1
#endif /* _BORLANDC */
#ifdef _MSC_VER
#pragma pack(1)
#endif /* _MSC_VER */
/************************************************************
* Structure Name: OCINIT
*
* Description:
*
* Passed to OC_InitScanner() function to specify
* dual-port RAM partition sizes for output image,
* input image, and host retentive data.
*
*************************************************************/
typedef struct tagOCINIT
{
WORD
OutputImageSize; /* size in bytes */
WORD
InputImageSize; /* size in bytes */
WORD
HostRetentiveDataSize; /* size in bytes */
} OCINIT;
/************************************************************
* Structure Name: OCSLOTCFG
*
* Description:
*
* Configuration information for a module. The mix and
* type codes together form a unique identification for
* each module.
*
*************************************************************/
typedef struct tagOCSLOTCFG
{
BYTE mix; /* mix code */
BYTE type; /* type code */
BYTE InputSize; /* number of inputs in bytes */
BYTE OutputSize; /* number of outputs in bytes */
WORD M0Size; /* size of M0 file in words */
WORD M1Size; /* size of M1 file in words */
WORD GSize; /* size of G file in words */
WORD *GData; /* pointer to array of length GSize words */