www.pudn.com > IEC104_codeamaterial.rar > extio.h, change:2010-12-21,size:1325b
/*------------------------------------------------------------------------ Module: extio.h Author: solar Project: Creation Date: Description: ------------------------------------------------------------------------*/ /*------------------------------------------------------------------------ $Log: $ ------------------------------------------------------------------------*/ #ifndef _EXTIO_H #define _EXTIO_H #include "timer.h" #define EXTIO_BCADDR 0xFF #define EXTIO_CMD_PRSET_READ 0x01 #define EXTIO_CMD_PRSET_WRITE 0x02 #define EXTIO_CMD_PR_RESET 0x03 #define EXTIO_CMD_FREQ_FOLLOW 0x04 typedef struct{ BYTE addr; BYTE cmd; WORD len; BYTE send; char ret; }VExtIoCmd; #pragma pack(1) typedef struct{ BYTE type; DWORD cfg; BYTE yxno; BYTE port; WORD bit; }VExtIoDiMap; typedef struct{ BYTE yxno; BYTE value1; BYTE value2; /*如果单点遥信, value2为0xFF*/ struct VCalClock chg_tm; }VExtIoDiSoe; #pragma pack(0) //EV for ExtIoS #define EV_KILLBUS 0x01 #define EV_HBEAT 0x02 #define EXTIO_REQALL_TM 3 //轮询一圈基准时间,s #define EXTIO_LOGOUT_TM 10 //检出logout的时间,s #define EXTIO_HBEAT_TM (EXTIO_LOGOUT_TM-2) //HBeat时间点,s #endif