DFS_Shuo_Chen 3 ماه پیش
والد
کامیت
a9183f1b85
29فایلهای تغییر یافته به همراه385 افزوده شده و 81 حذف شده
  1. 1 0
      .gitignore
  2. 6 6
      SensorDataSimulator/Release/conn.ini
  3. BIN
      VaporRecoveryMonitor/VaporRecoveryMonitor/Bin/VaporRecoveryMonitor.exe
  4. BIN
      VaporRecoveryMonitor/VaporRecoveryMonitor/Bin/setting/setting.db
  5. 65 3
      VaporRecoveryMonitor/VaporRecoveryMonitor/Bin/skin_1366_768/setting.xml
  6. BIN
      VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor.v12.suo
  7. BIN
      VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/Release/VaporRec.A31C344F.tlog/CL.read.1.tlog
  8. BIN
      VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/Release/VaporRec.A31C344F.tlog/CL.write.1.tlog
  9. BIN
      VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/Release/VaporRec.A31C344F.tlog/cl.command.1.tlog
  10. BIN
      VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/Release/VaporRec.A31C344F.tlog/link.read.1.tlog
  11. 19 17
      VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/Release/VaporRecoveryMonitor.log
  12. 14 14
      VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/conn.ini
  13. 1 1
      VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/global.cpp
  14. 43 31
      VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/global.h
  15. BIN
      VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/iniConfigTool.exe
  16. 1 1
      VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/instance.cpp
  17. 115 0
      VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/vr_app.cpp
  18. BIN
      VaporRecoveryMonitor/油气回收系统安装包/油气回收在线监控系统安装包/files/VR/VaporRecoveryMonitor.exe
  19. 1 1
      VaporRecoveryMonitor/油气回收系统安装包/油气回收在线监控系统安装包/files/VR/conn.ini
  20. BIN
      VaporRecoveryMonitor/油气回收系统安装包/油气回收在线监控系统安装包/files/VR/iniConfigTool.exe
  21. 65 3
      VaporRecoveryMonitor/油气回收系统安装包/油气回收在线监控系统安装包/files/VR/skin_1366_768/setting.xml
  22. BIN
      iniConfigTool/Bin/iniConfigTool.exe
  23. BIN
      iniConfigTool/iniConfigTool.v12.suo
  24. 44 1
      iniConfigTool/iniConfigTool/PvConfig.cpp
  25. 7 0
      iniConfigTool/iniConfigTool/PvConfig.h
  26. BIN
      iniConfigTool/iniConfigTool/Release/iniConfigTool.res
  27. 3 3
      iniConfigTool/iniConfigTool/conn.ini
  28. BIN
      iniConfigTool/iniConfigTool/iniConfigTool.rc
  29. BIN
      iniConfigTool/iniConfigTool/resource.h

+ 1 - 0
.gitignore

@@ -138,3 +138,4 @@ VaporRecoveryMonitor/油气回收系统安装包/油气回收在线监控系统
 VaporRecoveryMonitor/油气回收系统安装包/油气回收在线监控系统安装包V1.16.16.zip
 VaporRecoveryMonitor/油气回收系统安装包/油气回收在线监控系统安装包V1.16.17.zip
 VaporRecoveryMonitor/油气回收系统安装包/1.bat
+VaporRecoveryMonitor/油气回收系统安装包/油气回收在线监控系统安装包V1.16.18.zip

+ 6 - 6
SensorDataSimulator/Release/conn.ini

@@ -1,13 +1,13 @@
 [Config]
 val232_0=08 ff
-val232_1=08 46
+val232_1=08 78
 val232_2=08 16
-val232_3=08 16
-val232_4=ff ff
+val232_3=08 36
+val232_4=02 b1
 val232_5=02 b1
 val232_6=02 b1
-val232_7=08 14
-val232_8=02 b1
+val232_7=08 36
+val232_8=00 00
 PORT_232=11
 PORT_485=
 val485_Addr1=10
@@ -16,7 +16,7 @@ val485_Addr2=13
 val485_Value2=00 00 00 02
 val485_Addr3=14
 val485_Value3=00 00 00 03
-val232_9=02 b1
+val232_9=08 96
 val232_10=08 14
 val232_11=02 b1
 val232_12=02 c3

BIN
VaporRecoveryMonitor/VaporRecoveryMonitor/Bin/VaporRecoveryMonitor.exe


BIN
VaporRecoveryMonitor/VaporRecoveryMonitor/Bin/setting/setting.db


+ 65 - 3
VaporRecoveryMonitor/VaporRecoveryMonitor/Bin/skin_1366_768/setting.xml

@@ -5,6 +5,7 @@
     <horizontallayout height="36" bkcolor="#ff2460a0" textpadding="20,0,0,0">
       <option   name="setting1"  width="100"  text="设置1"  group="setting" font ="316" textcolor="#ffffffff" bkcolor="#ff2460a0" selectedbkcolor="#ff95b4de" selectedtextcolor="#ffffffff" selected="true"></option>
       <option   name="setting2"  width="100"  text="设置2"  group="setting" font ="316" textcolor="#ffffffff" bkcolor="#ff2460a0" selectedbkcolor="#ff95b4de" selectedtextcolor="#ffffffff"></option>
+      <option   name="setting3"  width="100"  text="零压校准"  group="setting" font ="316" textcolor="#ffffffff" bkcolor="#ff2460a0" selectedbkcolor="#ff95b4de" selectedtextcolor="#ffffffff"></option>
       
 
       <label></label>
@@ -105,19 +106,80 @@
         <horizontallayout>
         </horizontallayout>
 
-
         <horizontallayout height="40">
           <label></label>
           <button name="saveconfig" text="保存" width="120"  bkcolor="#ff2460a0" textcolor="0xffffffff" font ="515"></button>
         </horizontallayout>
 
-
       </verticallayout>
-  
       </horizontallayout>
 
 
       
