| | |
| | | package com.hdl.sdk.ttl.HDLAppliances.HDLAirCondition.Parser; |
| | | |
| | | |
| | | import android.util.Log; |
| | | |
| | | import com.hdl.sdk.ttl.Config.Configuration; |
| | | import com.hdl.sdk.ttl.HDLAppliances.Config.HDLApConfig; |
| | | import com.hdl.sdk.ttl.HDLDeviceManger.Bean.AppliancesInfo; |
| | |
| | | byte[] airBytes = null; |
| | | outter: |
| | | for (int i = 0; i < HDLDeviceManager.devicesDataList.size(); i++) { |
| | | if (appliancesInfo.getDeviceSubnetID() == HDLDeviceManager.devicesDataList.get(i).getSourceSubnetID() |
| | | && appliancesInfo.getDeviceDeviceID() == HDLDeviceManager.devicesDataList.get(i).getSourceDeviceID()) { |
| | | if (appliancesInfo.getDeviceSubnetID() == HDLDeviceManager.devicesDataList.get(i).getDeviceSubnetID() |
| | | && appliancesInfo.getDeviceDeviceID() == HDLDeviceManager.devicesDataList.get(i).getDeviceDeviceID()) { |
| | | for (int j = 0; j < HDLDeviceManager.devicesDataList.get(i).getAppliancesInfoList().size(); j++) { |
| | | if (HDLDeviceManager.devicesDataList.get(i).getAppliancesInfoList().get(j).getBigType() == Configuration.AIR_BIG_TYPE |
| | | && HDLDeviceManager.devicesDataList.get(i).getAppliancesInfoList().get(j).getDeviceType() != HDLApConfig.TYPE_AC_PANEL |
| | | && appliancesInfo.getChannelNum() == HDLDeviceManager.devicesDataList.get(i).getAppliancesInfoList().get(j).getChannelNum()) { |
| | | newInfo = HDLDeviceManager.devicesDataList.get(i).getAppliancesInfoList().get(j); |
| | | if (newInfo.getArrCurState() == null) { |
| | | newInfo.setArrCurState(new byte[13]); |
| | | newInfo.setArrCurState(new byte[19]); |
| | | } |
| | | airBytes = newInfo.getArrCurState(); |
| | | break outter; |
| | |
| | | } |
| | | } |
| | | } |
| | | byte[] addBytes = new byte[13]; |
| | | if (airBytes != null && airBytes.length >= 13) { |
| | | byte[] addBytes = new byte[19]; |
| | | if (airBytes != null && airBytes.length >= 19) { |
| | | System.arraycopy(airBytes, 0, addBytes, 0, airBytes.length); |
| | | addBytes[0] = (byte) newInfo.getChannelNum(); |
| | | |
| | |
| | | byte[] airBytes = null; |
| | | outter: |
| | | for (int i = 0; i < HDLDeviceManager.devicesDataList.size(); i++) { |
| | | if (appliancesInfo.getDeviceSubnetID() == HDLDeviceManager.devicesDataList.get(i).getSourceSubnetID() |
| | | && appliancesInfo.getDeviceDeviceID() == HDLDeviceManager.devicesDataList.get(i).getSourceDeviceID()) { |
| | | if (appliancesInfo.getDeviceSubnetID() == HDLDeviceManager.devicesDataList.get(i).getDeviceSubnetID() |
| | | && appliancesInfo.getDeviceDeviceID() == HDLDeviceManager.devicesDataList.get(i).getDeviceDeviceID()) { |
| | | for (int j = 0; j < HDLDeviceManager.devicesDataList.get(i).getAppliancesInfoList().size(); j++) { |
| | | if (HDLDeviceManager.devicesDataList.get(i).getAppliancesInfoList().get(j).getBigType() == Configuration.AIR_BIG_TYPE |
| | | && HDLDeviceManager.devicesDataList.get(i).getAppliancesInfoList().get(j).getDeviceType() == HDLApConfig.TYPE_AC_TECHSYS |
| | | && (HDLDeviceManager.devicesDataList.get(i).getAppliancesInfoList().get(j).getDeviceType() == HDLApConfig.TYPE_AC_TECHSYS |
| | | || HDLDeviceManager.devicesDataList.get(i).getAppliancesInfoList().get(j).getDeviceType() == HDLApConfig.TYPE_AC_KNXTECHSYS) |
| | | && appliancesInfo.getChannelNum() == HDLDeviceManager.devicesDataList.get(i).getAppliancesInfoList().get(j).getChannelNum()) { |
| | | newInfo = HDLDeviceManager.devicesDataList.get(i).getAppliancesInfoList().get(j); |
| | | if (newInfo.getArrCurState() == null) { |