《UDS诊断服务课件.ppt》由会员分享,可在线阅读,更多相关《UDS诊断服务课件.ppt(45页珍藏版)》请在taowenge.com淘文阁网|工程机械CAD图纸|机械工程制图|CAD装配图下载|SolidWorks_CaTia_CAD_UG_PROE_设计图分享下载上搜索。
1、上海保隆汽车科技股份有限公司版权所有 2012UDS诊断服务诊断服务什么是什么是UDS?UDS-Unified diagnostic services (统一诊断服务统一诊断服务)俗称俗称14229.形象的说:就是使用一套仪器,对当前汽车出形象的说:就是使用一套仪器,对当前汽车出现的问题进行分析。而这套仪器与汽车交谈所现的问题进行分析。而这套仪器与汽车交谈所使用的语言就是使用的语言就是UDS(不是唯一的方法)。(不是唯一的方法)。2基本时间参数基本时间参数3定时器定时器最小值最小值标准值标准值最大值最大值P2CAN_Server对于服务器接收到请求消息后发出响应消息时间的性能要求 0-50P2
2、CAN_Client客户端在成功发送完请求消息后等待服务器发送的响应时的 超时设置(FF或SF)100-P2*CAN_Server当服务器在发送否定响应码为0 x78 的否定响应后,到服务 器发出响应消息时间的性能要求 0-5000P2*CAN_Client当客户端在接收到否定响应码为0 x78的否定响应后等待服 务器发送响应时的增强型超时设置(FF或SF)5050-P3CAN_Client_Phys 客户端成功发送物理寻址请求消息,并且该请求消息不需要 服务器进行响应后,客户端再次发送下一个物理寻址请求消 息的最小间隔时间 50-P3CAN_Client_Func 客户端成功发送完功能寻址请
3、求消息,并再次发送下一个功 能寻址请求消息时的最小间隔时间,分两种情况:一种为客 户端发送的请求不需要服务器响应,一种为仅由部分支持该 请求的服务器响应,即存在部分服务器不给予响应。50-寻址方式寻址方式4根据物理地址的不同进行访问-只能访问单个ECU节点根据功能的不同进行访问-能访问多个ECU节点物理寻址功能寻址诊断服务诊断服务5SID描述描述0 x10DiagnosticSessionControl0 x11ECUReset0 x14ClearDiagnosticInformation0 x19ReadDTCInformation0 x22ReadDataByIdentifier0 x27
4、SecurityAccess0 x28CommunicationControl service0 x2EWriteDataByIdentifier0 x31RoutineControl0 x3ETesterPresent0 x85ControlDTCSetting否定响应(否定响应(1)6数值数值描述描述0 x11serviceNotSupported 服务器不支持客户端请求的诊断服务0 x12subfuntionNotSupported 服务器不支持客户端请求服务的子功能0 x13incorrectMessageLengthOrInvalidFormat 服务器认为客户端的请求报文的数据长度
5、(或者格式)不符合标准0 x22conditionsNotCorrect 服务器执行诊断服务的条件不满足0 x31requestOutOfRange 服务器没有客户端请求的数据,此否定响应适用于支持数据读、写,或者根据数据调整功能的服务器0 x33securityAccessDenied 服务器阻止客户端的受限诊断服务请求,原因包括:服务器的测试条件不满足 服务器的安全状态处于锁定状态否定响应(否定响应(2)7数值数值描述描述0 x35invalidKey 服务器认为客户端返回的密钥错误0 x36exceedNumberOfAttempts 服务器认为客户端尝试安全访问(解锁)的失败次数超标(
6、一般是大于3次)0 x37requiredTimeDelayNotExpired 服务器拒绝客户端的安全访问请求,因为服务器允许接收请求的计时器未到时0 x78requestCorrectlyReceived-ResponsePending 服务器正确接收到客户端发送的请求,正在处理中,但尚未处理完,此否定响应的发送时间应满足本规范中P2CAN_Server的要求,并且服务器应重复发送此否定响应,直到完成操作。0 x7FserviceNotSupportedInActiveSession 在当前诊断模式下,服务器不支持客户端请求的SIDDiagnosticSessionControl8Data
7、 Byte No.Parameter NameMessage UsageData Valuehex1Diagnostic Session Control Request Service IDM102Sub Function=Diagnostic Session Type M00-FFDefault Session Positive Response Required 01Programming Session Positive Response Required 02Extended Diagnostic Session Positive Response Required 03Default
8、 Session No Positive Response Required 81Programming Session No Positive Response Required82Extended Diagnostic Session -No Positive Response Required83服务请求格式服务请求格式DiagnosticSessionControl9正响应格式正响应格式Data Byte No.Parameter NameMessage UsageData Valuehex1Diagnostic Session Control Response Service Id
9、M502Diagnostic Session TypeM00-FF负响应格式负响应格式Data Byte No.Parameter NameMessage UsageData Valuehex1Negative Response M7F2Diagnostic Session Control M103Negative Response Trouble CodeM00-FFSub Function Not Supported 12Incorrect Message Length Or Invalid Format 13Conditions Not Correct22ECUReset10服务请求格式
10、服务请求格式Data Byte No.Parameter NameMessage UsageData Valuehex1ECU Reset Request Service IDM112Sub Function=Reset Type M00-FFHard Reset Positive Response Required01Soft Reset Positive Response Required03Hard Reset No Positive Response Required81Soft Reset No Positive Response Required83ECUReset11正响应格式正
11、响应格式Data Byte No.Parameter NameMessage UsageData Valuehex1ECU Reset Response Service Id M512Reset TypeM00-FF负响应格式负响应格式Data Byte No.Parameter NameMessage UsageData Valuehex1Negative Response M7F2ECU ResetM113Negative Response Trouble CodeM00-FFSub Function Not Supported 12Incorrect Message Length Or
12、Invalid Format 13ClearDiagnosticInformation12服务请求格式服务请求格式Data Byte No.Parameter NameMessage UsageData Valuehex1Clear Diagnostic Information Request Service IDM142-4groupOfDTC=groupOfDTCHighByte,groupOfDTCMiddleByte,groupOfDTCLowByteM000000-FFFFFFgroupOfDTChexDescriptionxxxxxxBody GroupxxxxxxNetwork
13、Communication GroupFFFFFFAll GroupsClearDiagnosticInformation13正响应格式正响应格式负响应格式负响应格式Data Byte No.Parameter NameMessage UsageData Valuehex1Clear Diagnostic Information Response Service Id M54Data Byte No.Parameter NameMessage UsageData Valuehex1Negative Response M7F2Clear Diagnostic InformationM143Neg
14、ative Response Trouble CodeM00-FFIncorrect Message Length Or Invalid Format 13Conditions Not Correct 22Request Out Of Range31ReadDTCInformation14服务请求格式服务请求格式Data Byte No.Parameter NameMessage UsageData Valuehex1Read DTC Information Request Service IDM192Sub Function=Request Type M00-FFReportNumberOf
15、DTCByStatusMask013DTCStatusMaskM00-FFReport Number of DTC by Status MaskReadDTCInformation15正响应格式正响应格式负响应格式负响应格式Report Number of DTC by Status MaskData Byte No.Parameter NameMessage UsageData Valuehex1Read DTC Information Response Service IDM592Request TypeM00-FFReportNumberOfDTCByStatusMask013DTCSt
16、atusAvailabilityMaskM00-FF4ISO15031-6 DTC FormatM0056DTCCount=DTC Count High ByteDTC Count Low Byte M0000-FFFFData Byte No.Parameter NameMessage UsageData Valuehex1Negative Response M7F2Read DTC InformationM193Negative Response Trouble CodeM00-FFSub Function Not Supported 12Incorrect Message Length
17、Or Invalid Format 13ReadDTCInformation16服务请求格式服务请求格式Data Byte No.Parameter NameMessage UsageData Valuehex1Read DTC Information Request Service IDM192Sub Function=Request Type M00-FFReportDTCByStatusMask023DTCStatusMaskM00-FFReport DTC by Status MaskReadDTCInformation17正响应格式正响应格式Report DTC by Status
18、MaskData Byte No.Parameter NameMessage UsageData Valuehex1Read DTC Information Response Service IDM592Report TypeM00-FFReportDTCByStatusMask023DTCStatusAvailabilityMaskM00-FF4:nDTCAndStatusRecord=DTCHighByte#1DTCMiddleByte#1DTCLowByte#1statusOfDTC#1DTCHighByte#2DTCMiddleByte#2DTCLowByte#2statusOfDTC
19、#2:DTCHighByte#mDTCMiddleByte#mDTCLowByte#mstatusOfDTC#m C00-FF:00-FFReadDTCInformation18负响应格式负响应格式Data Byte No.Parameter NameMessage UsageData Valuehex1Negative Response M7F2Read DTC InformationM193Negative Response Trouble CodeM00-FFSub Function Not Supported 12Incorrect Message Length Or Invalid
20、Format 13Report DTC by Status MaskReadDTCInformation19服务请求格式服务请求格式Data Byte No.Parameter NameMessage UsageData Valuehex1Read DTC Information Request Service IDM192Sub Function=Request Type M00-FFReportDTCSnapshotIdentification04345DTCMaskRecord=DTCHighByteDTCMiddleByteDTCLowByte C00 FF00-FF00-FF6DTC
21、SnapshotRecordNumberC00-FFReport DTC Snapshot IdentificationReadDTCInformation20正响应格式正响应格式Data Byte No.Parameter NameMessage UsageData Valuehex1Read DTC Information Response Service IDM592Report TypeM00-FFreportDTCSnapshotRecordByDTCNumber043456DTCAndStatusRecord=DTCHighByteDTCMiddleByteDTCLowBytest
22、atusOfDTC M00 FF00-FF00-FF00-FF7DTCSnapshotRecordNumber#1C00-FF8DTCSnapshotRecordNumberOfIdentifiers#1C00-FF9:9+k-19+k:9+k+(p-1):r-(m-1)-2:r-(m-1)-1r-(m-1):rDTCSnapshotRecord#1=dataIdentifier#1 byte#1(MSB):dataIdentifier#1 byte#ksnapshotData#1 byte#1:snapshotData#1 byte#p:dataIdentifier#w byte#1(MSB
23、):dataIdentifier#w byte#ksnapshotData#w byte#1:snapshotData#w byte#m C00-FF:00-FF00-FF:00-FF:00-FF:00-FF00-FF:00-FF:C:Report DTC Snapshot IdentificationReadDTCInformation21负响应格式负响应格式Report DTC Snapshot IdentificationData Byte No.Parameter NameMessage UsageData Valuehex1Negative Response M7F2Read DTC
24、 InformationM193Negative Response Trouble CodeM00-FFSub Function Not Supported 12Incorrect Message Length Or Invalid Format 13Request Out Of Range31ReadDTCInformation22服务请求格式服务请求格式Report DTC Extended Data Record by DTC NumberData Byte No.Parameter NameMessage UsageData Valuehex1Read DTC Information
25、Request Service IDM192Sub Function=Request Type M00-FFReportDTCExtendedDataRecordByDTCNumber06345DTCMaskRecord=DTCHighByteDTCMiddleByteDTCLowByte M000000-FFFFFF6DTCExtendedDataRecordNumberM00-FFDTCExtendedDataRecordNumberhexDescriptionxxRequest DTC occurrence counterxxRequest aging counterxxRequest
26、aged counterxxRequest pending counterxxRequest all extended data recordsReadDTCInformation23正响应格式正响应格式Report DTC Snapshot IdentificationData Byte No.Parameter NameMessage UsageData Valuehex1Read DTC Information Response Service IDM592Request TypeM00-FFReportDTCExtendedDataRecordByDTCNumber063456DTCA
27、ndStatusRecord=DTCHighByteDTCMiddleByteDTCLowBytestatusOfDTC M7DTCExtendedDataRecordNumber#1C8:nDTCExtendedDataRecord#1=extendedData#1 byte#1:extendedData#1 byte#p CmDTCExtendedDataRecordNumber#xCm+1:kDTCExtendedDataRecord#x=extendedData#x byte#1:extendedData#x byte#q CReadDTCInformation24负响应格式负响应格式
28、Report DTC Snapshot IdentificationData Byte No.Parameter NameMessage UsageData Valuehex1Negative Response M7F2Read DTC InformationM193Negative Response Trouble CodeM00-FFSub Function Not Supported 12Incorrect Message Length Or Invalid Format 13Request Out Of Range31ReadDTCInformation25服务请求格式服务请求格式Re
29、port Supported DTCData Byte No.Parameter NameMessage UsageData Valuehex1Read DTC Information Request Service IDM192Sub Function=Request Type M00-FFReportSupportedDTC0AReadDTCInformation26正响应格式正响应格式Report Supported DTCData Byte No.Parameter NameMessage UsageData Valuehex1Read DTC Information Response
30、 Service IDM592Report TypeM00-FFReportSupportedDTC0A3DTCStatusAvailabilityMaskM00-FF4DTCAndStatusRecord=DTCHighByte#1DTCMiddleByte#1DTCLowByte#1statusOfDTC#1DTCHighByte#2DTCMiddleByte#2DTCLowByte#2statusOfDTC#2:DTCHighByte#mDTCMiddleByte#mDTCLowByte#mstatusOfDTC#m CReadDTCInformation27负响应格式负响应格式Repo
31、rt Supported DTCData Byte No.Parameter NameMessage UsageData Valuehex1Negative Response M7F2Read DTC InformationM193Negative Response Trouble CodeM00-FFSub Function Not Supported 12Incorrect Message Length Or Invalid Format 13Read Data by Identifier28服务请求格式服务请求格式Data Byte No.Parameter NameMessage Us
32、ageData Valuehex1Read Data By Identifier Request Service IDM2223DataIdentifier=byte#1(MSB)byte#2 M00-FF00-FFRead Data by Identifier29正响应格式正响应格式负响应格式负响应格式Data Byte No.Parameter NameMessage UsageData Valuehex1Read Data By Identifier Response Service IDM6223DataIdentifier=byte#1(MSB)byte#2 M00-FF00-FF#
33、4:#(k-1)+4DataRecord=data#1:data#k M00-FF:00-FFData Byte No.Parameter NameMessage UsageData Valuehex1Negative Response M7F2Read Data By IdentifierM223Negative Response Trouble CodeM00-FFIncorrect Message Length Or Invalid Format 13Request Out Of Range 31Security Access30服务请求格式服务请求格式Step 1:Request se
34、edData Byte No.Parameter NameMessage UsageData Valuehex1Security Access Request Service IDM272Sub Function=Security Access Type M00-FFRequest Seed01Security Access31正响应格式正响应格式负响应格式负响应格式Data Byte No.Parameter NameMessage UsageData Valuehex1Security Access Response Service IDM672securityAccessTypeM00-
35、FFRequest Seed013456securitySeed=seed#1(MSB)seed#2seed#3seed#4(LSB)M00-FF00-FF00-FF00-FFData Byte No.Parameter NameMessage UsageData Valuehex1Negative Response M7F2Security AccessM273Negative Response Trouble CodeM00-FFSub Function Not Supported12Incorrect Message Length Or Invalid Format13Required
36、Time Delay Not Expired37Service Not Supported In Active Session7FStep 1:Request seedSecurity Access32服务请求格式服务请求格式Step 2:Seed security keyData Byte No.Parameter NameMessage UsageData Valuehex1Security Access Request Service IDM272Sub Function=Security Access Type M00-FFSend Key Security023456security
37、Key=key#1(MSB)key#2key#3key#4M00-FF00-FF00-FF00-FFSecurity Access33正响应格式正响应格式负响应格式负响应格式Step 2:Seed security keyData Byte No.Parameter NameMessage UsageData Valuehex1Security Access Response Service IDM672securityAccessTypeM00-FFSend Key Security02Data Byte No.Parameter NameMessage UsageData Valuehex
38、1Negative Response M7F2Security AccessM273Negative Response Trouble CodeM00-FFSub Function Not Supported12Incorrect Message Length Or Invalid Format13Request Sequence Error24Invalid Key35Exceeded Number Of Attempts36Service Not Supported In Active Session7FCommunication Control34服务请求格式服务请求格式Data Byt
39、e No.Parameter NameMessage UsageData Value1Communication Control Request Service IDM282Sub Function=Control TypeM00-FFEnable Rx And Tx Positive Response Required00Disable Rx And Disable Tx Positive Response Required03Enable Rx And Tx No Positive Response Required80Disable Rx And Disable Tx No Positi
40、ve Response Required833Communication TypeM00-FFNormal Communication Messages01Network Management Messages02Normal Communication Messages and Network Management Messages03Communication Control35正响应格式正响应格式负响应格式负响应格式Data Byte No.Parameter NameMessage UsageData Valuehex1Communication Control Response Se
41、rvice ID M682Sub Function=control TypeM00-FFData Byte No.Parameter NameMessage UsageData Valuehex1Negative Response M7F2Communication ControlM283Negative Response Trouble CodeM00-FFSub Function Not Supported 12Incorrect Message Length Or Invalid Format 13Request Out Of Range31Service Not Supported I
42、n Active Session7FWrite Data by Identifier36服务请求格式服务请求格式Data Byte No.Parameter NameMessage UsageData Valuehex1Write Data by Identifier Request Service IDM2E23DataIdentifier#1=byte#1(MSB)byte#2 M00-FF00-FF4:m+3DataRecord=data#1:data#m M00-FF:00-FFWrite Data by Identifier37正响应格式正响应格式负响应格式负响应格式Data Byt
43、e No.Parameter NameMessage UsageData Valuehex1Write Data by Identifier Response Service IDM6E23DataIdentifier#1=byte#1(MSB)byte#2 M00-FF00-FFData Byte No.Parameter NameMessage UsageData Valuehex1Negative Response M7F2Write Data by IdentifierM2E3Negative Response Trouble CodeM00-FFIncorrect Message L
44、ength Or Invalid Format 13Conditions Not Correct22Request Out Of Range 31Security Access Denied33Service Not Supported In Active Session7FRoutine Control38服务请求格式服务请求格式Data Byte No.Parameter NameMessage UsageData Valuehex1Routine Control Request Service IDM312Sub Function=Routine Control TypeM00-FFSt
45、artRoutine01StopRoutine02RequestRoutineResults0334RoutineIdentifier=byte#1(MSB)byte#2M0000-FFFF5:nRoutineControlOptionRecord =routineControlOption#1:routineControlOption#m CRoutine Control39正响应格式正响应格式Data Byte No.Parameter NameMessage UsageData Valuehex1Routine Control Response Service IDM712Routine
46、 Control TypeM00-FF34RoutineIdentifier#1=byte#1(MSB)byte#2 M0000-FFFF5:nRoutineStatusRecord=routineStatus#1:routineStatus#mRoutine Control40负响应格式负响应格式Data Byte No.Parameter NameMessage UsageData Valuehex1Negative Response M7F2Write Data by IdentifierM313Negative Response Trouble CodeM00-FFSub Functi
47、on Not Supported 12Incorrect Message Length Or Invalid Format 13Conditions Not Correct22Request Sequence Error24Request Out Of Range 31Security Access Denied33Service Not Supported In Active Session7FTester Present41服务请求格式服务请求格式Data Byte No.Parameter NameMessage UsageData Valuehex1Tester Present Req
48、uest Service IDM3E2Sub Function=zero Sub FunctionM00-FFPositive Response Required00No Positive Response Required80Tester Present42正响应格式正响应格式负响应格式负响应格式Data Byte No.Parameter NameMessage UsageData Valuehex1Tester Present Response Service Id M7E2Sub Function=zero Sub FunctionM00-FFData Byte No.Paramete
49、r NameMessage UsageData Valuehex1Negative Response M7F2Tester Present M3E3Negative Response Trouble CodeM00-FFSub Function Not Supported 12Incorrect Message Length Or Invalid Format 13Control DTC Setting43服务请求格式服务请求格式Data Byte No.Parameter NameMessage UsageData Valuehex1Control DTC Setting Request S
50、ervice IDM852Sub Function=DTC Setting TypeM00-FFOn Positive Response Required01Off Positive Response Required02On No Positive Response Required81Off No Positive Response Required82Control DTC Setting44正响应格式正响应格式负响应格式负响应格式Data Byte No.Parameter NameMessage UsageData Valuehex1Control DTC Setting Respo