+       <horizontallayout padding="5,10,5,5" bkcolor="#ffd6dfea">
+       <verticallayout padding="15,15,5,5">
+         
+         
+        <horizontallayout  height="30" >
+          <label text ="零压校准(调零)须知:校准时传感器必须已经安装固定好,并处于大气压之下" width="800" font ="515"></label>
+        </horizontallayout>
+
+        <horizontallayout>
+        </horizontallayout>
+         
+         <horizontallayout  height="30" >
+           <label text ="校准密码:" width="120" font ="515"></label>
+           <edit name="pressure_reset_pw" width="250" font ="515"> </edit>
+         </horizontallayout>
+         
+        <horizontallayout  height="50" >
+        <label text ="油罐压力1:" width="120" font ="515"></label>
+        <label name="reset_tankpressure_1" width="150" font ="515"> </label>
+ <button name="pressure_reset_1" text="校准" padding="0,10,0,0" height="30" width="120"  bkcolor="#ff2460a0" textcolor="0xffffffff" font ="515"></button>
+        </horizontallayout>
+         
+         
+        <horizontallayout  height="50" >
+        <label text ="油罐压力2:" width="120" font ="515"></label>
+        <label name="reset_tankpressure_2" width="150" font ="515"> </label>
+ <button name="pressure_reset_2" text="校准" padding="0,10,0,0" height="30" width="120"  bkcolor="#ff2460a0" textcolor="0xffffffff" font ="515"></button>
+        </horizontallayout>
+         
+        <horizontallayout  height="50" >
+        <label text ="油罐压力3:" width="120" font ="515"></label>
+        <label name="reset_tankpressure_3" width="150" font ="515"> </label>
+ <button name="pressure_reset_3" text="校准" padding="0,10,0,0" height="30" width="120"  bkcolor="#ff2460a0" textcolor="0xffffffff" font ="515"></button>
+        </horizontallayout>  
+           
+         
+        <horizontallayout  height="50" >
+        <label text ="油罐压力4:" width="120" font ="515"></label>
+        <label name="reset_tankpressure_4" width="150" font ="515"> </label>
+ <button name="pressure_reset_4" text="校准" padding="0,10,0,0" height="30" width="120"  bkcolor="#ff2460a0" textcolor="0xffffffff" font ="515"></button>
+        </horizontallayout>
+       
+         
+        <horizontallayout  height="50" >
+        <label text ="管线压力:" width="120" font ="515"></label>
+        <label name="reset_liquid" width="150" font ="515"> </label>
+ <button name="liquid_reset" text="校准" padding="0,10,0,0" height="30" width="120"  bkcolor="#ff2460a0" textcolor="0xffffffff" font ="515"></button>
+        </horizontallayout>
+       
+         
+        <horizontallayout>
+        </horizontallayout>
+        <horizontallayout>
+        </horizontallayout>
+        <horizontallayout>
+        </horizontallayout>
+         <horizontallayout>
+         </horizontallayout>
+      
+      </verticallayout>
+      </horizontallayout>
+    
+    
+      
       
     </tablayout>
     

BIN
VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor.v12.suo


BIN
VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/Release/VaporRec.A31C344F.tlog/CL.read.1.tlog


BIN
VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/Release/VaporRec.A31C344F.tlog/CL.write.1.tlog


BIN
VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/Release/VaporRec.A31C344F.tlog/cl.command.1.tlog


BIN
VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/Release/VaporRec.A31C344F.tlog/link.read.1.tlog


+ 19 - 17
VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/Release/VaporRecoveryMonitor.log

@@ -1,21 +1,23 @@
-Build started 2025/7/2 11:01:12.
+Build started 2025/7/3 17:00:35.
      1>Project "C:\bitbucket\apacsys-vaporrecoverymonitor_new\VaporRecoveryMonitor\VaporRecoveryMonitor\VaporRecoveryMonitor\VaporRecoveryMonitor.vcxproj" on node 2 (Build target(s)).
      1>ClCompile:
