UDSInterface_Cfg.h 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282
  1. /********************************************************************************
  2. * 常州易控汽车电子股份有限公司
  3. * (c) Copyright 2009-2018 ECTEK
  4. * 保留所有权利
  5. ********************************************************************************
  6. * 工程名称:匹配标定与故障诊断接口
  7. * 文件名: UDSInterface_Cfg.h
  8. * 功能描述 : UDS配置文件
  9. * 引用记录:
  10. * 备注:
  11. * 修订记录:
  12. * 日期 版本 作者 描述
  13. * 2018.12.07 00.01.02 刘略 第一版
  14. *******************************************************************************/
  15. #ifndef __UDSINTERFACE_CFG_H
  16. #define __UDSINTERFACE_CFG_H
  17. #define _UDSINTERFACE_NUM_DID 100 //DID数量
  18. #define _UDSINTERFACE_NUM_ROUTINE 10 //Routine Control数量
  19. #define _UDSINTERFACE_NUM_SNAPSHOT 0 //Snapshot绑定DID数量
  20. #define _UDS_INDEX_DID_UINT8_N 0 ///数据类型为数组
  21. #define _UDS_INDEX_DID_UINT8 1
  22. #define _UDS_INDEX_DID_INT8 2
  23. #define _UDS_INDEX_DID_UINT16 3
  24. #define _UDS_INDEX_DID_INT16 4
  25. #define _UDS_INDEX_DID_UINT32 5
  26. #define _UDS_INDEX_DID_INT32 6
  27. #define _UDS_INDEX_DID_UINT64 7
  28. #define _UDS_INDEX_DID_INT64 8
  29. #define _UDS_INDEX_DID_FLOAT32 9
  30. #define _UDS_INDEX_DID_FLOAT64 10
  31. /*DID数据的存储方式*/
  32. #define _UDS_INDEX_DID_LSB 1 ///小端存储
  33. #define _UDS_INDEX_DID_MSB 0 ///大端存储
  34. /*部分DID的数据长度*/
  35. #define _EOL_LEN_K2REI_VMVIN 34 //Vehicle Manufacturer Vehicle Identification Number
  36. #define _EOL_LEN_K2REI_VMECUSWVER 64 //Vehicle Manufacturer ECU Software Version
  37. #define _EOL_LEN_K2REI_VMECUHWNR 16 //Vehicle Manufacturer ECU Hardware Number
  38. #define _EOL_LEN_K2REI_VMTESTERSN 16 //Vehicle Manufacturer Repair Shop Code or Tester Serial Number
  39. #define _EOL_LEN_K2REI_VMPMDATE 10 //Vehicle Manufacturer Program Data
  40. #define _EOL_LEN_K2REI_VMEGTSTDATE 10 //Vehicle Manufacturer Engine Test Date
  41. #define _EOL_LEN_K2REI_VMDSID 66 //Vehicle Manufacturer Dataset Identification
  42. /*DID定义*/
  43. #define _UDS_INDEX_DID_VEHNANUFECUSWNO 0xF188U
  44. #define _UDS_INDEX_DID_VEHMANUFECUSWVERNO 0xF189U
  45. #define _UDS_INDEX_DID_VIN 0xF190U
  46. #define _UDS_INDEX_DID_VEHMANUFECUHWNO 0xF191U
  47. #define _UDS_INDEX_DID_SYSNAMEORENGTYPE 0xF197U
  48. #define _UDS_INDEX_DID_REPAIRSHOPCODE 0xF198U
  49. #define _UDS_INDEX_DID_PROGAMMINGDATE 0xF199U
  50. #define _UDS_INDEX_DID_CALIBRATIONEQSWNO 0xF19CU
  51. #define _UDS_INDEX_DID_ECUINSTALLDATE 0xF19DU
  52. /*Data Identifier*/
  53. #define _UDS_INDEX_DID_RESETINFO 0xF120U
  54. #define _UDS_INDEX_DID_EOLTESTSWT 0xF121U//
  55. #define _UDS_INDEX_DID_CALDATANAME 0xF150U//
  56. #define _UDS_INDEX_DID_CALDATAPARTNO 0xF151U//
  57. #define _UDS_INDEX_DID_CALECUPARTNO 0xF152U
  58. #define _UDS_INDEX_DID_CALSWVERNO 0xF153U//
  59. #define _UDS_INDEX_DID_CALVEHMODEL 0xF154U//
  60. #define _UDS_INDEX_DID_USERCUSTCODE0 0xF155U//
  61. #define _UDS_INDEX_DID_USERCUSTCODE1 0xF156U
  62. #define _UDS_INDEX_DID_USERCUSTCODE2 0xF157U
  63. #define _UDS_INDEX_DID_USERCUSTCODE3 0xF158U
  64. #define _UDS_INDEX_DID_USERCUSTCODE4 0xF159U
  65. #define _UDS_INDEX_DID_USERCUSTCODE5 0xF15AU
  66. #define _UDS_INDEX_DID_BOOTSWIDENT 0xF180U
  67. #define _UDS_INDEX_DID_APPSWIDENT 0xF181U
  68. #define _UDS_INDEX_DID_APPDATAIDENT 0xF182U
  69. #define _UDS_INDEX_DID_BOOTSWFINGERPRINT 0xF183U
  70. #define _UDS_INDEX_DID_APPSWFINGERPRINT 0xF184U
  71. #define _UDS_INDEX_DID_APPDATAFINGERPRINT 0xF185U
  72. #define _UDS_INDEX_DID_VEHMANUFSPAREPARTNO 0xF187U
  73. #define _UDS_INDEX_DID_VEHNANUFECUSWNO 0xF188U
  74. #define _UDS_INDEX_DID_VEHMANUFECUSWVERNO 0xF189U
  75. #define _UDS_INDEX_DID_SYSSUPPLIERIDENT 0xF18AU
  76. #define _UDS_INDEX_DID_ECUMANUFDATE 0xF18BU
  77. #define _UDS_INDEX_DID_ECUSERIALNO 0xF18CU//
  78. #define _UDS_INDEX_DID_SUPPORTFUNCUNIT 0xF18DU
  79. #define _UDS_INDEX_DID_VIN 0xF190U
  80. #define _UDS_INDEX_DID_VEHMANUFECUHWNO 0xF191U
  81. #define _UDS_INDEX_DID_SYSSUPPLIERECUHWNO 0xF192U
  82. #define _UDS_INDEX_DID_SYSSUPPLIERECUHWVERNO 0xF193U
  83. #define _UDS_INDEX_DID_SYSSUPPLIERECUSWNO 0xF194U
  84. #define _UDS_INDEX_DID_SYSSUPPLIERECUSWVERNO 0xF195U
  85. #define _UDS_INDEX_DID_EXHREGORTYPEAPPRNO 0xF196U
  86. #define _UDS_INDEX_DID_SYSNAMEORENGTYPE 0xF197U
  87. #define _UDS_INDEX_DID_REPAIRSHOPCODE 0xF198U
  88. #define _UDS_INDEX_DID_PROGAMMINGDATE 0xF199U
  89. #define _UDS_INDEX_DID_CALREPAIRSHOPCODE 0xF19AU
  90. #define _UDS_INDEX_DID_CALIBRATIONDATE 0xF19BU
  91. #define _UDS_INDEX_DID_CALIBRATIONEQSWNO 0xF19CU
  92. #define _UDS_INDEX_DID_ECUINSTALLDATE 0xF19DU
  93. #define _UDS_INDEX_DID_ODXFILEIDENT 0xF19EU
  94. #define _UDS_INDEX_DID_ENTITYIDENT 0xF19FU
  95. /*下面是上柴新加的DID*/
  96. #define UDS_INDEX_DID_DATASET_VER_PRO_VEHICLE_SUPPLIER_DIS 0XF012U
  97. #define UDS_INDEX_DID_HISTORICAL_INTERROGATION_RECORD 0XF101U
  98. #define UDS_INDEX_DID_SUPPLIER_ECU_SOFT_VER_NUM 0XF105U
  99. #define UDS_INDEX_DID_SUPPLIER_ECU_DATASET_VER_NUM 0XF011U
  100. #define UDS_INDEX_DID_ECUAPPLICATIONSOFTWAREVERSIONNUMBER 0XF1A0U
  101. #define UDS_INDEX_DID_ECUCALIBRATIONSOFTWARENUMBER 0XF1A1U
  102. #define UDS_INDEX_DID_ECUNETREFERENCENUMBER 0XF1A2U
  103. #define UDS_INDEX_DID_CBALIRATIONDATAIDENTIFIER 0XF1A3U
  104. #define UDS_INDEX_DID_CURRENT_RERILL_LOAD_LEVEL_FROM_SCRMON 0X301U
  105. #define UDS_INDEX_DID_DOSING_STRATEGY_CURRENT_NH3_LOAD_LEVE_CATALYST 0X302U
  106. #define UDS_INDEX_DID_DOSING_STRATEGY_HC_POISONING_EASY_RELEASED 0X303U
  107. #define UDS_INDEX_DID_DOSING_STRATEGY_HC_POISONING_DIFFICULTLY 0X304U
  108. #define UDS_INDEX_DID_DOSING_STRATEGY_AGE_SCR_CATALYST 0X306U
  109. #define UDS_INDEX_DID_DOSING_STRATEGY_AGE_OXI_HC 0X307U
  110. #define UDS_INDEX_DID_DOSING_STRATEGY_AGE_OXI_NO2 0X308U
  111. #define UDS_INDEX_DID_DOSING_STRATEGY_AGEOXI_HC_NO2 0X309U
  112. #define UDS_INDEX_DID_DOSING_STRATEGY_CURRENT_STATE_LONG_TERM_ADAP 0X310U
  113. #define UDS_INDEX_DID_UDC_MRdCAGDOSQNT 0X319U
  114. #define UDS_INDEX_DID_DOSED_QUANTITY_SCR_POD 0X327U//写
  115. #define UDS_INDEX_DID_SCRCTL_CTRCNT 0X334U
  116. #define UDS_INDEX_DID_INDEX_FOR_ENGINE_TEST_SCR 0X336U
  117. #define UDS_INDEX_DID_INDUCEMENT_OVERRIDE_COUNTER_VALUE 0X33EU
  118. #define UDS_INDEX_DID_SYSDIAG_TIINDCOVRDDURNCNTR_MP 0X3B4U
  119. #define UDS_INDEX_DID_UDOSVLV_O_P_ATS 0X0401U
  120. #define UDS_INDEX_DID_UHTRPL_O_D_ATS 0X0402U
  121. #define UDS_INDEX_DID_UHTRTNK_O_D_ATS 0X0403U
  122. #define UDS_INDEX_DID_UPMPMOT_O_P_ATS 0X0404U
  123. #define UDS_INDEX_DID_URREVLV_O_D_ATS 0X0405U
  124. #define UDS_INDEX_DID_UHTRBL_O_D_ATS 0X0406U
  125. #define UDS_INDEX_DID_UHTRSM_O_D_ATS 0X0407U
  126. #define UDS_INDEX_DID_UHTRSL_O_D_ATS 0X0408U
  127. #define UDS_INDEX_DID_UHTRRly_O_D_ATS 0X0409U
  128. #define UDS_INDEX_DID_Routine_SysDosQun_Measurement 0x0501U
  129. #define UDS_INDEX_DID_Routine_DosQun_Measurement 0x0502U
  130. #define UDS_INDEX_DID_Routine_DosQunInt 0x0503U
  131. #define UDS_INDEX_DID_Routine_System_Emptying 0x0504U
  132. #define UDS_INDEX_DID_Routine_SCRComplete 0x0505U
  133. #define UDS_INDEX_DID_Routine_System_Pre_Spray_Test 0x0507U
  134. #define UDS_INDEX_DID_Routine_Pressure_BuildUP_Spray_Test 0x0508U
  135. #define UDS_INDEX_DID_Routine_Spray_Phase 0x0509U
  136. #define UDS_INDEX_DID_READ_VARIANT_DA_MANGER_STR_FROM_EEPROM 0X1001U
  137. #define UDS_INDEX_DID_RAW_VALUE_INPUTS_DIRECTLY_AFTER_ADC 0X1600U
  138. #define UDS_INDEX_DID_PHYSICAL_VALUES_OF_THE_INPUTS 0X1601U
  139. #define UDS_INDEX_DID_BATTEY_VALTAGE 0X1602U
  140. #define UDS_INDEX_DID_MAIN_STATE_MACHINE 0X1603U
  141. #define UDS_INDEX_DID_COSCR_STATE_MACHINE 0X1604U
  142. #define UDS_INDEX_DID_ENGINE_TEST_DOSING_QUANTITY_MEASUREMENT 0X1605U
  143. #define UDS_INDEX_DID_SECTION_ENGINE_TEST_SYSTEM_EMPTYING 0X1610U
  144. #define UDS_INDEX_DID_ACTUAL_ENGINE_PERCENT_TORQUE_PTHLEAD_TRQINRCURR 0x1612U
  145. #define UDS_INDEX_DID_COOLANT_TEMPERATURE_CENGDST_T 0X1613U
  146. #define UDS_INDEX_DID_FUEL_TEMPERATURE_FUELT_T 0X1614U
  147. #define UDS_INDEX_DID_OIL_TEMPERATURE_OIL_TSWMP 0X1615U
  148. #define UDS_INDEX_DID_RESERVED 0X1616U
  149. #define UDS_INDEX_DID_NOX_SENSOR_HEATER_RELEASED_US_DS_SCRCTL_STHTRRLS 0X1617U
  150. #define UDS_INDEX_DID_NOX_SENSOR_US_SCR_NOMCATDS 0X1618U
  151. #define UDS_INDEX_DID_NOX_SENSOR_DS_SCR_NOCAT2DS 0X1619U
  152. #define UDS_INDEX_DID_ANALOG_OUTPUTS_UDOSVLV_RPS_UPMPMOT_RPS 0X1620U
  153. #define UDS_INDEX_DID_TOTAL_VEHICLE_DISTANCE_GLBDA_LTOTDST 0X1623U
  154. #define UDS_INDEX_DID_NOX_RAW_EMISSIONS_UPSTREAM_SCR_CAL_MOD 0X1624U
  155. #define UDS_INDEX_DID_LAMBDA_VALUE_UPSTREAM_SCR_TRBNDSRLAM_RLAM 0X1625U
  156. #define UDS_INDEX_DID_ENGINE_TEST_SCR_COMPLETE 0X1626U
  157. #define UDS_INDEX_DID_ACTIVE_DIAGNOSTIC_INFORMATION 0xF100U
  158. #define UDS_INDEX_DID_HARDWARE_PART_NUMBER_BUSINESS_UNIT_SPECIFIC 0XF111U
  159. #define UDS_INDEX_DID_SOFTWARE_PART_NUMBER_BUSINESS_UNIT_SPECIFIC 0XF121U
  160. #define UDS_INDEX_DID_HARD_VERSION_INFORMATION 0XF150U
  161. #define UDS_INDEX_DID_SOFTWARE_VERSION_INFORMATION 0XF151U
  162. #define UDS_INDEX_DID_BOOT_SOFTWARE_VERSION_INFORMATION 0XF153U
  163. #define UDS_INDEX_DID_HARDWARE_SUPPLIER_IDENTIFICATION 0XF154U
  164. #define UDS_INDEX_DID_SOFTWARE_SUPPLIER_IDENTIFICATION 0XF155U
  165. #define UDS_INDEX_DID_WRITE_FINGERPRINT_DATAIDENTIFIER_EOL 0XF15AU
  166. #define UDS_INDEX_DID_WRITE_FINGERPRINT_DATAIDENTIFIER_AFTERSALE 0XF15BU
  167. #define UDS_INDEX_DID_DCU_CODE_IDENTIFICATION_SERIAL_NUMBER 0XF18CU
  168. #define UDS_INDEX_DID_ECU_BOOTLOADER_SOFTWARE_NUMBER 0XF183U
  169. #define UDS_INDEX_DID_ECU_PART_NUMBER 0XF187U
  170. #define UDS_INDEX_DID_SYSTERM_SUPPLIERID 0XF18AU
  171. #define UDS_INDEX_DID_ECU_MANUFACTUREDATE 0XF18BU
  172. #define UDS_INDEX_DID_SUPPLIER_ECU_SERIAL_NUMBER 0XF18CU
  173. #define UDS_INDEX_DID_VEHICL_ASSEMBLY_NUMBER 0XF18EU
  174. #define UDS_INDEX_DID_ECUHARDWARE_VERSIONNNmber 0xF191U
  175. #define UDS_INDEX_DID_VIN 0xF190U
  176. #define UDS_INDEX_DID_SUPPER_ECU_HARDWARE_NUMBER 0XF192U
  177. #define UDS_INDEX_DID_SUPPER_ECU_HARDWARE_VERSION_NUMBER 0XF193U
  178. #define UDS_INDEX_DID_ENGINE_TYPE_PROGRAMMED_BY_ENGINE_SUPPLIER 0XF197U
  179. #define UDS_INDEX_DID_DOSING_VALVE_RB_PART_NUMBER 0XF1F0U
  180. #define UDS_INDEX_DID_DOSING_VALVE_IDENTIFICATION_CODE 0XF1F1U
  181. #define UDS_INDEX_DID_SUPPLY_MODULE_RB_PART_NUMBER 0XF1F2U
  182. #define UDS_INDEX_DID_SUPPLY_MODULE_IDENTIFICATION_CODE 0XF1F3U
  183. #define UDS_INDEX_DID_UDV_CHECK 0XF1F4U
  184. #define UDS_INDEX_DID_FIRST_PROGRAMMED_SW_CONTAINER_NUMBER 0XF1F5U
  185. #define UDS_INDEX_DID_MANUFACTURING_date_ONE 0XF1F6U
  186. #define UDS_INDEX_DID_MANUFACTURING_date_TWO 0XF1F7U
  187. #define UDS_INDEX_DID_EEPROM_LAYOUT_VERSION 0XF1F8U
  188. #define UDS_INDEX_DID_READ_TPROT_INFORMATION 0XFD00U
  189. /*27145相关*/
  190. #define UDS_INDEX_STATUS_VEHICLE_ENGINE 0xF41CU
  191. #define UDS_INDEX_FLOW_RATE_SENSOR 0xf410U
  192. #define UDS_INDEX_PRESSURE_INTAKE 0xf40bU
  193. #define UDS_INDEX_NOX_CONTROL_SYSTEM 0xf485U
  194. #define UDS_INDEX_BANK_DPF 0xf47aU
  195. #define UDS_INDEX_FUEL_RAIL_PRESSURE 0xf423U
  196. #define UDS_INDEX_ITID_PROTOCOL_IDENTIFICATION 0XF810U
  197. #define UDS_INDEX_ITID_VIN 0XF802U
  198. #define UDS_INDEX_ITID_SUPPORTITID 0XF800U
  199. #define UDS_INDEX_ITID_SUPPORTITID_TWO 0XF820U
  200. #define UDS_INDEX_ITID_SUPPORTITID_FOUR 0XF840U
  201. #define UDS_INDEX_ITID_SUPPORTITID_SIX 0XF860U
  202. #define UDS_INDEX_ITID_SUPPORTITID_EIGHT 0XF880U
  203. #define UDS_INDEX_ITID_SUPPORTITID_A 0XF8A0U
  204. #define UDS_INDEX_ITID_SUPPORTITID_C 0XF8C0U
  205. #define UDS_INDEX_ITID_SUPPORTITID_E 0XF8E0U
  206. #define UDS_INDEX_DID_SUPPORTDID 0XF400U
  207. #define UDS_INDEX_DID_SUPPORTDID_two 0XF420U
  208. #define UDS_INDEX_DID_SUPPORTDID_FOUR 0XF440U
  209. #define UDS_INDEX_DID_SUPPORTDID_SIX 0XF460U
  210. #define UDS_INDEX_DID_SUPPORTDID_EIGHT 0XF480U
  211. #define UDS_INDEX_DID_SUPPORTDID_A 0XF4A0U
  212. #define UDS_INDEX_DID_SUPPORTDID_C 0XF4C0U
  213. #define UDS_INDEX_DID_SUPPORTDID_E 0XF4E0U
  214. #define UDS_INDEX_DID_ENGINE_RPM 0XF40CU
  215. #define UDS_INDEX_DID_VEHICLE_SPEED 0XF40DU
  216. #define UDS_INDEX_DID_ENGINE_COOLANT_TEM 0XF405U
  217. #define UDS_INDEX_DID_ATMOSPHERIC_PRESSURE_VALUE 0XF433U
  218. #define UDS_INDEX_DID_CONTROL_MODULE_VOLTAGE 0XF442U
  219. #define UDS_INDEX_DID_AMBIENT_AIR_TEMPERATURE 0XF446U
  220. #define UDS_INDEX_DID_ENGINE_OIL_TEMPERATURE 0XF45CU
  221. #define UDS_INDEX_DID_INTAKE_AIR_FLOW_CONTROL 0XF46AU
  222. #define UDS_INDEX_DID_MASS_AIR_FLOW_SENSOR 0XF466U
  223. #define UDS_INDEX_DID_ENGINE_COOLANT_TEMPERATURE 0XF467U
  224. #define UDS_INDEX_DID_INTAKE_AIR_TEMPERATURE_SENSOR 0XF468U
  225. #define UDS_INDEX_DID_NOX_SENSOR 0XF483U
  226. #define UDS_INDEX_DID_O2_SENSOR 0XF48CU
  227. #define UDS_INDEX_MID_SUPPORTMID 0XF600U
  228. #define UDS_INDEX_MID_SUPPORTMID_TWO 0XF620U
  229. #define UDS_INDEX_MID_SUPPORTMID_FOUR 0XF640U
  230. #define UDS_INDEX_MID_SUPPORTMID_SIX 0XF660U
  231. #define UDS_INDEX_MID_SUPPORTMID_EIGHT 0XF680U
  232. #define UDS_INDEX_MID_SUPPORTMID_A 0XF6A0U
  233. #define UDS_INDEX_MID_SUPPORTMID_C 0XF6C0U
  234. #define UDS_INDEX_MID_SUPPORTMID_E 0XF6E0U
  235. /*27145RID定义*/
  236. #define UDS_INDEX_RID_SUPPORT 0XE000U
  237. #define UDS_INDEX_RID_SUPPORT_TWO 0XE020U
  238. #define UDS_INDEX_RID_SUPPORT_FOUR 0XE040U
  239. #define UDS_INDEX_RID_SUPPORT_SIX 0XE060U
  240. #define UDS_INDEX_RID_SUPPORT_EIGHT 0XE080U
  241. #define UDS_INDEX_RID_SUPPORT_A 0XE0A0U
  242. #define UDS_INDEX_RID_SUPPORT_E 0XE0E0U
  243. #define UDS_INDEX_RID_SUPPORT_C 0XE0C0U
  244. #define UDS_INDEX_RID_EVAPORATIVE_SYS_LEAK_TEST 0XE001U
  245. //luoshun
  246. #define UDS_INDEX_DID_SUPPORT_F463 0XF463U
  247. #define UDS_INDEX_DID_SUPPORT_F404 0XF404U
  248. #define UDS_INDEX_DID_SUPPORT_F49E 0XF49EU
  249. #define UDS_INDEX_DID_SUPPORT_F449 0XF449U
  250. #define UDS_INDEX_DID_SUPPORT_F44A 0XF44AU
  251. //关于冻结帧的DID
  252. #define UDS_INDEX_DID_SUPPORT_F461 0XF461U
  253. #define UDS_INDEX_DID_SUPPORT_F462 0XF462U
  254. extern uint8 UDS_SysO_bAcvDewptNoxSnsrCA ;
  255. extern uint8 ITID_PROTOCOL_IDENTIFICATIONUB;
  256. extern uint8 dataSysOUB;
  257. #endif