Ver Fonte

Merge branch 'master' of https://git.steerinfo.com/caol/jisco_winform_wzjl.git

duyong há 4 anos atrás
pai
commit
bf1b483577
2 ficheiros alterados com 38 adições e 6 exclusões
  1. 1 1
      CarMeterSystem/frmMain.cs
  2. 37 5
      MeterPlugInLibrary/LED/LED_Control.cs

+ 1 - 1
CarMeterSystem/frmMain.cs

@@ -169,7 +169,7 @@ namespace CarMeterSystem
                         collection.EventDataCollectionArgs += new EventDataCollection(EventData);//数据采集及扫码信息
                         collection.Start(PbCache.sportInfo.baseSpotNo, PbCache.sportInfo.baseSpotName);
 
-                        imageCurlControl.Start(); //图片上传线程
+                        //imageCurlControl.Start(); //图片上传线程
                         sweepCodeClass.StartThreadSweep(); //扫码线程
                     }
                     else

+ 37 - 5
MeterPlugInLibrary/LED/LED_Control.cs

@@ -282,6 +282,23 @@ namespace MeterPlugInLibrary
 
         public void setStatic4LineMsg(string Ip, string ledInfo)
         {
+            string info1 = "";
+            string info2 = "";
+            string info3 = "";
+            string info4 = "";
+
+            //split ledInfo
+            string[] list = ledInfo.Split(',');
+
+
+            for(int i=0; i<list.Length; i++)
+            {
+                if (i == 0) info1 = list[0];
+                if (i == 1) info2 = list[1];
+                if (i == 2) info3 = list[2];
+                if (i == 3) info4 = list[3];
+            }
+
             int nResult;
             LedDll.COMMUNICATIONINFO CommunicationInfo = new LedDll.COMMUNICATIONINFO();//定义一通讯参数结构体变量用于对设定的LED通讯,具体对此结构体元素赋值说明见COMMUNICATIONINFO结构体定义部份注示
 
@@ -313,21 +330,36 @@ namespace MeterPlugInLibrary
             //int nsize = System.Runtime.InteropServices.Marshal.SizeOf(typeof(LedDll.FONTPROP));
 
             nResult = LedDll.LV_AddImageTextArea(hProgram, 1, 2, ref AreaRect, 0);
+
             //nResult = LedDll.LV_QuickAddSingleLineTextArea(hProgram, 1, 2, ref AreaRect, LedDll.ADDTYPE_STRING, ledInfo, ref FontProp, 4);//快速通过字符添加一个单行文本区域,函数见函数声明注示
             AreaRect.left = 0;
             AreaRect.top = 0;
             AreaRect.width = 192;
-            AreaRect.height = 64;
+            AreaRect.height = 15;
 
-            nResult = LedDll.LV_AddStaticTextToImageTextArea(hProgram, 1, 2, LedDll.ADDTYPE_STRING, ledInfo, ref FontProp, 1, 2, 1);//快速通过字符添加一个单行文本区域,函数见函数声明注示
+            nResult = LedDll.LV_AddStaticTextToImageTextArea(hProgram, 1, 2, LedDll.ADDTYPE_STRING, info1, ref FontProp, 1, 2, 1);//快速通过字符添加一个单行文本区域,函数见函数声明注示
 
 
             AreaRect.left = 0;
-            AreaRect.top = 20;
+            AreaRect.top = 15;
             AreaRect.width = 192;
-            AreaRect.height = 64;
+            AreaRect.height = 15;
 
-            nResult = LedDll.LV_AddStaticTextToImageTextArea(hProgram, 1, 2, LedDll.ADDTYPE_STRING, ledInfo, ref FontProp, 1, 2, 1);//快速通过字符添加一个单行文本区域,函数见函数声明注示
+            nResult = LedDll.LV_AddStaticTextToImageTextArea(hProgram, 1, 2, LedDll.ADDTYPE_STRING, info2, ref FontProp, 1, 2, 1);//快速通过字符添加一个单行文本区域,函数见函数声明注示
+
+            AreaRect.left = 0;
+            AreaRect.top = 30;
+            AreaRect.width = 192;
+            AreaRect.height = 15;
+
+            nResult = LedDll.LV_AddStaticTextToImageTextArea(hProgram, 1, 2, LedDll.ADDTYPE_STRING, info3, ref FontProp, 1, 2, 1);//快速通过字符添加一个单行文本区域,函数见函数声明注示
+
+            AreaRect.left = 0;
+            AreaRect.top = 45;
+            AreaRect.width = 192;
+            AreaRect.height = 15;
+
+            nResult = LedDll.LV_AddStaticTextToImageTextArea(hProgram, 1, 2, LedDll.ADDTYPE_STRING, info4, ref FontProp, 1, 2, 1);//快速通过字符添加一个单行文本区域,函数见函数声明注示