|
|
|
|
/****************************************************************************
|
|
|
|
|
** File name : HTIEC61850.h
|
|
|
|
|
** Description : define iec 61850 network protocol api
|
|
|
|
|
** Create date : 2019.09.01
|
|
|
|
|
** Auther by : Liuyx
|
|
|
|
|
** Version info : V1.0.01
|
|
|
|
|
** Copyright (C) 2002-2019 xi'an huatek, Inc Co., Ltd
|
|
|
|
|
** Update record:
|
|
|
|
|
** DATE AUTHER DESC
|
|
|
|
|
** -------------------------------------------------------------------------
|
|
|
|
|
** 2019.09.01 Liuyx first build
|
|
|
|
|
****************************************************************************/
|
|
|
|
|
#ifndef __HT_LIBIEC_61850_H
|
|
|
|
|
#define __HT_LIBIEC_61850_H
|
|
|
|
|
#include "HTGlobal.h"
|
|
|
|
|
#include "iec61850_client.h"
|
|
|
|
|
#include "iec61850_model.h"
|
|
|
|
|
#include "iec61850_dynamic_model.h"
|
|
|
|
|
#include "iec61850_config_file_parser.h"
|
|
|
|
|
|
|
|
|
|
#ifdef _SISCO_MMS_LITE
|
|
|
|
|
#pragma comment(lib,"acsi_ld.lib")
|
|
|
|
|
#pragma comment(lib,"mmslite_ld.lib")
|
|
|
|
|
#endif // _SISCO_MMS_LITE
|
|
|
|
|
|
|
|
|
|
#ifdef _LIB_IEC_61850
|
|
|
|
|
#pragma comment(lib,"iec61850.lib")
|
|
|
|
|
#endif // _LIB_IEC_61850
|
|
|
|
|
|
|
|
|
|
#pragma pack (push ,1)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#pragma pack (pop)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#if defined (__cplusplus)
|
|
|
|
|
extern "C" {
|
|
|
|
|
#endif /* defined (__cplusplus) */
|
|
|
|
|
|
|
|
|
|
// <20><>ȡ<EFBFBD><C8A1><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϣ
|
|
|
|
|
const char *getIedError(int error);
|
|
|
|
|
|
|
|
|
|
// <20><>Զ<EFBFBD><D4B6>IED<45><44>ȡģ<C8A1><C4A3><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
int vGetRemoteIEDModelConfig(IedConnection con);
|
|
|
|
|
|
|
|
|
|
// ICD<43>ļ<EFBFBD><C4BC><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
IedModel *LoadModelConfigFile(char *icd_file);
|
|
|
|
|
|
|
|
|
|
// <20><>ʼ<EFBFBD><CABC>61850<35><30><EFBFBD>ӻ<EFBFBD><D3BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
void vIedInitIedEvent();
|
|
|
|
|
|
|
|
|
|
// <20>ͷ<EFBFBD><CDB7><EFBFBD><EFBFBD>Ӽ<EFBFBD><D3BC><EFBFBD>Դ
|
|
|
|
|
void vIedFreeIedEvent(ST_IED_CONN_HANDLE &stIedHandle);
|
|
|
|
|
|
|
|
|
|
// <20><><EFBFBD><EFBFBD>Ied<65><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ӵĸ澯<C4B8><E6BEAF>Ϣ
|
|
|
|
|
void vSetIedDevicesWarnMesg(char *Ied_ip, int port, time_t altime);
|
|
|
|
|
|
|
|
|
|
// ɾ<><C9BE>Ied<65><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ӵĸ澯<C4B8><E6BEAF>Ϣ
|
|
|
|
|
void vDelIedDevicesWarnMesg(char *Ied_ip, int port, time_t altime);
|
|
|
|
|
|
|
|
|
|
// IED<45>ļ<EFBFBD><C4BC><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
void showComtradeFile(IedConnection con, const char *pszDirName);
|
|
|
|
|
|
|
|
|
|
// ¼<><C2BC><EFBFBD>ļ<EFBFBD><C4BC><EFBFBD><EFBFBD><EFBFBD>,<2C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>߳<EFBFBD>
|
|
|
|
|
void vDownLoadComtradeFiles(/*void *arg*/ ST_IED_CONN_HANDLE &stIedCon);
|
|
|
|
|
|
|
|
|
|
// <20>ϴ<EFBFBD><CFB4>ļ<EFBFBD>--ĿǰIED<45><44>֧<EFBFBD><D6A7><EFBFBD>ϴ<EFBFBD><CFB4>ļ<EFBFBD>
|
|
|
|
|
void setComtradeFile(IedConnection con, const char *filename);
|
|
|
|
|
|
|
|
|
|
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ص<EFBFBD>¼<EFBFBD><C2BC><EFBFBD>ļ<EFBFBD><C4BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
int unPackComtradeFile(char *pfile);
|
|
|
|
|
|
|
|
|
|
// ɾ<><C9BE>¼<EFBFBD><C2BC><EFBFBD>ļ<EFBFBD>
|
|
|
|
|
void deleteComtradeFile(IedConnection con, const char *filename);
|
|
|
|
|
|
|
|
|
|
// <20><>ȡʵʱ<CAB5><CAB1><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>-ң<><D2A3>
|
|
|
|
|
void vGetFCMXData_YC(IedConnection conn);
|
|
|
|
|
|
|
|
|
|
// <20><>ȡʵʱ<CAB5><CAB1><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>-ң<><D2A3>
|
|
|
|
|
void vGetFCMXData_YX(IedConnection conn);
|
|
|
|
|
|
|
|
|
|
// <20><><EFBFBD>ÿ<EFBFBD><C3BF>Ʋ<EFBFBD><C6B2><EFBFBD>
|
|
|
|
|
void vSetFCSEData_CTRL(IedConnection conn);
|
|
|
|
|
|
|
|
|
|
#if defined (__cplusplus)
|
|
|
|
|
}
|
|
|
|
|
#endif /* defined (__cplusplus) */
|
|
|
|
|
|
|
|
|
|
#endif /* __HT_LIBIEC_61850_H */
|