CanVar.c 30 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433
  1. /*
  2. * CanVar.c
  3. *
  4. * Created on: 2021年12月27日
  5. * 编码
  6. * Author: QiXiang_CHENJIE
  7. */
  8. #include "CanVar.h"
  9. UINT32 BcuInTable[28] = {
  10. 0x1801D0F3,
  11. 0x1801D8F3,
  12. 0x1880D0F3,
  13. 0x1881D0F3,
  14. 0x1882D0F3,
  15. 0x1883D0F3,
  16. 0x1884D0F3,
  17. 0x1885D0F3,
  18. 0x1886D0F3,
  19. 0x1887D0F3,
  20. 0x1888D0F3,
  21. 0x1889D0F3,
  22. 0x188AD0F3,
  23. 0x18C1D0F3,
  24. 0x18C2D0F3,
  25. 0x18E1D0F3,
  26. 0x18E2D0F3,
  27. 0x18E3D0F3,
  28. 0x18E4D0F3,
  29. 0x18E5D0F3,
  30. 0x18E6D0F3,
  31. 0x18F1D0F3,
  32. 0x18F2D0F3,
  33. 0x18F3D0F3,
  34. 0x18F4D0F3,
  35. 0x18F5D0F3,
  36. 0x18FF45F4,
  37. 0x18FFC13A,
  38. };
  39. BOOL BcuRxShortError[28];
  40. BOOL BcuRxLongError[28];
  41. UINT8 BcuRxErrorCounter[28];
  42. UINT8 BcuRxFlag[28];
  43. /************************************************************
  44. *BCU->Ebc解码变量存放区
  45. ************************************************************/
  46. UINT8 BMS_ReqVIN = 0x00; //是否请求VIN码,0:预留;1:请求VIN;2:不请求VIN;3:无效;,Re-1,Off-0,
  47. UINT8 BMS_ReqHVOff = 0x00; //是否请求下高压,0:预留;1:请求下高压;2:不请求下高压;3:无效;,Re-1,Off-0,
  48. UINT8 BMS_ProtocolEditionH = 0x00; //通讯协议版本高位(例 : 版本为3 .1, 则此处发3), , Re - 1, Off - 0,
  49. UINT8 BMS_ProtocolEditionL = 0x00; //通讯协议版本低位(例 : 版本为3 .1, 则此处发1), , Re - 1, Off - 0,
  50. UINT8 BMS_CharDevNum = 0x00; //可充电装置系统序号(BMS是整车中可充电装置系统中的第几个, 需要整车告知),1,Re-1,Off-0,
  51. UINT8 BMS_FtPosRly = 0x00; //主正继电器粘连故障,0:正常; 1:故障,Re-1,Off-0,
  52. UINT8 BMS_FtNegRly = 0x00; //主负继电器粘连故障,0:正常; 1:故障,Re-1,Off-0,
  53. UINT8 BMS_FtPosCharRly1 = 0x00; //充正1继电器粘连故障,0:正常; 1:故障,Re-1,Off-0,
  54. UINT8 BMS_FtNegCharRly1 = 0x00; //充负1继电器粘连故障,0:正常; 1:故障,Re-1,Off-0,
  55. UINT8 BMS_FtPosCharRly2 = 0x00; //充正2继电器粘连故障,0:正常; 1:故障,Re-1,Off-0,
  56. UINT8 BMS_FtNegCharRly2 = 0x00; //充负2继电器粘连故障,0:正常; 1:故障,Re-1,Off-0,
  57. UINT8 BMS_FtHeatRly1 = 0x00; //加热1/正继电器粘连故障,0:正常; 1:故障,Re-1,Off-0,
  58. UINT8 BMS_FtHeatRly2 = 0x00; //加热2/负继电器粘连故障,0:正常; 1:故障,Re-1,Off-0,
  59. UINT8 BMS_StPosRly = 0x00; //主正继电器状态(如继电器状态由BMS检测),0:预留;1:开启;2:闭合;3:无效;,Re-1,Off-0,
  60. UINT8 BMS_StNegRly = 0x00; //主负继电器状态(如继电器状态由BMS检测),0:预留;1:开启;2:闭合;3:无效;,Re-1,Off-0,
  61. UINT8 BMS_StPreCharRly = 0x00; //预充继电器状态,0:预留;1:开启;2:闭合;3:无效;,Re-1,Off-0,
  62. UINT8 BMS_StPosCharRly1 = 0x00; //直流充正继电器1状态,0:预留;1:开启;2:闭合;3:无效;,Re-1,Off-0,
  63. UINT8 BMS_StNegCharRly1 = 0x00; //直流充负继电器1状态,0:预留;1:开启;2:闭合;3:无效;,Re-1,Off-0,
  64. UINT8 BMS_StPosCharRly2 = 0x00; //直流充正继电器2状态,0:预留;1:开启;2:闭合;3:无效;,Re-1,Off-0,
  65. UINT8 BMS_StNegCharRly2 = 0x00; //直流充负继电器2状态,0:预留;1:开启;2:闭合;3:无效;,Re-1,Off-0,
  66. UINT8 BMS_FtAuxRelayWeld = 0x00; //附件继电器粘连故障(保留),0:正常; 1:故障,Re-1,Off-0,
  67. UINT8 BMS_BraOpenCirc = 0x00; //支路断路故障,0:正常; 1:故障,Re-1,Off-0,
  68. UINT8 BMS_FtBackCharCurrOutLim = 0x00; //回充电流超限报警,0:正常1 : 1级 轻微故障 2 : 2级 较严重故障 3 : 3级 最严重故障, Re - 1, Off - 0,
  69. UINT8 BMS_FtPosRlyOpen = 0x00; //主正继电器无法闭合报警,0:正常; 1:故障,Re-1,Off-0,
  70. UINT8 BMS_FtNegRlyOpen = 0x00; //主负继电器无法闭合报警,0:正常; 1:故障,Re-1,Off-0,
  71. UINT8 BMS_FtPosCharRly1Open = 0x00; //直流充电正1继电器无法闭合报警,0:正常; 1:故障,Re-1,Off-0,
  72. UINT8 BMS_FtPosCharRly2Open = 0x00; //直流充电正2继电器无法闭合报警,0:正常; 1:故障,Re-1,Off-0,
  73. UINT8 BMS_FtNegCharRly1Open = 0x00; //直流充电负1继电器无法闭合报警,0:正常; 1:故障,Re-1,Off-0,
  74. UINT8 BMS_FtNegCharRly2Open = 0x00; //直流充电负2继电器无法闭合报警,0:正常; 1:故障,Re-1,Off-0,
  75. UINT8 BMS_FtTMSContClose = 0x00; //加热膜或TMS接触器无法断开报警,0:正常; 1:故障,Re-1,Off-0,
  76. UINT8 BMS_FtTMSContOpen = 0x00; //加热膜或TMS接触器无法闭合报警,0:正常; 1:故障,Re-1,Off-0,
  77. UINT8 BMS_FtTMS = 0x00; //热管理系统故障,0:正常; 1:故障,Re-1,Off-0,
  78. UINT8 BMS_Ft24VSpy = 0x00; // BMS 24V供电异常报警,0:正常; 1:故障,Re-1,Off-0,
  79. UINT8 BMS_FtPACKSelfProt = 0x00; //电池包自保护报警,0:正常; 1:故障,Re-1,Off-0,
  80. UINT8 BMS_FtCharSockTempOver = 0x00; //充电插座过温报警,0:正常1 : 1级 轻微故障 2 : 2级 较严重故障 3 : 3级 最严重故障, Re - 1, Off - 0,
  81. UINT8 BMS_FtTempOutCtrl = 0x00; //热失控报警,0:正常; 1:故障,Re-1,Off-0,
  82. UINT8 BMS_StPosHeatRly = 0x00; //加热正继电器状态,0:保留;1:开启;2:闭合;3:无效,Re-1,Off-0,
  83. UINT8 BMS_StNegHeatRly = 0x00; //加热负继电器状态,0:保留;1:开启;2:闭合;3:无效,Re-1,Off-0,
  84. UINT8 BMS_CharSysNum = 0x00; //可充电储能子系统总数(保留),,Re-1,Off-0,
  85. UINT8 BMS_FtCode = 0x00; //电池系统故障码,详见附表电池系统故障码列表,Re-1,Off-0,
  86. UINT8 BMS_ST1CheckSum = 0x00; // B2V_ST1的CheckSum,Byte0=Byte1 XOR Byte2 XOR Byte3 XOR Byte4 XOR Byte5 XOR Byte6 XOR Byte7,Re-1,Off-0,
  87. UINT8 BMS_ST1Counter = 0x00; // B2V_ST1的生命信号,0~14循环,15:信号无效,Re-1,Off-0,
  88. UINT8 BMS_Mode = 0x00; // BMS当前状态,0:预留;1:高压上电;2:高压下电;3:无效;,Re-1,Off-0,
  89. UINT8 BMS_AuxRlySt = 0x00; //附件继电器状态,0:开启;1:闭合;,Re-1,Off-0,
  90. UINT8 BMS_BattBalaSt = 0x00; // BMS当前均衡状态,0:未开启均衡;1:开启均衡;,Re-1,Off-0,
  91. UINT8 BMS_CharGunSt = 0x00; //直流充电枪连接状态,0:未连接1 : 连接, Re - 1, Off - 0,
  92. UINT8 BMS_CharMode = 0x00; // BMS当前充电模式,0:预留1 : 直流充电 2 : 交流充电 3 : 其他充电, Re - 1, Off - 0,
  93. UINT8 BMS_CharSt = 0x00; //充电状态,0:可以充电1 : 正在充电 2 : 充电结束 3 : 充电故障, Re - 1, Off - 0,
  94. UINT8 BMS_FtLvl = 0x00; //当前最高故障等级,0:正常1 : 1级 轻微故障 2 : 2级 较严重故障 3 : 3级 最严重故障, Re - 1, Off - 0,
  95. UINT8 BMS_FtCellTempDiff = 0x00; //电芯温差异常报警,0:无故障; 1:1级 轻微故障; 2:2级 较严重故障3 : 3级 最严重故障, Re - 1, Off - 0,
  96. UINT8 BMS_FtCellTempHigh = 0x00; //电芯温度过高报警,0:无故障; 1:1级 轻微故障; 2:2级 较严重故障3 : 3级 最严重故障, Re - 1, Off - 0,
  97. UINT8 BMS_FtPACKOverVolt = 0x00; // PACK过压报警,0:无故障; 1:1级 轻微故障; 2:2级 较严重故障3 : 3级 最严重故障, Re - 1, Off - 0,
  98. UINT8 BMS_FtPACKUndeVolt = 0x00; // PACK欠压报警,0:无故障; 1:1级 轻微故障; 2:2级 较严重故障3 : 3级 最严重故障, Re - 1, Off - 0,
  99. UINT8 BMS_FtSOCLow = 0x00; // SOC过低报警,0:无故障; 1:1级 轻微故障; 2:2级 较严重故障3 : 3级 最严重故障, Re - 1, Off - 0,
  100. UINT8 BMS_FtCellOverVolt = 0x00; //单体电压过高报警,0:无故障; 1:1级 轻微故障; 2:2级 较严重故障3 : 3级 最严重故障, Re - 1, Off - 0,
  101. UINT8 BMS_FtCellUndeVolt = 0x00; //单体电压欠压报警,0:无故障; 1:1级 轻微故障; 2:2级 较严重故障3 : 3级 最严重故障, Re - 1, Off - 0,
  102. UINT8 BMS_FtIns = 0x00; //绝缘报警,0:无故障; 1:1级 轻微故障; 2:2级 较严重故障3 : 3级 最严重故障, Re - 1, Off - 0,
  103. UINT8 BMS_FtCellOverVoltDiff = 0x00; //单体压差过大,0:无故障; 1:1级 轻微故障; 2:2级 较严重故障3 : 3级 最严重故障, Re - 1, Off - 0,
  104. UINT8 BMS_FtCharCurrOver = 0x00; //充电电流过大报警,0:无故障; 1:1级 轻微故障; 2:2级 较严重故障3 : 3级 最严重故障, Re - 1, Off - 0,
  105. UINT8 BMS_FtDisCharCurrOver = 0x00; //放电电流过大报警,0:无故障; 1:1级 轻微故障; 2:2级 较严重故障3 : 3级 最严重故障, Re - 1, Off - 0,
  106. UINT8 BMS_FtCellTempLow = 0x00; //电芯温度过低报警,0:无故障; 1:1级 轻微故障; 2:2级 较严重故障3 : 3级 最严重故障, Re - 1, Off - 0,
  107. UINT8 BMS_FtBranVoltDifOver = 0x00; //支路压差过大报警(存在并联支路的系统),0:无故障; 1:1级 轻微故障; 2:2级 较严重故障3 : 3级 最严重故障, Re - 1, Off - 0,
  108. UINT8 BMS_FtBMSHardWare = 0x00; // BMS硬件故障,0:无故障; 1:1级 轻微故障; 2:2级 较严重故障3 : 3级 最严重故障, Re - 1, Off - 0,
  109. UINT8 BMS_FtSOCHigh = 0x00; // SOC过高报警,0:正常; 1:故障,Re-1,Off-0,
  110. UINT8 BMS_FtSOCJump = 0x00; // SOC跳变报警,0:正常; 1:故障,Re-1,Off-0,
  111. UINT8 BMS_FtInCom = 0x00; // BMS内部通信故障,0:正常; 1:故障,Re-1,Off-0,
  112. UINT8 BMS_FtSysMism = 0x00; // BMS/可充电储能系统不匹配报警,0:正常; 1:故障,Re-1,Off-0,
  113. UINT8 BMS_FtHvIntLock = 0x00; //高压互锁报警,0:正常; 1:故障,Re-1,Off-0,
  114. UINT8 BMS_FtSmoke = 0x00; //火警探测器故障,0:正常; 1:故障,Re-1,Off-0,
  115. UINT8 BMS_FtFire = 0x00; //电池包火灾报警,0:正常; 1:故障,Re-1,Off-0,
  116. UINT8 BMS_FtNum = 0x00; // BMS当前发生的故障总数目(包括GB32960中规定的故障数目),,Re-1,Off-0,
  117. UINT8 BMS_PackSOC = 0x00; //电池包SOC,,Re-0.4,Off-0,
  118. UINT8 BMS_PackSOH = 0x00; //电池包SOH,,Re-0.4,Off-0,
  119. UINT8 BMS_MaxCellTemp = 0x00; //单体最高温度,,Re-1,Off--50,℃
  120. UINT8 BMS_MinCellTemp = 0x00; //单体最低温度,,Re-1,Off--50,℃
  121. UINT8 BMS_AverCellTemp = 0x00; //单体平均温度,,Re-1,Off--50,℃
  122. UINT8 BMS_MaxCellTempCSC = 0x00; //最高温度电芯所在子系统(CSC)编号,范围(1~255),Re-1,Off-0,
  123. UINT8 BMS_MaxCellTempNum = 0x00; //最高温度电芯所在子系统(CSC)内温度探针编号,范围(1~255),Re-1,Off-0,
  124. UINT8 BMS_MinCellTempCSC = 0x00; //最低温度电芯所在子系统(CSC)编号,范围(1~255),Re-1,Off-0,
  125. UINT8 BMS_MinCellTempNum = 0x00; //最低温度电芯所在子系统(CSC)内温度探针编号,范围(1~255),Re-1,Off-0,
  126. UINT8 BMS_MaxCellVoltCSC = 0x00; //最高电压电芯所在子系统(CSC)编号,范围(1~255),Re-1,Off-0,
  127. UINT8 BMS_MaxCellVoltNum = 0x00; //最高电压电芯所在子系统(CSC)内单体编号,范围(1~255),Re-1,Off-0,
  128. UINT8 BMS_MinCellVoltCSC = 0x00; //最低电压电芯所在子系统(CSC)编号,范围(1~255),Re-1,Off-0,
  129. UINT8 BMS_MinCellVoltNum = 0x00; //最低电压电芯所在子系统(CSC)内单体编号,范围(1~255),Re-1,Off-0,
  130. UINT8 BMS_InsDeteSt = 0x00; // BMS绝缘检测状态,0:停止检测;1:激活检测;,Re-1,Off-0,
  131. UINT8 BMS_FtCharInsLow = 0x00; //充电绝缘阻值低,0:正常; 1:故障,Re-1,Off-0,
  132. UINT8 BMS_FtCurrSenr = 0x00; //电流传感器故障,0:正常; 1:故障,Re-1,Off-0,
  133. UINT8 BMS_FtHeatingFilm = 0x00; //加热膜加热回路故障,0:正常; 1:故障,Re-1,Off-0,
  134. UINT8 BMS_FtMainLoopPreChar = 0x00; //主回路预充或预检故障,0:正常; 1:故障,Re-1,Off-0,
  135. UINT8 BMS_FtAuxLoopPreChar = 0x00; //辅件回路预充或预检故障,0:正常; 1:故障,Re-1,Off-0,
  136. UINT8 BMS_FtACANLost = 0x00; // ACAN/整车CAN通讯故障,0:正常; 1:故障,Re-1,Off-0,
  137. UINT8 BMS_FtDCDC = 0x00; // BMS-DC-DC故障,0:正常; 1:故障,Re-1,Off-0,
  138. UINT8 BMS_FtSOCDif = 0x00; // SOC差异过大,0:正常; 1:故障,Re-1,Off-0,
  139. UINT8 BMS_FtCellOverDisChar = 0x00; //电芯过放故障,0:正常; 1:故障,Re-1,Off-0,
  140. UINT8 BMS_FtCharOver = 0x00; //车载储能装置过充报警,0:正常;1:1级 轻微故障;2:2级 较严重故障3 : 10级 最严重故障, Re - 1, Off - 0,
  141. UINT8 BMS_FtContDisCharCurrOverLoad = 0x00; //持续回充过流故障,0:正常;1:1级 轻微故障;2:2级 较严重故障3 : 10级 最严重故障, Re - 1, Off - 0,
  142. UINT8 BMS_FtContCharCurrOverLoad = 0x00; //持续放电过流故障,0:正常;1:1级 轻微故障;2:2级 较严重故障3 : 10级 最严重故障, Re - 1, Off - 0,
  143. UINT8 BMS_Gun1DCNegTemp = 0x00; //充电口1负温感值,,Re-1,Off--40,℃
  144. UINT8 BMS_Gun1DCPosTemp = 0x00; //充电口1正温感值,,Re-1,Off--40,℃
  145. UINT8 BMS_Gun2DCNegTemp = 0x00; //充电口2负温感值,,Re-1,Off--40,℃
  146. UINT8 BMS_Gun2DCPosTemp = 0x00; //充电口2正温感值,,Re-1,Off--40,℃
  147. UINT8 BMS_CurrHeatSt = 0x00; //当前加热状态,0:未加热;1:加热中;2:预留;3:无效;,Re-1,Off-0,
  148. UINT8 BMS_CurrCoolSt = 0x00; //当前冷却状态,0:未冷却;1:冷却中;2:预留;3:无效;,Re-1,Off-0,
  149. UINT8 BMS_FtCharCnct = 0x00; //插枪连接信号异常,0:正常; 1:故障,Re-1,Off-0,
  150. UINT8 BMS_FtOverDisCharCurrDuringChar = 0x00; //充电时放电电流过大,0:正常; 1:故障,Re-1,Off-0,
  151. UINT8 BMS_FtCharNTC = 0x00; //充电插座NTC故障,0:正常; 1:故障,Re-1,Off-0,
  152. UINT8 BMS_FtELock = 0x00; //电子锁故障,0:正常; 1:故障,Re-1,Off-0,
  153. UINT8 BMS_CellVoltFramNum = 0x00; //单体电压帧序号,有效值1~255,Re-1,Off-0,
  154. UINT8 BMS_CellTempFramNum = 0x00; //温度帧序号,有效值1~255,Re-1,Off-0,
  155. UINT8 BMS_CSC_Code = 0x00; //子系统编号CSC,有效值1~255,Re-1,Off-0,
  156. UINT8 BMS_CellTemp[64] = {0x00}; //当前CSC下的第N个探针的温度,255 "Invalid" 0xFF 无效有效值 0 ~254, 单位 ℃, 范围(-50 ~204)℃, , Re - 1, Off-- 50,℃
  157. UINT8 BMS_Checksum = 0x00; //电池编码信息1的CheckSum,Byte0=Byte1 XOR Byte2 XOR Byte3 XOR Byte4 XOR Byte5 XOR Byte6 XOR Byte7,Re-1,Off-0,
  158. UINT8 BMS_PackComp = 0x00; //电池厂家,1:"CATL" 2:"Li Shen" 3:"MGL" 4:"SAMSUN" 5:"LG",Re-1,Off-0,
  159. UINT8 BMS_BattCodeLeng = 0x00; //电池编码长度,0:Do not transmit this Code,Re-1,Off-0,
  160. UINT8 BMS_SN[27] = {0x00}; //电池编码(SN)字符1(ASCII),,Re-1,Off-0,
  161. UINT8 BMS_BattType = 0x00; //电池类型,1:铅酸电池; 2:镍氢电池; 3:磷酸铁锂电池; 4:锰酸锂电池; 5:钴酸锂电池; 6:三元材料电池; 7:聚合物锂离子电池; 8:钛酸锂电池; 9:超级电容; 10~13:保留; 14:燃料电池;15:保留,Re-1,Off-0,
  162. UINT8 BMS_CoolType = 0x00; //电池冷却方式,0:其他冷却方式1 : 自然冷却 2 : 风扇冷却 3 : 水冷却, Re - 1, Off - 0,
  163. UINT8 BMS_CSC_Total = 0x00; //电池系统中CSC总的数目,,Re-1,Off-0,
  164. UINT8 BMS_CellVoltLevel = 0x00; //单体平台电压(非实时变化的值),有效值0~5V; 255 "Signal Invalid" 0xFF 无效,Re-0.1,Off-0,V
  165. UINT8 BMS_CellMinVolt = 0x00; //单体可用最低电压(非实时变化的值),有效值0~5V; 255 "Signal Invalid" 0xFF 无效,Re-0.1,Off-0,V
  166. UINT8 BMS_CellMaxVolt = 0x00; //单体可用最高电压(非实时变化的值),有效值0~5V; 255 "Signal Invalid" 0xFF 无效,Re-0.1,Off-0,V
  167. UINT8 BMS_HVBranNum = 0x00; //电池系统高压支路数,,Re-1,Off-0,
  168. UINT8 BMS_SingleHVBranchCellNum = 0x00; //电池系统单支路电芯数,,Re-1,Off-0,
  169. UINT8 BMS_ReqMode = 0x00; // BMS请求设定模式,0:关机模式1 : 制冷模式 2 : 制热模式 3 : 自循环模式, Re - 1, Off - 0,
  170. UINT8 BMS_HVCmd = 0x00; //高压请求,0:请求上高压1 : 请求下高压, Re - 1, Off - 0,
  171. UINT8 BMS_ChgSts = 0x00; //充电状态,0:非充电1 : 充电, Re - 1, Off - 0,
  172. UINT8 BMS_HVRelaySts = 0x00; // BMS高压继电器状态,0:断开状态; 1:闭合状态; 2~3:无效,Re-1,Off-0,
  173. UINT8 BMS_SetTemp = 0x00; //设定温度,,Re-1,Off--40,
  174. UINT8 BMS_Life = 0x00; // BMS生命帧,,Re-1,Off-0,
  175. UINT8 BMS_CRC = 0x00; // CRC校验值,,Re-1,Off-0,
  176. UINT8 TMS_WorkStatus = 0x00; // TMS工作状态,0:关机模式1 : 制冷模式 2 : 制热模式 3 : 自循环模式, Re - 1, Off - 0,
  177. UINT8 TMS_HVRelayST = 0x00; // TMS高压继电器状态,0:断开状态; 1:闭合状态; 2~3:无效,Re-1,Off-0,
  178. UINT8 TMS_OutletTemp = 0x00; //出水温度(机组到电池),255:无效,Re-1,Off--40,
  179. UINT8 TMS_InletTemp = 0x00; //回水温度(电池到机组),255:无效,Re-1,Off--40,
  180. UINT8 TMS_ErrCode = 0x00; // TMS故障码,0:无故障; 出现 1 种以上循环发送,Re-1,Off-0,
  181. UINT8 TMS_FaultLevel = 0x00; // TMS故障码等级,0:无效1 : 1级故障 2 : 2级故障 3 : 3级故障, Re - 1, Off - 0,
  182. UINT16 BMS_SoftwareVersion = 0x00; //软件版本号:RyyyBzzz(R为软件版本、B为测试版本、正式版本不带B) ,yyy:0~254,精度1,255:无效,不显示;zzz:0~254,精度1,255:无效,不显示;
  183. UINT16 BMS_HardwareVersion = 0x00; //硬件版本号:VyyyBzzz(V为硬件版本、B为测试版本、正式版本不带B) ,,Re-1,Off-0,
  184. UINT16 BMS_PackCurr = 0x00; //电池包总电流,充电为负值,放电为正值,,Re-0.1,Off--1000,A
  185. UINT16 BMS_MaxCharCurr = 0x00; //电池包最大回充电流,,Re-0.1,Off--1000,A
  186. UINT16 BMS_MaxDisCharCurr = 0x00; //电池包最大放电电流,,Re-0.1,Off--1000,A
  187. UINT16 BMS_PosIns = 0x00; //母线正对车体绝缘电阻,,Re-1,Off-0,KΩ
  188. UINT16 BMS_NegIns = 0x00; //母线负对车体绝缘电阻,,Re-1,Off-0,KΩ
  189. UINT16 BMS_BattVolt = 0x00; //电池包内侧电压,,Re-0.1,Off-0,V
  190. UINT16 BMS_LinkVolt = 0x00; //电池包外侧电压,,Re-0.1,Off-0,V
  191. UINT16 BMS_MaxCellVolt = 0x00; //单体最高电压值,,Re-0.001,Off-0,V
  192. UINT16 BMS_AverCellVolt = 0x00; //电芯电压平均值,,Re-0.001,Off-0,V
  193. UINT16 BMS_MinCellVolt = 0x00; //电芯最低电压值,,Re-0.001,Off-0,V
  194. UINT16 BMS_ContChrgCurr = 0x00; // BMS允许的持续回充电流,,Re-0.1,Off-0,A
  195. UINT16 BMS_ContDisCharCurr = 0x00; // BMS允许的持续放电电流,,Re-0.1,Off--1000,A
  196. UINT16 BMS_CharReqVolt = 0x00; //充电所需电压(交流),,Re-0.1,Off-0,V
  197. UINT16 BMS_CharReqCurr = 0x00; //充电所需电流(交流),,Re-0.1,Off--1000,A
  198. UINT16 BMS_SysInsRes = 0x00; //系统绝缘电阻,,Re-1,Off-0,KΩ
  199. UINT16 BMS_MaxDisCharPwr = 0x00; //最大允许放电功率,,Re-0.1,Off-0,kw
  200. UINT16 BMS_MaxCharPwr = 0x00; //最大允许充电功率,,Re-0.1,Off-0,kw
  201. UINT16 BMS_ContDisCharPwr = 0x00; // BMS允许的持续放电功率,,Re-0.1,Off-0,kw
  202. UINT16 BMS_ContCharPwr = 0x00; // BMS允许的持续充电功率,,Re-0.1,Off-0,kw
  203. UINT16 BMS_InstEngyCons = 0x00; //动力电池瞬时百公里能耗,,Re-0.1,Off-0,kwh
  204. UINT16 BMS_TotalEngyCons = 0x00; //动力电池总/平均百公里能耗,,Re-0.1,Off-0,kwh
  205. UINT16 BMS_SOE = 0x00; //剩余电量,,Re-0.01,Off-0,kwh
  206. UINT16 BMS_RmanCharTime = 0x00; //剩余充电时间,,Re-1,Off-0,min
  207. UINT16 BMS_CharNum = 0x00; //充电次数,,Re-1,Off-0,
  208. UINT16 BMS_CellVolt[384] = {0x00}; //电芯的电压,65535 "Invalid" 0xFFFF 无效有效值 0 ~65534, 范围(0 ~65.534) V, Re - 0.001, Off - 0, V
  209. UINT16 BMS_BattRateCap = 0x00; //电池包额定容量,有效值 0~65534,65535 "Signal Invalid" 无效,Re-1,Off-0,Ah
  210. UINT16 BMS_BattRateVolt = 0x00; //电池包额定电压,有效值 0~6553.4,65535 "Signal Invalid" 无效,Re-0.1,Off-0,V
  211. UINT16 BMS_BattRateEngy = 0x00; //电池包额定能量,有效值 0~6553.4,65535 "Signal Invalid" 无效,Re-0.1,Off-0,kWh
  212. UINT16 BMS_CellTotal = 0x00; // PACK中单体电芯的总数目,,Re-1,Off-0,
  213. UINT16 BMS_TempTotal = 0x00; // PACK中电芯温度点(探针)的总数目,,Re-1,Off-0,
  214. UINT16 BMS_SingleCharEngy = 0x00; //单次充电kWh 数,,Re-0.1,Off-0,KWh
  215. UINT16 BMS_SingleCharCapy = 0x00; //单次充电Ah 数,,Re-0.1,Off-0,Ah
  216. UINT16 BMS_HVVolt = 0x00; // BMS当前电压,,Re-1,Off-0,
  217. UINT16 TMS_ReqPow = 0x00; // TMS需求功率,65535:无效,Re-0.1,Off-0,Kw
  218. UINT32 BMS_TotalCharEngy = 0x00; //累计充入kWh 数,,Re-0.1,Off-0,KWh
  219. UINT32 BMS_TotalDisCharEngy = 0x00; //累计放出kWh 数,,Re-0.1,Off-0,KWh
  220. UINT32 BMS_TotalBackCharEngy = 0x00; //累计动能回馈充入kWh 数,,Re-0.1,Off-0,KWh
  221. UINT32 BMS_TotalStaCharEngy = 0x00; //累计换电站充入kWh 数,,Re-0.1,Off-0,KWh
  222. UINT32 BMS_TotalGunCharEngy = 0x00; //累计插枪充电充入kWh 数,,Re-0.1,Off-0,KWh
  223. UINT32 BMS_TotalGunCharCapy = 0x00; //累计插枪充电充入Ah 数,,Re-0.1,Off-0,Ah
  224. UINT32 BMS_TotalCharCapy = 0x00; //累计充入Ah 数,,Re-0.1,Off-0,Ah
  225. UINT32 BMS_TotalDisCharCapy = 0x00; //累计放出Ah 数,,Re-0.1,Off-0,Ah
  226. UINT32 BMS_TotalBackCharCapy = 0x00; //累计动能回馈充入Ah 数,,Re-0.1,Off-0,Ah
  227. UINT32 BMS_TotalStaCharCapy = 0x00; //累计换电站充入Ah 数,,Re-0.1,Off-0,Ah
  228. /*VCU->EBC信号*****************************************/
  229. UINT32 VcuInTable[4] = {
  230. 0x18F101D0,
  231. 0x18F103D0,
  232. 0x18E1F3D0,
  233. 0x18FEF100};
  234. BOOL VcuRxShortError[4];
  235. BOOL VcuRxLongError[4];
  236. UINT8 VcuRxFlag[4];
  237. UINT8 VcuRxErrorCounter[4];
  238. UINT8 VCU_Num_VIN[17]; // VCU-VIN
  239. UINT8 VCU_St_VinRecv; // VIN接收状态
  240. UINT8 VCU_St_BattRly = 0x00; //电池接触器状态,0:闭合,指示灯灭 1:断开,指示灯亮 2:预留 3:无效,R-1,Off-0,
  241. UINT8 VCU_St_Check = 0x00; // VCU自检状态,0:正在自检 1:自检成功 2:自检失败 3:无效,R-1,Off-0,
  242. UINT8 VCU_St_SysIntLock = 0x00; //系统互锁状态,0:没有互锁 1:充电互锁 2:预留 3:无效,R-1,Off-0,
  243. UINT8 VCU_St_Veh = 0x00; //整车状态,0:Wait 1:Ready 2:预留 3:无效,R-1,Off-0,
  244. UINT8 VCU_St_Gear = 0x00; //档位状态, -1:倒档 0:空档 1:1档 2:2档 3:3档 4:4档 5:5档 6:6档 7:7档 8:8档 9:9档 10:10档 11:11档 12:12档 13:13档 14:14无效 ,R-1,Off--125,
  245. UINT8 VCU_Ft_Sys = 0x00; // VCU故障(与MCU故障点亮同一个符号),0:无故障 1:系统故障,R-1,Off-0,
  246. UINT8 VCU_Ft_Tran = 0x00; //变速箱故障,0:正常 1:报警,R-1,Off-0,
  247. UINT8 VCU_Ft_BattSys = 0x00; //动力电池系统故障,0:正常 1:报警,R-1,Off-0,
  248. UINT8 VCU_State_Veh = 0x00; //车辆状态,1:车辆启动状态 2:熄火 3:其他状态 14:异常 15:无效,R-1,Off-0,
  249. UINT8 VCU_Counter = 0x00; //循环计数器,,R-0.1,Off-0,
  250. UINT8 VCU_SoftVersion = 0x00; // VCU软件版本号,,R-0.1,Off-0,
  251. UINT8 VCU_St_AccPedal = 0x00; //加速踏板状态,,R-0.4,Off-0,
  252. UINT8 VCU_St_BrakePedal = 0x00; //刹车踏板状态,,R-0.4,Off-0,
  253. UINT8 VCU_St_ParkBrakeSw = 0; //手刹状态
  254. // declear the UINT16 vars
  255. UINT16 VCU_VehSpd = 0x00; //车速,,R-0.0039,Off-0,Km/h
  256. UINT16 VCU_RemaMile = 0x00; //剩余里程,,R-0.125,Off-0,Km
  257. /*EBC->CAN信号*****************************/
  258. UINT32 EbcOutTable[2][2] =
  259. {{0x18FFF8A7, 100},
  260. {0x18FEF8A7, 100}};
  261. UINT8 EBC_Counter = 0; // EBC_Counter LIFE 信号
  262. UINT8 EBC_LockSt = 0; // EBC_LockSt 锁止销反馈状态
  263. UINT8 EBC_CnctSt = 0; //换电连接器状态(充电回路&放电回路同时闭合代表闭合,有一路断开则为断开)
  264. UINT8 EBC_DisCharCnctSt = 0; // 放电回路换电连接器状态(保留)
  265. UINT8 EBC_CharCnctSt = 0; // 充电回路换电连接器状态(保留)
  266. UINT8 EBC_FtLvl = 0; //换电系统故障等级
  267. UINT8 EBC_FtCode = 0; //换电系统故障码
  268. UINT8 EBC_AirPressure = 0; //气压值
  269. UINT8 EBC_CharSt = 0; //充电标志位
  270. UINT8 EBC_ActHeatReq = 0; //主动预热请求
  271. UINT8 EBC_InhiHVOn = 0; //禁止高压上电
  272. UINT8 EBC_ReqHVOff = 0; //请求高压下电
  273. UINT8 EBC_StopChgCmd = 0; //停止充电指令
  274. UINT8 EBC_State = 0; //换电控制器状态
  275. UINT8 EBC_DisCharPos1Temp = 0; //放电正1温度
  276. UINT8 EBC_DischarNeg1Temp = 0; //放电负1温度
  277. UINT8 EBC_DisCharPos2Temp = 0; //放电正2温度
  278. UINT8 EBC_DisCharNeg2Temp = 0; //放电负2温度
  279. UINT8 EBC_ChgPos1Temp = 0; //充电正1温度(保留)
  280. UINT8 EBC_ChgNeg1Temp = 0; //充电负1温度(保留)
  281. UINT8 EBC_ChgPos2Temp = 0; //充电正2温度(保留)
  282. UINT8 EBC_ChgNeg2Temp = 0; //充电负2温度(保留)
  283. /*************************************************************
  284. *Ebc->Ble组码变量以及Ebc应用层变量存放区
  285. ************************************************************/
  286. uint8 g_c_BlePwr = 0;
  287. uint8 g_c_AirPwr = 0;
  288. uint8 g_c_LedPwr = 0;
  289. uint16 bcud_E_snglChrg; //单次充电能量,精度0.1kwh
  290. uint16 bcud_pct_soc; //电池SOC,精度0.1
  291. uint16 bcud_Q_snglChrg; //单次充电容量,精度0.1Ah
  292. uint16 bcud_V_battU; //电池电压 精度0.1V
  293. uint32 bcud_E_accChrg; //累计充电能量,精度0.1kwh
  294. uint32 bcud_E_accDischrg; //累计放电能量,精度0.1kwh
  295. uint32 bcud_E_accPlugInChrg; //累计插枪充电能量,精度0.1kwh
  296. uint32 bcud_E_accRecovry; //累计回收能量,精度0.1kwh
  297. uint32 bcud_E_accSwapBatt; //累计换电站能量,精度0.1kwh
  298. uint32 bcud_Q_accChrg; //累计充电容量,精度0.1ah
  299. uint32 bcud_Q_accDischrg; //累计放电容量,精度0.1ah
  300. uint32 bcud_Q_accPlugInChrg; //累计插枪充电容量,精度0.1ah
  301. uint32 bcud_Q_accRecovry; //累计回收容量,精度0.1ah
  302. uint32 bcud_Q_accSwapBatt; //累计换电站容量,精度0.1ah
  303. uint32 vcud_M_accDrv; //累计行驶里程,精度0.1km
  304. uint8 bcud_pct_bcuSoh; //电池Soh,精度0.4%
  305. uint8 bcud_st_bcuComun; //电池通讯状态,0-通信中断,1-通信正常
  306. uint8 bcud_st_bcuMainRelay; //主继电器信号,0-保留 1-断开,2-关闭 3-异常
  307. uint8 bcud_st_bcuTmsLiquid; //热管理液位状态,1-液位正常,0-液位过低
  308. uint8 bcud_st_hvWork; //电池高压状态,0-高压开启 1-预充,2-高压关断,3-高压上电故障
  309. uint8 bcuv_Num_battSn[32]; //电池SN号码
  310. uint8 vcud_P_airSensorBack; //后桥气压值,单位Mpa,精度0.01Mpa
  311. uint8 vcud_P_airSensorForward; //前桥气压值,单位Mpa,精度0.01Mpa
  312. uint8 vcud_st_carStart; //整车启动状态,0001-车辆启动状态,0010-熄火,0011-其他状态,1111-无效
  313. uint8 vcud_st_footbrake; //脚刹信号,0-无效,1-有效
  314. uint8 vcud_st_gear; //档位信号,FF-倒挡(R),0-空挡(N),X-前进档(DX)X取1-12
  315. uint8 vcud_st_handbrake; //手刹信号,0-无效,1-有效
  316. uint8 vcud_st_keyOn; //钥匙信号,1-上电,0-下电
  317. uint8 vcud_st_Steer; //方向盘信号,bit0-左侧转向灯,bit1-右侧转向灯,每bit 0-OFF,1-ON
  318. uint8 vcud_st_vcuComun; // vcu通讯状态,0-通信中断,1-通信正常
  319. uint8 vcuv_Num_vin[17]; // VIN码
  320. uint8 bled_flg_lockCmd = 0; //锁钩电磁阀锁紧命令,1-有效,0-无效
  321. uint8 bled_flg_unlockCmd = 0; //锁钩电磁阀解锁命令,1-有效,0-无效
  322. uint8 bled_flg_lockCmdForce = 0; //锁钩电磁阀锁紧强制命令,1-有效,0-无效
  323. uint8 bled_flg_unlockCmdForce = 0; //锁钩电磁阀解锁强制命令,1-有效,0-无效
  324. uint8 bled_flg_topAscendCmd = 0; //顶板上升命令,1-有效,0-无效
  325. uint8 bled_flg_topDescendCmd = 0; //顶板下降命令,1-有效,0-无效
  326. uint8 bled_flg_topAscendCmdForce = 0; //顶板强制上升命令,1-有效,0-无效
  327. uint8 bled_flg_topDescendCmdForce = 0; //顶板强制下降命令,1-有效,0-无效
  328. uint8 bled_flg_openDustReCmd = 0; //除尘打开指令,1-有效,0-无效
  329. uint8 bled_flg_closeDustReCmd = 0; //除尘关闭指令,1-有效,0-无效
  330. uint8 bled_flg_Heart = 0; //心跳维持指令
  331. uint8 bled_flg_getEbcData = 0; //获取ebc数据指令
  332. uint8 bled_flg_getVcuData = 0; //获取vcu数据指令
  333. uint8 bled_flg_getBmsData = 0; //获取bms数据指令
  334. uint8 bled_flg_handShake = 0; //握手指令
  335. uint8 bled_flg_swapBattDone = 0; //换电完成指令
  336. uint8 bled_flg_backToDrv = 0; //回到行驶状态指令
  337. uint8 bled_flg_autoLock = 0; //自动锁定指令
  338. uint8 bled_flg_autoUnlock = 0; //自动解锁指令
  339. uint8 bled_flg_toSwapMod = 0; //换到换电状态
  340. uint8 bled_flg_safeStopCmd = 0; //急停指令
  341. uint32 bled_Nr_softVer = 0; // BLE软件版本
  342. uint8 bled_flg_role = 0; // ble的主从模式 01-主,02-从
  343. uint8 bled_flg_bleConn = 0; // ble蓝牙连接状态
  344. uint8 bled_flg_bleDisconn = 0; // ble蓝牙断开状态
  345. uint8 bled_st_dataTrans = 0; //蓝牙数据传输状态
  346. /*
  347. ebc应用层变量
  348. */
  349. uint8 ebcd_flg_Can2SendEnbale = 0; //应答BLE的使能
  350. uint8 ebcd_st_toBleAns = 0; //应答BLE的指令序号
  351. uint8 ebcd_P_airSensor = 0; //压力传感器气压值:单位Mpa,精度0.01Mpa
  352. uint8 ebcd_T_plugin[4] = {0}; //四个接插件温度,加了偏移量40
  353. uint8 ebcd_flg_forbidHVOn = 0; //禁止高压上电 BMS
  354. uint8 ebcb_flg_reqHvOff = 0; //请求高压下电 BMS
  355. uint8 ebcd_flg_LockErr = 0; //锁紧机构故障状态,0-异常,1-正常
  356. uint8 ebcd_flg_dChrgLockErr = 0; //放电互锁故障状态
  357. uint8 ebcd_flg_chrgLockErr = 0; //充电互锁故障状态
  358. uint8 ebcd_flg_dChgCnctOverTemp = 0; //放电连接器过温标志
  359. uint8 ebcd_st_ebcWork = DriveMode; // Ebc当前状态 0-行车,1-通讯(握手才进入通讯状态),2-换电
  360. uint8 ebcd_Nr_errMax; //故障等级:当前故障最大等级
  361. uint8 ebcd_Num_faultCode; // ebc故障码,未定义
  362. uint8 ebcd_st_chargingMod; //充电模式,1-车载充电,2-换电站充电
  363. uint8 ebdc_st_lockUpState = 0; //锁止机构状态,0-故障,1-解锁成功,2-上锁成功
  364. uint8 ebdc_st_ConnecState = 0; //换电连接器状态(充电回路&放电回路同时闭合代表闭合,有一路断开则为断开),0_未连接 1_连接
  365. uint8 ebcd_flg_pluginLockSig; //互锁接插件信号状态,1-触发,0-无触发
  366. uint8 ebcd_flg_swapAdmit; //允许换电判断:0-不允许,1-允许
  367. uint8 ebcd_Num_err1; //故障码1
  368. uint8 ebcd_Num_err2; //故障码2
  369. uint8 ebcd_st_ebcConnect; // Ebc通讯模式,0-无线蓝牙,1-有线连接 ,默认0
  370. uint8 ebcd_st_ebcLockWork; // Ebc解锁模式,0-单步模式,1-自动模式
  371. uint8 ebcd_st_errTable1; //故障表1,bit0-气压异常,bit1-液位异常,bit2-Flash读取异常
  372. uint8 ebcd_st_errTable2; //故障表2,bit0-互锁异常,bit1-整车CAN异常,bit2-电池CAN异常,bit3-锁钩异常,bit4-升降机异常,bit5-电池位置异常
  373. uint8 ebcd_st_errTable3; //故障表3,bit0-放电互锁异常,bit1-充电互锁异常,bit2-整车高压互锁异常
  374. uint8 ebcd_st_lockSensor; //锁紧传感器信号:bit0-bit3:传感器0-3的状态每,bit:1-触发,0-不触发
  375. uint8 ebcd_st_lockSucJug; //锁紧完成判断:0-完全未锁紧,1-完全锁紧,2-未完全锁紧"
  376. uint8 ebcd_st_pedstSensor; //底座落座传感器:bit0-bit1:传感器0-1的状态,每bit:1-触发,0-无触发
  377. uint8 ebcd_st_pedstSucJug; //电池底座到位判断:0-完全未到位,1-完全到位,2-未完全到位
  378. uint8 ebcd_st_pluginLockSig; //互锁接插件信号具体状态,1-触发,0-无触发
  379. uint8 ebcd_st_unlockSensor; //解锁传感器信号:bit0-bit3:传感器0-3的状态每,bit:1-触发,0-不触发
  380. uint8 ebcd_st_unlockSucJug; //解锁完成判断:0-完全未解锁,1-完全解锁,2-未完全解锁
  381. uint8 m_flg_HVlock1 = 0; //互锁状态1,电池换电接插件
  382. uint8 m_flg_HVlock2 = 0; //互锁状态2,整车放电接插件
  383. uint16 Test_LockPressure = 0; //锁紧力测试
  384. uint8 ebcd_flg_ebcManCtrlEn = 0; // EBC手动控制使能
  385. uint8 ebcd_flg_ebcManCtrlMode = 0; // EBC手动控制模式
  386. #define EEPDATA_START_SEC_VAR
  387. #include "MemMap.h"
  388. uint16 ebcd_Nr_swapBatt; //换电次数
  389. uint16 ebcd_Nr_swapSucBatt; //换电成功次数
  390. uint16 ManuControlTimes = 0;
  391. uint16 LockDelayTime = 0; //锁定延时时间(传感器到位以后延时多少时间确定为锁定成功
  392. uint16 UnlockDelayTime = 0; //解锁延时时间(传感器到位以后延时多少时间确定为解锁成功
  393. uint8 sfmv_Num_FltEEsave = 0;
  394. #define EEPDATA_STOP_SEC_VAR
  395. #include "MemMap.h"
  396. #define APPLAYERVER_START_SEC_VAR
  397. #include "MemMap.h"
  398. const uint8 T_table[240] = {239, 238, 237, 236, 235, 234, 233, 232, 231, 230, 229, 228, 227, 226, 225, 224,
  399. 223, 222, 221, 220, 219, 218, 217, 216, 215, 214, 213, 212, 211, 210, 209, 208, 207, 206, 205, 204, 203,
  400. 202, 201, 200, 199, 198, 197, 196, 195, 194, 193, 192, 191, 190, 189, 188, 187, 186, 185, 184, 183, 182,
  401. 181, 180, 179, 178, 177, 176, 175, 174, 173, 172, 171, 170, 169, 168, 167, 166, 165, 164, 163, 162, 161,
  402. 160, 159, 158, 157, 156, 155, 154, 153, 152, 151, 150, 149, 148, 147, 146, 145, 144, 143, 142, 141, 140,
  403. 139, 138, 137, 136, 135, 134, 133, 132, 131, 130, 129, 128, 127, 126, 125, 124, 123, 122, 121, 120, 119,
  404. 118, 117, 116, 115, 114, 113, 112, 111, 110, 109, 108, 107, 106, 105, 104, 103, 102, 101, 100, 99, 98, 97,
  405. 96, 95, 94, 93, 92, 91, 90, 89, 88, 87, 86, 85, 84, 83, 82, 81, 80, 79, 78, 77, 76, 75, 74, 73, 72, 71, 70, 69,
  406. 68, 67, 66, 65, 64, 63, 62, 61, 60, 59, 58, 57, 56, 55, 54, 53, 52, 51, 50, 49, 48, 47, 46, 45, 44, 43, 42, 41,
  407. 40, 39, 38, 37, 36, 35, 34, 33, 32, 31, 30, 29, 28, 27, 26, 25, 24, 23, 22, 21, 20, 19, 18, 17, 16, 15, 14, 13,
  408. 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0};
  409. const uint32 R_table[240] = {125, 127, 129, 131, 133, 136, 138, 141, 143, 145, 148, 151, 153, 156, 159, 162, 165,
  410. 168, 171, 174, 177, 180, 183, 187, 190, 194, 198, 201, 205, 209, 213, 217, 221, 226, 230, 234, 239, 244, 249,
  411. 254, 259, 264, 269, 274, 280, 286, 292, 298, 304, 310, 316, 323, 330, 337, 344, 351, 359, 366, 374, 382, 391,
  412. 399, 408, 417, 426, 436, 445, 455, 466, 476, 487, 498, 509, 521, 533, 546, 558, 571, 585, 599, 613, 627, 642,
  413. 658, 674, 690, 707, 724, 742, 760, 779, 799, 819, 839, 861, 883, 905, 928, 952, 977, 1002, 1029, 1056, 1083,
  414. 1112, 1142, 1172, 1204, 1236, 1270, 1305, 1340, 1377, 1415, 1455, 1495, 1537, 1581, 1626, 1672, 1720, 1769,
  415. 1821, 1874, 1928, 1985, 2044, 2104, 2167, 2232, 2299, 2369, 2441, 2515, 2592, 2672, 2755, 2841, 2931, 3023,
  416. 3119, 3218, 3321, 3428, 3539, 3654, 3773, 3898, 4026, 4160, 4299, 4443, 4593, 4749, 4911, 5080, 5255, 5438,
  417. 5627, 5825, 6030, 6244, 6466, 6698, 6940, 7191, 7454, 7727, 8012, 8309, 8619, 8942, 9280, 9632, 10000, 10383,
  418. 10784, 11203, 11641, 12098, 12577, 13077, 13600, 14147, 14720, 15319, 15947, 16604, 17293, 18015, 18771,
  419. 19564, 20395, 21268, 22183, 23144, 24152, 25211, 26324, 27493, 28722, 30014, 31373, 32802, 34307, 35891,
  420. 37558, 39315, 41166, 43117, 45174, 47343, 49633, 52049, 54599, 57293, 60140, 63148, 66329, 69693, 73252,
  421. 77019, 81008, 85233, 89710, 94455, 99488, 104827, 110493, 116508, 122898, 129687, 136905, 144580,
  422. 152746, 161438, 170694, 180554, 191063, 202269};
  423. const uint8 DataPackCounter[21] = {1, 1, 7, 5, 16, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1};
  424. const uint8 DataPackBegin[21] = {0, 0x11, 0x21, 0x31, 0x40, 0x51, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
  425. #define APPLAYERVER_STOP_SEC_VAR
  426. #include "MemMap.h"