From d3a9358843b9539017debde289fb38e4fdf26938 Mon Sep 17 00:00:00 2001
From: wei <kaede@kaededeMacBook-Air.local>
Date: 星期二, 23 三月 2021 09:18:48 +0800
Subject: [PATCH] 增加新风bus命令
---
HDL_ON/Entity/Function/Scene.cs | 6
HDL_ON/UI/UI2/FuntionControlView/1ContorlPage/AcControlPage.cs | 2
DLL/.DS_Store | 0
HDL_ON/Common/ApiUtlis.cs | 44 +++-----
HDL_ON/DAL/DriverLayer/Control_Udp.cs | 7 +
HDL_ON/Entity/Enumerative/Command.cs | 87 +++++++++++++---
HDL_ON/Entity/FunctionList.cs | 10 ++
HDL_ON/Entity/Function/Function.cs | 34 ++++++
HDL_ON/UI/UI2/FuntionControlView/1ContorlPage/FhControlPage.cs | 2
HDL_ON/DAL/Server/HttpServerRequest.cs | 12 ++
HDL_ON/DAL/DriverLayer/Packet.cs | 49 +++++++++
HDL_ON/UI/UI2/FuntionControlView/AC/ACPageBLL.cs | 2
HDL_ON/UI/UI2/FuntionControlView/FoolHeating/FloorHeatingPageBLL.cs | 2
.vs/HDL_APP_Project/xs/UserPrefs.xml | 27 +++--
HDL_ON/UI/UI1-Login/LoginPage.cs | 6
15 files changed, 222 insertions(+), 68 deletions(-)
diff --git a/.vs/HDL_APP_Project/xs/UserPrefs.xml b/.vs/HDL_APP_Project/xs/UserPrefs.xml
index 2c68f5f..ff802b6 100644
--- a/.vs/HDL_APP_Project/xs/UserPrefs.xml
+++ b/.vs/HDL_APP_Project/xs/UserPrefs.xml
@@ -1,15 +1,20 @@
锘�<Properties StartupConfiguration="{D998E133-F0DD-4760-BE3C-461632F54DA4}|Default">
- <MonoDevelop.Ide.ItemProperties.HDL-ON__iOS PreferredExecutionTarget="MonoDevelop.IPhone.IPhoneSimulatorTarget." />
- <MonoDevelop.Ide.Workbench ActiveDocument="HDL_ON/UI/UI2/FuntionControlView/EnvironmentalScience/EchartsOption_Pie.cs">
+ <MonoDevelop.Ide.ItemProperties.HDL-ON__iOS PreferredExecutionTarget="MonoDevelop.IPhone.IPhoneSimulatorTarget.94B44E9C-E1BC-4BF7-812E-FC71E9B623B2" />
+ <MonoDevelop.Ide.Workbench ActiveDocument="HDL_ON/Entity/Function/Function.cs">
<Files>
- <File FileName="HDL_ON/DAL/Server/HttpUtil.cs" Line="6" Column="19" />
<File FileName="HDL_ON/UI/UI2/FuntionControlView/EnvironmentalScience/EnvironmentalPage.cs" />
<File FileName="HDL_ON/UI/MainPage.cs" />
<File FileName="HDL_ON/UI/UI2/FuntionControlView/EnvironmentalScience/EnvironmentalSensorPage.cs" />
<File FileName="HDL_ON/UI/UI0-Public/PublicAssmebly.cs" />
<File FileName="HDL_ON/DAL/Server/IMessageCommon.cs" />
<File FileName="HDL_ON/UI/UI2/FuntionControlView/EnvironmentalScience/EchartsOption.cs" />
- <File FileName="HDL_ON/UI/UI2/FuntionControlView/EnvironmentalScience/EchartsOption_Pie.cs" Line="34" Column="1" />
+ <File FileName="HDL_ON/UI/UI2/FuntionControlView/EnvironmentalScience/EchartsOption_Pie.cs" Line="26" Column="29" />
+ <File FileName="HDL_ON/Entity/Enumerative/MyEnum.cs" Line="47" Column="23" />
+ <File FileName="HDL_ON/DAL/DriverLayer/Control_Udp.cs" Line="633" Column="51" />
+ <File FileName="HDL_ON/DAL/DriverLayer/Packet.cs" Line="641" Column="59" />
+ <File FileName="HDL_ON/UI/UI1-Login/LoginPage.cs" Line="197" Column="18" />
+ <File FileName="HDL_ON/DAL/DriverLayer/Control.cs" Line="382" Column="59" />
+ <File FileName="HDL_ON/Entity/Function/Function.cs" Line="1052" Column="47" />
</Files>
<Pads>
<Pad Id="ProjectPad">
@@ -23,21 +28,24 @@
</Node>
<Node name="Entity" expanded="True">
<Node name="Device" expanded="True" />
- <Node name="Function" expanded="True" />
+ <Node name="Enumerative" expanded="True" />
+ <Node name="Function" expanded="True">
+ <Node name="Function.cs" selected="True" />
+ </Node>
<Node name="ResponseEntity" expanded="True" />
</Node>
<Node name="UI" expanded="True">
<Node name="CSS" expanded="True" />
- <Node name="UI0-Public" expanded="True" />
<Node name="UI1-Login" expanded="True" />
<Node name="UI2" expanded="True">
<Node name="1-HomePage" expanded="True" />
<Node name="2-Classification" expanded="True" />
+ <Node name="4-PersonalCenter" expanded="True">
+ <Node name="AddDevice" expanded="True" />
+ </Node>
<Node name="FuntionControlView" expanded="True">
<Node name="1ContorlPage" expanded="True" />
- <Node name="EnvironmentalScience" expanded="True">
- <Node name="EchartsOption_Pie.cs" selected="True" />
- </Node>
+ <Node name="EnvironmentalScience" expanded="True" />
</Node>
</Node>
</Node>
@@ -72,7 +80,6 @@
<String>Shared.IOS/Shared.IOS.csproj</String>
</DisabledProjects>
<MonoDevelop.Ide.Workspace ActiveConfiguration="Debug" />
- <MonoDevelop.Ide.ItemProperties.HDL-ON__Android PreferredExecutionTarget="Android.SelectDevice" />
<MonoDevelop.Ide.DebuggingService.Breakpoints>
<BreakpointStore />
</MonoDevelop.Ide.DebuggingService.Breakpoints>
diff --git a/DLL/.DS_Store b/DLL/.DS_Store
index c8509ed..9894ff5 100644
--- a/DLL/.DS_Store
+++ b/DLL/.DS_Store
Binary files differ
diff --git a/HDL_ON/Common/ApiUtlis.cs b/HDL_ON/Common/ApiUtlis.cs
index 1517a67..2c87fbc 100644
--- a/HDL_ON/Common/ApiUtlis.cs
+++ b/HDL_ON/Common/ApiUtlis.cs
@@ -172,28 +172,6 @@
continue;
}
var newFunction = deviceList.list.Find((obj) => obj.deviceId == localFunction.deviceId);
- //if (newFunction == null)//濡傛灉浜戠鏈�鏂版暟鎹病鏈夎鏉℃暟鎹紝鍒欐湰鍦伴渶瑕佸垹鎺夎鏁版嵁璁板綍
- //{
- // FunctionList.List.DeleteFunction(localFunction);
- //}
- //else
- //{
- // MainPage.Log($"deviceType:{localFunction.spk} local:{localFunction.modifyTime} server:{newFunction.modifyTime}");
- // i++;
- // //if (localFunction.modifyTime != newFunction.modifyTime)
- // //{
- // // //鍙紭鍖�
- // // localFunction.name = newFunction.name;
- // // localFunction.collect = newFunction.collect;
- // // localFunction.modifyTime = newFunction.modifyTime;
- // // localFunction.roomIds = newFunction.roomIds;
- // // localFunction.bus = newFunction.bus;
- // // localFunction.SaveFunctionFile();
- // //}
- // localFunction = newFunction;
- // localFunction.SaveFunctionFile();
- // deviceList.list.Remove(newFunction);//鎿嶄綔瀹岀殑鏁版嵁娓呯悊鎺夛紝鍓╀笅鐨勫氨鏄柊澧炵殑鍔熻兘
- //}
if (delFile == localFunction.savePath)
{
@@ -202,10 +180,7 @@
}
delFile = localFunction.savePath;
FunctionList.List.DeleteFunction(localFunction);
-
}
-
-
}
//澶勭悊鍓╀笅鐨勬柊澧炲姛鑳�
foreach (var newFunction in deviceList.list)
@@ -369,5 +344,24 @@
})
{ IsBackground = true }.Start();
}
+
+ /// <summary>
+ /// 鑾峰彇鍔熻兘淇℃伅
+ /// </summary>
+ public void GetFunctionInfo(string functionId)
+ {
+ var deviceResult = Ins.HttpRequest.GetDeviceInfo(functionId);
+ if (deviceResult.Code == StateCode.SUCCESS)
+ {
+ MainPage.Log($"璇诲彇璁惧淇℃伅鎴愬姛");
+ var packList = Newtonsoft.Json.JsonConvert.DeserializeObject<DevcieApiPack>(deviceResult.Data.ToString());
+
+ foreach(var function in packList.list)
+ {
+ function.SaveFunctionFile();
+ FunctionList.List.IniFunctionList(function.savePath,true);
+ }
+ }
+ }
}
}
\ No newline at end of file
diff --git a/HDL_ON/DAL/DriverLayer/Control_Udp.cs b/HDL_ON/DAL/DriverLayer/Control_Udp.cs
index 35e8539..54d9b11 100644
--- a/HDL_ON/DAL/DriverLayer/Control_Udp.cs
+++ b/HDL_ON/DAL/DriverLayer/Control_Udp.cs
@@ -630,6 +630,9 @@
break;
}
break;
+ case FunctionCategory.AirFresh:
+
+ break;
}
#region 鍙戦�佸懡浠ょ珛鍗虫洿鏂癠I
//HomePage.UpdataFunctionStates(function);
@@ -890,6 +893,10 @@
case Command.SetACMode:
case Command.ReadFloorHeat:
case Command.SetFloorHeat:
+ case Command.FreshAirRead:
+ case Command.FreshAirControl:
+ case Command.FreshAirRead_JinMao:
+ case Command.FreshAirControl_JinMao:
this.sendFlag += string.Format("{0}", target.AddData[0]);
break;
case Command.SetLogicLoopColor:
diff --git a/HDL_ON/DAL/DriverLayer/Packet.cs b/HDL_ON/DAL/DriverLayer/Packet.cs
index b99f6dd..5f0b9f5 100644
--- a/HDL_ON/DAL/DriverLayer/Packet.cs
+++ b/HDL_ON/DAL/DriverLayer/Packet.cs
@@ -315,7 +315,7 @@
if (function.GetBusId() == subnetID + "_" + deviceID + "_" + receiveBytes[0])
{
function.SetAttrState(FunctionAttributeKey.TempType, receiveBytes[1].ToString());
- function.SetAttrState(FunctionAttributeKey.IndoorTemp, receiveBytes[2].ToString());
+ function.SetAttrState(FunctionAttributeKey.RoomTemp, receiveBytes[2].ToString());
function.trait_on_off.curValue = receiveBytes[8] == 1 ? "on" : "off";
acFunction.SetMode(receiveBytes[9],function);
acFunction.SetFan(receiveBytes[10],function);
@@ -446,7 +446,7 @@
{
indoorTemp = receiveBytes[9];
}
- function.SetAttrState(FunctionAttributeKey.IndoorTemp, indoorTemp);
+ function.SetAttrState(FunctionAttributeKey.RoomTemp, indoorTemp);
function.lastState += " " + function.GetAttrState(FunctionAttributeKey.Mode) + new FloorHeating().GetTempUnitString(function);
RoomPage.UpdataStates(function);
@@ -621,7 +621,7 @@
{
if (ac.GetBusId() == subnetID + "_" + deviceID + "_" + receiveBytes[0])
{
- ac.SetAttrState(FunctionAttributeKey.IndoorTemp, receiveBytes[1].ToString());
+ ac.SetAttrState(FunctionAttributeKey.RoomTemp, receiveBytes[1].ToString());
FunctionPage.UpdataStates(ac);
}
}
@@ -636,6 +636,45 @@
Control.Ins.IsSearchLocalGatewaySuccessful = true;
Control.Ins.GatewayOnline_Local = true;
DAL.Mqtt.MqttClient.DisConnectRemote();//鏂紑mqtt
+ }
+ break;
+ case Command.FreshAirControlACK_JinMao:
+ case Command.FreshAirReadACK_JinMao:
+ var airFresh = FunctionList.List.GetAirFreshList().Find((obj) => obj.GetBusId() == subnetID + "_" + deviceID + "_" + receiveBytes[0]);
+ if (airFresh != null)
+ {
+ /// 3 寮�鍏� 0-鍏虫満锛�1-寮�鏈�
+ /// 4 杩愯妯″紡 1-閫氶锛�2-鍔犳箍 humidification/fan
+ /// 5 鑺傝兘鑸掗�傞�夋嫨 1-鑸掗�傦紝2-鑺傝兘 true/false
+ /// 6 椋庨�熸。浣� 0-鑷姩锛�1-1妗o紝2-2妗o紝3-3妗� level_1/level_2/level_3/auto
+ /// 7 婀垮害璁惧畾 %
+ /// 8 瀹ゅ唴娓╁害鍊� 鈩�
+ /// 9 瀹ゅ唴婀垮害鍊� 鈩�
+ /// 10 杩囨护缃戝墿浣� %
+ /// 11 杩囨护缃戜娇鐢ㄨ秴鏃� 1 瓒呮椂 0 鏃� true/false
+ airFresh.SetAttrState(FunctionAttributeKey.OnOff, receiveBytes[2] == 0 ? "off" : "on");
+ airFresh.SetAttrState(FunctionAttributeKey.Mode, receiveBytes[3] == 1 ? "humidification" : "fan");
+ airFresh.SetAttrState(FunctionAttributeKey.Energy, receiveBytes[4] == 1 ? "true" : "false");
+ switch (receiveBytes[5])
+ {
+ case 0:
+ airFresh.SetAttrState(FunctionAttributeKey.FanSpeed, "auto");
+ break;
+ case 1:
+ airFresh.SetAttrState(FunctionAttributeKey.FanSpeed, "level_1");
+ break;
+ case 2:
+ airFresh.SetAttrState(FunctionAttributeKey.FanSpeed, "level_2");
+ break;
+ case 3:
+ airFresh.SetAttrState(FunctionAttributeKey.FanSpeed, "level_3");
+ break;
+ }
+ airFresh.SetAttrState(FunctionAttributeKey.Humidity, receiveBytes[6].ToString());
+ airFresh.SetAttrState(FunctionAttributeKey.IndoorTemp, receiveBytes[7].ToString());
+ airFresh.SetAttrState(FunctionAttributeKey.IndoorHumidity, receiveBytes[8].ToString());
+ airFresh.SetAttrState(FunctionAttributeKey.FilterRemain, receiveBytes[9].ToString());
+ airFresh.SetAttrState(FunctionAttributeKey.FilterTimeout, receiveBytes[10] == 1 ? "true" : "false");
}
break;
}
@@ -672,6 +711,10 @@
switch (command)
{
case Command.SetSingleLightACK:
+ case Command.FreshAirReadACK:
+ case Command.FreshAirControlACK:
+ case Command.FreshAirReadACK_JinMao:
+ case Command.FreshAirControlACK_JinMao:
receiveFlag += string.Format("{0}", usefulBytes[0]);
break;
case Command.SetLogicLoopColorACK:
diff --git a/HDL_ON/DAL/Server/HttpServerRequest.cs b/HDL_ON/DAL/Server/HttpServerRequest.cs
index 615f915..288ddf1 100644
--- a/HDL_ON/DAL/Server/HttpServerRequest.cs
+++ b/HDL_ON/DAL/Server/HttpServerRequest.cs
@@ -1816,7 +1816,19 @@
return HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_Get3tyBrandDevcieList, requestJson);
}
+ /// <summary>
+ /// 鑾峰彇璁惧璇︽儏
+ /// </summary>
+ /// <returns></returns>
+ public ResponsePackNew GetDeviceInfo(string functionId)
+ {
+ Dictionary<string, object> d = new Dictionary<string, object>();
+ d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
+ d.Add("deviceIds", new List<string>() { functionId });
+ var requestJson = HttpUtil.GetSignRequestJson(d);
+ return HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_GetDevcieInfoList, requestJson);
+ }
/// <summary>
/// 鑾峰彇璁惧璇︽儏鍒楄〃
diff --git a/HDL_ON/Entity/Enumerative/Command.cs b/HDL_ON/Entity/Enumerative/Command.cs
index 4bb8432..a95726f 100644
--- a/HDL_ON/Entity/Enumerative/Command.cs
+++ b/HDL_ON/Entity/Enumerative/Command.cs
@@ -14,6 +14,75 @@
ReadAnalog = 0xE50A,
ReadAnalogACK = 0xE50B,
+ #region 鏂伴鍗忚
+ //鏂伴鍗忚鎺у埗
+ //闄勫姞鏁版嵁锛� 鏂伴閫氶亾鍙凤紙1 - 200锛� + 寮�鍏筹紙0锛�1锛� + 椋庨�燂紙0 鍏筹紝1浣庯紝2涓紝3楂橈級 + 妯″紡锛�0鎵嬪姩锛�1 鑷姩,2 鏅鸿兘锛�3 瀹氭椂锛�
+ FreshAirControl = 0x144A,
+ //杩斿洖锛氭柊椋庨�氶亾鍙凤紙1 - 200锛� + 寮�鍏筹紙0锛�1锛� + 椋庨�燂紙0 鍏筹紝1浣庯紝2涓紝3楂橈級 + 妯″紡锛�0鎵嬪姩锛�1 鑷姩,2 鏅鸿兘锛�3 瀹氭椂锛�+妯℃嫙閲忥紙2byte==16bit锛�+
+ //瀹ゅ唴娓╁害(4byte) + 瀹ゅ娓╁害(4byte) + 瀹ゅ唴婀垮害(4byte)+ PM2.5(4byte) + TVOC(4byte) + CO2(4byte)
+ FreshAirControlACK = 0x144B,
+ //2.鏂伴鍗忚璇荤姸鎬�
+ //闄勫姞鏁版嵁锛� 鏂伴閫氶亾鍙凤紙1 - 200锛�
+ FreshAirRead = 0x144C,
+ //杩斿洖锛氭柊椋庨�氶亾鍙凤紙1 - 200锛� + 寮�鍏筹紙0锛�1锛� + 椋庨�燂紙0 鍏筹紝1浣庯紝2涓紝3楂橈級 + 妯″紡锛�0鎵嬪姩锛�1 鑷姩,2 鏅鸿兘锛�3 瀹氭椂锛� +妯℃嫙閲忥紙2byte==16bit锛�+
+ //瀹ゅ唴娓╁害(4byte) + 瀹ゅ娓╁害(4byte) + 瀹ゅ唴婀垮害(4byte)+ PM2.5(4byte) + TVOC(4byte) + CO2(4byte)
+ FreshAirReadACK = 0x144D,
+ #endregion
+
+ #region 閲戣寕搴� 鏄嗘槑 娓╁窞 鏂伴鍗忚
+ /// <summary>
+ /// 闄勫姞鏁版嵁闀垮害:1
+ /// 鏂伴缂栧彿 1~200
+ /// </summary>
+ FreshAirRead_JinMao = 0x1446,
+ /// <summary>
+ /// 闄勫姞鏁版嵁闀垮害:30
+ /// 1 鏂伴缂栧彿 1~200
+ /// 2 绫诲瀷 绗笁鏂圭被鍨� 0锛氶噾鑼傛柊椋�
+ /// 3 寮�鍏� 0-鍏虫満锛�1-寮�鏈�
+ /// 4 杩愯妯″紡 1-閫氶锛�2-鍔犳箍
+ /// 5 鑺傝兘鑸掗�傞�夋嫨 1-鑸掗�傦紝2-鑺傝兘
+ /// 6 椋庨�熸。浣� 0-鑷姩锛�1-1妗o紝2-2妗o紝3-3妗�
+ /// 7 婀垮害璁惧畾 %
+ /// 8 瀹ゅ唴娓╁害鍊� 鈩�
+ /// 9 瀹ゅ唴婀垮害鍊� 鈩�
+ /// 10 杩囨护缃戝墿浣� %
+ /// 11 杩囨护缃戜娇鐢ㄨ秴鏃� 1 瓒呮椂 0 鏃�
+ /// </summary>
+ FreshAirReadACK_JinMao = 0x1447,
+ /// <summary>
+ /// 闄勫姞鏁版嵁闀垮害:4
+ /// 1 鏂伴缂栧彿 1~200
+ /// 2 绫诲瀷 绗笁鏂圭被鍨� 0锛氶噾鑼傛柊椋�
+ /// 3 寮�鍏� 0-鍏虫満锛�1-寮�鏈�
+ /// 4 杩愯妯″紡 1-閫氶锛�2-鍔犳箍
+ /// 5 鑺傝兘鑸掗�傞�夋嫨 1-鑸掗�傦紝2-鑺傝兘
+ /// 6 椋庨�熸。浣� 0-鑷姩锛�1-1妗o紝2-2妗o紝3-3妗�
+ /// 7 婀垮害璁惧畾 %
+ /// 8 瀹ゅ唴娓╁害鍊� 鈩�
+ /// 9 瀹ゅ唴婀垮害鍊� 鈩�
+ /// 10 杩囨护缃戝墿浣� %
+ /// 11 杩囨护缃戜娇鐢ㄨ秴鏃� 1 瓒呮椂 0 鏃�
+ /// </summary>
+ FreshAirControl_JinMao = 0x1448,
+ /// <summary>
+ /// 闄勫姞鏁版嵁闀垮害:30
+ /// 1 鏂伴缂栧彿 1~200
+ /// 2 绫诲瀷 绗笁鏂圭被鍨� 0锛氶噾鑼傛柊椋�
+ /// 3 寮�鍏� 0-鍏虫満锛�1-寮�鏈�
+ /// 4 杩愯妯″紡 1-閫氶锛�2-鍔犳箍
+ /// 5 鑺傝兘鑸掗�傞�夋嫨 1-鑸掗�傦紝2-鑺傝兘
+ /// 6 椋庨�熸。浣� 0-鑷姩锛�1-1妗o紝2-2妗o紝3-3妗�
+ /// 7 婀垮害璁惧畾 %
+ /// 8 瀹ゅ唴娓╁害鍊� 鈩�
+ /// 9 瀹ゅ唴婀垮害鍊� 鈩�
+ /// 10 杩囨护缃戝墿浣� %
+ /// 11 杩囨护缃戜娇鐢ㄨ秴鏃�
+ /// </summary>
+ FreshAirControlACK_JinMao = 0x1449,
+ #endregion
+
+
#region 缁垮缓娓╂帶鍣ㄥ崗璁�
/// <summary>
/// 璇诲彇娓╂帶鍣ㄤ富鏈烘寚浠�
@@ -1222,24 +1291,6 @@
LogicstateControl = 0xE014,
LogicstateControlACK = 0xE015,
- #region 鏂伴鍗忚
- //鏂伴鍗忚鎺у埗
- //闄勫姞鏁版嵁锛� 鏂伴閫氶亾鍙凤紙1 - 200锛� + 寮�鍏筹紙0锛�1锛� + 椋庨�燂紙0 鍏筹紝1浣庯紝2涓紝3楂橈級 + 妯″紡锛�0鎵嬪姩锛�1 鑷姩,2 鏅鸿兘锛�3 瀹氭椂锛�
- FreshAirControl = 0x144A,
- //杩斿洖锛氭柊椋庨�氶亾鍙凤紙1 - 200锛� + 寮�鍏筹紙0锛�1锛� + 椋庨�燂紙0 鍏筹紝1浣庯紝2涓紝3楂橈級 + 妯″紡锛�0鎵嬪姩锛�1 鑷姩,2 鏅鸿兘锛�3 瀹氭椂锛�+妯℃嫙閲忥紙2byte==16bit锛�+
- //瀹ゅ唴娓╁害(4byte) + 瀹ゅ娓╁害(4byte) + 瀹ゅ唴婀垮害(4byte)+ PM2.5(4byte) + TVOC(4byte) + CO2(4byte)
- FreshAirControlACK = 0x144B,
-
-
- //2.鏂伴鍗忚璇荤姸鎬�
- //闄勫姞鏁版嵁锛� 鏂伴閫氶亾鍙凤紙1 - 200锛�
- FreshAirRead = 0x144C,
- //杩斿洖锛氭柊椋庨�氶亾鍙凤紙1 - 200锛� + 寮�鍏筹紙0锛�1锛� + 椋庨�燂紙0 鍏筹紝1浣庯紝2涓紝3楂橈級 + 妯″紡锛�0鎵嬪姩锛�1 鑷姩,2 鏅鸿兘锛�3 瀹氭椂锛� +妯℃嫙閲忥紙2byte==16bit锛�+
- //瀹ゅ唴娓╁害(4byte) + 瀹ゅ娓╁害(4byte) + 瀹ゅ唴婀垮害(4byte)+ PM2.5(4byte) + TVOC(4byte) + CO2(4byte)
- FreshAirReadACK = 0x144D,
-
-
- #endregion
/// <summary>
/// 甯冮槻璁剧疆
diff --git a/HDL_ON/Entity/Function/Function.cs b/HDL_ON/Entity/Function/Function.cs
index 177d948..9211829 100644
--- a/HDL_ON/Entity/Function/Function.cs
+++ b/HDL_ON/Entity/Function/Function.cs
@@ -768,7 +768,7 @@
/// <summary>
/// 瀹ゅ唴娓╁害
/// </summary>
- public const string IndoorTemp = "room_temp";
+ public const string RoomTemp = "room_temp";
/// <summary>
/// value
/// </summary>
@@ -838,7 +838,7 @@
/// </summary>
public const string AnionTimeLeft = "anion_time_surplus";
/// <summary>
- /// 鎵撳紑鐧昏(椋庢墖)
+ /// 鎵撳紑绛夌骇(椋庢墖)
/// </summary>
public const string OpenLevel = "openLevel";
/// <summary>
@@ -846,6 +846,30 @@
/// </summary>
public const string Key = "key";
+ /// <summary>
+ /// 鑺傝兘
+ /// </summary>
+ public const string Energy = "energy";
+ /// <summary>
+ /// 婀垮害
+ /// </summary>
+ public const string Humidity = "humidity";
+ /// <summary>
+ /// 瀹ゅ唴娓╁害
+ /// </summary>
+ public const string IndoorTemp = "indoor_temp";
+ /// <summary>
+ /// 瀹ゅ唴婀垮害
+ /// </summary>
+ public const string IndoorHumidity = "indoor_humidity";
+ /// <summary>
+ /// 杩囨护缃戝墿浣欓噺
+ /// </summary>
+ public const string FilterRemain = "filter_remain";
+ /// <summary>
+ /// 杩囨护缃戞槸鍚﹁秴鏃惰鍛�
+ /// </summary>
+ public const string FilterTimeout = "filter_timeout";
#region tuya
/// <summary>
@@ -1022,6 +1046,10 @@
/// 锛堟柊椋庯級
/// </summary>
public const string AirFreshStandard = "airFresh.standard";
+ /// <summary>
+ /// 鏂伴 鈥斺�旈噾鑼傚畾鍒�
+ /// </summary>
+ public const string AirFreshJinmao = "airFresh.jinmao";
/// <summary>
/// 鏂伴spk鍒楄〃
@@ -1031,6 +1059,7 @@
{
var spkList = new List<string>();
spkList.Add(AirFreshStandard);
+ spkList.Add(AirFreshJinmao);
return spkList;
}
#endregion
@@ -1181,6 +1210,7 @@
/// 绾㈠閬ユ帶鍣�
/// </summary>
public const string IrLearn = "ir.learn";
+
#region 娑傞甫
/// <summary>
/// 瀹剁數銆佹秱楦︾┖姘斿噣鍖栧櫒
diff --git a/HDL_ON/Entity/Function/Scene.cs b/HDL_ON/Entity/Function/Scene.cs
index 386ded3..6f15f57 100644
--- a/HDL_ON/Entity/Function/Scene.cs
+++ b/HDL_ON/Entity/Function/Scene.cs
@@ -446,7 +446,7 @@
case FunctionAttributeKey.SetTemp:
text = Language.StringByID(StringId.Temp);
break;
- case FunctionAttributeKey.IndoorTemp:
+ case FunctionAttributeKey.RoomTemp:
text = Language.StringByID(StringId.IndoorTemp);
break;
case FunctionAttributeKey.Delay:
@@ -475,7 +475,7 @@
switch (key)
{
case FunctionAttributeKey.SetTemp:
- case FunctionAttributeKey.IndoorTemp:
+ case FunctionAttributeKey.RoomTemp:
us = "掳C";
break;
case FunctionAttributeKey.Percent:
@@ -500,7 +500,7 @@
text = value == "on" ? Language.StringByID(StringId.On) : Language.StringByID(StringId.OFF);
break;
case FunctionAttributeKey.SetTemp:
- case FunctionAttributeKey.IndoorTemp:
+ case FunctionAttributeKey.RoomTemp:
case FunctionAttributeKey.Brightness:
case FunctionAttributeKey.Percent:
if (value == "")
diff --git a/HDL_ON/Entity/FunctionList.cs b/HDL_ON/Entity/FunctionList.cs
index fe72790..98aee72 100644
--- a/HDL_ON/Entity/FunctionList.cs
+++ b/HDL_ON/Entity/FunctionList.cs
@@ -70,6 +70,16 @@
var spkList = SPK.FhSpkList();
return Functions.FindAll((obj) => spkList.Contains(obj.spk));
}
+
+ /// <summary>
+ /// 鏂伴鍒楄〃
+ /// </summary>
+ /// <returns></returns>
+ public List<Function> GetAirFreshList()
+ {
+ var spkList = SPK.AirFreshSpkList();
+ return Functions.FindAll((obj) => spkList.Contains(obj.spk));
+ }
#region 瀹剁數鍒楄〃 electricals
/// <summary>
/// 瀹剁數鍒楄〃
diff --git a/HDL_ON/UI/UI1-Login/LoginPage.cs b/HDL_ON/UI/UI1-Login/LoginPage.cs
index ea01c2e..b8bb50a 100644
--- a/HDL_ON/UI/UI1-Login/LoginPage.cs
+++ b/HDL_ON/UI/UI1-Login/LoginPage.cs
@@ -185,20 +185,20 @@
};
bodyView.AddChidren(btnIcon_bg);
-#if DEBUG
+ #if DEBUG
bool b = false;
btnIcon.MouseUpEventHandler += (sender, e) =>
{
//return;
if (b)
{
- etAccount.Text = "18316672920";//"18316120654";//lcg "18316672920";//hzx;// "13415629083"//cf;//tujie"18316120654";
+ etAccount.Text = "Sumant.Bhatia@havells.com";//"18316120654";//lcg "18316672920";//hzx;// "13415629083"//cf;//tujie"18316120654";
// "15622703419"lwn;// "18824864143";//"464027401@qq.com"; //"2791308028@qq.com";//13697499568
}
else
{
etAccount.Text = "15971583093";//鍑夐湼"18666455392";//13375012446//13602944661//tzy 18778381374
- //15971583093 gs//tzy 274116637@qq.com
+ //15971583093 gs//tzy 274116637@qq.com//Sumant.Bhatia@havells.com 鍥藉鏈嶅姟鍣ㄦ祴璇�
}
b = !b;
etPassword.Text = "123456";
diff --git a/HDL_ON/UI/UI2/FuntionControlView/1ContorlPage/AcControlPage.cs b/HDL_ON/UI/UI2/FuntionControlView/1ContorlPage/AcControlPage.cs
index 4874520..e27dcf5 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/1ContorlPage/AcControlPage.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/1ContorlPage/AcControlPage.cs
@@ -723,7 +723,7 @@
Application.RunOnMainThread(() =>
{
btnTemp.Text = device.GetAttrState(FunctionAttributeKey.SetTemp);
- btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.IndoorTemp))) + "掳C";
+ btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.RoomTemp))) + "掳C";
btnMode.UnSelectedImagePath = acFunction.GetModeIconPath(device.GetAttrState(FunctionAttributeKey.Mode));
btnWindSpeed.UnSelectedImagePath = acFunction.GetFanIconPath(device.GetAttrState(FunctionAttributeKey.FanSpeed));
arcBar.Progress = Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.SetTemp)));
diff --git a/HDL_ON/UI/UI2/FuntionControlView/1ContorlPage/FhControlPage.cs b/HDL_ON/UI/UI2/FuntionControlView/1ContorlPage/FhControlPage.cs
index fb28e5d..bfa25c1 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/1ContorlPage/FhControlPage.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/1ContorlPage/FhControlPage.cs
@@ -458,7 +458,7 @@
Application.RunOnMainThread(() =>
{
btnTemp.Text = device.GetAttrState(FunctionAttributeKey.SetTemp);
- btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.IndoorTemp))) + "掳C";
+ btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.RoomTemp))) + "掳C";
btnMode.UnSelectedImagePath = fhTemp.GetModeIconPath(device.GetAttrState(FunctionAttributeKey.Mode));
arcBar.Progress = Convert.ToInt32(Convert.ToDouble(device.GetAttrState(FunctionAttributeKey.SetTemp)));
if (device.trait_on_off.curValue.ToString() == "on")
diff --git a/HDL_ON/UI/UI2/FuntionControlView/AC/ACPageBLL.cs b/HDL_ON/UI/UI2/FuntionControlView/AC/ACPageBLL.cs
index dfbc2d6..9ec2bdf 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/AC/ACPageBLL.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/AC/ACPageBLL.cs
@@ -26,7 +26,7 @@
AC temp = new AC();
updataTime = DateTime.Now;
bodyView.btnTemp.Text = updateTemp.GetAttrState(FunctionAttributeKey.SetTemp);
- bodyView.btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(updateTemp.GetAttrState((string)FunctionAttributeKey.IndoorTemp))) + "掳C";
+ bodyView.btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(updateTemp.GetAttrState((string)FunctionAttributeKey.RoomTemp))) + "掳C";
bodyView.btnMode.UnSelectedImagePath = temp.GetModeIconPath(updateTemp.GetAttrState(FunctionAttributeKey.Mode));
bodyView.btnWindSpeed.UnSelectedImagePath = temp.GetFanIconPath(updateTemp.GetAttrState(FunctionAttributeKey.FanSpeed));
bodyView.arcBar.Progress = Convert.ToInt32(Convert.ToDouble(updateTemp.GetAttrState(FunctionAttributeKey.SetTemp)));
diff --git a/HDL_ON/UI/UI2/FuntionControlView/FoolHeating/FloorHeatingPageBLL.cs b/HDL_ON/UI/UI2/FuntionControlView/FoolHeating/FloorHeatingPageBLL.cs
index d0a5660..7340af2 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/FoolHeating/FloorHeatingPageBLL.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/FoolHeating/FloorHeatingPageBLL.cs
@@ -20,7 +20,7 @@
return;
}
bodyView.btnTemp.Text = updateTemp.GetAttrState(FunctionAttributeKey.SetTemp);
- bodyView.btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(updateTemp.GetAttrState(FunctionAttributeKey.IndoorTemp))) + "掳C";
+ bodyView.btnIndoorTemp.Text = Language.StringByID(StringId.IndoorTemp) + Convert.ToInt32(Convert.ToDouble(updateTemp.GetAttrState(FunctionAttributeKey.RoomTemp))) + "掳C";
bodyView.btnMode.UnSelectedImagePath = bodyView.fhTemp.GetModeIconPath(updateTemp.GetAttrState(FunctionAttributeKey.Mode));
bodyView.arcBar.Progress = Convert.ToInt32(Convert.ToDouble(updateTemp.GetAttrState(FunctionAttributeKey.SetTemp)));
if (updateTemp.trait_on_off.curValue.ToString() == "on")
--
Gitblit v1.8.0