UDS-TransferData(传输数据)(0x36)服务

1、作用:客户端利用传输数据服务从客户端向服务器或从服务器向客户端传输 数据。

2、请求消息定义

A_Data byteParameter nameCvtHex valueMnemonic
#1TransferData Request SIDM0x36TD
#2blockSequenceCounterM00-FFBSC
#3
:
#n
transferRequestParameterRecord[] = [
transferRequestParameter#1
:
transferRequestParameter#m ]
M0x00 – 0xFF
:
0x00 – 0xFF
TRPR_
TRTP_
:
TRTP_
C = Conditional: this parameter is mandatory if a download is in progress.
Definition

blockSequenceCounter

blockSequenceCounter参数从0x01开始,第一个传输数据请求在0x34或0x35之后,传输数据请求每增加一次,这个参数值就会加1.当参数值增加到FF时,接下来又从0x01开始。
-如果下载/上传数据的请求被服务器正确的接收和处理,但肯定消息响应消息没有到达客户端,则客户端认为应用层超时并重复相同的请求。这样服务器会接收重复请求并根据计入的块序列计数器确定重复计数。然后服务器不在重新写数据,而是立即将肯定响应消息发送到服务器内存中。

-如果传输数据请其与下载/上传数据没有被服务器正确的接收,然后服务器不会返回肯定响应。客户端将认为应用层超时并会重复请求。这样服务器会重复接收传输数据请求并根据计入块序列计数器确定该请求位新传输数据请求。然后服务器会处理服务并发送肯定响应。

transferRequestParameterRecord

此参数包括了服务器需求的并且支持的数据参数。数据的长度和格式由主机厂定义。

3、肯定消息响应

A_Data byteParameter nameCvtHex valueMnemonic
#1RequestUpload Response SIDM0x36TD
#2blockSequenceCounterM00-FFBSC

#3
:
#n

transferRequestParameterRecord[] = [
transferRequestParameter#1
:
transferRequestParameter#m ]
C
:
U
0x00 – 0xFF
:
0x00 – 0xFF
TRPR_
TRTP_
:
TRTP_
Definition

blockSequenceCounter

同上

transferResponseParameterRecord(传输响应参数记录)

此参数应该包括客户端要求的且支持的数据,参数的长度和格式由主机厂定义。

示例:下载时,传输响应参数记录可以包括服务器计算校验值。上传,传输参数记录包括上传的数据。下载时,传输数据参数不应该重复传输请求参数记录。

4、否定消息响应定义

NRC说明Mnemonic
0x13incorrectMessageLengthOrInvalidFormat
长度错误
IMLOIF
0x24

requestSequenceError RSE(请求序列错误)
⎯ 当服务器收到一个请求时,但请求下载或者上传没有激活
⎯ 请求下载或者上传激活,但服务器已收到请求下载或者上传服务中的内存大小所有参数
注意:块序接收到数据传输请求等效于列计数器 The repetition of a TransferData request message with a
blockSequenceCounter equal to the one included in the previous TransferData request
message shall be accepted by the server.

RSE
0x31requestOutOfRange 
This NRC shall be returned if:
⎯ The transferRequestParameterRecord contains additional control parameters (e.g.
additional address information) and this control information is invalid.
⎯ The transferRequestParameterRecord is not consistent with the requestDownload or
requestUpload service parameter maxNumberOfBlockLength.
⎯ The transferRequestParameterRecord is not consistent with the server’s memory
alignment constraints.
ROOR

0x71

transferDataSuspended
This NRC shall be returned if the download module length does not meet the
requirements of the memorySize parameter sent in the request message of the
requestDownload service.
TDS
0x72generalProgrammingFailure
This NRC shall be returned if the server detects an error when erasing or programming a
memory location in the permanent memory device (e.g. Flash Memory) during the
download of data.
GPF
0x73wrongBlockSequenceCounter
This NRC shall be returned if the server detects an error in the sequence of the
blockSequenceCounter.
NOTE The repetition of a TransferData request message with a
blockSequenceCounter equal to the one included in the previous TransferData request
message shall be accepted by the server.
WBSC
0x92 / 0x93voltageTooHigh / voltageTooLow
This return code shall be sent as applicable if the voltage measured at the primary power
pin of the server is out of the acceptable range for downloading data into the server’s
permanent memory (e.g. Flash Memory).
VTH / VTL

  • 1
    点赞
  • 6
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值