-         C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\CL.exe /c /I..\..\..\SDK\DuiLib /I..\VaporRecoveryMonitor /I..\..\..\cryptopp /Zi /nologo /W3 /WX- /sdl /Od /Oi /Oy- /GL /D WIN32 /D NDEBUG /D _WINDOWS /D _CRT_NONSTDC_NO_DEPRECATE /D _CRT_SECURE_NO_WARNINGS /D _USING_V110_SDK71_ /D _UNICODE /D UNICODE /Gm- /EHsc /MT /GS /Gy /fp:precise /Zc:wchar_t /Zc:forScope /Yu"stdafx.h" /Fp"Release\VaporRecoveryMonitor.pch" /Fo"Release\\" /Fd"Release\vc120.pdb" /Gd /TP /analyze- /errorReport:prompt vr_object.cpp
-         vr_object.cpp
-     1>c:\bitbucket\apacsys-vaporrecoverymonitor_new\vaporrecoverymonitor\vaporrecoverymonitor\vaporrecoverymonitor\VRCObject.h(9): warning C4348: 'SocketPackage' : redefinition of default parameter : parameter 1
-                 c:\bitbucket\apacsys-vaporrecoverymonitor_new\vaporrecoverymonitor\vaporrecoverymonitor\vaporrecoverymonitor\CommObject.h(7) : see declaration of 'SocketPackage'
-     1>c:\bitbucket\apacsys-vaporrecoverymonitor_new\vaporrecoverymonitor\vaporrecoverymonitor\vaporrecoverymonitor\_io.h(7): warning C4348: 'SocketPackage' : redefinition of default parameter : parameter 1
-                 c:\bitbucket\apacsys-vaporrecoverymonitor_new\vaporrecoverymonitor\vaporrecoverymonitor\vaporrecoverymonitor\_io.h(9) : see declaration of 'SocketPackage'
-     1>vr_object.cpp(364): warning C4244: 'initializing' : conversion from 'double' to 'int', possible loss of data
-     1>vr_object.cpp(394): warning C4800: 'BOOL' : forcing value to bool 'true' or 'false' (performance warning)
-     1>vr_object.cpp(581): warning C4018: '>=' : signed/unsigned mismatch
-     1>vr_object.cpp(589): warning C4018: '>=' : signed/unsigned mismatch
-     1>vr_object.cpp(605): warning C4018: '>=' : signed/unsigned mismatch
-     1>vr_object.cpp(607): warning C4018: '>=' : signed/unsigned mismatch
-     1>vr_object.cpp(616): warning C4018: '>=' : signed/unsigned mismatch
-     1>vr_object.cpp(625): warning C4018: '>=' : signed/unsigned mismatch
-     1>vr_object.cpp(1145): warning C4244: 'initializing' : conversion from 'double' to 'int', possible loss of data
+         C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\CL.exe /c /I..\..\..\SDK\DuiLib /I..\VaporRecoveryMonitor /I..\..\..\cryptopp /Zi /nologo /W3 /WX- /sdl /Od /Oi /Oy- /GL /D WIN32 /D NDEBUG /D _WINDOWS /D _CRT_NONSTDC_NO_DEPRECATE /D _CRT_SECURE_NO_WARNINGS /D _USING_V110_SDK71_ /D _UNICODE /D UNICODE /Gm- /EHsc /MT /GS /Gy /fp:precise /Zc:wchar_t /Zc:forScope /Yu"stdafx.h" /Fp"Release\VaporRecoveryMonitor.pch" /Fo"Release\\" /Fd"Release\vc120.pdb" /Gd /TP /analyze- /errorReport:prompt global.cpp
+         global.cpp
+     1>c:\bitbucket\apacsys-vaporrecoverymonitor_new\vaporrecoverymonitor\vaporrecoverymonitor\vaporrecoverymonitor\SM4.h(290): warning C4101: 'szArray' : unreferenced local variable
+     1>c:\bitbucket\apacsys-vaporrecoverymonitor_new\vaporrecoverymonitor\vaporrecoverymonitor\vaporrecoverymonitor\SM4.h(315): warning C4101: 'i' : unreferenced local variable
+     1>c:\bitbucket\apacsys-vaporrecoverymonitor_new\vaporrecoverymonitor\vaporrecoverymonitor\vaporrecoverymonitor\SM4.h(527): warning C4101: 'pbIV_pre' : unreferenced local variable
+     1>global.cpp(377): warning C4018: '<' : signed/unsigned mismatch
+     1>global.cpp(391): warning C4018: '<' : signed/unsigned mismatch
+     1>global.cpp(404): warning C4018: '<' : signed/unsigned mismatch
+     1>global.cpp(437): warning C4018: '<' : signed/unsigned mismatch
+     1>global.cpp(475): warning C4018: '<' : signed/unsigned mismatch
+     1>global.cpp(522): warning C4101: 'i' : unreferenced local variable
+     1>global.cpp(650): warning C4244: 'return' : conversion from 'uint64_t' to 'double', possible loss of data
+     1>global.cpp(659): warning C4101: 'Free' : unreferenced local variable
+     1>global.cpp(659): warning C4101: 'Available' : unreferenced local variable
+     1>global.cpp(1028): warning C4018: '<' : signed/unsigned mismatch
+     1>global.cpp(1050): warning C4018: '<' : signed/unsigned mismatch
+     1>global.cpp(1076): warning C4018: '<' : signed/unsigned mismatch
        Link:
          C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\link.exe /ERRORREPORT:PROMPT /OUT:"C:\bitbucket\apacsys-vaporrecoverymonitor_new\VaporRecoveryMonitor\VaporRecoveryMonitor\Bin\VaporRecoveryMonitor.exe" /INCREMENTAL:NO /NOLOGO /LIBPATH:"C:\bitbucket\apacsys-vaporrecoverymonitor_new\VaporRecoveryMonitor\VaporRecoveryMonitor\Lib\\" /LIBPATH:C:\common\openSSL\lib /LIBPATH:C:\common\openSSL /LIBPATH:"C:\Bitbucket\apacsys-vaporrecoverymonitor\cryptopp\lib\Output\Release" kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /MANIFEST /MANIFESTUAC:"level='asInvoker' uiAccess='false'" /manifest:embed /manifestinput:"C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\Include\Manifest\dpiaware.manifest" /DEBUG /PDB:"C:\bitbucket\apacsys-vaporrecoverymonitor_new\VaporRecoveryMonitor\VaporRecoveryMonitor\Bin\VaporRecoveryMonitor.pdb" /SUBSYSTEM:WINDOWS,"5.01" /OPT:REF /OPT:ICF /LTCG /TLBID:1 /DYNAMICBASE /NXCOMPAT /IMPLIB:"C:\bitbucket\apacsys-vaporrecoverymonitor_new\VaporRecoveryMonitor\VaporRecoveryMonitor\Bin\VaporRecoveryMonitor.lib" /MACHINE:X86 /SAFESEH Release\VaporRecoveryMonitor.res
          Release\AES.obj
@@ -150,4 +152,4 @@
 
 Build succeeded.
 
-Time Elapsed 00:00:09.95
+Time Elapsed 00:00:09.64

+ 14 - 14
VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/conn.ini

@@ -1,7 +1,7 @@
 ;上传平台选择
 [City]
 ;上传平台1;  0-北京;1-;2-;3-浙江杭州环保局;4-;5-山东省环保;6-广州;7-湖南中石化;8-山东烟台;9-重庆;10-;11-浙江金华环保局;12-南京环保局;13-福建厦门环保局;14-东莞市环保局;15-深圳环保局;16-江门环保局;17-沈阳环保局;18-广东惠州环保局;19=汕头环保局;20-云浮环保局;21-揭阳环保局;22-浙江宁波环保局;23-佛山市环保2;24-阳江环保局;25-安徽合肥环保局;26-浙江温州环保局;27-珠海环保局; 28-河北张家口环保局;29-浙江台州环保;30-湛江环保局;31-清远环保局;32-河北唐山环保局;33-内蒙古呼和浩特环保局;34-武汉环保局;35-宁夏环保局;36-成都环保局;999-测试1;1000-不设置
-CityNo=12
+CityNo=0
 ;上传平台2;  0-不设置;1-浙江浙石油;2-浙江中石化;3-山东青岛;4-湖南长沙环保局;5-佛山顺德(佛山市);6-广东中石化;7-重庆环保2;8-山东烟台;9-中化道达尔;999-测试2
 CityNo2=0
 ;上传平台3;0-不设置;1-浙江高速;2-中山智慧平台;3-北京中石化
@@ -721,7 +721,7 @@ path=/1/
 ;VRC36通讯
 [VRC36]
 ;串口号
-Comm=4
+Comm=0
 ;波特率
 baudrate=9600
 ;最小周期,单位毫秒,防止周期循环太快(范围为500-10000,默认3000)
@@ -743,13 +743,13 @@ UpperLimit=3
 ;量程下限,单位kPa , 负整数
 LowerLimit=-3
 ;油罐1的零压误差,油罐零压时后台显示的压力,单位 Pa , 两位小数
-ZeroOffset=150
+ZeroOffset=264.830000
 ;油罐2的零压误差
 Zero2=0
 ;油罐3的零压误差
-Zero3=0
+Zero3=154.940000
 ;油罐4的零压误差
