[go: up one dir, main page]

CN103529821B - A kind of configurableization method and device of the diagnosing protocol stack system based on CAN bus - Google Patents

A kind of configurableization method and device of the diagnosing protocol stack system based on CAN bus Download PDF

Info

Publication number
CN103529821B
CN103529821B CN201310461120.7A CN201310461120A CN103529821B CN 103529821 B CN103529821 B CN 103529821B CN 201310461120 A CN201310461120 A CN 201310461120A CN 103529821 B CN103529821 B CN 103529821B
Authority
CN
China
Prior art keywords
application layer
protocol stack
standard
internet
layer
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201310461120.7A
Other languages
Chinese (zh)
Other versions
CN103529821A (en
Inventor
程安宇
王蓉
申帅
赵恬
黎扬
许灵斐
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Chongqing University of Post and Telecommunications
Original Assignee
Chongqing University of Post and Telecommunications
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Chongqing University of Post and Telecommunications filed Critical Chongqing University of Post and Telecommunications
Priority to CN201310461120.7A priority Critical patent/CN103529821B/en
Publication of CN103529821A publication Critical patent/CN103529821A/en
Application granted granted Critical
Publication of CN103529821B publication Critical patent/CN103529821B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Computer And Data Communications (AREA)
  • Stored Programmes (AREA)
  • Small-Scale Networks (AREA)

Abstract

本发明公开了一种基于CAN总线诊断协议栈的可配置化方法,该诊断协议栈按照国际诊断标准ISO15765和AUTOSAR标准实现,包括封装的网络层和应用层模块、应用层标准接口、ECU抽象层标准接口以及可配置文件。用户在进行诊断需求开发时,应用现有模块通过配置文件设置可配置参数,只需按照标准接口专注于应用层和底层驱动的实现。本发明增强诊断软件的通用性、可靠性、移植性,方便在不同硬件平台上移植,避免网络层、应用层协议栈的重复开发,大大缩短了开发时间,减少开发成本,方便了开发和扩展。

The invention discloses a configurable method based on a CAN bus diagnostic protocol stack. The diagnostic protocol stack is implemented according to the international diagnostic standard ISO15765 and the AUTOSAR standard, and includes encapsulated network layer and application layer modules, application layer standard interfaces, and an ECU abstraction layer. Standard interface and configurable files. When developing diagnostic requirements, users can apply existing modules to set configurable parameters through configuration files, and only need to focus on the implementation of the application layer and underlying drivers according to the standard interface. The invention enhances the versatility, reliability and portability of diagnostic software, facilitates porting on different hardware platforms, avoids repeated development of network layer and application layer protocol stacks, greatly shortens development time, reduces development costs, and facilitates development and expansion .

Description

一种基于CAN总线的诊断协议栈系统的可配置化方法及装置A configurable method and device for a diagnostic protocol stack system based on CAN bus

技术领域technical field

本发明涉及汽车电子工程领域,尤其是一种基于CAN总线诊断协议栈系统的可配置化方法。The invention relates to the field of automotive electronic engineering, in particular to a configurable method for a diagnostic protocol stack system based on a CAN bus.

背景技术Background technique

随着电子技术和计算机技术的飞速发展,汽车上普遍采用了功能强大、性能可靠、成本较低的电子控制系统。对于智能化、网络化、高可靠性的汽车,集成了越来越多的电子控制单元ECU,电子控制系统越来越复杂,导致汽车故障定位和处理变得异常困难,传统的汽车诊断和维修方法已经难以满足故障诊断在实时性和准确性上的要求。With the rapid development of electronic technology and computer technology, electronic control systems with powerful functions, reliable performance and low cost are generally used in automobiles. For intelligent, networked and high-reliability vehicles, more and more electronic control units (ECUs) are integrated, and the electronic control system is becoming more and more complex, which makes it extremely difficult to locate and deal with vehicle faults. Traditional vehicle diagnosis and maintenance This method has been difficult to meet the real-time and accuracy requirements of fault diagnosis.

为了解决上述问题汽车制造商在电子控制单元中增设了故障自诊断系统,通过在汽车的运行过程中不间断的检测电子控制系统各组成部分的工作情况,从而检测出系统故障,并以故障代码(DTC)的形式存储在ECU的存储器中。当车辆出现故障,维修人员通过相应的诊断仪设备连接到车载诊断接口,从汽车ECU中读取ECU的工作状态和故障信息,检测和确定车辆故障。In order to solve the above problems, automobile manufacturers have added a fault self-diagnosis system in the electronic control unit. By continuously detecting the working conditions of the various components of the electronic control system during the operation of the car, system faults are detected, and the fault codes are displayed. (DTC) is stored in the memory of the ECU. When the vehicle breaks down, the maintenance personnel connect to the on-board diagnostic interface through the corresponding diagnostic equipment, read the working status and fault information of the ECU from the car ECU, and detect and determine the vehicle fault.

随着汽车开放系统架构AUTOSAR(AutomotiveOpenSystemsArchitecture)的不断普及应用,越来越多的汽车ECU软件开发都是基于AUTOSAR标准。它是由全球汽车制造商、供应商及其他电子软件公司联合提出的汽车开放系统架构标准,定义了一套分布式的、功能驱动的汽车电子软件开发方法及基于电子控制单元的软件架构标准化方法,以便应用在不同的汽车平台,提高软件复用性,降低开发成本。With the continuous popularization and application of the automotive open system architecture AUTOSAR (Automotive Open Systems Architecture), more and more automotive ECU software development is based on the AUTOSAR standard. It is an automotive open system architecture standard jointly proposed by global automakers, suppliers, and other electronic software companies. It defines a set of distributed, function-driven automotive electronic software development methods and electronic control unit-based software architecture standardization methods. , so that it can be applied to different vehicle platforms, improve software reusability, and reduce development costs.

AUTOSAR标准中故障诊断模块的相应模块定义了一个系统的通信协议栈,并将其划分为驱动层、接口层和服务层,并通过该通信协议栈与外界诊断设备或者上位机诊断软件相连。The corresponding module of the fault diagnosis module in the AUTOSAR standard defines a system communication protocol stack, and divides it into driver layer, interface layer and service layer, and connects with external diagnostic equipment or upper computer diagnostic software through the communication protocol stack.

文献:CAN总线网络层协议栈开发测试(计算机工程,2011年8月第15期)对ISO15765协议进行分析,依据协议在基于MC9S12DP512芯片的整车控制器上完成了CAN网络层协议栈的开发。并在VC环境下开发测试程序,对协议栈进行了测试。该协议栈开发针对具体的一款芯片定制,可移植性、通用性不强,其软件测试没有经过标准的测试工具测试,其系统缺乏可靠性。Document: CAN bus network layer protocol stack development test (Computer Engineering, August 2011 No. 15) analyzed the ISO15765 protocol, and completed the development of the CAN network layer protocol stack on the vehicle controller based on the MC9S12DP512 chip according to the protocol. And develop the test program in VC environment, and test the protocol stack. The development of the protocol stack is customized for a specific chip, and its portability and versatility are not strong. Its software testing has not been tested by standard testing tools, and its system lacks reliability.

公开号为CN102200913A,名称为“一种基于模型的自动变速箱软件开发平台的分层设计方法”的发明专利,所述软件开发平台的分层分为三层:模型应用层、硬件抽象层和底层驱动层,其中所述硬件抽象层用于模型应用层和底层驱动层的对接,自动变速箱控制策略由模型开发工具进行建模,仿真和测试,并自动生成C代码并转化为应用层软件模块,形成模型应用层;模型应用层通过硬件抽象层进行数据交换,通过对接的函数实现底层平台数据的访问和对应操作;底层驱动层包括CAN驱动、A/D转换、数字量输入和输出,以及平台自身功能和状态监测,底层驱动层通过硬件抽象层的函数调用,执行相应操作,实时处理和更新数据。但该方法仍然存在车载网络诊断技术中通用性不强、可移植性差的问题。The publication number is CN102200913A, and the invention patent titled "A Model-Based Layered Design Method for Automatic Transmission Software Development Platform", the layering of the software development platform is divided into three layers: model application layer, hardware abstraction layer and The underlying driver layer, wherein the hardware abstraction layer is used for the connection between the model application layer and the underlying driver layer, the automatic transmission control strategy is modeled, simulated and tested by the model development tool, and C code is automatically generated and converted into application layer software The module forms the model application layer; the model application layer exchanges data through the hardware abstraction layer, and realizes the access and corresponding operation of the underlying platform data through the docking function; the underlying driver layer includes CAN driver, A/D conversion, digital input and output, As well as the platform's own function and status monitoring, the underlying driver layer performs corresponding operations through function calls in the hardware abstraction layer, and processes and updates data in real time. However, this method still has the problems of poor versatility and poor portability in vehicle network diagnosis technology.

发明内容Contents of the invention

本发明的目的是要解决现有车载网络诊断技术中通用性不强、可移植性差的现状,提出一种基于CAN总线诊断协议栈的可配置化方法,增强现有诊断软件的通用性、可靠性和复用性,使得汽车厂商在诊断软件的开发过程中,可以专注于应用层需求的开发,适用于多种不同的应用平台。本发明采用以下技术方案实现:一种基于CAN网络诊断协议栈的可配置化方法。The purpose of the present invention is to solve the current situation of poor versatility and poor portability in the existing vehicle network diagnosis technology, and propose a configurable method based on the CAN bus diagnostic protocol stack to enhance the versatility and reliability of the existing diagnostic software Reusability and reusability enable automobile manufacturers to focus on the development of application layer requirements in the development process of diagnostic software, which is suitable for many different application platforms. The present invention is realized by adopting the following technical solutions: a configurable method based on CAN network diagnosis protocol stack.

诊断协议栈软件架构遵循AUTOSAR标准规定的CAN总线故障诊断模块。诊断协议栈网络层、应用层源码按照国际诊断标准ISO15765、ISO14229实现;ISO15765、ISO14229中定义了诊断协议栈网络层和应用层的内容,与OSI模型相对应:ISO15765-2定义了诊断协议栈网络层的内容,与OSI模型的网络层、传输层相对应;ISO15765-3和ISO14229-1定义了诊断协议栈应用层的内容,与OSI模型的应用层相对应。The diagnostic protocol stack software architecture follows the CAN bus fault diagnosis module stipulated in the AUTOSAR standard. Diagnosis protocol stack network layer and application layer source code are implemented according to international diagnostic standards ISO15765 and ISO14229; ISO15765 and ISO14229 define the content of diagnostic protocol stack network layer and application layer, corresponding to OSI model: ISO15765-2 defines diagnostic protocol stack network The content of the layer corresponds to the network layer and the transport layer of the OSI model; ISO15765-3 and ISO14229-1 define the content of the application layer of the diagnostic protocol stack, which corresponds to the application layer of the OSI model.

诊断协议栈单元对网络层、应用层源码进行封装,将网络层、应用层的数据结构和函数原型放在头文件中,同时对函数的源文件进行编译,得到函数定义的.lib文件格式的目标代码;诊断协议栈单元定义符合AUTOSAR标准的应用层和ECU抽象层接口;可配置化单元提取出诊断协议栈中用户可自行配置的参数,在可配置文件中对网络层可配置参数进行设置,更新网络层配置文件;在诊断协议栈可配置文件中选择要支持的诊断服务,按照诊断协议栈应用层标准接口实现诊断服务功能;按照诊断协议栈ECU抽象层标准接口完成CAN模块的驱动,CAN报文的接收、发送。The diagnostic protocol stack unit encapsulates the source code of the network layer and application layer, puts the data structure and function prototype of the network layer and application layer in the header file, and compiles the source file of the function at the same time to obtain the .lib file format of the function definition Object code; the diagnostic protocol stack unit defines the application layer and ECU abstract layer interface that conform to the AUTOSAR standard; the configurable unit extracts the parameters that users can configure in the diagnostic protocol stack, and sets the configurable parameters of the network layer in the configurable file , update the network layer configuration file; select the diagnostic service to be supported in the configurable file of the diagnostic protocol stack, and realize the diagnostic service function according to the standard interface of the application layer of the diagnostic protocol stack; complete the driving of the CAN module according to the standard interface of the ECU abstraction layer of the diagnostic protocol stack, Receiving and sending of CAN messages.

所述对网络层、应用层源码进行封装具体包括:采用.lib格式封装网络层模块、应用层模块,按照应用层标准接口采用.c格式实现应用层服务功能源码,按照应用层标准接口采用.c格式实现ECU底层驱动程序,用户生成.c格式的配置文件,并加入网络层库文件。The encapsulation of the source code of the network layer and the application layer specifically includes: encapsulating the network layer module and the application layer module in the .lib format, implementing the application layer service function source code in the .c format according to the application layer standard interface, and adopting the .c format according to the application layer standard interface. The c format implements the ECU underlying driver program, and the user generates a configuration file in the .c format and adds the network layer library file.

诊断协议栈的可配置化单元提取出诊断协议栈中用户可自行配置的参数,在可配置文件中用.xml形式定义其格式,比如:网络层时间参数、应用层时间参数、应用层具体服务等,用户可根据具体项目需求在配置文件中设置参数值。配置完成的诊断协议栈包括模块化封装的协议栈网络层、应用层源码(.lib文件),根据用户需求生成的参数配置文件(.c文件),根据用户需求完成的芯片驱动程序(.c文件),根据用户需求完成的应用层服务程序(.c文件)。The configurable unit of the diagnostic protocol stack extracts the parameters that can be configured by the user in the diagnostic protocol stack, and defines its format in the form of .xml in the configurable file, such as: network layer time parameters, application layer time parameters, application layer specific services etc. Users can set parameter values in the configuration file according to specific project requirements. The configured diagnostic protocol stack includes a modular packaged protocol stack network layer, application layer source code (.lib file), a parameter configuration file (.c file) generated according to user requirements, and a chip driver (.c file), the application layer service program (.c file) completed according to user requirements.

本发明还提出一种基于CAN总线诊断协议栈的可配置化装置,该装置包括:诊断协议栈单元对网络层、应用层源码进行封装,将网络层、应用层的数据结构和函数原型放在头文件中,同时对函数的源文件进行编译,得到函数定义的.lib文件格式的目标代码;诊断协议栈单元定义符合AUTOSAR标准的应用层和ECU抽象层接口;可配置化单元提取出诊断协议栈中用户可自行配置的参数,在可配置文件中对网络层可配置参数进行设置,更新网络层配置文件;在诊断协议栈可配置文件中选择要支持的诊断服务,按照诊断协议栈应用层标准接口实现诊断服务功能;按照诊断协议栈ECU抽象层标准接口完成CAN模块的驱动,CAN报文的接收、发送。The present invention also proposes a configurable device based on the CAN bus diagnostic protocol stack, which includes: the diagnostic protocol stack unit encapsulates the source code of the network layer and the application layer, and puts the data structure and function prototype of the network layer and the application layer in In the header file, the source file of the function is compiled at the same time to obtain the target code of the .lib file format defined by the function; the diagnostic protocol stack unit defines the application layer and the ECU abstract layer interface that conform to the AUTOSAR standard; the configurable unit extracts the diagnostic protocol The parameters in the stack that users can configure by themselves, set the configurable parameters of the network layer in the configurable file, and update the network layer configuration file; select the diagnostic service to be supported in the configurable file of the diagnostic protocol stack, and follow the diagnostic protocol stack application layer The standard interface realizes the diagnosis service function; according to the standard interface of the ECU abstraction layer of the diagnosis protocol stack, the CAN module is driven, and the CAN message is received and sent.

本发明解决了当前诊断软件复用性不强的问题,用户可使用已封装模块,并按照其标准接口专注于应用层需求的开发,避免了网络层、应用层协议栈的重复开发,大大缩短了开发时间,减少开发成本;本发明解决了诊断软件在不同硬件平台上的移植问题,支持硬件平台与软件代码的无缝连接。本发明整体架构按照AUTOSAR标准设计实现,提高了软件的可靠性;本发明将国际诊断标准中用户可自行配置的参数提取出来,用户在进行诊断项目开发时,可根据自身需求修改配置参数,从而提高了软件的通用性,方便用户的开发和扩展。The invention solves the problem of weak reusability of the current diagnostic software. Users can use the packaged modules and focus on the development of application layer requirements according to their standard interfaces, avoiding repeated development of network layer and application layer protocol stacks, and greatly reducing The development time is reduced, and the development cost is reduced; the invention solves the problem of transplanting diagnostic software on different hardware platforms, and supports the seamless connection between hardware platforms and software codes. The overall structure of the present invention is designed and implemented according to the AUTOSAR standard, which improves the reliability of the software; the present invention extracts the parameters that users can configure by themselves in the international diagnostic standard, and the user can modify the configuration parameters according to their own needs when developing diagnostic projects, so that The versatility of the software is improved, which is convenient for users to develop and expand.

附图说明Description of drawings

图1是诊断协议栈整体结构示意图;Fig. 1 is a schematic diagram of the overall structure of the diagnostic protocol stack;

图2是诊断协议栈工作过程示意图;Fig. 2 is a schematic diagram of the working process of the diagnosis protocol stack;

图3是ISO诊断协议在OSI模型中的映射关系。Figure 3 is the mapping relationship of the ISO diagnostic protocol in the OSI model.

具体实施方式detailed description

下面结合附图和实例对本发明做进一步说明,所述实施例是本发明的一部分实施例,而不是全部实施例,所以所述实施例不应理解为对本发明的限制。The present invention will be further described below in conjunction with the accompanying drawings and examples. The embodiments are part of the embodiments of the present invention, not all embodiments, so the embodiments should not be construed as limiting the present invention.

本发明提出一种基于CAN总线诊断协议栈的可配置化方法,按照国际诊断标准ISO15765和AUTOSAR标准接口实现诊断系统网络层、应用层功能,可经过配置生成诊断软件,完成外部诊断设备与车载ECU间的通信。The present invention proposes a configurable method based on the CAN bus diagnostic protocol stack, realizes the network layer and application layer functions of the diagnostic system according to the international diagnostic standard ISO15765 and the AUTOSAR standard interface, and can generate diagnostic software through configuration to complete external diagnostic equipment and vehicle-mounted ECU communication between.

如图1所示本诊断协议栈实现ISO15765所描述的网络层功能,封装成库,并提取网络层可配置参数(如:网络层时间参数、网络层控制参数等),在配置文件中定义。诊断协议栈根据AUTOSAR定义向应用层程序和ECU抽象层提供标准接口。汽车不同ECU所具备的诊断功能各不相同,根据需求选择车载ECU芯片及所支持的诊断服务。作为本发明的一个选择性实施案例,选择飞思卡尔MC9S12DG128芯片作为车载ECU,选择0x10(诊断会话控制)、0x27(安全访问)、0x3E(诊断设备在线)、0x2E(写入数据)为所支持的诊断服务。As shown in Figure 1, this diagnostic protocol stack implements the network layer functions described in ISO15765, encapsulates them into a library, and extracts configurable parameters of the network layer (such as: network layer time parameters, network layer control parameters, etc.), and defines them in the configuration file. The diagnostic protocol stack provides a standard interface to the application layer program and the ECU abstraction layer according to the AUTOSAR definition. The diagnostic functions of different ECUs in automobiles are different, and the on-board ECU chip and the supported diagnostic services should be selected according to the needs. As an optional implementation case of the present invention, Freescale MC9S12DG128 chip is selected as the vehicle-mounted ECU, and 0x10 (diagnostic session control), 0x27 (safe access), 0x3E (diagnostic equipment online), 0x2E (write data) are selected as supported diagnostic services.

如图2所示诊断协议栈工作示意图。诊断协议栈单元对网络层、应用层源码进行封装,将网络层、应用层的数据结构和函数原型放在头文件中,同时对函数的源文件进行编译,得到函数定义的.lib文件格式的目标代码;诊断协议栈单元定义符合AUTOSAR标准的应用层和ECU抽象层接口;可配置化单元提取出诊断协议栈中用户可自行配置的参数,在可配置文件中对网络层可配置参数进行设置,更新网络层配置文件;在诊断协议栈可配置文件中选择要支持的诊断服务,按照诊断协议栈应用层标准接口实现诊断服务功能;按照诊断协议栈ECU抽象层标准接口完成CAN模块的驱动,CAN报文的接收、发送。Figure 2 shows the working diagram of the diagnostic protocol stack. The diagnostic protocol stack unit encapsulates the source code of the network layer and application layer, puts the data structure and function prototype of the network layer and application layer in the header file, and compiles the source file of the function at the same time to obtain the .lib file format of the function definition Object code; the diagnostic protocol stack unit defines the application layer and ECU abstract layer interface that conform to the AUTOSAR standard; the configurable unit extracts the parameters that users can configure in the diagnostic protocol stack, and sets the configurable parameters of the network layer in the configurable file , update the network layer configuration file; select the diagnostic service to be supported in the configurable file of the diagnostic protocol stack, and realize the diagnostic service function according to the standard interface of the application layer of the diagnostic protocol stack; complete the driving of the CAN module according to the standard interface of the ECU abstraction layer of the diagnostic protocol stack, Receiving and sending of CAN messages.

诊断协议栈包括:The diagnostic stack includes:

A.封装模块采用.lib格式封装网络层、应用层模块;A. The package module uses the .lib format to package the network layer and application layer modules;

B.标准定义模块根据AUTOSAR标准定义应用层接口,通过应用层接口接入应用服务程序;根据AUTOSAR标准定义ECU抽象层接口,通过ECU抽象层接口接入ECU底层驱动程序;B. The standard definition module defines the application layer interface according to the AUTOSAR standard, and accesses the application service program through the application layer interface; defines the ECU abstract layer interface according to the AUTOSAR standard, and accesses the ECU underlying driver through the ECU abstract layer interface;

c..c格式配置文件模块定义了ECU抽象层配置参数、网络层配置参数和应用层配置参数。The c..c format configuration file module defines ECU abstraction layer configuration parameters, network layer configuration parameters and application layer configuration parameters.

根据当前需求开发诊断协议栈,首先创建工程加入采用.lib格式封装网络层、应用层模块,其次根据当前需求在配置文件中对可配置参数进行配置:Develop the diagnostic protocol stack according to the current needs. First, create a project and add the network layer and application layer modules in .lib format. Then configure the configurable parameters in the configuration file according to the current needs:

1.设置网络层可配置参数,更新网络层配置文件;1. Set the configurable parameters of the network layer and update the configuration file of the network layer;

2.设置应用层可配置参数,在可配置文件中设置要支持的诊断服务0x10、0x27、0x3E、0x2E,并通过应用层标准接口接入应用服务程序;2. Set the configurable parameters of the application layer, set the diagnostic services to be supported in the configurable file 0x10, 0x27, 0x3E, 0x2E, and access the application service program through the standard interface of the application layer;

3.设置ECU抽象层可配置参数,并通过ECU抽象层标准接口接入MC9S12DG128芯片的驱动程序,包括CAN模块的驱动程序,CAN报文的接收、发送模块。3. Set the configurable parameters of the ECU abstraction layer, and access the driver program of the MC9S12DG128 chip through the standard interface of the ECU abstraction layer, including the driver program of the CAN module, and the module for receiving and sending CAN messages.

最后将配置生成的诊断协议栈经编译后下载到车载ECU(MC9S12DG128芯片)中,运行协议栈程序。Finally, the diagnostic protocol stack generated by the configuration is compiled and downloaded to the vehicle ECU (MC9S12DG128 chip), and the protocol stack program is run.

诊断协议栈采用分层模块化方式实现,如图3所示。采用.lib格式封装网络层、应用层模块按照国际诊断标准ISO15765和ISO14229实现,其中应用层模块由ISO15765-3和ISO14229定义,其中网络层模块由ISO15765-2定义,ECU抽象层由ISO11898定义。各模块间接口由AUTOSAR标准定义。The diagnostic protocol stack is implemented in a layered and modular manner, as shown in Figure 3. The network layer and application layer modules are encapsulated in .lib format and implemented in accordance with the international diagnostic standards ISO15765 and ISO14229. The application layer modules are defined by ISO15765-3 and ISO14229, the network layer modules are defined by ISO15765-2, and the ECU abstraction layer is defined by ISO11898. The interface between each module is defined by the AUTOSAR standard.

通过以上实施例可以看出,用户在进行车辆故障诊断软件开发时可以有效利用本方法,只需根据需求在可配置文件中对可配置参数进行设置,按照标准接口完成底层驱动和应用层具体服务功能,而不用考虑诊断软件网络层和应用层的设计与实现,便能够高效、准确的实现整个车辆故障诊断。It can be seen from the above embodiments that the user can effectively use this method when developing vehicle fault diagnosis software, only need to set the configurable parameters in the configurable file according to the requirements, and complete the underlying driver and application layer specific services according to the standard interface function, without considering the design and implementation of the diagnostic software network layer and application layer, it can efficiently and accurately realize the entire vehicle fault diagnosis.

通过上述具体实例对本发明进行了说明,但是本发明并不局限于上述实例,上述方法可应用于飞思卡尔MC9S12XEQ512平台和瑞萨R5F10DPJ平台。对本领域的相关人员,在进行车辆故障诊断软件的开发过程中可以依据本发明的技术方案和思想,完成不同需求的开发,而所有这些都应该属于本发明权利要求的保护范围之内。The present invention is illustrated through the above specific examples, but the present invention is not limited to the above examples, and the above method can be applied to Freescale MC9S12XEQ512 platform and Renesas R5F10DPJ platform. For those skilled in the art, during the development of vehicle fault diagnosis software, they can complete the development of different requirements according to the technical scheme and thought of the present invention, and all of these should fall within the protection scope of the claims of the present invention.

Claims (8)

1. the configurableization method based on CAN bus diagnostic protocol stack, diagnosing protocol stack cell is fixedJustice meets application layer and the ECU abstraction layer interface of AUTOSAR standard; At the configurable literary composition of diagnosing protocol stack cellIn part, select the diagnosis service that will support, realize diagnosis service function according to application layer standard interface; According to ECULevel of abstraction standard interface completes the driving of CAN module, the reception of CAN message, transmission; It is characterized in that: examineDisconnected protocol stack unit encapsulates Internet, application layer source code, by the data structure of Internet, application layerBe placed in header file with function prototype, the source file of function compiled simultaneously, obtain the .lib of function definitionThe object code of file format; Configurableization unit extracts the ginseng that in diagnosing protocol stack, user can configure voluntarilyNumber arranges Internet configurable parameter in configurable file, upgrades Internet configuration file.
2. method according to claim 1, is characterized in that: described to Internet, application layer sourceCode encapsulates specifically and comprises: adopt .lib form encapsulation network layer module, application layer module, according to applicationLayer standard interface adopts .c form to realize application layer services function source code, adopts .c according to application layer standard interfaceForm is realized ECU bsp driver, and user generates the configuration file of .c form, and adds Internet library textPart.
3. method according to claim 1, is characterized in that: the parameter bag that user can configure voluntarilyDraw together: Internet time parameter, application layer time parameter, application layer specific service.
4. method according to claim 2, is characterized in that: described application layer module, application layerStandard interface meets AUTOSAR standard.
5. the configurable gasifying device based on CAN bus diagnostic protocol stack, diagnosing protocol stack cell is fixedJustice meets application layer and the ECU abstraction layer interface of AUTOSAR standard; In the configurable file of diagnosing protocol stackThe diagnosis service that selection will be supported, realizes diagnosis service function according to application layer standard interface; Take out according to ECUResemble the driving that layer standard interface completes CAN module, the reception of CAN message, transmission; It is characterized in that: diagnosisProtocol stack unit encapsulates Internet, application layer source code, by the data structure of Internet, application layer andFunction prototype is placed in header file, the source file of function is compiled simultaneously, obtains the .lib of function definitionThe object code of file format; Configurableization unit extracts the ginseng that in diagnosing protocol stack, user can configure voluntarilyNumber arranges Internet configurable parameter in configurable file, upgrades Internet configuration file.
6. device according to claim 5, is characterized in that: described to Internet, application layer sourceCode encapsulates specifically and comprises: adopt .lib form encapsulation network layer module, application layer module, according to applicationLayer standard interface adopts .c form to realize application layer services function source code, adopts .c according to application layer standard interfaceForm is realized ECU bsp driver, and user generates the configuration file of .c form, and adds Internet library textPart.
7. device according to claim 5, is characterized in that: the parameter bag that user can configure voluntarilyDraw together: Internet time parameter, application layer time parameter, application layer specific service.
8. device according to claim 5, is characterized in that: described application layer module, application layerStandard interface meets AUTOSAR standard.
CN201310461120.7A 2013-09-29 2013-09-29 A kind of configurableization method and device of the diagnosing protocol stack system based on CAN bus Active CN103529821B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201310461120.7A CN103529821B (en) 2013-09-29 2013-09-29 A kind of configurableization method and device of the diagnosing protocol stack system based on CAN bus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310461120.7A CN103529821B (en) 2013-09-29 2013-09-29 A kind of configurableization method and device of the diagnosing protocol stack system based on CAN bus

Publications (2)

Publication Number Publication Date
CN103529821A CN103529821A (en) 2014-01-22
CN103529821B true CN103529821B (en) 2016-05-11

Family

ID=49931908

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310461120.7A Active CN103529821B (en) 2013-09-29 2013-09-29 A kind of configurableization method and device of the diagnosing protocol stack system based on CAN bus

Country Status (1)

Country Link
CN (1) CN103529821B (en)

Families Citing this family (18)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105172616B (en) * 2015-04-20 2017-11-24 南京金龙新能源汽车研究院有限公司 A kind of electric automobile Intelligent whole-vehicle controller
CN105137943B (en) * 2015-09-06 2018-06-26 同济大学 A kind of micro-hybrid system integration control device
CN105515930A (en) * 2015-12-15 2016-04-20 上海博泰悦臻网络技术服务有限公司 Vehicle bus message processing method and equipment, and vehicle
CN107438048B (en) * 2016-05-25 2020-06-02 宝沃汽车(中国)有限公司 Distribution strategy generation method and device of vehicle-mounted controller signal and vehicle
CN106094624B (en) * 2016-06-24 2018-10-26 苏州工业职业技术学院 Hybrid vehicle electron program station system based on embedded type C AN buses
CN106230605B (en) * 2016-07-29 2019-07-02 浙江吉利控股集团有限公司 A kind of management system based on AUTOSAR In-vehicle networking
CN106375298A (en) * 2016-08-30 2017-02-01 湖南中车时代通信信号有限公司 A Realization Method of Configurable Security Communication Protocol
CN106503376B (en) * 2016-10-27 2019-10-01 安徽江淮汽车集团股份有限公司 A kind of automotive networking framework modeling and simulating method and system
CN107102920B (en) * 2017-03-14 2021-10-26 延锋伟世通电子科技(南京)有限公司 Online debugging system and method for ONCAN instrument
CN107329762B (en) * 2017-06-30 2020-09-08 浙江孚宝智能科技有限公司 Method and system for describing and integrating software service
CN109976834B (en) * 2019-03-29 2022-01-28 上海仁童电子科技有限公司 Protocol stack parameter configuration method and device
CN111722870B (en) * 2020-06-10 2023-05-02 中国第一汽车股份有限公司 Driving configuration method, device and equipment of electronic control unit and storage medium
CN111740972B (en) * 2020-06-15 2022-06-21 中国第一汽车股份有限公司 Method, device, equipment and storage medium for updating communication protocol stack information
CN111752830B (en) * 2020-06-22 2022-08-16 中国第一汽车股份有限公司 Automobile diagnosis system, and updating method, device and equipment of automobile diagnosis system
CN111831265B (en) * 2020-07-27 2024-02-02 吉林大学 AUTOSAR-based electric vehicle sensor signal processing assembly interface design method
CN112230630A (en) * 2020-12-09 2021-01-15 奥特酷智能科技(南京)有限公司 Method for realizing diagnosis in automatic driving based on DDS protocol
CN114285840B (en) * 2021-12-23 2024-08-06 浙江吉利控股集团有限公司 Vehicle data acquisition method, intelligent terminal and storage medium
CN116521143B (en) * 2023-07-04 2023-09-29 上海鉴智其迹科技有限公司 DID read-write service processing method and device for fault diagnosis

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1556641A (en) * 2004-01-01 2004-12-22 浙江大学 Component-based Realization Method of Communication Protocol
CN102200913A (en) * 2011-06-20 2011-09-28 奇瑞汽车股份有限公司 Layered design method of model-based automatic transmission software development platform
CN102523229A (en) * 2011-12-23 2012-06-27 大唐移动通信设备有限公司 Information access method and device
CN102611695A (en) * 2012-01-18 2012-07-25 武汉光庭科技有限公司 Method for designing general-type SAE J1939 protocol stack

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1556641A (en) * 2004-01-01 2004-12-22 浙江大学 Component-based Realization Method of Communication Protocol
CN102200913A (en) * 2011-06-20 2011-09-28 奇瑞汽车股份有限公司 Layered design method of model-based automatic transmission software development platform
CN102523229A (en) * 2011-12-23 2012-06-27 大唐移动通信设备有限公司 Information access method and device
CN102611695A (en) * 2012-01-18 2012-07-25 武汉光庭科技有限公司 Method for designing general-type SAE J1939 protocol stack

Also Published As

Publication number Publication date
CN103529821A (en) 2014-01-22

Similar Documents

Publication Publication Date Title
CN103529821B (en) A kind of configurableization method and device of the diagnosing protocol stack system based on CAN bus
CN104865948B (en) A kind of automobile controller automatic diagnostic device and method
CN114265386B (en) SOA-based application service diagnosis architecture and method
CN105137943B (en) A kind of micro-hybrid system integration control device
CN109740222B (en) Testing device and system for automobile networking scene
CN108255152B (en) vehicle diagnosis method, diagnosis box and computer readable storage medium
CN106325231A (en) Method and system for remote fault detection of vehicles on production line
CN103279118B (en) The real-time mark system of a kind of integral new-energy passenger multiple units cooperative control device
CN102346477A (en) Analysis method and equipment for fault diagnosis communication protocol on basis of automotive open system architecture (AUTOSAR)
CN111443688B (en) Network layer testing system and method of vehicle diagnostic service based on CAN bus
CN107608814A (en) A kind of method of data sharing, the device and mobile terminal of data sharing
CN114089713A (en) Communication method based on UDS, ECU and upper computer
CN104298129A (en) Test simulator of automotive electronic controller
CN103439961A (en) Automobile electronic control unit diagnostic function test method and system
CN113625694B (en) Chassis line control device and chassis line control test system
CN111624981B (en) Steering wheel angle calibration system and calibration method of automobile power-assisted steering system
CN113905461A (en) Wireless communication module of integrated gateway
CN117749624A (en) Configurable method for vehicle data acquisition
CN103257648B (en) Automobile calibration system
CN105530288B (en) Data interaction method
Park et al. An OSGi based in-vehicle gateway platform architecture for improved sensor extensibility and interoperability
CN116974261A (en) Early evaluation system of automobile electronic and electric architecture based on virtualization technology
CN111221317A (en) Automobile diagnosis data processing method and system
CN103731330A (en) Calibration data communication device and communication method
US20230047570A1 (en) A Method, a Device and a Computer Program for Operating a Modular Test Bench Comprising at Least One Test Bench Circuit to Test a Test Object

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant