C语言实现的UDS诊断协议栈,专为小型嵌入式设备打造,可轻松实现将设备接入CAN/LIN网络(源码)

上传者: m0_37302966 | 上传时间: 2025-07-29 11:53:57 | 文件大小: 1.11MB | 文件类型: ZIP
源码说明 UDS 诊断协议栈相关源码位于 "UDS_For_STM32MP157/CM4/UDSBase" 和 "UDS_For_STM32MP157/CM4/UDSLogic" 这两个目录下 先说 "UDSBase" 目录下的源码文件,其中核心文件有两个,分别是 "uds_tp.c" 和 "uds_service.c" 比如当我们想向外发送 100 个字节数据的时候,由于物理硬件的限制(CAN 一帧最多只能发送 8 个字节的数据),我们是没用办法把这 100 个字节的数据一次性全部发送出去的,这时候我们不得不将一整包数据拆分,然后一帧一帧地发送出去,"uds_tp.c" 就是实现这个拆分功能的,比如给每一帧添加一个帧序号等等,这样子接收方才能够准确的将接收到的数据完整的还原成一整包数据;有发送就有接收,"uds_tp.c" 还能将接收到的多帧数据拼接组装,去除帧序号等辅助信息,最后形成一整包完整的有效数据,再将其传送到上层或应用层去处理。"uds_tp.c" 的实现是完全遵循 ISO 15765-2 协议的 经 "uds_tp.c" 处理过的数据将继续交由 "uds_service.

文件下载

资源详情