-Zero4=0
+Zero4=330.760000
 ;液阻压力传感器的零压误差
 ZeroOffset2=0
 ;油气空间1
@@ -765,17 +765,17 @@ EnableTankPress=1
 ;油罐传感器1地址(默认值为1)
 TankPress_Addr=1
 ;是否有油罐压力传感器2
-EnableTankPress2=0
+EnableTankPress2=1
 ;油罐压力传感器2地址
-TankPress_Addr2=0
+TankPress_Addr2=7
 ;是否有油罐压力传感器3
-EnableTankPress3=0
+EnableTankPress3=1
 ;油罐压力传感器3地址
-TankPress_Addr3=0
+TankPress_Addr3=8
 ;是否有油罐压力传感器4
 EnableTankPress4=0
 ;油罐压力传感器4地址
-TankPress_Addr4=0
+TankPress_Addr4=9
 
 
 ;是否有温度传感器1
@@ -871,7 +871,7 @@ EnableOil_12=0
 Oil_12_Type=0
 Oil_12_Addr=0
 
-;安装液阻传感器加油机编号(1-9),没有时填0
+;安装管线压力传感器的加油机编号(1-9),没有时填0
 fip=0
 ;气体浓度误差范围调整,单位ppm,最大200
 gasoffset=100
@@ -938,14 +938,14 @@ usenarrowal=0
 enablefillinglog=1
 nozstr=
 tankstr=
-stationname=连平加油站
+stationname=珠江二加油站
 Times=1:1;2:0;5:0;6:0;13:0;14:0;15:0;16:0;17:0;18:0;19:0;20:0;23:0;24:0;
 Times_alert=1:0;2:0;5:0;6:0;13:0;14:0;15:0;16:0;17:0;18:0;19:0;20:0;23:0;24:0;
-configupdatetime=20241029095424
+configupdatetime=20250703160542
 
 [RunningState]
 UnLockFlag=000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
-Date=20250702
+Date=20250703
 TradeFlag=100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
 
 

+ 1 - 1
VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/global.cpp

@@ -25,7 +25,7 @@
 
 using namespace VR::notify;
 
-string g_version = "V1.16.17";
+string g_version = "V1.16.18";
 
 
 int g_read_unuploadday = 31;	//程序开启时读未上传交易的天数 非特殊情况皆为31天

+ 43 - 31
VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/global.h

@@ -221,6 +221,8 @@ public:
 		continue_days = 0;
 		m_state = SensorState_OffLine;
 		m_data = 0;
+
+		memset(&m_warning, 0, sizeof(m_warning));
 	}
 
 	Sensor(string strname)
@@ -526,7 +528,7 @@ public:
 
 	void setWarning(tank_warning_record warn)
 	{
-		memcpy_s(&warning, sizeof(tank_warning_record), &warn, sizeof(tank_warning_record));
+		memcpy_s(&m_warning, sizeof(tank_warning_record), &warn, sizeof(tank_warning_record));
 	}
 
 	void setMax(int max)
@@ -549,7 +551,7 @@ protected:
 	SensorState m_state;
 	int m_warningType;
 
-	tank_warning_record warning;
+	tank_warning_record m_warning;
 
 
 private:
@@ -635,7 +637,7 @@ public:
 
 
 			//预警
-			if (warning.zero_h[m_index] >= VR::rules::ref_tankwarning_zero_s / 3600)
+			if (m_warning.zero_h[m_index] >= VR::rules::ref_tankwarning_zero_s / 3600)
 			{
 				zerostate = 1;
 			}
@@ -643,7 +645,7 @@ public:
 			{
 				zerostate = 0;
 			}
-			if (warning.zero_h[m_index] >= VR::rules::ref_tankwarning_zero_s_gdzsh / 3600)
+			if (m_warning.zero_h[m_index] >= VR::rules::ref_tankwarning_zero_s_gdzsh / 3600)
 			{
 				zerostate_gdzsh = 1;
 			}
@@ -656,7 +658,7 @@ public:
 			{
 				if (VR::rules::ref_pv_warningtype == 1)
 				{
-					if (warning.pvtime[m_index] > 0)
+					if (m_warning.pvtime[m_index] > 0)
 					{
 						pvstate = 1;
 					}
@@ -670,10 +672,10 @@ public:
 					//tank_pvtext_pre->SetText("P/V阀预警(分));
 					//tank_pvsecond->SetTextInt(warning_.pv_m);
 
-					int pv_time = warning.pv_m[m_index];
+					int pv_time = m_warning.pv_m[m_index];
 					if (g_CityNo == CITY_FS)
 					{
-						pv_time = warning.pv_m_max[m_index];
+						pv_time = m_warning.pv_m_max[m_index];
 					}
 
 					if (pv_time >= VR::rules::ref_tankwarning_pv)
@@ -692,7 +694,7 @@ public:
 				//char chcr[10];
 				//sprintf_s(chcr, "%d%%", recordset.front().crisisrate);
 				//tank_pvcrisis->SetText(chcr);
-				if (warning.pvcrisis[m_index] >= VR::rules::ref_precrisis)
+				if (m_warning.pvcrisis[m_index] >= VR::rules::ref_precrisis)
 				{
 					pvcrisisstate = 1;
 				}
@@ -706,7 +708,7 @@ public:
 			if (VR::rules::bEnablePost && g_bEnablePostProcess)
 			{
 				//tank_posttime->SetTextInt(warning_.post_h);
-				if (warning.post_h[m_index] >= VR::rules::ref_tankwarning_post_s / 3600)
+				if (m_warning.post_h[m_index] >= VR::rules::ref_tankwarning_post_s / 3600)
 				{
 					poststate = 1;
 				}
@@ -720,7 +722,7 @@ public:
 			//报警
 
 			//tank_zeropressureday->SetTextInt(warning_.zero_continue_days);
-			if (warning.zero_continue_days[m_index] >= VR::rules::ref_tankwarning_zero_d)
+			if (m_warning.zero_continue_days[m_index] >= VR::rules::ref_tankwarning_zero_d)
 			{
 				zerostate_w = 1;
 			}
@@ -734,7 +736,7 @@ public:
 				if (VR::rules::ref_pv_warningtype == 1)
 				{
 				//	tank_pvtime->SetTextInt(warning_.pv_m);
-					if (warning.pv_m[m_index] >= VR::rules::ref_tankwarning_pv)
+					if (m_warning.pv_m[m_index] >= VR::rules::ref_tankwarning_pv)
 					{
 						pvstate_w = 1;
 					}
@@ -747,7 +749,7 @@ public:
 				{
 					//tank_pvtext->SetText("P/V阀预警(天)");
 					//tank_pvtime->SetTextInt(warning_.pv_continue_days);
-					if (warning.pv_continue_days[m_index] >= VR::rules::ref_tankwarning_pv_day)
+					if (m_warning.pv_continue_days[m_index] >= VR::rules::ref_tankwarning_pv_day)
 					{
 						pvstate_w = 1;
 					}
@@ -762,7 +764,7 @@ public:
 			if (VR::rules::bEnablePVCrisis)
 			{
 				//tank_pvcrisistime->SetTextInt(warning_.pvcrisis_continue_days);
-				if (warning.pvcrisis_continue_days[m_index] >= VR::rules::ref_tankwarning_pvcrisis)
+				if (m_warning.pvcrisis_continue_days[m_index] >= VR::rules::ref_tankwarning_pvcrisis)
 				{
 					pvcrisisstate_w = 1;
 				}
@@ -775,7 +777,7 @@ public:
 			if (VR::rules::bEnablePost && g_bEnablePostProcess)
 			{
 				//tank_postday->SetTextInt(warning_.post_continue_days);
-				if (warning.post_continue_days[m_index] >= VR::rules::ref_tankwarning_post_d)
+				if (m_warning.post_continue_days[m_index] >= VR::rules::ref_tankwarning_post_d)
 				{
 					poststate_w = 1;
 				}
@@ -792,30 +794,30 @@ public:
 			warningtext = "";
 			if (zerostate)
 			{
-				warningtext += "零压" + to_string(warning.zero_h[m_index]) + "小时," + to_string(warning.zero_continue_days[m_index]) + "天;";
+				warningtext += "零压" + to_string(m_warning.zero_h[m_index]) + "小时," + to_string(m_warning.zero_continue_days[m_index]) + "天;";
 			}
 
 			if (pvstate)
 			{
 				if (VR::rules::ref_pv_warningtype == 1)
 				{
-					warningtext += "P/V阀" + to_string(warning.pvtime[m_index]) + "秒," + to_string(warning.pv_m[m_index]) + "分钟;";
+					warningtext += "P/V阀" + to_string(m_warning.pvtime[m_index]) + "秒," + to_string(m_warning.pv_m[m_index]) + "分钟;";
 				}
 				else
 				{
 
-					warningtext += "P/V阀" + to_string(warning.pv_m[m_index]) + "分钟," + to_string(warning.pv_continue_days[m_index]) + "天;";
+					warningtext += "P/V阀" + to_string(m_warning.pv_m[m_index]) + "分钟," + to_string(m_warning.pv_continue_days[m_index]) + "天;";
 				}
 			}
 
 			if (pvcrisisstate)
 			{
-				warningtext += "P/V阀临界" + to_string(warning.pvcrisis[m_index]) + "%," + to_string(warning.pvcrisis_continue_days[m_index]) + "天;";
+				warningtext += "P/V阀临界" + to_string(m_warning.pvcrisis[m_index]) + "%," + to_string(m_warning.pvcrisis_continue_days[m_index]) + "天;";
 			}
 
 			if (poststate)
 			{
-				warningtext += "后处理压力" + to_string(warning.post_h[m_index]) + "小时," + to_string(warning.post_continue_days[m_index]) + "天;";
+				warningtext += "后处理压力" + to_string(m_warning.post_h[m_index]) + "小时," + to_string(m_warning.post_continue_days[m_index]) + "天;";
 			}
 
 			if (unionstate_w)
@@ -845,6 +847,8 @@ public:
 			str = "地址冲突";
 			break;
 		}
+
+		m_text = str;
 		return str;
 	}
 
@@ -853,6 +857,11 @@ public:
 		return warningtext;
 	}
 
+	string getText()
+	{
+		return m_text;
+	}
+
 	void updatelaststate()
 	{
 		lastpvstate = pvstate;
@@ -902,6 +911,7 @@ public:
 	int unionstate_w;
 
 	string warningtext;
+	string m_text;
 
 private:
 	double m_zerooffset;
@@ -1000,6 +1010,8 @@ public:
 			str = "地址冲突";
 			break;
 		}
+
+		m_text = str;
 		return str;
 	}
 
@@ -1199,13 +1211,13 @@ public:
 			}
 			
 
-			if (!g_UseBeijingNewStandard && warning.gas_continue_days >= 1)
+			if (!g_UseBeijingNewStandard && m_warning.gas_continue_days >= 1)
 			{
-				if (warning.gas_max >= VR::rules::ref_gasppm_alert)
+				if (m_warning.gas_max >= VR::rules::ref_gasppm_alert)
 				{
 					gasstate_w = 1;
 				}
-				else if (warning.gas_continue_days >= VR::rules::ref_tankwarning_gas)
+				else if (m_warning.gas_continue_days >= VR::rules::ref_tankwarning_gas)
 				{
 					gasstate_w = 1;
 				}
@@ -1215,14 +1227,14 @@ public:
 				}
 			}
 
-			if (!g_UseBeijingNewStandard  && warning.postgas_continue_days >= 1)
+			if (!g_UseBeijingNewStandard  && m_warning.postgas_continue_days >= 1)
 			{
 
-				if (warning.postgas_max >= VR::rules::ref_gasppm_alert)
+				if (m_warning.postgas_max >= VR::rules::ref_gasppm_alert)
 				{
 					poststate_w = 1;
 				}
-				else if (warning.postgas_continue_days >= VR::rules::ref_tankwarning_gas)
+				else if (m_warning.postgas_continue_days >= VR::rules::ref_tankwarning_gas)
 				{
 					poststate_w = 1;
 				}
@@ -1232,14 +1244,14 @@ public:
 				}
 			}
 
-			if (!g_UseBeijingNewStandard &&  warning.well_continue_days[m_index] >= 1)
+			if (!g_UseBeijingNewStandard &&  m_warning.well_continue_days[m_index] >= 1)
 			{
 
-				if (warning.well_max[m_index] >= VR::rules::ref_gasppm_alert)
+				if (m_warning.well_max[m_index] >= VR::rules::ref_gasppm_alert)
 				{
 					wellstate_w = 1;
 				}
-				else if (warning.well_continue_days[m_index] >= VR::rules::ref_tankwarning_gas)
+				else if (m_warning.well_continue_days[m_index] >= VR::rules::ref_tankwarning_gas)
 				{
 					wellstate_w = 1;
 				}
@@ -1249,14 +1261,14 @@ public:
 				}
 			}
 
