From 4cda72771765720a6a8721bd8844945c2403afe6 Mon Sep 17 00:00:00 2001
From: QuakeGod <quakegod@sina.com>
Date: 星期一, 23 十月 2023 08:52:12 +0800
Subject: [PATCH] fix vcxproj version

---
 MTerm2/KDefine.h |  144 ++++++++++++++++++++++++++++++++++++++++++++++--
 1 files changed, 138 insertions(+), 6 deletions(-)

diff --git a/MTerm2/KDefine.h b/MTerm2/KDefine.h
index 9d5faa1..1ffe483 100644
--- a/MTerm2/KDefine.h
+++ b/MTerm2/KDefine.h
@@ -1,4 +1,4 @@
-/*
+锘�/*
 
 
 
@@ -84,6 +84,138 @@
 
 };
 
+enum enInputFilter
+{
+	InputFilter_None = 0,
+	InputFilter_1mS = 1,
+	InputFilter_2mS = 2,
+	InputFilter_4mS = 3,
+	InputFilter_8mS = 4,
+	InputFilter_16mS = 5,
+	InputFilter_32mS = 6,
+	InputFilter_64mS = 7,
+	InputFilter_128mS = 8,
+	InputFilter_256mS = 9,
+};
+
+enum enOutputHold
+{
+	Output_Hold = 0,
+	Output_Set_0 = 1,
+	Output_Set_1 = 2,
+};
+
+enum enPortType
+{
+	PortType_Com = 0,	//录脝脣茫禄煤脥篓脩露
+	PortType_Gen = 1,	//脥篓脫脙脥篓脩露拢卢脳脭脫脡驴脷
+	PortType_KLink = 2, //Klink脥篓脩露
+	PortType_KBus = 3, 	//KBus脥篓脩露
+	PortType_KNet = 4, 	// KNet脥篓脩露
+	PortType_ModbusRTU = 5, //Modbus RTU 脥篓脩露
+};
+
+enum enKeventType
+{
+	EventTypeNone = 0,
+	EventTypePowerUp = 1,
+	EventTypePowerDown = 2,
+	EventTypePowerRecover = 3,
+	EventTypeConnected = 4,
+	EventTypeLostCon = 5,
+	EventTypeSetTime = 6,
+	EventTypeSysCfg = 7,
+	EventTypeProg = 8,
+	EventTypeForce = 9,
+	EventTypeClearEvent = 10,
+
+
+	EventType
+};
+typedef struct tagInfoBlock
+{
+	USHORT nDeviceType;
+	USHORT ProgVer;
+	USHORT KlinkVer;
+	USHORT nCapacity;
+	UCHAR nDInput;
+	UCHAR nDOutput;
+	UCHAR nAInput;
+	UCHAR nAOutput;
+	UCHAR nHInput;
+	UCHAR nHOutput;
+	UCHAR nExt1;
+	UCHAR nEXT2;
+
+}stKMInfoBlock;
+
+typedef struct tagKMFuncParam
+{
+	USHORT EnablePLC : 1;		//浣胯兘鍐呴儴PLC鍔熻兘
+	USHORT RunMode;				//宸ヤ綔妯″紡
+}stKMFuncParam;
+
+//杈撳叆杈撳嚭鍦板潃鏄犲皠
+typedef struct tagAddrMapping
+{
+	USHORT InputAddr;
+	USHORT OutputAddr;
+	USHORT WRAddr;
+	USHORT DTAddr;
+}stAddrMapping;
+typedef struct tagComPortParam
+{
+	USHORT PortType : 4;				/* 0-5=Com,Gen,KLink,KBus,KNet,RTU */
+	USHORT ByteSize : 2;        /* 0-1=Number of bits/byte, 7-8    */
+	USHORT Parity : 4;					/* 0-4=None,Odd,Even,Mark,Space    */
+	USHORT StopBits : 2;        /* 0,1,2 = 1, 1.5, 2               */
+	USHORT EofChar : 2;         /* 0,1,2 = None, CR, CR+LF, ETX;  End of character  */
+	USHORT SofChar : 2;					/* 0,1,2 = None, STX */
+	USHORT BaudRate;       /* =*100 Baudrate at which running       */
+}stComPortParam;
+
+typedef struct tagInputFilterParam
+{
+	BYTE Filter0 : 4;
+	BYTE Filter1 : 4;
+
+}stInputFilterParam;
+
+typedef struct tagOutputHoldParam
+{
+	BYTE Hold1 : 4;
+	BYTE Hold2 : 4;
+}stOutputHoldParam;
+// 纭欢鎻忚堪鏂囦欢
+
+typedef struct tagMSysCfg
+{
+	unsigned short Sign1;		//2
+	unsigned short Seq1;		//2
+	UINT cfgvar2;				//4
+	stComPortParam Ports[2];				//2*4B
+	stOutputHoldParam OutputParams[16];		//16B
+	stInputFilterParam InputParams[16];		//16B
+
+	UINT cfgvar3;
+	UINT cfgvar4;
+	UINT cfgvar5;
+	UINT cfgvar6;
+	UINT cfgvar7;
+	UINT cfgvar8;
+	UINT cfgvar9;
+	UINT cfgvar10;
+	UINT cfgvar11;
+	UINT cfgvar12;
+	UINT cfgvar13;
+	UINT cfgvar14;
+	UINT cfgvar15;
+	UINT cfgvar16;							//14*4 56B
+	UINT Space1[5];							// 20B
+
+	unsigned short CRC1;					//2B
+	unsigned short EndSign1;				//2B
+}stKMSysCfg, *pKMSysCfg;					//128B
 
 
 typedef struct tagTimer
@@ -236,8 +368,8 @@
 	unsigned short nParamAddr;
 }stBinProg1;
 typedef struct stBinProg15
-{	//定时器
-	//单参数高级指令
+{	//瀹氭椂鍣�
+	//鍗曞弬鏁伴珮绾ф寚浠�
 	unsigned char nOp;
 	unsigned char nOpNum;
 	unsigned short nParamAddr1;
@@ -246,8 +378,8 @@
 	unsigned short resvr2;
 }stBinProg15;
 typedef struct stBinProg2
-{	//比较指令
-	//双参数高级指令
+{	//姣旇緝鎸囦护
+	//鍙屽弬鏁伴珮绾ф寚浠�
 	unsigned char nOp;
 	unsigned char nOpNum;
 	unsigned short nParamAddr1;
@@ -256,7 +388,7 @@
 	unsigned short nParamAddr2;
 }stBinProg2;
 typedef struct stBinProg3
-{	//三参数高级指令
+{	//涓夊弬鏁伴珮绾ф寚浠�
 	unsigned char nOp;
 	unsigned char nOpNum;
 	unsigned short nParamAddr1;

--
Gitblit v1.9.1