[{"title":"( 136 个子文件 1.11MB ) C语言实现的UDS诊断协议栈,专为小型嵌入式设备打造,可轻松实现将设备接入CAN/LIN网络(源码)","children":[{"title":"stm32mp157d-uds_for_stm32mp157-mx.dts.bak <span style='color:#111;'> 3.17KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_tim.c <span style='color:#111;'> 214.30KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_fdcan.c <span style='color:#111;'> 169.17KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_rcc_ex.c <span style='color:#111;'> 98.96KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_rcc.c <span style='color:#111;'> 85.84KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_tim_ex.c <span style='color:#111;'> 78.22KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_mdma.c <span style='color:#111;'> 61.45KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_dma.c <span style='color:#111;'> 48.48KB </span>","children":null,"spread":false},{"title":"uds_tp.c <span style='color:#111;'> 35.24KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal.c <span style='color:#111;'> 28.52KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_pwr.c <span style='color:#111;'> 26.55KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_pwr_ex.c <span style='color:#111;'> 21.14KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_dma_ex.c <span style='color:#111;'> 21.01KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_exti.c <span style='color:#111;'> 20.63KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_gpio.c <span style='color:#111;'> 19.18KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_cortex.c <span style='color:#111;'> 16.36KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_hsem.c <span style='color:#111;'> 14.30KB </span>","children":null,"spread":false},{"title":"uds_service.c <span style='color:#111;'> 11.55KB </span>","children":null,"spread":false},{"title":"main.c <span style='color:#111;'> 8.81KB </span>","children":null,"spread":false},{"title":"system_stm32mp1xx.c <span style='color:#111;'> 8.76KB </span>","children":null,"spread":false},{"title":"SID27_SecurityAccess.c <span style='color:#111;'> 6.81KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_it.c <span style='color:#111;'> 5.57KB </span>","children":null,"spread":false},{"title":"fdcan.c <span style='color:#111;'> 4.37KB </span>","children":null,"spread":false},{"title":"msg_buf.c <span style='color:#111;'> 4.13KB </span>","children":null,"spread":false},{"title":"SID10_SessionControl.c <span style='color:#111;'> 3.87KB </span>","children":null,"spread":false},{"title":"SID31_RoutineControl.c <span style='color:#111;'> 3.79KB </span>","children":null,"spread":false},{"title":"service_cfg.c <span style='color:#111;'> 3.39KB </span>","children":null,"spread":false},{"title":"SID28_CommunicationControl.c <span style='color:#111;'> 2.93KB </span>","children":null,"spread":false},{"title":"sysmem.c <span style='color:#111;'> 2.75KB </span>","children":null,"spread":false},{"title":"uds_port.c <span style='color:#111;'> 2.75KB </span>","children":null,"spread":false},{"title":"syscalls.c <span style='color:#111;'> 2.61KB </span>","children":null,"spread":false},{"title":"SID19_ReadDTCInformation.c <span style='color:#111;'> 2.36KB </span>","children":null,"spread":false},{"title":"SID11_EcuReset.c <span style='color:#111;'> 2.26KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_msp.c <span style='color:#111;'> 2.26KB </span>","children":null,"spread":false},{"title":"SID85_ControlDTCSetting.c <span style='color:#111;'> 2.22KB </span>","children":null,"spread":false},{"title":"SID2E_WriteDataByIdentifier.c <span style='color:#111;'> 2.14KB </span>","children":null,"spread":false},{"title":"SID14_ClearDiagnosticInformation.c <span style='color:#111;'> 2.06KB </span>","children":null,"spread":false},{"title":"SID22_ReadDataByIdentifier.c <span style='color:#111;'> 2.03KB </span>","children":null,"spread":false},{"title":"SID3E_TesterPresent.c <span style='color:#111;'> 1.92KB </span>","children":null,"spread":false},{"title":"gpio.c <span style='color:#111;'> 1.91KB </span>","children":null,"spread":false},{"title":"SID34_RequestDownload.c <span style='color:#111;'> 1.84KB </span>","children":null,"spread":false},{"title":"SID36_TransferData.c <span style='color:#111;'> 1.71KB </span>","children":null,"spread":false},{"title":"SID37_RequestTransferExit.c <span style='color:#111;'> 1.64KB </span>","children":null,"spread":false},{"title":"UDS_For_STM32MP157_CM4 Debug.cfg <span style='color:#111;'> 706B </span>","children":null,"spread":false},{"title":".cproject <span style='color:#111;'> 26.75KB </span>","children":null,"spread":false},{"title":"UDS诊断刷写流程.drawio <span style='color:#111;'> 70.05KB </span>","children":null,"spread":false},{"title":"stm32mp157d-uds_for_stm32mp157-mx.dts <span style='color:#111;'> 3.89KB </span>","children":null,"spread":false},{"title":"stm32mp157d-uds_for_stm32mp157-mx.dts <span style='color:#111;'> 3.17KB </span>","children":null,"spread":false},{"title":"stm32mp157d-uds_for_stm32mp157-mx.dts <span style='color:#111;'> 3.17KB </span>","children":null,"spread":false},{"title":"stm32mp157d-uds_for_stm32mp157-mx-u-boot.dtsi <span style='color:#111;'> 2.65KB </span>","children":null,"spread":false},{"title":"stm32mp15-mx.dtsi <span style='color:#111;'> 483B </span>","children":null,"spread":false},{"title":"stm32mp15-mx.dtsi <span style='color:#111;'> 483B </span>","children":null,"spread":false},{"title":".gitignore <span style='color:#111;'> 10B </span>","children":null,"spread":false},{"title":"stm32mp157dxx_cm4.h <span style='color:#111;'> 2.50MB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_rcc.h <span style='color:#111;'> 254.11KB </span>","children":null,"spread":false},{"title":"stm32_hal_legacy.h <span style='color:#111;'> 204.56KB </span>","children":null,"spread":false},{"title":"core_cm33.h <span style='color:#111;'> 168.55KB </span>","children":null,"spread":false},{"title":"core_armv8mml.h <span style='color:#111;'> 162.10KB </span>","children":null,"spread":false},{"title":"core_cm7.h <span style='color:#111;'> 142.50KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_fdcan.h <span style='color:#111;'> 129.50KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_tim.h <span style='color:#111;'> 126.04KB </span>","children":null,"spread":false},{"title":"core_cm4.h <span style='color:#111;'> 118.63KB </span>","children":null,"spread":false},{"title":"core_cm3.h <span style='color:#111;'> 107.34KB </span>","children":null,"spread":false},{"title":"core_sc300.h <span style='color:#111;'> 106.06KB </span>","children":null,"spread":false},{"title":"core_cm23.h <span style='color:#111;'> 100.23KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_rcc_ex.h <span style='color:#111;'> 97.79KB </span>","children":null,"spread":false},{"title":"core_armv8mbl.h <span style='color:#111;'> 93.83KB </span>","children":null,"spread":false},{"title":"cmsis_gcc.h <span style='color:#111;'> 58.85KB </span>","children":null,"spread":false},{"title":"cmsis_armclang.h <span style='color:#111;'> 53.35KB </span>","children":null,"spread":false},{"title":"core_cm0plus.h <span style='color:#111;'> 48.22KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_dma.h <span style='color:#111;'> 46.30KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_mdma.h <span style='color:#111;'> 45.77KB </span>","children":null,"spread":false},{"title":"core_sc000.h <span style='color:#111;'> 45.14KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal.h <span style='color:#111;'> 42.11KB </span>","children":null,"spread":false},{"title":"core_cm1.h <span style='color:#111;'> 41.48KB </span>","children":null,"spread":false},{"title":"core_cm0.h <span style='color:#111;'> 40.29KB </span>","children":null,"spread":false},{"title":"cmsis_iccarm.h <span style='color:#111;'> 26.83KB </span>","children":null,"spread":false},{"title":"cmsis_armcc.h <span style='color:#111;'> 26.70KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_tim_ex.h <span style='color:#111;'> 23.56KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_pwr_ex.h <span style='color:#111;'> 19.06KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_exti.h <span style='color:#111;'> 18.19KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_cortex.h <span style='color:#111;'> 17.76KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_pwr.h <span style='color:#111;'> 17.25KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_gpio_ex.h <span style='color:#111;'> 14.32KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_gpio.h <span style='color:#111;'> 13.98KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_conf.h <span style='color:#111;'> 11.21KB </span>","children":null,"spread":false},{"title":"mpu_armv7.h <span style='color:#111;'> 11.17KB </span>","children":null,"spread":false},{"title":"mpu_armv8.h <span style='color:#111;'> 10.38KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_dma_ex.h <span style='color:#111;'> 10.24KB </span>","children":null,"spread":false},{"title":"cmsis_compiler.h <span style='color:#111;'> 8.54KB </span>","children":null,"spread":false},{"title":"uds_service.h <span style='color:#111;'> 6.96KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_def.h <span style='color:#111;'> 6.89KB </span>","children":null,"spread":false},{"title":"stm32mp1xx_hal_hsem.h <span style='color:#111;'> 6.73KB </span>","children":null,"spread":false},{"title":"stm32mp1xx.h <span style='color:#111;'> 6.05KB </span>","children":null,"spread":false},{"title":"uds_tp.h <span style='color:#111;'> 4.19KB </span>","children":null,"spread":false},{"title":"uds_tp_private.h <span style='color:#111;'> 3.11KB </span>","children":null,"spread":false},{"title":"uds_port.h <span style='color:#111;'> 3.04KB </span>","children":null,"spread":false},{"title":"tz_context.h <span style='color:#111;'> 2.62KB </span>","children":null,"spread":false},{"title":"SID10_SessionControl.h <span style='color:#111;'> 2.37KB </span>","children":null,"spread":false},{"title":"system_stm32mp1xx.h <span style='color:#111;'> 2.36KB </span>","children":null,"spread":false},{"title":"......","children":null,"spread":false},{"title":"<span style='color:steelblue;'>文件过多,未全部展示</span>","children":null,"spread":false}],"spread":true}]

评论信息

免责申明

【只为小站】的资源来自网友分享,仅供学习研究,请务必在下载后24小时内给予删除,不得用于其他任何用途,否则后果自负。基于互联网的特殊性,【只为小站】 无法对用户传输的作品、信息、内容的权属或合法性、合规性、真实性、科学性、完整权、有效性等进行实质审查;无论 【只为小站】 经营者是否已进行审查,用户均应自行承担因其传输的作品、信息、内容而可能或已经产生的侵权或权属纠纷等法律责任。
本站所有资源不代表本站的观点或立场,基于网友分享,根据中国法律《信息网络传播权保护条例》第二十二条之规定,若资源存在侵权或相关问题请联系本站客服人员,zhiweidada#qq.com,请把#换成@,本站将给予最大的支持与配合,做到及时反馈和处理。关于更多版权及免责申明参见 版权及免责申明