-			if (!g_UseBeijingNewStandard &&  warning.oil_continue_days[m_index] >= 1)
+			if (!g_UseBeijingNewStandard &&  m_warning.oil_continue_days[m_index] >= 1)
 			{
 
-				if (warning.oil_max[m_index] >= VR::rules::ref_gasppm_alert)
+				if (m_warning.oil_max[m_index] >= VR::rules::ref_gasppm_alert)
 				{
 					oilstate_w = 1;
 				}
-				else if (warning.oil_continue_days[m_index] >= VR::rules::ref_tankwarning_gas)
+				else if (m_warning.oil_continue_days[m_index] >= VR::rules::ref_tankwarning_gas)
 				{
 					oilstate_w = 1;
 				}

BIN
VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/iniConfigTool.exe


+ 1 - 1
VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/instance.cpp

@@ -2208,7 +2208,7 @@ int APIENTRY WinMain(_In_ HINSTANCE hInstance, _In_opt_ HINSTANCE hPrevInstance,
 	singleton<GData>::GetInstance()->yz_fip = GetPrivateProfileIntA("Tank", "fip", 0, ".//conn.ini");
 	if (singleton<GData>::GetInstance()->yz_fip < 0 || singleton<GData>::GetInstance()->yz_fip > 9)
 	{
-		singleton<GData>::GetInstance()->yz_fip = 0;
+		singleton<GData>::GetInstance()->yz_fip = 1;
 	}
 
 	singleton<GData>::GetInstance()->g_gasoffset = GetPrivateProfileIntA("Tank", "gasoffset", 0, ".//conn.ini");

+ 115 - 0
VaporRecoveryMonitor/VaporRecoveryMonitor/VaporRecoveryMonitor/vr_app.cpp

@@ -76,12 +76,15 @@ void VRMonitorApp::InitWindow ()
 		logo_station_show->SetBkImage(L"file='logo_zsh.png' dest='24,21,66,65'");
 	}
 
+
 	char chsname[50] = { 0 };
 	GetPrivateProfileStringA("other", "stationname","", chsname,50, ".//conn.ini");
 	name_station_show->SetText(chsname);
 	name_station->SetText(chsname);
 
 
+
+
 	DUI_OBJ_EXT(engine_group, CTileLayoutUI);
 	DUI_OBJ_EXT (nozzles_group, CTileLayoutUI);
 
@@ -573,6 +576,96 @@ void VRMonitorApp::OnClick (DuiLib::TNotifyUI& msg)
 		std::thread t1(func);
 		t1.detach();
 	}
+	else if (itemName == L"pressure_reset_1" ||
+			itemName == L"pressure_reset_2" ||
+			itemName == L"pressure_reset_3" || 
+			itemName == L"pressure_reset_4" || 
+			itemName == L"liquid_reset")
+	{
+		DUI_OBJ(pressure_reset_pw);
+		auto pw = pressure_reset_pw->GetText();
+
+
+		Sensor_Pressure* ppress  = nullptr;
+		string key = "";
+		
+		if (itemName == L"pressure_reset_1")
+		{
+			ppress = g_pressgroup.GetPress1();
+			key = "ZeroOffset";
+		}
+		else if (itemName == L"pressure_reset_2")
+		{
+			ppress = g_pressgroup.GetPress2();
+			key = "Zero2";
+		}
+		else if (itemName == L"pressure_reset_3")
+		{
+			ppress = g_pressgroup.GetPress3();
+			key = "Zero3";
+		}
+		else if (itemName == L"pressure_reset_4")
+		{
+			ppress = g_pressgroup.GetPress4();
+			key = "Zero4";
+		}
+		else if (itemName == L"liquid_reset")
+		{
+			ppress = g_liquidgroup.GetLiquid();
+			key = "ZeroOffset2";
+		}
+
+		if (pw == L"1248")
+		{
+			if (ppress->isWorking())
+			{
+				auto setoffset = [](string key,double offset){
+					WritePrivateProfileStringA("Tank", key.c_str(), to_string(offset).c_str(), ".//conn.ini");
+					};
+
+				double offset = ppress->getZeroOffset();
+				double press = ppress->getdata() / 100.0;
+				offset += press;
+				setoffset(key, offset);
+				ppress->setZeroOffset(offset);
+				ppress->setdata(0);
+
+
+
+				if (itemName == L"pressure_reset_1")
+				{
+					g_EnvironmentData.TankPressure[0] = ppress->getdata();
+				}
+				else if (itemName == L"pressure_reset_2")
+				{
+					g_EnvironmentData.TankPressure[1] = ppress->getdata();
+				}
+				else if (itemName == L"pressure_reset_3")
+				{
+					g_EnvironmentData.TankPressure[2] = ppress->getdata();
+				}
+				else if (itemName == L"pressure_reset_4")
+				{
+					g_EnvironmentData.TankPressure[3] = ppress->getdata();
+				}
+				else if (itemName == L"liquid_reset")
+				{
+					g_EnvironmentData.LiquidResistance = ppress->getdata();
+				}
+
+				MessageBox(GetHWND(), L"校准成功", L"提示", 0);
+			}
+			else
+			{
+				MessageBox(GetHWND(), L"压力数据必须处于正常状态才可校准", nullptr, 0);
+			}
+		}
+		else
+		{
+			MessageBox(GetHWND(), L"密码不对", nullptr, 0);
+		}
+
+	}
 	else if(itemName == L"new_nozzle")
 	{
 		DUI_OBJ (nozzle_list);
@@ -899,6 +992,15 @@ void VRMonitorApp::OnClick (DuiLib::TNotifyUI& msg)
 	{
 		DUI_OBJ_EXT(setting_tab, CTabLayoutUI);
 		setting_tab->SelectItem(1);
+	}
+	else if (itemName == L"setting3")
+	{
+		DUI_OBJ_EXT(setting_tab, CTabLayoutUI);
+		setting_tab->SelectItem(2);
+
+
+
+
 	}
 	else if (itemName == L"gas_percentage" || itemName == L"gas_percentage_text" )
 	{
@@ -1030,6 +1132,19 @@ LRESULT VRMonitorApp::HandleCustomMessage (UINT uMsg, WPARAM wParam, LPARAM lPar
 
 			UpdateReportState();
 
+
+			DUI_OBJ(reset_tankpressure_1);
+			DUI_OBJ(reset_tankpressure_2);
+			DUI_OBJ(reset_tankpressure_3);
+			DUI_OBJ(reset_tankpressure_4);
+			DUI_OBJ(reset_liquid);
+			reset_tankpressure_1->SetText(string2Duistring(g_pressgroup.GetPress1()->getText()));
+			reset_tankpressure_2->SetText(string2Duistring(g_pressgroup.GetPress2()->getText()));
+			reset_tankpressure_3->SetText(string2Duistring(g_pressgroup.GetPress3()->getText()));
+			reset_tankpressure_4->SetText(string2Duistring(g_pressgroup.GetPress4()->getText()));
+			reset_liquid->SetText(string2Duistring(g_liquidgroup.GetLiquid()->getText()));
+
+
 			if (times++ % 3 == 0)
 			{
 				update_callback();

BIN
VaporRecoveryMonitor/油气回收系统安装包/油气回收在线监控系统安装包/files/VR/VaporRecoveryMonitor.exe


+ 1 - 1
VaporRecoveryMonitor/油气回收系统安装包/油气回收在线监控系统安装包/files/VR/conn.ini

@@ -871,7 +871,7 @@ EnableOil_12=0
 Oil_12_Type=0
 Oil_12_Addr=0
 
-;安装液阻传感器加油机编号(1-9),没有时填0
+;安装管线压力传感器加油机编号(1-9),没有时填0
 fip=0
 ;气体浓度误差范围调整,单位ppm,最大200
 gasoffset=100

BIN
VaporRecoveryMonitor/油气回收系统安装包/油气回收在线监控系统安装包/files/VR/iniConfigTool.exe


+ 65 - 3
VaporRecoveryMonitor/油气回收系统安装包/油气回收在线监控系统安装包/files/VR/skin_1366_768/setting.xml

@@ -5,6 +5,7 @@
     <horizontallayout height="36" bkcolor="#ff2460a0" textpadding="20,0,0,0">
       <option   name="setting1"  width="100"  text="设置1"  group="setting" font ="316" textcolor="#ffffffff" bkcolor="#ff2460a0" selectedbkcolor="#ff95b4de" selectedtextcolor="#ffffffff" selected="true"></option>
       <option   name="setting2"  width="100"  text="设置2"  group="setting" font ="316" textcolor="#ffffffff" bkcolor="#ff2460a0" selectedbkcolor="#ff95b4de" selectedtextcolor="#ffffffff"></option>
+      <option   name="setting3"  width="100"  text="零压校准"  group="setting" font ="316" textcolor="#ffffffff" bkcolor="#ff2460a0" selectedbkcolor="#ff95b4de" selectedtextcolor="#ffffffff"></option>
       
 
       <label></label>
@@ -105,19 +106,80 @@
         <horizontallayout>
         </horizontallayout>
 
-
         <horizontallayout height="40">
           <label></label>
           <button name="saveconfig" text="保存" width="120"  bkcolor="#ff2460a0" textcolor="0xffffffff" font ="515"></button>
         </horizontallayout>
 
-
       </verticallayout>
-  
       </horizontallayout>
 
 
       
+       <horizontallayout padding="5,10,5,5" bkcolor="#ffd6dfea">
+       <verticallayout padding="15,15,5,5">
+         
+         
+        <horizontallayout  height="30" >
+          <label text ="零压校准(调零)须知:校准时传感器必须已经安装固定好,并处于大气压之下" width="800" font ="515"></label>
+        </horizontallayout>
+
+        <horizontallayout>
+        </horizontallayout>
+         
+         <horizontallayout  height="30" >
+           <label text ="校准密码:" width="120" font ="515"></label>
+           <edit name="pressure_reset_pw" width="250" font ="515"> </edit>
+         </horizontallayout>
+         
+        <horizontallayout  height="50" >
+        <label text ="油罐压力1:" width="120" font ="515"></label>
+        <label name="reset_tankpressure_1" width="150" font ="515"> </label>
+ <button name="pressure_reset_1" text="校准" padding="0,10,0,0" height="30" width="120"  bkcolor="#ff2460a0" textcolor="0xffffffff" font ="515"></button>
+        </horizontallayout>
+         
+         
+        <horizontallayout  height="50" >
+        <label text ="油罐压力2:" width="120" font ="515"></label>
+        <label name="reset_tankpressure_2" width="150" font ="515"> </label>
+ <button name="pressure_reset_2" text="校准" padding="0,10,0,0" height="30" width="120"  bkcolor="#ff2460a0" textcolor="0xffffffff" font ="515"></button>
+        </horizontallayout>
+         
+        <horizontallayout  height="50" >
+        <label text ="油罐压力3:" width="120" font ="515"></label>
+        <label name="reset_tankpressure_3" width="150" font ="515"> </label>
+ <button name="pressure_reset_3" text="校准" padding="0,10,0,0" height="30" width="120"  bkcolor="#ff2460a0" textcolor="0xffffffff" font ="515"></button>
+        </horizontallayout>  
+           
+         
+        <horizontallayout  height="50" >
+        <label text ="油罐压力4:" width="120" font ="515"></label>
+        <label name="reset_tankpressure_4" width="150" font ="515"> </label>
+ <button name="pressure_reset_4" text="校准" padding="0,10,0,0" height="30" width="120"  bkcolor="#ff2460a0" textcolor="0xffffffff" font ="515"></button>
+        </horizontallayout>
+       
+         
+        <horizontallayout  height="50" >
+        <label text ="管线压力:" width="120" font ="515"></label>
+        <label name="reset_liquid" width="150" font ="515"> </label>
+ <button name="liquid_reset" text="校准" padding="0,10,0,0" height="30" width="120"  bkcolor="#ff2460a0" textcolor="0xffffffff" font ="515"></button>
+        </horizontallayout>
+       
+         
+        <horizontallayout>
+        </horizontallayout>
+        <horizontallayout>
+        </horizontallayout>
+        <horizontallayout>
+        </horizontallayout>
+         <horizontallayout>
+         </horizontallayout>
+      
+      </verticallayout>
+      </horizontallayout>
+    
+    
+      
       
     </tablayout>
     

BIN
iniConfigTool/Bin/iniConfigTool.exe


BIN
iniConfigTool/iniConfigTool.v12.suo


+ 44 - 1
iniConfigTool/iniConfigTool/PvConfig.cpp

@@ -30,6 +30,9 @@ void CPvConfig::DoDataExchange(CDataExchange* pDX)
 	DDX_Control(pDX, IDC_EDIT_POST_PRESS, ED_POST_PRESS);
 	DDX_Control(pDX, IDC_EDIT_POST_PRESS_S, ED_POST_PRESS_S);
 	DDX_Control(pDX, IDC_EDIT_POST_ID, ED_POST_ID);
+	DDX_Control(pDX, IDC_EDIT_UpperLimit, ED_UpperLimit);
+	DDX_Control(pDX, IDC_EDIT_LowerLimit, ED_LowerLimit);
+	DDX_Control(pDX, IDC_EDIT_Liquid_Fip, ED_Liquid_Fip);
 }
 
 
@@ -40,6 +43,10 @@ BEGIN_MESSAGE_MAP(CPvConfig, CDialogEx)
 	ON_EN_CHANGE(IDC_EDIT_POST_PRESS, &CPvConfig::OnEnChangeEditPostPress)
 	ON_EN_CHANGE(IDC_EDIT_POST_PRESS_S, &CPvConfig::OnEnChangeEditPostPressS)
 	ON_EN_CHANGE(IDC_EDIT_POST_ID, &CPvConfig::OnEnChangeEditPostId)
+	ON_EN_CHANGE(IDC_EDIT_UpperLimit, &CPvConfig::OnEnChangeEditUpperlimit)
+	ON_EN_CHANGE(IDC_EDIT_LowerLimit, &CPvConfig::OnEnChangeEditLowerlimit)
+	ON_EN_CHANGE(IDC_EDIT_Liquid_Fip, &CPvConfig::OnEnChangeEditLiquidFip)
+	ON_BN_CLICKED(IDC_BUTTON1, &CPvConfig::OnBnClickedButton1)
 END_MESSAGE_MAP()
 
 
@@ -62,6 +69,10 @@ BOOL CPvConfig::OnInitDialog()
 	int POST_Press_S = GetPrivateProfileIntA("PostProcess", "Pressure_S", 0, ".//conn.ini");
 	int POST_ID = GetPrivateProfileIntA("PostProcess", "id", 0, ".//conn.ini");
 
+	int UpperLimit = GetPrivateProfileIntA("Tank", "UpperLimit", 0, ".//conn.ini");
+	int LowerLimit = GetPrivateProfileIntA("Tank", "LowerLimit", 0, ".//conn.ini");
+	int Liquid_Fip = GetPrivateProfileIntA("Tank", "fip", 0, ".//conn.ini");
+
 
 	ED_PV_PRESS.SetWindowTextA(to_string(PV_Press).c_str());
 	ED_PV_PRESS_N.SetWindowTextA(to_string(-1* PV_Press_N).c_str());
@@ -71,7 +82,9 @@ BOOL CPvConfig::OnInitDialog()
 	ED_POST_PRESS_S.SetWindowTextA(to_string(-1 * POST_Press_S).c_str());
 	ED_POST_ID.SetWindowTextA(to_string(POST_ID).c_str());
 
-
+	ED_UpperLimit.SetWindowTextA(to_string(UpperLimit).c_str());
+	ED_LowerLimit.SetWindowTextA(to_string(-1 * LowerLimit).c_str());
+	ED_Liquid_Fip.SetWindowTextA(to_string(Liquid_Fip).c_str());
 
 
 
@@ -125,3 +138,33 @@ void CPvConfig::OnEnChangeEditPostId()
 	ED_POST_ID.GetWindowTextA(str);
 	WritePrivateProfileStringA("PostProcess", "id", str, ".//conn.ini");
 }
+
+
+void CPvConfig::OnEnChangeEditUpperlimit()
+{
+	CString str;
+	ED_UpperLimit.GetWindowTextA(str);
+	WritePrivateProfileStringA("Tank", "UpperLimit", str, ".//conn.ini");
+}
+
+
+void CPvConfig::OnEnChangeEditLowerlimit()
+{
+	CString str;
+	ED_LowerLimit.GetWindowTextA(str);
+	WritePrivateProfileStringA("Tank", "LowerLimit", ("-" + str), ".//conn.ini");
+}
+
+
+void CPvConfig::OnEnChangeEditLiquidFip()
+{
+	CString str;
+	ED_Liquid_Fip.GetWindowTextA(str);
+	WritePrivateProfileStringA("Tank", "fip", str, ".//conn.ini");
+}
+
+
+void CPvConfig::OnBnClickedButton1()
+{
+	OnOK();
+}

+ 7 - 0
iniConfigTool/iniConfigTool/PvConfig.h

@@ -33,4 +33,11 @@ public:
 	afx_msg void OnEnChangeEditPostPress();
 	afx_msg void OnEnChangeEditPostPressS();
 	afx_msg void OnEnChangeEditPostId();
+	afx_msg void OnEnChangeEditUpperlimit();
+	afx_msg void OnEnChangeEditLowerlimit();
+	afx_msg void OnEnChangeEditLiquidFip();
+	CEdit ED_UpperLimit;
+	CEdit ED_LowerLimit;
+	CEdit ED_Liquid_Fip;
+	afx_msg void OnBnClickedButton1();
 };

BIN
iniConfigTool/iniConfigTool/Release/iniConfigTool.res


+ 3 - 3
iniConfigTool/iniConfigTool/conn.ini

@@ -144,9 +144,9 @@ Comm=0
 ;串口号(485)
 Comm_485=1
 ;量程上限,单位kPa,整数 
-UpperLimit=3
+UpperLimit=5
 ;量程下限,单位kPa , 负整数
-LowerLimit=-3
+LowerLimit=-5
 ;零压误差,油罐零压时后台显示的压力,单位 Pa , 两位小数
 ZeroOffset = 0
 ;液阻压力传感器的零压误差
@@ -191,7 +191,7 @@ Well_2_Type=1
 Well_2_Addr=8
 
 ;安装液阻传感器加油机编号(1-9),没有时填0
-fip=1
+fip=3
 TankPress_Addr=1
 EnableTankPress=1
 Well_2_Addr=7

BIN
iniConfigTool/iniConfigTool/iniConfigTool.rc


BIN
iniConfigTool/iniConfigTool/resource.h