WO2019174504A1 - Method and device for establishing a logical channel, and vehicle communication interface (vci) - Google Patents

Method and device for establishing a logical channel, and vehicle communication interface (vci) Download PDF

Info

Publication number
WO2019174504A1
WO2019174504A1 PCT/CN2019/077125 CN2019077125W WO2019174504A1 WO 2019174504 A1 WO2019174504 A1 WO 2019174504A1 CN 2019077125 W CN2019077125 W CN 2019077125W WO 2019174504 A1 WO2019174504 A1 WO 2019174504A1
Authority
WO
WIPO (PCT)
Prior art keywords
instructions
establishing
instruction
vehicle
data
Prior art date
Application number
PCT/CN2019/077125
Other languages
French (fr)
Chinese (zh)
Inventor
赖辉强
瞿松松
Original Assignee
深圳市道通科技股份有限公司
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 深圳市道通科技股份有限公司 filed Critical 深圳市道通科技股份有限公司
Publication of WO2019174504A1 publication Critical patent/WO2019174504A1/en

Links

Images

Classifications

    • GPHYSICS
    • G07CHECKING-DEVICES
    • G07CTIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
    • G07C5/00Registering or indicating the working of vehicles
    • G07C5/008Registering or indicating the working of vehicles communicating information to a remotely located station
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B23/00Testing or monitoring of control systems or parts thereof
    • G05B23/02Electric testing or monitoring
    • G05B23/0205Electric testing or monitoring by means of a monitoring system capable of detecting and responding to faults
    • G05B23/0208Electric testing or monitoring by means of a monitoring system capable of detecting and responding to faults characterized by the configuration of the monitoring system
    • G05B23/0213Modular or universal configuration of the monitoring system, e.g. monitoring system having modules that may be combined to build monitoring program; monitoring system that can be applied to legacy systems; adaptable monitoring system; using different communication protocols
    • GPHYSICS
    • G07CHECKING-DEVICES
    • G07CTIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
    • G07C5/00Registering or indicating the working of vehicles
    • G07C5/08Registering or indicating performance data other than driving, working, idle, or waiting time, with or without registering driving, working, idle or waiting time
    • G07C5/0808Diagnosing performance data

Definitions

  • the present application relates to the field of automobile diagnostic technology, and in particular, to a method and device for establishing a logical channel and a vehicle communication interface VCI.
  • the automotive diagnostic system for detecting vehicle faults and performance is more and more widely used. It mainly connects the diagnostic software in the automotive network and the vehicle diagnostic equipment through the vehicle communication interface VCI, and uses the diagnostic software to the automotive computer in the automotive network (Electronic Control Unit). , ECU) for diagnosis.
  • ECU Electronic Control Unit
  • the dependence of automobiles on ECUs is increasing. There are more than a dozen ECUs in one car, and dozens of ECUs in many.
  • the inventors have found that at least the following problems exist in the related art: at present, the automobile diagnostic equipment can only access one ECU at a time, and the diagnostic efficiency is low.
  • an embodiment of the present invention provides a method for establishing a logical channel, which is applied to a vehicle communication interface VCI, and the method includes:
  • the establishing at least two logical channels according to the at least two first instructions including:
  • the establishing channel elements on each software layer of the VCI according to the at least two first instructions including:
  • the method further includes:
  • a main thread is established on the operating system layer, and the main thread is used to manage the at least two threads.
  • the establishing channel elements on each software layer of the VCI according to the at least two first instructions including:
  • the establishing channel elements on each software layer of the VCI according to the at least two first instructions including:
  • the establishing at least one bus driving object in the hardware driver layer according to the bus type and/or the pin information in the at least two first instructions includes:
  • the bus types of the first instructions in the at least two first instructions are different, or the pin information of each first instruction is different, at least two bus driving objects are established in the hardware driver layer.
  • the first instruction is in one-to-one correspondence with the bus drive object.
  • the receiving, by the at least two first instructions sent by the vehicle diagnostic device includes:
  • the at least two first instructions sent by the vehicle diagnostic device are simultaneously received by the asynchronous communication layer.
  • the method further includes:
  • the method further includes:
  • the data is transmitted to the vehicle diagnostic device via at least 2 logical channels; wherein the ECU is in one-to-one correspondence with the logical channel.
  • an embodiment of the present invention provides a device for establishing a logical channel, which is applied to a vehicle communication interface VCI, and the device includes:
  • a first instruction receiving module configured to receive at least two first instructions sent by the vehicle diagnostic device, the first instruction being used to instruct the vehicle diagnostic device to establish a connection with an electronic control unit ECU of the vehicle;
  • a logic channel establishing module configured to establish at least two logical channels according to the at least two first instructions, where the first instruction is in one-to-one correspondence with the logical channel, and the logical channel is used to transmit the vehicle diagnosis Data between the device and the ECU.
  • the logical channel establishing module is specifically configured to:
  • the logical channel establishing module includes:
  • the first logical channel establishing submodule is configured to establish at least two threads on the real-time operating system layer according to the at least two first instructions, where the first instruction corresponds to the thread one-to-one.
  • the device further includes:
  • a main thread establishing module configured to establish a main thread on the real-time operating system layer, where the main thread is used to manage the at least two threads.
  • the logical channel establishing module includes:
  • a second logical channel establishing submodule configured to establish at least two protocol objects in the protocol stack layer according to respective protocol types in the at least two first instructions, where the first instruction corresponds to the protocol object one-to-one.
  • the logical channel establishing module includes:
  • the third logical channel establishing submodule is configured to establish at least one bus driving object in the hardware driver layer according to the respective bus type and/or pin information in the at least two first instructions.
  • the third logical channel establishing submodule is specifically configured to:
  • the bus types of the first instructions in the at least two first instructions are different, or the pin information of each first instruction is different, at least two bus driving objects are established in the hardware driver layer.
  • the first instruction is in one-to-one correspondence with the bus drive object.
  • the first instruction receiving module is specifically configured to:
  • the at least two first instructions sent by the vehicle diagnostic device are simultaneously received by the asynchronous communication layer.
  • the device further includes:
  • a second instruction receiving module configured to receive at least two second instructions sent by the vehicle diagnostic device, where the second instruction includes data and a channel identifier;
  • a logic channel determining module configured to determine at least two logical channels according to respective channel identifiers of the at least two second instructions, where the second instruction corresponds to the logical channel one-to-one;
  • a first data sending module configured to send, by using the at least two logical channels, data in the at least two second instructions to an ECU corresponding to each of the at least two logical channels.
  • the device further includes:
  • a data receiving module configured to receive data sent by each of at least two ECUs
  • a second data sending module configured to send the data to the vehicle diagnostic device through at least two logical channels; wherein the ECU is in one-to-one correspondence with the logical channel.
  • an embodiment of the present invention provides a vehicle communication interface VCI, including:
  • At least one processor and,
  • the memory stores instructions executable by the at least one processor
  • the at least one processor is configured to invoke the instructions to perform the method described above.
  • an embodiment of the present invention provides a non-transitory computer readable storage medium storing computer-executable instructions when the computer-executable instructions are used by a vehicle
  • the vehicle communication interface VCI is caused to perform the above method.
  • an embodiment of the present invention provides a computer program product, the computer program product comprising a computer program stored on a non-transitory computer readable storage medium, the computer program comprising program instructions, when the program When the command is invoked by the vehicle communication interface VCI, the vehicle communication interface VCI is caused to perform the method described above.
  • Embodiments of the present invention form a plurality of channels for accessing individual ECUs by establishing at least two logical channels for transmitting data between the vehicle diagnostic device and the ECU in accordance with at least two first instructions. Through the at least two logical channels, the vehicle diagnostic device can simultaneously access at least two ECUs, improving diagnostic efficiency.
  • FIG. 1 is a schematic diagram of an application scenario of a method and an apparatus for establishing a logical channel according to an embodiment of the present invention
  • FIG. 2 is a schematic diagram of a software basic architecture corresponding to a method for establishing a logical channel according to an embodiment of the present invention
  • FIG. 3 is a schematic flow chart of an embodiment of a method for establishing a logical channel according to the present invention
  • FIG. 4 is a schematic diagram of a logical channel for forming a plurality of access ECUs between a vehicle diagnostic device and a vehicle control network in an embodiment of a method for establishing a logical channel according to the present invention
  • FIG. 5 is a schematic flowchart of a method for establishing a diagnostic command by a vehicle diagnostic device to a vehicle network through a vehicle communication interface VCI according to a method for establishing a logical channel according to an embodiment of the present invention
  • FIG. 6 is a schematic flow chart of receiving, by the vehicle diagnostic device, the feedback data sent by the vehicle network through the traffic tool communication interface VCI in the logic channel establishing method according to the embodiment of the present invention
  • FIG. 7 is a schematic structural diagram of an embodiment of a logical channel establishing apparatus of the present invention.
  • FIG. 8 is a schematic structural diagram of an embodiment of a logical channel establishing apparatus of the present invention.
  • FIG. 9 is a schematic structural diagram of an embodiment of a logical channel establishing apparatus of the present invention.
  • FIG. 10 is a schematic diagram showing the hardware structure of a vehicle communication interface VCI according to an embodiment of the present invention.
  • the method and device for establishing a logical channel provided by the embodiment of the present invention are applicable to the application scenario shown in FIG. 1 .
  • the application scenario includes a vehicle diagnostic device 20, a vehicle communication interface VCI (Vehicle Connection Interface) 10, and a vehicle control network 30.
  • VCI Vehicle Connection Interface
  • the vehicle control network 30 is a detected object including a plurality of ECUs, and data of various parts of the vehicle, such as operation data, trouble codes, and the like, can be obtained by diagnosing a plurality of ECUs.
  • the vehicle communication interface VCI10 is a bridge for communication between the vehicle diagnostic device 20 and the vehicle control network 30, responsible for transmitting instructions of the vehicle diagnostic device 20 to the ECU to corresponding ECUs in the vehicle control network 30, and for controlling the vehicle.
  • the transmitted data or instructions are transmitted to the vehicle diagnostic device 20.
  • the VCI 10 can also be used to translate protocol or data protocol formats to enable communication between the two when the vehicle diagnostic device 20 is different from the communication protocol used by the vehicle control network 30.
  • the vehicles described in the embodiments of the present application include small cars, heavy trucks, airplanes, ships, and the like, which are not limited herein.
  • the non-blocking asynchronous communication mode can be adopted between the vehicle diagnostic device 20 and the vehicle communication interface VCI10, and can be connected by a wired interface such as a USB interface, or can be connected by a wireless method such as Bluetooth or WIFI, and the vehicle communication interface VCI10 and the vehicle control network. 30 is connected through a diagnostic interface such as an OBD (On-Board Diagnostic) interface.
  • OBD On-Board Diagnostic
  • the vehicle diagnostic device 20 can be, for example, a personal computer, a smart phone, or the like, capable of running diagnostic software.
  • the diagnostic software provides a human-computer interaction interface. By operating the interface, the user can select a diagnostic function, and the diagnostic software converts the diagnostic function selected by the user.
  • the diagnostic commands of the respective ECUs are sent and sent to the vehicle communication interface VCI10.
  • a plurality of logical channels may be created in the vehicle communication interface VCI10 for interacting data between the plurality of ECUs and the vehicle diagnostic device 20. For example, establishing multiple threads to process instructions for each ECU separately, establishing a plurality of protocol objects to convert each instruction into standard transmission data that the bus can transmit, and establishing at least one bus driving object for transmitting standard transmission data to the vehicle via the bus. Control network 30 and the like. In this way, a plurality of logical channels for accessing each ECU are formed. For specific implementations, refer to the following embodiments.
  • the vehicle control network 30 obtains feedback data corresponding to the diagnostic instruction according to the diagnostic instruction, and transmits the feedback data to the vehicle diagnostic device 20 through a corresponding logical channel of the vehicle communication interface VCI10.
  • the diagnostic software of the vehicle diagnostic device 20 parses the feedback data of the vehicle control network 30, obtains the diagnostic results, and presents the diagnostic results to the user.
  • the manner of interaction between the vehicle diagnostic device 20 and the vehicle control network 30 may also be other manners, which is not limited herein.
  • the method and the device for establishing a logical channel may be implemented by a computer software program in combination with hardware, firmware, and the like configured in the VCI.
  • the basic architecture of the software program in the embodiment of the present application may include an asynchronous communication layer and an operating system.
  • Layer, protocol stack layer and hardware driver layer please refer to Figure 2,
  • Figure 2 is a software architecture example diagram.
  • the asynchronous communication layer is used for asynchronous communication with the vehicle diagnostic device 20, and the operating system layer is used for managing data interaction between the vehicle diagnostic device 20 and the vehicle control network 30, and a real-time operating system can be used.
  • a main thread and a plurality of threads can be created in the operating system, and the diagnostic command of the vehicle diagnostic device 20 for each ECU is sent to each thread by the main thread, and each thread manages data interaction between the ECU and the vehicle diagnostic device 20 by using each thread.
  • Each thread is scheduled by the operating system so that the operations of accessing each ECU can be performed simultaneously.
  • the protocol stack layer is used for conversion between upper layer protocol data and physical layer standard transmission data, and may include protocols such as ISO15765, ISO9141, ISO14230, TP20, TP16, RAWCAN, and the like.
  • the protocol stack layer may create a plurality of protocol objects corresponding to the threads, and use each protocol object to perform conversion between upper layer protocol data and physical layer standard transmission data for data exchanged between one ECU and the vehicle diagnostic device 20.
  • the hardware driver layer abstracts the physical hardware including the bus for transmitting instruction signals to the corresponding physical hardware for transmission.
  • the hardware driver layer may include a bus abstraction layer.
  • At least one bus drive object may be created in the bus abstraction layer, and the data of the protocol stack layer is sent to the vehicle control network 30 through the bus by the bus drive object, and the data received on the bus is collected and sent to the protocol stack layer.
  • a protocol object may correspond to one bus driver object, or multiple protocol objects may share the same bus driver object, provided that the protocol types, bus types, bus pin numbers, and bus pin numbers of the protocol objects are the same.
  • the pins used between bus drive objects cannot conflict with each other.
  • one bus drive object can be used for PIN6 and PIN14, and another bus drive image can be used for PIN3 and PIN11.
  • the hardware driver layer may also define a soft timer abstraction for abstracting the MCU peripheral hardware timer to provide a soft timer for use by the protocol stack layer.
  • a protocol stack interface may be set in the protocol stack layer, and a driver layer access interface may be set in the hardware driver layer, and the driver layer access interface may be provided in an asynchronous communication manner. Logical channel access.
  • FIG. 3 is a schematic flowchart diagram of a method for establishing a logical channel according to an embodiment of the present invention. The method may be performed by the vehicle communication interface VCI10 in FIG. 1 . As shown in FIG. 3, the method includes:
  • the vehicle diagnostic device 20 can create a plurality of diagnostic objects correspondingly in the diagnostic software installed therein, and each diagnostic object is used to diagnose one ECU.
  • the diagnostic software uses asynchronous communication on the external interface. Multiple diagnostic objects can access the VCI through this interface.
  • the at least two first instructions may be issued by different diagnostic objects of the diagnostic software.
  • the first command may be an instruction dedicated to instructing the vehicle diagnostic device 20 to establish a connection with a corresponding ECU, or may be a diagnostic command of the vehicle diagnostic device 20 to the ECU.
  • the vehicle communication interface VCI 10 can simultaneously receive the at least two first instructions sent by the vehicle diagnostic device through an asynchronous communication layer.
  • Step 102 Establish at least two logical channels according to the at least two first instructions, where the first instruction is in one-to-one correspondence with the logical channel, where the logical channel is used to transmit the vehicle diagnostic device 20 and the Data between ECUs.
  • a channel between the vehicle diagnostic device 20 and the ECU corresponding to the first instruction is established according to each first instruction, thereby establishing a logical channel for the at least two first instructions, the logic channel and the ECU A correspondence.
  • channel elements for communicating with adjacent software layers may be established on each software layer of the VCI to establish the at least two logical channels.
  • at least two threads corresponding to the first instruction may be established on the operating system layer, and a main thread for managing the at least two threads may be established.
  • at least two protocol objects corresponding to the first instruction are established in the protocol stack layer according to respective protocol types in the at least two first instructions.
  • At least one bus drive object is established on the hardware driver layer according to respective bus type and/or pin information in the at least two first instructions. In this way, at least two vehicle diagnostic devices 20 are accessed to access the vehicle control network 30 for the vehicle diagnostic device 20 to access at least two ECUs.
  • the main thread can be established when the vehicle communication interface VCI10 is powered on.
  • the main thread is responsible for receiving data (eg, first instructions or diagnostic instructions) issued by the vehicle diagnostic device 20 and distributing the data to the threads.
  • the main thread may also be responsible for receiving data sent by the thread (eg, feedback data of the vehicle) and uploading the data to the vehicle diagnostic device 20.
  • the thread acts as a manager of the logical channel described above for managing data interaction between an ECU and the vehicle diagnostic device 20. That is, the data transmitted by the main thread is received and distributed to the protocol object, and the data transmitted by the protocol object is received and sent to the main thread or vehicle diagnostic device 20.
  • the thread ID can be assigned to the thread when it is created to distinguish other threads from being used by only one ECU for data transmission.
  • the protocol object is used for conversion between upper layer protocol data and physical layer standard transmission data. Since the data needs to be transmitted over the bus to the vehicle control network 30, the data needs to be converted to the physical layer's bus transmission data protocol format, i.e., data link layer and physical layer protocol conversion.
  • the vehicle control network includes a Controller Area Network (CAN) bus, a communication ( Kommunikation, K) bus, etc.
  • the data can be converted into a CAN bus data protocol format, a K bus data protocol format, and the like.
  • the bus driver object is configured to receive physical layer standard transmission data transmitted by the protocol object and transmit the data to the vehicle control network 30 via the bus, and receive physical layer standard transmission data of the bus transmission and transmit the data to the protocol object.
  • One logical channel may correspond to one bus driving object, or multiple logical channels may share the same bus driving object, provided that the bus type and pin information in the first instruction corresponding to the logical channel are the same, for example, protocol type, bus type, The number of bus pins is the same as the bus pin number.
  • a bus may be jointly established in the hardware driver layer for the first instruction in which the bus type and the pin information are the same.
  • the drive object establishes one bus drive object for each of the first instructions having different bus types or pin information. If the bus types of the first instructions in the at least two first instructions are different, or the pin information of each first instruction is different, then each hardware driver layer establishes one for each first instruction. Bus driven object.
  • the thread and protocol objects establish a logical relationship with the ECUs in the vehicle control network 30 through the bus driver objects of the abstraction layer, thereby forming a logical channel for the plurality of vehicle diagnostic devices 20 to access the vehicle control network 30. You can use these logical channels to access multiple ECUs simultaneously.
  • Embodiments of the present invention form a plurality of channels for accessing individual ECUs by establishing at least two logical channels for transmitting data between the vehicle diagnostic device and the ECU in accordance with at least two first instructions. Through the at least two logical channels, the vehicle diagnostic device can simultaneously access at least two ECUs, improving diagnostic efficiency.
  • the vehicle communication interface VCI10 performs the following steps:
  • the second instruction may be a diagnostic instruction of the vehicle diagnostic device 20 to the vehicle control network 30, including the instruction itself and the channel ID.
  • the second instruction can be received by the main thread.
  • the main thread determines the thread corresponding to the logical channel according to the channel identifier, and sends the data to the thread, and the thread receives the data and then sends the data to the corresponding protocol object.
  • the protocol object converts the data into corresponding standard transmission data and transmits the standard transmission data to a corresponding bus drive object.
  • the bus driver object receives the standard transmission data transmitted by the protocol object and transmits the standard transmission data to the vehicle control network 30 via the bus.
  • the bus driver object buffers the standard transmission data sent by each protocol object into memory and then sends it out in the order of the current throughput of the bus.
  • the vehicle diagnostic device 20 receives the feedback data transmitted by the vehicle control network 30 via the vehicle communication interface VCI 10, as shown in FIG. 6, the vehicle communication interface VCI 10 performs the following steps:
  • the bus driving object detects the data transmitted on the bus in real time, collects the data, filters out irrelevant data, obtains standard transmission data corresponding to the feedback data, and then transmits the standard data. Send to each protocol object corresponding to the bus driver object.
  • Each protocol object confirms whether the standard transmission data corresponding to the feedback data sent by the bus drive object is the feedback data corresponding to the ECU that is responsible for itself, and if so, receives the standard transmission data corresponding to the feedback data, and if not, the protocol object does not Receiving standard transmission data corresponding to the feedback data.
  • the protocol object After receiving the standard transmission data, the protocol object performs protocol conversion on the data, obtains feedback data, and then sends the feedback data to its corresponding thread.
  • the thread receives the feedback data corresponding to the ECU that it is responsible for, and may directly send the feedback data to the vehicle diagnostic device 20, or may send the feedback data to the vehicle diagnostic device 20 through the main thread.
  • the embodiment of the present invention further provides a device for establishing a logical channel, which is used in the vehicle communication interface VCI10 in FIG. 1.
  • the device 700 includes:
  • the first instruction receiving module 701 is configured to receive at least two first instructions sent by the vehicle diagnostic device, where the first instruction is used to indicate that the vehicle diagnostic device establishes a connection with an electronic control unit ECU of the vehicle;
  • a logical channel establishing module 702 configured to establish at least two logical channels according to the at least two first instructions, where the first instruction is in one-to-one correspondence with the logical channel, and the logical channel is used to transmit the vehicle Diagnosing data between the device and the ECU.
  • Embodiments of the present invention form a plurality of channels for accessing individual ECUs by establishing at least two logical channels for transmitting data between the vehicle diagnostic device and the ECU in accordance with at least two first instructions. Through the at least two logical channels, the vehicle diagnostic device can simultaneously access at least two ECUs, improving diagnostic efficiency.
  • the logical channel establishing module 702 is specifically configured to:
  • the logical channel establishing module 702 includes:
  • the first logical channel establishing sub-module 7021 is configured to establish at least two threads on the real-time operating system layer according to the at least two first instructions, where the first instruction corresponds to the thread one-to-one.
  • the device 700 further includes:
  • the main thread establishing module 703 is configured to establish a main thread on the real-time operating system layer, where the main thread is used to manage the at least two threads.
  • the logical channel establishing module 702 includes:
  • a second logical channel establishing sub-module 7022 configured to establish at least two protocol objects in the protocol stack layer according to respective protocol types in the at least two first instructions, where the first instruction corresponds to the protocol object one-to-one .
  • the logical channel establishing module 702 includes:
  • the third logical channel establishing sub-module 7023 is configured to establish at least one bus driving object in the hardware driver layer according to the respective bus type and/or pin information in the at least two first instructions.
  • the third logical channel establishing submodule 7023 is specifically configured to:
  • the bus types of the first instructions in the at least two first instructions are different, or the pin information of each first instruction is different, at least two bus driving objects are established in the hardware driver layer.
  • the first instruction is in one-to-one correspondence with the bus drive object.
  • the first instruction receiving module 701 is specifically configured to:
  • the at least two first instructions sent by the vehicle diagnostic device are simultaneously received by the asynchronous communication layer.
  • the apparatus 700 further includes:
  • a second instruction receiving module 704 configured to receive at least two second instructions sent by the vehicle diagnostic device, where the second instruction includes data and a channel identifier;
  • the logical channel determining module 705 is configured to determine at least two logical channels according to respective channel identifiers of the at least two second instructions, where the second instructions are in one-to-one correspondence with the logical channels;
  • the first data sending module 706 is configured to send, by using the at least two logical channels, data in the at least two second instructions to an ECU corresponding to each of the at least two logical channels.
  • the apparatus 700 further includes:
  • the data receiving module 707 is configured to receive data sent by each of the at least two ECUs;
  • the second data sending module 708 is configured to send the data to the vehicle diagnostic device by using at least two logical channels; wherein the ECU is in one-to-one correspondence with the logical channel.
  • the foregoing logical channel establishing apparatus may perform the logical channel establishing method provided by the embodiment of the present application, and has the corresponding functional modules and beneficial effects of executing the logical channel establishing method.
  • the logic channel establishment method provided by the embodiment of the present application.
  • FIG. 10 is a schematic diagram showing the hardware structure of a vehicle communication interface VCI10 according to an embodiment of the present invention. As shown in FIG. 10, the vehicle communication interface VCI10 includes:
  • processors 11 and memory 12 one processor 11 is taken as an example in FIG.
  • the processor 11 and the memory 12 can be connected by a bus or other means, and the bus connection is taken as an example in FIG.
  • the memory 12 is a non-volatile computer readable storage medium, and can be used for storing a non-volatile software program, a non-volatile computer executable program, and a module, such as a computer corresponding to the logical channel establishment method in the embodiment of the present invention.
  • the program instructions/modules of the executable program (for example, the first instruction receiving module 701 and the logical channel establishing module 702 shown in FIG. 7).
  • the processor 11 executes various functional applications and data processing of the vehicle communication interface VCI 10 by executing non-volatile software programs, instructions, and modules stored in the memory 12, that is, implementing the logical channel establishment method of the above method embodiments.
  • the memory 12 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application required for at least one function, the above software architecture, and the like; the storage data area may be stored according to the use of the vehicle communication interface VCI10. Data, etc. Further, the memory 12 may include a high speed random access memory, and may also include a nonvolatile memory such as at least one magnetic disk storage device, flash memory device, or other nonvolatile solid state storage device. In some embodiments, memory 12 may optionally include memory remotely located relative to processor 11 that may be coupled to vehicle communication interface VCI 10 via a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.
  • the one or more units are stored in the memory 12, and when executed by the one or more processors 11, performing a logical channel establishment method in any of the above method embodiments, for example, performing FIG. 3 described above Method steps 101-102, method steps 103-105 in FIG. 5, method steps 106-107 in FIG. 6, implementing modules 701-702 shown in FIG. 7, modules 701-703 in FIG. 8, submodules 7021-7023, the functions of modules 701-708, sub-modules 7021-7023 in FIG.
  • the above-mentioned vehicle communication interface VCI10 can execute the logic channel establishment method provided by the embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method.
  • the vehicle communication interface VCI 10 embodiment For technical details that are not described in detail in the vehicle communication interface VCI 10 embodiment, reference may be made to the method provided by the embodiments of the present invention.
  • Embodiments of the present invention also provide a non-transitory computer readable storage medium storing computer executable instructions that are executed by one or more processors, for example, The logical channel establishing method in any of the foregoing method embodiments, for example, performing the method steps 101-102 in FIG. 3 described above, the method steps 103-105 in FIG. 5, and the method steps 106-107 in FIG.
  • the device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separate, and the components displayed as units may or may not be physical units, ie may be located A place, or it can be distributed to multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the embodiment.
  • the embodiments can be implemented by means of software plus a general hardware platform, and of course, by hardware.
  • a person skilled in the art can understand that all or part of the process of implementing the above embodiments can be completed by a computer program to instruct related hardware, and the program can be stored in a computer readable storage medium. When executed, the flow of an embodiment of the methods as described above may be included.
  • the storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM).

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Small-Scale Networks (AREA)
  • Engineering & Computer Science (AREA)
  • Automation & Control Theory (AREA)

Abstract

A method and device for establishing a logical channel, and a vehicle communication interface (VCI). The method comprises: receiving at least two first instructions sent by a vehicle diagnostic device, the first instructions being used for instructing to establish a connection between the vehicle diagnostic device and an electronic control unit (ECU) of the vehicle (101); establishing at least two logical channels according to the at least two first instructions, the first instructions having one-to-one correspondence to the logical channels, and the logical channels being used for transmitting data between the vehicle diagnostic device and the ECU (102). By establishing at least two logical channels for transmitting data between a vehicle diagnostic device and an ECU according to at least two first instructions, a plurality of channels for accessing ECUs can be formed. By means of the at least two logical channels, the vehicle diagnostic device can simultaneously get access to at least two ECUs, so that the diagnostic efficiency is improved.

Description

逻辑通道的建立方法、装置和交通工具通信接口VCILogical channel establishment method, device and vehicle communication interface VCI
本申请要求于2018年3月16日提交中国专利局、申请号为201810217879.3、申请名称为“逻辑通道的建立方法、装置和交通工具通信接口VCI”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of the Chinese patent application filed on March 16, 2018, the Chinese Patent Office, the application number is 201810217879.3, and the application name is "Logic Channel Establishment Method, Device and Vehicle Communication Interface VCI". The citations are incorporated herein by reference.
技术领域Technical field
本申请涉及汽车诊断技术领域,特别涉及一种逻辑通道的建立方法、装置和交通工具通信接口VCI。The present application relates to the field of automobile diagnostic technology, and in particular, to a method and device for establishing a logical channel and a vehicle communication interface VCI.
背景技术Background technique
目前检测汽车故障和性能的汽车诊断***的应用越来越广泛,其主要通过汽车通信接口VCI连接汽车网络和汽车诊断设备中的诊断软件,利用诊断软件对汽车网络中的汽车电脑(Electronic Control Unit,ECU)进行诊断。目前汽车对ECU的依赖日益加大,一台汽车少则十几个ECU,多则可达几十上百个ECU。At present, the automotive diagnostic system for detecting vehicle faults and performance is more and more widely used. It mainly connects the diagnostic software in the automotive network and the vehicle diagnostic equipment through the vehicle communication interface VCI, and uses the diagnostic software to the automotive computer in the automotive network (Electronic Control Unit). , ECU) for diagnosis. At present, the dependence of automobiles on ECUs is increasing. There are more than a dozen ECUs in one car, and dozens of ECUs in many.
实现本发明过程中,发明人发现相关技术中至少存在如下问题:目前汽车诊断设备一次只能访问一个ECU,诊断效率较低。In the process of implementing the present invention, the inventors have found that at least the following problems exist in the related art: at present, the automobile diagnostic equipment can only access one ECU at a time, and the diagnostic efficiency is low.
发明内容Summary of the invention
本发明实施例的目的是提供一种能提高诊断效率的逻辑通道的建立方法、装置和交通工具通信接口VCI。It is an object of embodiments of the present invention to provide a method, apparatus, and vehicle communication interface VCI for establishing a logical channel that can improve diagnostic efficiency.
第一方面,本发明实施例提供了一种逻辑通道的建立方法,应用于交通工具通信接口VCI,所述方法包括:In a first aspect, an embodiment of the present invention provides a method for establishing a logical channel, which is applied to a vehicle communication interface VCI, and the method includes:
接收交通工具诊断设备发送的至少2个第一指令,所述第一指令用于指示所述交通工具诊断设备与交通工具的电子控制单元ECU建立连接;Receiving at least two first instructions sent by the vehicle diagnostic device, the first instructions being used to instruct the vehicle diagnostic device to establish a connection with an electronic control unit ECU of the vehicle;
根据所述至少2个第一指令,建立至少2个逻辑通道,所述第一指令与所述逻辑通道一一对应,所述逻辑通道用于传输所述交通工具诊断设备与所述ECU之间的数据。Establishing at least two logical channels according to the at least two first instructions, wherein the first instruction is in one-to-one correspondence with the logical channel, and the logical channel is configured to transmit between the vehicle diagnostic device and the ECU The data.
可选的,所述根据所述至少2个第一指令,建立至少2个逻辑通道,包括:Optionally, the establishing at least two logical channels according to the at least two first instructions, including:
根据所述至少2个第一指令,在所述VCI的各软件层上建立通道元素;其中,所述各软件层上的通道元素用于与相邻的软件层进行通信,以建立所述至少2个逻辑通道。Establishing channel elements on each software layer of the VCI according to the at least two first instructions; wherein channel elements on the software layers are used to communicate with adjacent software layers to establish the at least 2 logical channels.
可选的,所述根据所述至少2个第一指令,在所述VCI的各软件层上建立 通道元素,包括:Optionally, the establishing channel elements on each software layer of the VCI according to the at least two first instructions, including:
根据所述至少2个第一指令,在操作***层上建立至少2个线程,所述第一指令与所述线程一一对应。And establishing at least two threads on the operating system layer according to the at least two first instructions, where the first instruction corresponds to the thread one-to-one.
可选的,所述方法还包括:Optionally, the method further includes:
在所述操作***层上建立主线程,所述主线程用于管理所述至少2个线程。A main thread is established on the operating system layer, and the main thread is used to manage the at least two threads.
可选的,所述根据所述至少2个第一指令,在所述VCI的各软件层上建立通道元素,包括:Optionally, the establishing channel elements on each software layer of the VCI according to the at least two first instructions, including:
根据所述至少2个第一指令中各自的协议类型,在协议栈层建立至少2个协议对象,所述第一指令与所述协议对象一一对应。And establishing at least two protocol objects in the protocol stack layer according to respective protocol types in the at least two first instructions, where the first instruction corresponds to the protocol object one-to-one.
可选的,所述根据所述至少2个第一指令,在所述VCI的各软件层上建立通道元素,包括:Optionally, the establishing channel elements on each software layer of the VCI according to the at least two first instructions, including:
根据所述至少2个第一指令中各自的总线类型和/或管脚信息,在硬件驱动层建立至少1个总线驱动对象。And establishing at least one bus drive object in the hardware driver layer according to respective bus type and/or pin information in the at least two first instructions.
可选的,所述根据所述至少2个第一指令中各自的总线类型和/或管脚信息,在硬件驱动层建立至少1个总线驱动对象,包括:Optionally, the establishing at least one bus driving object in the hardware driver layer according to the bus type and/or the pin information in the at least two first instructions includes:
若所述至少2个第一指令中存在总线类型和管脚信息均相同的第一指令,则在所述硬件驱动层为总线类型和管脚信息均相同的第一指令建立一个总线驱动对象;If there is a first instruction in which the bus type and the pin information are the same in the at least two first instructions, establishing, by the hardware driver layer, a bus driving object for the first instruction in which the bus type and the pin information are the same;
若所述至少2个第一指令中各个第一指令的总线类型均不相同,或者各个第一指令的管脚信息均不相同,则在所述硬件驱动层建立至少2个总线驱动对象,所述第一指令与所述总线驱动对象一一对应。If the bus types of the first instructions in the at least two first instructions are different, or the pin information of each first instruction is different, at least two bus driving objects are established in the hardware driver layer. The first instruction is in one-to-one correspondence with the bus drive object.
可选的,所述接收所述交通工具诊断设备发送的至少2个第一指令,包括:Optionally, the receiving, by the at least two first instructions sent by the vehicle diagnostic device, includes:
通过异步通讯层同时接收所述交通工具诊断设备发送的所述至少2个第一指令。The at least two first instructions sent by the vehicle diagnostic device are simultaneously received by the asynchronous communication layer.
可选的,所述方法还包括:Optionally, the method further includes:
接收所述交通工具诊断设备发送的至少2个第二指令,所述第二指令包括数据以及通道标识;Receiving at least two second instructions sent by the vehicle diagnostic device, the second instructions including data and channel identifiers;
根据所述至少2个第二指令中各自的通道标识,确定至少2个逻辑通道,所述第二指令与所述逻辑通道一一对应;Determining at least two logical channels according to respective channel identifiers of the at least two second instructions, wherein the second instructions are in one-to-one correspondence with the logical channels;
通过所述至少2个逻辑通道,将所述至少2个第二指令中的数据发送至所述至少2个逻辑通道各自对应的ECU。And transmitting, by the at least two logical channels, data in the at least two second instructions to an ECU corresponding to each of the at least two logical channels.
可选的,所述方法还包括:Optionally, the method further includes:
接收至少2个ECU各自发送的数据;Receiving data transmitted by at least two ECUs;
通过至少2个逻辑通道,将所述数据发送至所述交通工具诊断设备;其中,所述ECU与所述逻辑通道一一对应。The data is transmitted to the vehicle diagnostic device via at least 2 logical channels; wherein the ECU is in one-to-one correspondence with the logical channel.
第二方面,本发明实施例提供了一种逻辑通道的建立装置,应用于交通工具通信接口VCI,所述装置包括:In a second aspect, an embodiment of the present invention provides a device for establishing a logical channel, which is applied to a vehicle communication interface VCI, and the device includes:
第一指令接收模块,用于接收交通工具诊断设备发送的至少2个第一指令,所述第一指令用于指示所述交通工具诊断设备与交通工具的电子控制单元ECU建立连接;a first instruction receiving module, configured to receive at least two first instructions sent by the vehicle diagnostic device, the first instruction being used to instruct the vehicle diagnostic device to establish a connection with an electronic control unit ECU of the vehicle;
逻辑通道建立模块,用于根据所述至少2个第一指令,建立至少2个逻辑通道,所述第一指令与所述逻辑通道一一对应,所述逻辑通道用于传输所述交通工具诊断设备与所述ECU之间的数据。a logic channel establishing module, configured to establish at least two logical channels according to the at least two first instructions, where the first instruction is in one-to-one correspondence with the logical channel, and the logical channel is used to transmit the vehicle diagnosis Data between the device and the ECU.
可选的,所述逻辑通道建立模块具体用于:Optionally, the logical channel establishing module is specifically configured to:
根据所述至少2个第一指令,在所述VCI的各软件层上建立通道元素;其中,所述各软件层上的通道元素用于与相邻的软件层进行通信,以建立所述至少2个逻辑通道。Establishing channel elements on each software layer of the VCI according to the at least two first instructions; wherein channel elements on the software layers are used to communicate with adjacent software layers to establish the at least 2 logical channels.
可选的,所述逻辑通道建立模块包括:Optionally, the logical channel establishing module includes:
第一逻辑通道建立子模块,用于根据所述至少2个第一指令,在实时操作***层上建立至少2个线程,所述第一指令与所述线程一一对应。The first logical channel establishing submodule is configured to establish at least two threads on the real-time operating system layer according to the at least two first instructions, where the first instruction corresponds to the thread one-to-one.
可选的,所述装置还包括:Optionally, the device further includes:
主线程建立模块,用于在所述实时操作***层上建立主线程,所述主线程用于管理所述至少2个线程。And a main thread establishing module, configured to establish a main thread on the real-time operating system layer, where the main thread is used to manage the at least two threads.
可选的,所述逻辑通道建立模块包括:Optionally, the logical channel establishing module includes:
第二逻辑通道建立子模块,用于根据所述至少2个第一指令中各自的协议类型,在协议栈层建立至少2个协议对象,所述第一指令与所述协议对象一一对应。And a second logical channel establishing submodule, configured to establish at least two protocol objects in the protocol stack layer according to respective protocol types in the at least two first instructions, where the first instruction corresponds to the protocol object one-to-one.
可选的,所述逻辑通道建立模块包括:Optionally, the logical channel establishing module includes:
第三逻辑通道建立子模块,用于根据所述至少2个第一指令中各自的总线类型和/或管脚信息,在硬件驱动层建立至少1个总线驱动对象。The third logical channel establishing submodule is configured to establish at least one bus driving object in the hardware driver layer according to the respective bus type and/or pin information in the at least two first instructions.
可选的,所述第三逻辑通道建立子模块具体用于:Optionally, the third logical channel establishing submodule is specifically configured to:
若所述至少2个第一指令中存在总线类型和管脚信息均相同的第一指令,则在所述硬件驱动层为总线类型和管脚信息均相同的第一指令建立一个总线驱动对象;If there is a first instruction in which the bus type and the pin information are the same in the at least two first instructions, establishing, by the hardware driver layer, a bus driving object for the first instruction in which the bus type and the pin information are the same;
若所述至少2个第一指令中各个第一指令的总线类型均不相同,或者各个第一指令的管脚信息均不相同,则在所述硬件驱动层建立至少2个总线驱动对象,所述第一指令与所述总线驱动对象一一对应。If the bus types of the first instructions in the at least two first instructions are different, or the pin information of each first instruction is different, at least two bus driving objects are established in the hardware driver layer. The first instruction is in one-to-one correspondence with the bus drive object.
可选的,所述第一指令接收模块具体用于:Optionally, the first instruction receiving module is specifically configured to:
通过异步通讯层同时接收所述交通工具诊断设备发送的所述至少2个第一指令。The at least two first instructions sent by the vehicle diagnostic device are simultaneously received by the asynchronous communication layer.
可选的,所述装置还包括:Optionally, the device further includes:
第二指令接收模块,用于接收所述交通工具诊断设备发送的至少2个第二指令,所述第二指令包括数据以及通道标识;a second instruction receiving module, configured to receive at least two second instructions sent by the vehicle diagnostic device, where the second instruction includes data and a channel identifier;
逻辑通道确定模块,用于根据所述至少2个第二指令中各自的通道标识,确定至少2个逻辑通道,所述第二指令与所述逻辑通道一一对应;a logic channel determining module, configured to determine at least two logical channels according to respective channel identifiers of the at least two second instructions, where the second instruction corresponds to the logical channel one-to-one;
第一数据发送模块,用于通过所述至少2个逻辑通道,将所述至少2个第二指令中的数据发送至所述至少2个逻辑通道各自对应的ECU。And a first data sending module, configured to send, by using the at least two logical channels, data in the at least two second instructions to an ECU corresponding to each of the at least two logical channels.
可选的,所述装置还包括:Optionally, the device further includes:
数据接收模块,用于接收至少2个ECU各自发送的数据;a data receiving module, configured to receive data sent by each of at least two ECUs;
第二数据发送模块,用于通过至少2个逻辑通道,将所述数据发送至所述交通工具诊断设备;其中,所述ECU与所述逻辑通道一一对应。And a second data sending module, configured to send the data to the vehicle diagnostic device through at least two logical channels; wherein the ECU is in one-to-one correspondence with the logical channel.
第三方面,本发明实施例提供了一种交通工具通信接口VCI,包括:In a third aspect, an embodiment of the present invention provides a vehicle communication interface VCI, including:
至少一个处理器;以及,At least one processor; and,
与所述至少一个处理器通信连接的存储器;其中,a memory communicatively coupled to the at least one processor; wherein
所述存储器存储有可被所述至少一个处理器执行的指令;The memory stores instructions executable by the at least one processor;
所述至少一个处理器用于调用所述指令,以执行上述的方法。The at least one processor is configured to invoke the instructions to perform the method described above.
第四方面,本发明实施例提供了一种非易失性计算机可读存储介质,所述非易失性计算机可读存储介质存储有计算机可执行指令,当所述计算机可执行指令被交通工具通信接口VCI调用时,使所述交通工具通信接口VCI执行上述的方法。In a fourth aspect, an embodiment of the present invention provides a non-transitory computer readable storage medium storing computer-executable instructions when the computer-executable instructions are used by a vehicle When the communication interface VCI is invoked, the vehicle communication interface VCI is caused to perform the above method.
第五方面,本发明实施例提供了一种计算机程序产品,所述计算机程序产品包括存储在非易失性计算机可读存储介质上的计算机程序,所述计算机程序包括程序指令,当所述程序指令被交通工具通信接口VCI调用时,使所述交通工具通信接口VCI执行上述的方法。In a fifth aspect, an embodiment of the present invention provides a computer program product, the computer program product comprising a computer program stored on a non-transitory computer readable storage medium, the computer program comprising program instructions, when the program When the command is invoked by the vehicle communication interface VCI, the vehicle communication interface VCI is caused to perform the method described above.
本发明实施例通过根据至少两个第一指令建立至少两个用于传输交通工具诊断设备与ECU之间数据的逻辑通道,以此形成多条访问各个ECU的通道。通过该至少两个逻辑通道,交通工具诊断设备可以同时访问至少两个ECU,提高了诊断效率。Embodiments of the present invention form a plurality of channels for accessing individual ECUs by establishing at least two logical channels for transmitting data between the vehicle diagnostic device and the ECU in accordance with at least two first instructions. Through the at least two logical channels, the vehicle diagnostic device can simultaneously access at least two ECUs, improving diagnostic efficiency.
附图说明DRAWINGS
一个或多个实施例通过与之对应的附图中的图片进行示例性说明,这些示例性说明并不构成对实施例的限定,附图中具有相同参考数字标号的元件表示为类似的元件,除非有特别申明,附图中的图不构成比例限制。The one or more embodiments are exemplified by the accompanying drawings in the accompanying drawings, and FIG. The figures in the drawings do not constitute a scale limitation unless otherwise stated.
图1是本发明实施例提供的逻辑通道的建立方法和装置的应用场景示意图;1 is a schematic diagram of an application scenario of a method and an apparatus for establishing a logical channel according to an embodiment of the present invention;
图2是本发明实施例逻辑通道的建立方法对应的软件基本架构示意图;2 is a schematic diagram of a software basic architecture corresponding to a method for establishing a logical channel according to an embodiment of the present invention;
图3是本发明逻辑通道的建立方法的一个实施例的流程示意图;3 is a schematic flow chart of an embodiment of a method for establishing a logical channel according to the present invention;
图4是本发明逻辑通道的建立方法的一个实施例中交通工具诊断设备和交通工具控制网络间形成多条访问ECU的逻辑通道示意图;4 is a schematic diagram of a logical channel for forming a plurality of access ECUs between a vehicle diagnostic device and a vehicle control network in an embodiment of a method for establishing a logical channel according to the present invention;
图5是本发明实施例逻辑通道建立方法中交通工具诊断设备通过交通工具通信接口VCI给汽车网络发送诊断指令的流程示意图;FIG. 5 is a schematic flowchart of a method for establishing a diagnostic command by a vehicle diagnostic device to a vehicle network through a vehicle communication interface VCI according to a method for establishing a logical channel according to an embodiment of the present invention; FIG.
图6是本发明实施例逻辑通道建立方法中交通工具诊断设备通过交通工 具通信接口VCI接收汽车网络发送的反馈数据的流程示意图;6 is a schematic flow chart of receiving, by the vehicle diagnostic device, the feedback data sent by the vehicle network through the traffic tool communication interface VCI in the logic channel establishing method according to the embodiment of the present invention;
图7是本发明逻辑通道建立装置的一个实施例的结构示意图;7 is a schematic structural diagram of an embodiment of a logical channel establishing apparatus of the present invention;
图8是本发明逻辑通道建立装置的一个实施例的结构示意图;8 is a schematic structural diagram of an embodiment of a logical channel establishing apparatus of the present invention;
图9是本发明逻辑通道建立装置的一个实施例的结构示意图;9 is a schematic structural diagram of an embodiment of a logical channel establishing apparatus of the present invention;
图10是本发明实施例提供的交通工具通信接口VCI的硬件结构示意图。FIG. 10 is a schematic diagram showing the hardware structure of a vehicle communication interface VCI according to an embodiment of the present invention.
具体实施方式detailed description
为使本发明实施例的目的、技术方案和优点更加清楚,下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。The technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the drawings in the embodiments of the present invention. It is a partial embodiment of the invention, and not all of the embodiments. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative efforts are within the scope of the present invention.
本发明实施例提供的逻辑通道的建立方法和装置适用于如图1所示的应用场景。所述应用场景包括交通工具诊断设备20、交通工具通信接口VCI(Vehicle Connection Interface)10和交通工具控制网络30。The method and device for establishing a logical channel provided by the embodiment of the present invention are applicable to the application scenario shown in FIG. 1 . The application scenario includes a vehicle diagnostic device 20, a vehicle communication interface VCI (Vehicle Connection Interface) 10, and a vehicle control network 30.
交通工具控制网络30是被检测对象,其包括多个ECU,通过对多个ECU进行诊断可以获得交通工具各部分的数据,如运行数据、故障码等。The vehicle control network 30 is a detected object including a plurality of ECUs, and data of various parts of the vehicle, such as operation data, trouble codes, and the like, can be obtained by diagnosing a plurality of ECUs.
交通工具通信接口VCI10是交通工具诊断设备20和交通工具控制网络30通信的桥梁,负责将交通工具诊断设备20对ECU的指令传输给交通工具控制网络30中相应的ECU,以及将交通工具控制网络30发送的数据或指令传输给交通工具诊断设备20。进一步地,VCI10还可以用于转换指令或数据的协议格式,以在交通工具诊断设备20与交通工具控制网络30所使用的通信协议不同时,实现这两者之间的通信。The vehicle communication interface VCI10 is a bridge for communication between the vehicle diagnostic device 20 and the vehicle control network 30, responsible for transmitting instructions of the vehicle diagnostic device 20 to the ECU to corresponding ECUs in the vehicle control network 30, and for controlling the vehicle. The transmitted data or instructions are transmitted to the vehicle diagnostic device 20. Further, the VCI 10 can also be used to translate protocol or data protocol formats to enable communication between the two when the vehicle diagnostic device 20 is different from the communication protocol used by the vehicle control network 30.
其中,本申请实施例中所描述的交通工具包括小型汽车、重型卡车、飞机、轮船等交通工具,在此不予限定。The vehicles described in the embodiments of the present application include small cars, heavy trucks, airplanes, ships, and the like, which are not limited herein.
交通工具诊断设备20和交通工具通信接口VCI10之间可以采用非阻塞异步通讯方式,通过USB接口等有线方式连接,也可以通过蓝牙、WIFI等无线方式连接,交通工具通信接口VCI10与交通工具控制网络30之间通过诊断接口例如OBD(On-Board Diagnostic)接口相连。The non-blocking asynchronous communication mode can be adopted between the vehicle diagnostic device 20 and the vehicle communication interface VCI10, and can be connected by a wired interface such as a USB interface, or can be connected by a wireless method such as Bluetooth or WIFI, and the vehicle communication interface VCI10 and the vehicle control network. 30 is connected through a diagnostic interface such as an OBD (On-Board Diagnostic) interface.
交通工具诊断设备20可以是例如个人计算机、智能手机等能运行诊断软件的设备,所述诊断软件提供人机交互界面,通过操作该界面用户可以选择诊断功能,诊断软件将用户选择的诊断功能转换成对各个ECU的诊断指令,并将该诊断指令发送给交通工具通信接口VCI10。The vehicle diagnostic device 20 can be, for example, a personal computer, a smart phone, or the like, capable of running diagnostic software. The diagnostic software provides a human-computer interaction interface. By operating the interface, the user can select a diagnostic function, and the diagnostic software converts the diagnostic function selected by the user. The diagnostic commands of the respective ECUs are sent and sent to the vehicle communication interface VCI10.
本申请实施例中,交通工具通信接口VCI10内可以创建多个逻辑通道,用于在多个ECU与交通工具诊断设备20之间交互数据。例如,建立多个线程分别处理对各个ECU的指令,建立多个协议对象将各个指令转换成总线能传输的标准传输数据,建立至少一个总线驱动对象用于通过总线将标准传输数据发送 给交通工具控制网络30等。以此形成多条访问各个ECU的逻辑通道。具体的实现方式可以参见下述实施例。In the embodiment of the present application, a plurality of logical channels may be created in the vehicle communication interface VCI10 for interacting data between the plurality of ECUs and the vehicle diagnostic device 20. For example, establishing multiple threads to process instructions for each ECU separately, establishing a plurality of protocol objects to convert each instruction into standard transmission data that the bus can transmit, and establishing at least one bus driving object for transmitting standard transmission data to the vehicle via the bus. Control network 30 and the like. In this way, a plurality of logical channels for accessing each ECU are formed. For specific implementations, refer to the following embodiments.
交通工具控制网络30根据该诊断指令获得该诊断指令对应的反馈数据,并将所述反馈数据通过交通工具通信接口VCI10的对应的逻辑通道发送给交通工具诊断设备20。交通工具诊断设备20的诊断软件对交通工具控制网络30的反馈数据进行解析,获得诊断结果,并将诊断结果向用户展示。The vehicle control network 30 obtains feedback data corresponding to the diagnostic instruction according to the diagnostic instruction, and transmits the feedback data to the vehicle diagnostic device 20 through a corresponding logical channel of the vehicle communication interface VCI10. The diagnostic software of the vehicle diagnostic device 20 parses the feedback data of the vehicle control network 30, obtains the diagnostic results, and presents the diagnostic results to the user.
当然,交通工具诊断设备20与交通工具控制网络30之间的交互方式还可以是其他方式,在此不予限定。Of course, the manner of interaction between the vehicle diagnostic device 20 and the vehicle control network 30 may also be other manners, which is not limited herein.
在实际应用中,逻辑通道的建立方法和装置可以由计算机软件程序结合VCI中配置的硬件、固件等来实现,在此,本申请实施例的软件程序的基本架构可以包括异步通讯层、操作***层、协议栈层和硬件驱动层,请参照图2,图2为软件架构示例图。In a practical application, the method and the device for establishing a logical channel may be implemented by a computer software program in combination with hardware, firmware, and the like configured in the VCI. The basic architecture of the software program in the embodiment of the present application may include an asynchronous communication layer and an operating system. Layer, protocol stack layer and hardware driver layer, please refer to Figure 2, Figure 2 is a software architecture example diagram.
其中,异步通讯层用于与交通工具诊断设备20之间进行异步通讯,操作***层用于对交通工具诊断设备20与交通工具控制网络30之间的数据交互操作进行管理,可以采用实时操作***。操作***内可以创建主线程和多个线程,利用主线程将交通工具诊断设备20对各个ECU的诊断指令发送给各线程,利用每个线程管理一个ECU与交通工具诊断设备20之间的数据交互。通过操作***调度各个线程,使访问各个ECU的操作可以同步进行。The asynchronous communication layer is used for asynchronous communication with the vehicle diagnostic device 20, and the operating system layer is used for managing data interaction between the vehicle diagnostic device 20 and the vehicle control network 30, and a real-time operating system can be used. . A main thread and a plurality of threads can be created in the operating system, and the diagnostic command of the vehicle diagnostic device 20 for each ECU is sent to each thread by the main thread, and each thread manages data interaction between the ECU and the vehicle diagnostic device 20 by using each thread. . Each thread is scheduled by the operating system so that the operations of accessing each ECU can be performed simultaneously.
协议栈层用于上层协议数据和物理层标准传输数据之间的转换,可以包括例如ISO15765、ISO9141、ISO14230、TP20、TP16、RAWCAN等协议。协议栈层可以与线程对应的创建多个协议对象,利用每个协议对象对一个ECU与交通工具诊断设备20之间交互的数据进行上层协议数据和物理层标准传输数据之间的转换。The protocol stack layer is used for conversion between upper layer protocol data and physical layer standard transmission data, and may include protocols such as ISO15765, ISO9141, ISO14230, TP20, TP16, RAWCAN, and the like. The protocol stack layer may create a plurality of protocol objects corresponding to the threads, and use each protocol object to perform conversion between upper layer protocol data and physical layer standard transmission data for data exchanged between one ECU and the vehicle diagnostic device 20.
硬件驱动层将包括总线在内的物理硬件抽象出来,用于将指令信号发送至对应的物理硬件上,以实现传输。The hardware driver layer abstracts the physical hardware including the bus for transmitting instruction signals to the corresponding physical hardware for transmission.
其中,硬件驱动层可以包括总线抽象层。总线抽象层内可以创建至少一个总线驱动对象,利用总线驱动对象将协议栈层的数据通过总线发送给交通工具控制网络30,以及将总线上接收的数据收集起来发送给协议栈层。可以一个协议对象对应一个总线驱动对象,也可以多个协议对象共享同一总线驱动对象,前提是这些协议对象的协议类型、总线类型、总线管脚数量和总线管脚编号相同。总线驱动对象之间所用管脚不能互相冲突,例如一个总线驱动对象可以用于PIN6和PIN14,另一个总线驱动象,可以用于PIN3和PIN11。Wherein, the hardware driver layer may include a bus abstraction layer. At least one bus drive object may be created in the bus abstraction layer, and the data of the protocol stack layer is sent to the vehicle control network 30 through the bus by the bus drive object, and the data received on the bus is collected and sent to the protocol stack layer. A protocol object may correspond to one bus driver object, or multiple protocol objects may share the same bus driver object, provided that the protocol types, bus types, bus pin numbers, and bus pin numbers of the protocol objects are the same. The pins used between bus drive objects cannot conflict with each other. For example, one bus drive object can be used for PIN6 and PIN14, and another bus drive image can be used for PIN3 and PIN11.
在一个实施例中,硬件驱动层还可以定义软定时器抽象,用于对MCU外设硬件定时器进行抽象,以提供软定时器给协议栈层使用。在一个实施例中,为了使各软件层间能互相访问,可以在协议栈层设置协议栈接口,在硬件驱动层设置驱动层访问接口,驱动层访问接口可以采用异步通讯方式,提供给多个逻辑通道访问。In one embodiment, the hardware driver layer may also define a soft timer abstraction for abstracting the MCU peripheral hardware timer to provide a soft timer for use by the protocol stack layer. In an embodiment, in order to enable each software layer to access each other, a protocol stack interface may be set in the protocol stack layer, and a driver layer access interface may be set in the hardware driver layer, and the driver layer access interface may be provided in an asynchronous communication manner. Logical channel access.
图3为本发明实施例提供的一种逻辑通道的建立方法的流程示意图,所述方法可以由图1中的交通工具通信接口VCI10执行。如图3所示,所述方法包括:FIG. 3 is a schematic flowchart diagram of a method for establishing a logical channel according to an embodiment of the present invention. The method may be performed by the vehicle communication interface VCI10 in FIG. 1 . As shown in FIG. 3, the method includes:
101:接收交通工具诊断设备发送的至少2个第一指令,所述第一指令用于指示所述交通工具诊断设备与交通工具的电子控制单元ECU建立连接。101: Receive at least two first instructions sent by the vehicle diagnostic device, the first instructions being used to instruct the vehicle diagnostic device to establish a connection with an electronic control unit ECU of the vehicle.
其中,交通工具诊断设备20可以在其安装的诊断软件中对应的创建多个诊断对象,每个诊断对象用于诊断一个ECU。诊断软件对外接口采用异步通讯的方式,多个诊断对象通过该接口均可以访问VCI。所述至少两个第一指令可以是诊断软件的不同诊断对象发出的。第一指令可以是专用于指示交通工具诊断设备20与对应的ECU建立连接的指令,也可以为交通工具诊断设备20对ECU的诊断指令。The vehicle diagnostic device 20 can create a plurality of diagnostic objects correspondingly in the diagnostic software installed therein, and each diagnostic object is used to diagnose one ECU. The diagnostic software uses asynchronous communication on the external interface. Multiple diagnostic objects can access the VCI through this interface. The at least two first instructions may be issued by different diagnostic objects of the diagnostic software. The first command may be an instruction dedicated to instructing the vehicle diagnostic device 20 to establish a connection with a corresponding ECU, or may be a diagnostic command of the vehicle diagnostic device 20 to the ECU.
在一个实施方式中,交通工具通信接口VCI10可以通过异步通讯层同时接收所述交通工具诊断设备发送的所述至少2个第一指令。In one embodiment, the vehicle communication interface VCI 10 can simultaneously receive the at least two first instructions sent by the vehicle diagnostic device through an asynchronous communication layer.
102:根据所述至少2个第一指令,建立至少2个逻辑通道,所述第一指令与所述逻辑通道一一对应,所述逻辑通道用于传输所述交通工具诊断设备20与所述ECU之间的数据。Step 102: Establish at least two logical channels according to the at least two first instructions, where the first instruction is in one-to-one correspondence with the logical channel, where the logical channel is used to transmit the vehicle diagnostic device 20 and the Data between ECUs.
即根据每个第一指令建立一条交通工具诊断设备20与所述第一指令对应的ECU之间的通道,从而为所述至少两个第一指令分别建立逻辑通道,所述逻辑通道与ECU一一对应。That is, a channel between the vehicle diagnostic device 20 and the ECU corresponding to the first instruction is established according to each first instruction, thereby establishing a logical channel for the at least two first instructions, the logic channel and the ECU A correspondence.
其中,可以在所述VCI的各软件层上建立用于与相邻的软件层进行通信的通道元素,以建立所述至少2个逻辑通道。以图2所示的软件架构为例,可以在操作***层上建立至少2个与所述第一指令一一对应的线程,建立用于管理所述至少2个线程的主线程。在协议栈层根据所述至少2个第一指令中各自的协议类型,建立至少2个与所述第一指令一一对应的协议对象。在硬件驱动层上根据所述至少2个第一指令中各自的总线类型和/或管脚信息,建立至少1个总线驱动对象。以此形成至少两条交通工具诊断设备20访问交通工具控制网络30的通道,用于使交通工具诊断设备20访问至少两个ECU。Wherein, channel elements for communicating with adjacent software layers may be established on each software layer of the VCI to establish the at least two logical channels. Taking the software architecture shown in FIG. 2 as an example, at least two threads corresponding to the first instruction may be established on the operating system layer, and a main thread for managing the at least two threads may be established. And at least two protocol objects corresponding to the first instruction are established in the protocol stack layer according to respective protocol types in the at least two first instructions. At least one bus drive object is established on the hardware driver layer according to respective bus type and/or pin information in the at least two first instructions. In this way, at least two vehicle diagnostic devices 20 are accessed to access the vehicle control network 30 for the vehicle diagnostic device 20 to access at least two ECUs.
其中,主线程可以在交通工具通信接口VCI10上电初始化时建立。主线程负责接收交通工具诊断设备20下发的数据(例如第一指令或者诊断指令),并将数据分发给线程。可选的,主线程还可以负责接收线程发送的数据(例如交通工具的反馈数据),并将数据上传给交通工具诊断设备20。The main thread can be established when the vehicle communication interface VCI10 is powered on. The main thread is responsible for receiving data (eg, first instructions or diagnostic instructions) issued by the vehicle diagnostic device 20 and distributing the data to the threads. Optionally, the main thread may also be responsible for receiving data sent by the thread (eg, feedback data of the vehicle) and uploading the data to the vehicle diagnostic device 20.
线程作为上述逻辑通道的管理者,用于管理一个ECU与所述交通工具诊断设备20的数据交互。即接收主线程发送的数据并将所述数据分发给协议对象,以及接收协议对象发送的数据并将所述数据发送给主线程或交通工具诊断设备20。可选的,线程创建时可以为其分配通道ID,以区分其他线程,使其被使用时只负责一个ECU的数据传输。The thread acts as a manager of the logical channel described above for managing data interaction between an ECU and the vehicle diagnostic device 20. That is, the data transmitted by the main thread is received and distributed to the protocol object, and the data transmitted by the protocol object is received and sent to the main thread or vehicle diagnostic device 20. Optionally, the thread ID can be assigned to the thread when it is created to distinguish other threads from being used by only one ECU for data transmission.
协议对象用于上层协议数据和物理层标准传输数据之间的转换。因为数据需要通过总线传输给交通工具控制网络30,所以数据需要转换成物理层的总 线传输数据协议格式,即进行数据链路层和物理层协议转换。在交通工具控制网络包括控制器局域网络(Controller Area Network,CAN)总线、通讯(Kommunikation,K)总线等的场合,数据可以转换成CAN总线数据协议格式、K总线数据协议格式等。The protocol object is used for conversion between upper layer protocol data and physical layer standard transmission data. Since the data needs to be transmitted over the bus to the vehicle control network 30, the data needs to be converted to the physical layer's bus transmission data protocol format, i.e., data link layer and physical layer protocol conversion. When the vehicle control network includes a Controller Area Network (CAN) bus, a communication (Kommunikation, K) bus, etc., the data can be converted into a CAN bus data protocol format, a K bus data protocol format, and the like.
总线驱动对象用于接收协议对象发送的物理层标准传输数据并将所述数据通过总线发送给交通工具控制网络30,以及接收总线传输的物理层标准传输数据并将所述数据发送给协议对象。可以一个逻辑通道对应一个总线驱动对象,也可以多个逻辑通道共享同一总线驱动对象,前提是该逻辑通道对应的第一指令中的总线类型和管脚信息均相同,例如协议类型、总线类型、总线管脚数量和总线管脚编号相同。The bus driver object is configured to receive physical layer standard transmission data transmitted by the protocol object and transmit the data to the vehicle control network 30 via the bus, and receive physical layer standard transmission data of the bus transmission and transmit the data to the protocol object. One logical channel may correspond to one bus driving object, or multiple logical channels may share the same bus driving object, provided that the bus type and pin information in the first instruction corresponding to the logical channel are the same, for example, protocol type, bus type, The number of bus pins is the same as the bus pin number.
即如果所述至少2个第一指令中存在总线类型和管脚信息均相同的第一指令,则可以在所述硬件驱动层为总线类型和管脚信息均相同的第一指令共同建立一个总线驱动对象,为其他总线类型或管脚信息不相同的第一指令各自建立1个总线驱动对象。如果所述至少2个第一指令中各个第一指令的总线类型均不相同,或者各个第一指令的管脚信息均不相同,则在所述硬件驱动层分别为每个第一指令建立一个总线驱动对象。That is, if there is a first instruction in which the bus type and the pin information are the same in the at least two first instructions, a bus may be jointly established in the hardware driver layer for the first instruction in which the bus type and the pin information are the same. The drive object establishes one bus drive object for each of the first instructions having different bus types or pin information. If the bus types of the first instructions in the at least two first instructions are different, or the pin information of each first instruction is different, then each hardware driver layer establishes one for each first instruction. Bus driven object.
如图4所示,线程和协议对象通过抽象层的总线驱动对象与交通工具控制网络30中的ECU建立了逻辑关系,从而形成了多条交通工具诊断设备20访问交通工具控制网络30的逻辑通道,可以利用这些逻辑通道,同时访问多个ECU。As shown in FIG. 4, the thread and protocol objects establish a logical relationship with the ECUs in the vehicle control network 30 through the bus driver objects of the abstraction layer, thereby forming a logical channel for the plurality of vehicle diagnostic devices 20 to access the vehicle control network 30. You can use these logical channels to access multiple ECUs simultaneously.
本发明实施例通过根据至少两个第一指令建立至少两个用于传输交通工具诊断设备与ECU之间数据的逻辑通道,以此形成多条访问各个ECU的通道。通过该至少两个逻辑通道,交通工具诊断设备可以同时访问至少两个ECU,提高了诊断效率。Embodiments of the present invention form a plurality of channels for accessing individual ECUs by establishing at least two logical channels for transmitting data between the vehicle diagnostic device and the ECU in accordance with at least two first instructions. Through the at least two logical channels, the vehicle diagnostic device can simultaneously access at least two ECUs, improving diagnostic efficiency.
其中,交通工具诊断设备20通过交通工具通信接口VCI10给交通工具控制网络30发送第二指令(诊断指令)时,如图5所示,交通工具通信接口VCI10执行以下步骤:Wherein, when the vehicle diagnostic device 20 sends a second command (diagnostic command) to the vehicle control network 30 through the vehicle communication interface VCI10, as shown in FIG. 5, the vehicle communication interface VCI10 performs the following steps:
103:接收所述交通工具诊断设备20发送的至少2个第二指令,所述第二指令包括数据以及通道标识。103: Receive at least two second instructions sent by the vehicle diagnostic device 20, the second instructions including data and a channel identifier.
其中,所述第二指令可以为交通工具诊断设备20对交通工具控制网络30的诊断指令,包括指令本身和通道ID。在图2所示的实施例中,可以通过主线程接收该第二指令。The second instruction may be a diagnostic instruction of the vehicle diagnostic device 20 to the vehicle control network 30, including the instruction itself and the channel ID. In the embodiment shown in FIG. 2, the second instruction can be received by the main thread.
104:根据所述至少2个第二指令中各自的通道标识,确定至少2个逻辑通道,所述第二指令与所述逻辑通道一一对应。104: Determine, according to respective channel identifiers of the at least two second instructions, at least two logical channels, where the second instruction corresponds to the logical channel one-to-one.
105:通过所述至少2个逻辑通道,将所述至少2个第二指令中的数据发送至所述至少2个逻辑通道各自对应的ECU。105: Send, by the at least two logical channels, data in the at least two second instructions to an ECU corresponding to each of the at least two logical channels.
即根据第二指令中的通道标识,确定该第二指令对应的逻辑通道,并通过确定的逻辑通道将第二指令中的数据发送给对应的ECU。在图2所示的实施例 中,主线程根据通道标识确定该逻辑通道对应的线程,并将数据发送给线程,线程接收数据后再发送给对应的协议对象。协议对象将所述数据转换成对应的标准传输数据,并将所述标准传输数据发送给对应的总线驱动对象。总线驱动对象接收所述协议对象发送的标准传输数据,并将所述标准传输数据通过总线传送给交通工具控制网络30。That is, according to the channel identifier in the second instruction, the logical channel corresponding to the second instruction is determined, and the data in the second instruction is sent to the corresponding ECU through the determined logical channel. In the embodiment shown in FIG. 2, the main thread determines the thread corresponding to the logical channel according to the channel identifier, and sends the data to the thread, and the thread receives the data and then sends the data to the corresponding protocol object. The protocol object converts the data into corresponding standard transmission data and transmits the standard transmission data to a corresponding bus drive object. The bus driver object receives the standard transmission data transmitted by the protocol object and transmits the standard transmission data to the vehicle control network 30 via the bus.
当一个总线驱动对象被多个协议对象共享时,总线驱动对象将各个协议对象发送的标准传输数据缓冲到内存,然后以总线的当前吞吐量顺序的发送出去。When a bus driver object is shared by multiple protocol objects, the bus driver object buffers the standard transmission data sent by each protocol object into memory and then sends it out in the order of the current throughput of the bus.
交通工具诊断设备20通过交通工具通信接口VCI10接收交通工具控制网络30发送的反馈数据时,如图6所示,交通工具通信接口VCI10执行以下步骤:When the vehicle diagnostic device 20 receives the feedback data transmitted by the vehicle control network 30 via the vehicle communication interface VCI 10, as shown in FIG. 6, the vehicle communication interface VCI 10 performs the following steps:
106:接收至少2个ECU各自发送的数据。106: Receive data sent by at least two ECUs.
107:通过至少2个逻辑通道,将所述数据发送至所述交通工具诊断设备;其中,所述ECU与所述逻辑通道一一对应。107: Send the data to the vehicle diagnostic device through at least 2 logical channels; wherein the ECU is in one-to-one correspondence with the logical channel.
即接收各个ECU的反馈数据,并通过各个逻辑通道将反馈数据发送给交通工具诊断设备20,每个逻辑通道只负责传送与其自身对应的反馈数据。以图2所示的实施例为例,总线驱动对象实时检测总线上传输的数据,并将数据收集起来,过滤掉不相关的数据,获得反馈数据对应的标准传输数据,然后将该标准传输数据发送给该总线驱动对象对应的各个协议对象。每个协议对象会确认总线驱动对象发送的反馈数据对应的标准传输数据是否是自身负责的ECU对应的反馈数据,如果是,会接收该反馈数据对应的标准传输数据,如果否,协议对象不会接收该反馈数据对应的标准传输数据。协议对象接收到所述标准传输数据后,对该数据进行协议转换,获得反馈数据,然后将该反馈数据发送给其对应的线程。线程接收到其负责的ECU对应的反馈数据,可以直接将该反馈数据发送给交通工具诊断设备20,也可以通过主线程将反馈数据发送给交通工具诊断设备20。That is, the feedback data of each ECU is received, and the feedback data is sent to the vehicle diagnostic device 20 through each logical channel, and each logical channel is only responsible for transmitting feedback data corresponding to itself. Taking the embodiment shown in FIG. 2 as an example, the bus driving object detects the data transmitted on the bus in real time, collects the data, filters out irrelevant data, obtains standard transmission data corresponding to the feedback data, and then transmits the standard data. Send to each protocol object corresponding to the bus driver object. Each protocol object confirms whether the standard transmission data corresponding to the feedback data sent by the bus drive object is the feedback data corresponding to the ECU that is responsible for itself, and if so, receives the standard transmission data corresponding to the feedback data, and if not, the protocol object does not Receiving standard transmission data corresponding to the feedback data. After receiving the standard transmission data, the protocol object performs protocol conversion on the data, obtains feedback data, and then sends the feedback data to its corresponding thread. The thread receives the feedback data corresponding to the ECU that it is responsible for, and may directly send the feedback data to the vehicle diagnostic device 20, or may send the feedback data to the vehicle diagnostic device 20 through the main thread.
相应的,本发明实施例还提供了一种逻辑通道的建立装置,用于图1中的交通工具通信接口VCI10,如图7所示,装置700包括:Correspondingly, the embodiment of the present invention further provides a device for establishing a logical channel, which is used in the vehicle communication interface VCI10 in FIG. 1. As shown in FIG. 7, the device 700 includes:
第一指令接收模块701,用于接收交通工具诊断设备发送的至少2个第一指令,所述第一指令用于指示所述交通工具诊断设备与交通工具的电子控制单元ECU建立连接;The first instruction receiving module 701 is configured to receive at least two first instructions sent by the vehicle diagnostic device, where the first instruction is used to indicate that the vehicle diagnostic device establishes a connection with an electronic control unit ECU of the vehicle;
逻辑通道建立模块702,用于根据所述至少2个第一指令,建立至少2个逻辑通道,所述第一指令与所述逻辑通道一一对应,所述逻辑通道用于传输所述交通工具诊断设备与所述ECU之间的数据。a logical channel establishing module 702, configured to establish at least two logical channels according to the at least two first instructions, where the first instruction is in one-to-one correspondence with the logical channel, and the logical channel is used to transmit the vehicle Diagnosing data between the device and the ECU.
本发明实施例通过根据至少两个第一指令建立至少两个用于传输交通工具诊断设备与ECU之间数据的逻辑通道,以此形成多条访问各个ECU的通道。 通过该至少两个逻辑通道,交通工具诊断设备可以同时访问至少两个ECU,提高了诊断效率。Embodiments of the present invention form a plurality of channels for accessing individual ECUs by establishing at least two logical channels for transmitting data between the vehicle diagnostic device and the ECU in accordance with at least two first instructions. Through the at least two logical channels, the vehicle diagnostic device can simultaneously access at least two ECUs, improving diagnostic efficiency.
可选的,在装置700的某些实施例中,逻辑通道建立模块702具体用于:Optionally, in some embodiments of the apparatus 700, the logical channel establishing module 702 is specifically configured to:
根据所述至少2个第一指令,在所述VCI的各软件层上建立通道元素;其中,所述各软件层上的通道元素用于与相邻的软件层进行通信,以建立所述至少2个逻辑通道。Establishing channel elements on each software layer of the VCI according to the at least two first instructions; wherein channel elements on the software layers are used to communicate with adjacent software layers to establish the at least 2 logical channels.
可选的,在装置700的某些实施例中,请参照图8,逻辑通道建立模块702包括:Optionally, in some embodiments of the apparatus 700, referring to FIG. 8, the logical channel establishing module 702 includes:
第一逻辑通道建立子模块7021,用于根据所述至少2个第一指令,在实时操作***层上建立至少2个线程,所述第一指令与所述线程一一对应。The first logical channel establishing sub-module 7021 is configured to establish at least two threads on the real-time operating system layer according to the at least two first instructions, where the first instruction corresponds to the thread one-to-one.
可选的,在装置700的某些实施例中,请参照图8,装置700还包括:Optionally, in some embodiments of the device 700, referring to FIG. 8, the device 700 further includes:
主线程建立模块703,用于在所述实时操作***层上建立主线程,所述主线程用于管理所述至少2个线程。The main thread establishing module 703 is configured to establish a main thread on the real-time operating system layer, where the main thread is used to manage the at least two threads.
可选的,在装置700的某些实施例中,请参照图8,逻辑通道建立模块702包括:Optionally, in some embodiments of the apparatus 700, referring to FIG. 8, the logical channel establishing module 702 includes:
第二逻辑通道建立子模块7022,用于根据所述至少2个第一指令中各自的协议类型,在协议栈层建立至少2个协议对象,所述第一指令与所述协议对象一一对应。a second logical channel establishing sub-module 7022, configured to establish at least two protocol objects in the protocol stack layer according to respective protocol types in the at least two first instructions, where the first instruction corresponds to the protocol object one-to-one .
可选的,在装置700的某些实施例中,请参照图8,逻辑通道建立模块702包括:Optionally, in some embodiments of the apparatus 700, referring to FIG. 8, the logical channel establishing module 702 includes:
第三逻辑通道建立子模块7023,用于根据所述至少2个第一指令中各自的总线类型和/或管脚信息,在硬件驱动层建立至少1个总线驱动对象。The third logical channel establishing sub-module 7023 is configured to establish at least one bus driving object in the hardware driver layer according to the respective bus type and/or pin information in the at least two first instructions.
可选的,在装置700的某些实施例中,第三逻辑通道建立子模块7023具体用于:Optionally, in some embodiments of the apparatus 700, the third logical channel establishing submodule 7023 is specifically configured to:
若所述至少2个第一指令中存在总线类型和管脚信息均相同的第一指令,则在所述硬件驱动层为总线类型和管脚信息均相同的第一指令建立一个总线驱动对象;If there is a first instruction in which the bus type and the pin information are the same in the at least two first instructions, establishing, by the hardware driver layer, a bus driving object for the first instruction in which the bus type and the pin information are the same;
若所述至少2个第一指令中各个第一指令的总线类型均不相同,或者各个第一指令的管脚信息均不相同,则在所述硬件驱动层建立至少2个总线驱动对象,所述第一指令与所述总线驱动对象一一对应。If the bus types of the first instructions in the at least two first instructions are different, or the pin information of each first instruction is different, at least two bus driving objects are established in the hardware driver layer. The first instruction is in one-to-one correspondence with the bus drive object.
可选的,在装置700的某些实施例中,第一指令接收模块701具体用于:Optionally, in some embodiments of the apparatus 700, the first instruction receiving module 701 is specifically configured to:
通过异步通讯层同时接收所述交通工具诊断设备发送的所述至少2个第一指令。The at least two first instructions sent by the vehicle diagnostic device are simultaneously received by the asynchronous communication layer.
可选的,在装置700的其他实施例中,装置700还包括:Optionally, in other embodiments of the apparatus 700, the apparatus 700 further includes:
第二指令接收模块704,用于接收所述交通工具诊断设备发送的至少2个第二指令,所述第二指令包括数据以及通道标识;a second instruction receiving module 704, configured to receive at least two second instructions sent by the vehicle diagnostic device, where the second instruction includes data and a channel identifier;
逻辑通道确定模块705,用于根据所述至少2个第二指令中各自的通道标 识,确定至少2个逻辑通道,所述第二指令与所述逻辑通道一一对应;The logical channel determining module 705 is configured to determine at least two logical channels according to respective channel identifiers of the at least two second instructions, where the second instructions are in one-to-one correspondence with the logical channels;
第一数据发送模块706,用于通过所述至少2个逻辑通道,将所述至少2个第二指令中的数据发送至所述至少2个逻辑通道各自对应的ECU。The first data sending module 706 is configured to send, by using the at least two logical channels, data in the at least two second instructions to an ECU corresponding to each of the at least two logical channels.
可选的,在装置700的其他实施例中,装置700还包括:Optionally, in other embodiments of the apparatus 700, the apparatus 700 further includes:
数据接收模块707,用于接收至少2个ECU各自发送的数据;The data receiving module 707 is configured to receive data sent by each of the at least two ECUs;
第二数据发送模块708,用于通过至少2个逻辑通道,将所述数据发送至所述交通工具诊断设备;其中,所述ECU与所述逻辑通道一一对应。The second data sending module 708 is configured to send the data to the vehicle diagnostic device by using at least two logical channels; wherein the ECU is in one-to-one correspondence with the logical channel.
需要说明的是,上述逻辑通道建立装置可执行本申请实施例所提供的逻辑通道建立方法,具备执行逻辑通道建立方法相应的功能模块和有益效果。未在装置实施例中详尽描述的技术细节,可参见本申请实施例所提供的逻辑通道建立方法。It should be noted that the foregoing logical channel establishing apparatus may perform the logical channel establishing method provided by the embodiment of the present application, and has the corresponding functional modules and beneficial effects of executing the logical channel establishing method. For the technical details that are not described in detail in the device embodiments, refer to the logic channel establishment method provided by the embodiment of the present application.
图10是本发明实施例提供的交通工具通信接口VCI10的硬件结构示意图,如图10所示,交通工具通信接口VCI10包括:FIG. 10 is a schematic diagram showing the hardware structure of a vehicle communication interface VCI10 according to an embodiment of the present invention. As shown in FIG. 10, the vehicle communication interface VCI10 includes:
一个或多个处理器11以及存储器12,图10中以一个处理器11为例。处理器11和存储器12可以通过总线或者其他方式连接,图10中以总线连接为例。One or more processors 11 and memory 12, one processor 11 is taken as an example in FIG. The processor 11 and the memory 12 can be connected by a bus or other means, and the bus connection is taken as an example in FIG.
存储器12作为一种非易失性计算机可读存储介质,可用于存储非易失性软件程序、非易失性计算机可执行程序以及模块,如本发明实施例中的逻辑通道建立方法对应的计算机可执行程序的程序指令/模块(例如,附图7所示的第一指令接收模块701和逻辑通道建立模块702)。处理器11通过运行存储在存储器12中的非易失性软件程序、指令以及模块,从而执行交通工具通信接口VCI10的各种功能应用以及数据处理,即实现上述方法实施例的逻辑通道建立方法。The memory 12 is a non-volatile computer readable storage medium, and can be used for storing a non-volatile software program, a non-volatile computer executable program, and a module, such as a computer corresponding to the logical channel establishment method in the embodiment of the present invention. The program instructions/modules of the executable program (for example, the first instruction receiving module 701 and the logical channel establishing module 702 shown in FIG. 7). The processor 11 executes various functional applications and data processing of the vehicle communication interface VCI 10 by executing non-volatile software programs, instructions, and modules stored in the memory 12, that is, implementing the logical channel establishment method of the above method embodiments.
存储器12可以包括存储程序区和存储数据区,其中,存储程序区可存储操作***、至少一个功能所需要的应用程序、上述软件架构等;存储数据区可存储根据交通工具通信接口VCI10使用所创建的数据等。此外,存储器12可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他非易失性固态存储器件。在一些实施例中,存储器12可选包括相对于处理器11远程设置的存储器,这些远程存储器可以通过网络连接至交通工具通信接口VCI10。上述网络的实例包括但不限于互联网、企业内部网、局域网、移动通信网及其组合。The memory 12 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application required for at least one function, the above software architecture, and the like; the storage data area may be stored according to the use of the vehicle communication interface VCI10. Data, etc. Further, the memory 12 may include a high speed random access memory, and may also include a nonvolatile memory such as at least one magnetic disk storage device, flash memory device, or other nonvolatile solid state storage device. In some embodiments, memory 12 may optionally include memory remotely located relative to processor 11 that may be coupled to vehicle communication interface VCI 10 via a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.
所述一个或者多个单元存储在所述存储器12中,当被所述一个或者多个处理器11执行时,执行上述任意方法实施例中的逻辑通道建立方法,例如,执行以上描述的图3中的方法步骤101-102,图5中的方法步骤103-105,图6中的方法步骤106-107,实现图7所示的模块701-702、图8中的模块701-703、子模块7021-7023、图9中的模块701-708、子模块7021-7023的功能。The one or more units are stored in the memory 12, and when executed by the one or more processors 11, performing a logical channel establishment method in any of the above method embodiments, for example, performing FIG. 3 described above Method steps 101-102, method steps 103-105 in FIG. 5, method steps 106-107 in FIG. 6, implementing modules 701-702 shown in FIG. 7, modules 701-703 in FIG. 8, submodules 7021-7023, the functions of modules 701-708, sub-modules 7021-7023 in FIG.
上述交通工具通信接口VCI10可执行本发明实施例所提供的逻辑通道建 立方法,具备执行方法相应的功能模块和有益效果。未在交通工具通信接口VCI10实施例中详尽描述的技术细节,可参见本发明实施例所提供的方法。The above-mentioned vehicle communication interface VCI10 can execute the logic channel establishment method provided by the embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method. For technical details that are not described in detail in the vehicle communication interface VCI 10 embodiment, reference may be made to the method provided by the embodiments of the present invention.
本发明实施例还提供了一种非易失性计算机可读存储介质,所述计算机可读存储介质存储有计算机可执行指令,该计算机可执行指令被一个或多个处理器执行,例如,执行上述任意方法实施例中的逻辑通道建立方法,例如,执行以上描述的图3中的方法步骤101-102,图5中的方法步骤103-105,图6中的方法步骤106-107,实现图7所示的模块701-702、图8中的模块701-703、子模块7021-7023、图9中的模块701-708、子模块7021-7023的功能。Embodiments of the present invention also provide a non-transitory computer readable storage medium storing computer executable instructions that are executed by one or more processors, for example, The logical channel establishing method in any of the foregoing method embodiments, for example, performing the method steps 101-102 in FIG. 3 described above, the method steps 103-105 in FIG. 5, and the method steps 106-107 in FIG. The functions of the modules 701-702 shown in FIG. 7, the modules 701-703 in FIG. 8, the sub-modules 7021-7023, the modules 701-708 in FIG. 9, and the sub-modules 7021-7023.
以上所描述的装置实施例仅仅是示意性的,其中所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目的。The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separate, and the components displayed as units may or may not be physical units, ie may be located A place, or it can be distributed to multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the embodiment.
通过以上的实施例的描述,本领域普通技术人员可以清楚地了解到各实施例可借助软件加通用硬件平台的方式来实现,当然也可以通过硬件。本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程是可以通过计算机程序来指令相关的硬件来完成,所述的程序可存储于一计算机可读取存储介质中,该程序在执行时,可包括如上述各方法的实施例的流程。其中,所述的存储介质可为磁碟、光盘、只读存储记忆体(Read-Only Memory,ROM)或随机存储记忆体(RandomAccessMemory,RAM)等。Through the description of the above embodiments, those skilled in the art can clearly understand that the embodiments can be implemented by means of software plus a general hardware platform, and of course, by hardware. A person skilled in the art can understand that all or part of the process of implementing the above embodiments can be completed by a computer program to instruct related hardware, and the program can be stored in a computer readable storage medium. When executed, the flow of an embodiment of the methods as described above may be included. The storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM).
最后应说明的是:以上实施例仅用以说明本发明的技术方案,而非对其限制;在本发明的思路下,以上实施例或者不同实施例中的技术特征之间也可以进行组合,步骤可以以任意顺序实现,并存在如上所述的本发明的不同方面的许多其它变化,为了简明,它们没有在细节中提供;尽管参照前述实施例对本发明进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本发明各实施例技术方案的范围。Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and are not limited thereto; in the idea of the present invention, the technical features in the above embodiments or different embodiments may also be combined. The steps may be carried out in any order, and there are many other variations of the various aspects of the invention as described above, which are not provided in the details for the sake of brevity; although the invention has been described in detail with reference to the foregoing embodiments, It should be understood by those skilled in the art that the technical solutions described in the foregoing embodiments may be modified or equivalently substituted for some of the technical features; and the modifications or substitutions do not deviate from the embodiments of the present invention. The scope of the technical solution.

Claims (22)

  1. 一种逻辑通道的建立方法,应用于交通工具通信接口VCI,其特征在于,所述方法包括:A method for establishing a logical channel, which is applied to a vehicle communication interface VCI, wherein the method comprises:
    接收交通工具诊断设备发送的至少2个第一指令,所述第一指令用于指示所述交通工具诊断设备与交通工具的电子控制单元ECU建立连接;Receiving at least two first instructions sent by the vehicle diagnostic device, the first instructions being used to instruct the vehicle diagnostic device to establish a connection with an electronic control unit ECU of the vehicle;
    根据所述至少2个第一指令,建立至少2个逻辑通道,所述第一指令与所述逻辑通道一一对应,所述逻辑通道用于传输所述交通工具诊断设备与所述ECU之间的数据。Establishing at least two logical channels according to the at least two first instructions, wherein the first instruction is in one-to-one correspondence with the logical channel, and the logical channel is configured to transmit between the vehicle diagnostic device and the ECU The data.
  2. 根据权利要求1所述的方法,其特征在于,所述根据所述至少2个第一指令,建立至少2个逻辑通道,包括:The method according to claim 1, wherein the establishing at least two logical channels according to the at least two first instructions comprises:
    根据所述至少2个第一指令,在所述VCI的各软件层上建立通道元素;其中,所述各软件层上的通道元素用于与相邻的软件层进行通信,以建立所述至少2个逻辑通道。Establishing channel elements on each software layer of the VCI according to the at least two first instructions; wherein channel elements on the software layers are used to communicate with adjacent software layers to establish the at least 2 logical channels.
  3. 根据权利要求2所述的方法,其特征在于,所述根据所述至少2个第一指令,在所述VCI的各软件层上建立通道元素,包括:The method according to claim 2, wherein the establishing channel elements on each software layer of the VCI according to the at least two first instructions comprises:
    根据所述至少2个第一指令,在操作***层上建立至少2个线程,所述第一指令与所述线程一一对应。And establishing at least two threads on the operating system layer according to the at least two first instructions, where the first instruction corresponds to the thread one-to-one.
  4. 根据权利要求3所述的方法,其特征在于,所述方法还包括:The method of claim 3, wherein the method further comprises:
    在所述操作***层上建立主线程,所述主线程用于管理所述至少2个线程。A main thread is established on the operating system layer, and the main thread is used to manage the at least two threads.
  5. 根据权利要求2所述的方法,其特征在于,所述根据所述至少2个第一指令,在所述VCI的各软件层上建立通道元素,包括:The method according to claim 2, wherein the establishing channel elements on each software layer of the VCI according to the at least two first instructions comprises:
    根据所述至少2个第一指令中各自的协议类型,在协议栈层建立至少2个协议对象,所述第一指令与所述协议对象一一对应。And establishing at least two protocol objects in the protocol stack layer according to respective protocol types in the at least two first instructions, where the first instruction corresponds to the protocol object one-to-one.
  6. 根据权利要求2所述的方法,其特征在于,所述根据所述至少2个第一指令,在所述VCI的各软件层上建立通道元素,包括:The method according to claim 2, wherein the establishing channel elements on each software layer of the VCI according to the at least two first instructions comprises:
    根据所述至少2个第一指令中各自的总线类型和/或管脚信息,在硬件驱动层建立至少1个总线驱动对象。And establishing at least one bus drive object in the hardware driver layer according to respective bus type and/or pin information in the at least two first instructions.
  7. 根据权利要求6所述的方法,其特征在于,所述根据所述至少2个第一指令中各自的总线类型和/或管脚信息,在硬件驱动层建立至少1个总线驱动对象,包括:The method according to claim 6, wherein the establishing at least one bus drive object in the hardware driver layer according to the respective bus type and/or pin information of the at least two first instructions comprises:
    若所述至少2个第一指令中存在总线类型和管脚信息均相同的第一指令,则在所述硬件驱动层为总线类型和管脚信息均相同的第一指令建立一个总线驱动对象;If there is a first instruction in which the bus type and the pin information are the same in the at least two first instructions, establishing, by the hardware driver layer, a bus driving object for the first instruction in which the bus type and the pin information are the same;
    若所述至少2个第一指令中各个第一指令的总线类型均不相同,或者各个第一指令的管脚信息均不相同,则在所述硬件驱动层建立至少2个总线驱动对象,所述第一指令与所述总线驱动对象一一对应。If the bus types of the first instructions in the at least two first instructions are different, or the pin information of each first instruction is different, at least two bus driving objects are established in the hardware driver layer. The first instruction is in one-to-one correspondence with the bus drive object.
  8. 根据权利要求1-7任一项所述的方法,其特征在于,所述接收所述交通工具诊断设备发送的至少2个第一指令,包括:The method according to any one of claims 1 to 7, wherein the receiving the at least two first instructions sent by the vehicle diagnostic device comprises:
    通过异步通讯层同时接收所述交通工具诊断设备发送的所述至少2个第一指令。The at least two first instructions sent by the vehicle diagnostic device are simultaneously received by the asynchronous communication layer.
  9. 根据权利要求1-8任一项所述的方法,其特征在于,所述方法还包括:The method of any of claims 1-8, wherein the method further comprises:
    接收所述交通工具诊断设备发送的至少2个第二指令,所述第二指令包括数据以及通道标识;Receiving at least two second instructions sent by the vehicle diagnostic device, the second instructions including data and channel identifiers;
    根据所述至少2个第二指令中各自的通道标识,确定至少2个逻辑通道,所述第二指令与所述逻辑通道一一对应;Determining at least two logical channels according to respective channel identifiers of the at least two second instructions, wherein the second instructions are in one-to-one correspondence with the logical channels;
    通过所述至少2个逻辑通道,将所述至少2个第二指令中的数据发送至所述至少2个逻辑通道各自对应的ECU。And transmitting, by the at least two logical channels, data in the at least two second instructions to an ECU corresponding to each of the at least two logical channels.
  10. 根据权利要求1-9任一项所述的方法,其特征在于,所述方法还包括:The method according to any one of claims 1 to 9, wherein the method further comprises:
    接收至少2个ECU各自发送的数据;Receiving data transmitted by at least two ECUs;
    通过至少2个逻辑通道,将所述数据发送至所述交通工具诊断设备;其中,所述ECU与所述逻辑通道一一对应。The data is transmitted to the vehicle diagnostic device via at least 2 logical channels; wherein the ECU is in one-to-one correspondence with the logical channel.
  11. 一种逻辑通道的建立装置,应用于交通工具通信接口VCI,其特征在于,所述装置包括:A logic channel establishing device is applied to a vehicle communication interface VCI, wherein the device comprises:
    第一指令接收模块,用于接收交通工具诊断设备发送的至少2个第一指 令,所述第一指令用于指示所述交通工具诊断设备与交通工具的电子控制单元ECU建立连接;a first instruction receiving module, configured to receive at least two first instructions sent by the vehicle diagnostic device, the first instruction being used to instruct the vehicle diagnostic device to establish a connection with an electronic control unit ECU of the vehicle;
    逻辑通道建立模块,用于根据所述至少2个第一指令,建立至少2个逻辑通道,所述第一指令与所述逻辑通道一一对应,所述逻辑通道用于传输所述交通工具诊断设备与所述ECU之间的数据。a logic channel establishing module, configured to establish at least two logical channels according to the at least two first instructions, where the first instruction is in one-to-one correspondence with the logical channel, and the logical channel is used to transmit the vehicle diagnosis Data between the device and the ECU.
  12. 根据权利要求11所述的装置,其特征在于,所述逻辑通道建立模块具体用于:The device according to claim 11, wherein the logical channel establishing module is specifically configured to:
    根据所述至少2个第一指令,在所述VCI的各软件层上建立通道元素;其中,所述各软件层上的通道元素用于与相邻的软件层进行通信,以建立所述至少2个逻辑通道。Establishing channel elements on each software layer of the VCI according to the at least two first instructions; wherein channel elements on the software layers are used to communicate with adjacent software layers to establish the at least 2 logical channels.
  13. 根据权利要求12所述的装置,其特征在于,所述逻辑通道建立模块包括:The device according to claim 12, wherein the logical channel establishing module comprises:
    第一逻辑通道建立子模块,用于根据所述至少2个第一指令,在实时操作***层上建立至少2个线程,所述第一指令与所述线程一一对应。The first logical channel establishing submodule is configured to establish at least two threads on the real-time operating system layer according to the at least two first instructions, where the first instruction corresponds to the thread one-to-one.
  14. 根据权利要求13所述的装置,其特征在于,所述装置还包括:The device according to claim 13, wherein the device further comprises:
    主线程建立模块,用于在所述实时操作***层上建立主线程,所述主线程用于管理所述至少2个线程。And a main thread establishing module, configured to establish a main thread on the real-time operating system layer, where the main thread is used to manage the at least two threads.
  15. 根据权利要求12所述的装置,其特征在于,所述逻辑通道建立模块包括:The device according to claim 12, wherein the logical channel establishing module comprises:
    第二逻辑通道建立子模块,用于根据所述至少2个第一指令中各自的协议类型,在协议栈层建立至少2个协议对象,所述第一指令与所述协议对象一一对应。And a second logical channel establishing submodule, configured to establish at least two protocol objects in the protocol stack layer according to respective protocol types in the at least two first instructions, where the first instruction corresponds to the protocol object one-to-one.
  16. 根据权利要求12所述的装置,其特征在于,所述逻辑通道建立模块包括:The device according to claim 12, wherein the logical channel establishing module comprises:
    第三逻辑通道建立子模块,用于根据所述至少2个第一指令中各自的总线类型和/或管脚信息,在硬件驱动层建立至少1个总线驱动对象。The third logical channel establishing submodule is configured to establish at least one bus driving object in the hardware driver layer according to the respective bus type and/or pin information in the at least two first instructions.
  17. 根据权利要求16所述的装置,其特征在于,所述第三逻辑通道建立子模块具体用于:The apparatus according to claim 16, wherein the third logical channel establishing submodule is specifically configured to:
    若所述至少2个第一指令中存在总线类型和管脚信息均相同的第一指令,则在所述硬件驱动层为总线类型和管脚信息均相同的第一指令建立一个总线驱动对象;If there is a first instruction in which the bus type and the pin information are the same in the at least two first instructions, establishing, by the hardware driver layer, a bus driving object for the first instruction in which the bus type and the pin information are the same;
    若所述至少2个第一指令中各个第一指令的总线类型均不相同,或者各个第一指令的管脚信息均不相同,则在所述硬件驱动层建立至少2个总线驱动对象,所述第一指令与所述总线驱动对象一一对应。If the bus types of the first instructions in the at least two first instructions are different, or the pin information of each first instruction is different, at least two bus driving objects are established in the hardware driver layer. The first instruction is in one-to-one correspondence with the bus drive object.
  18. 根据权利要求11-17任一项所述的装置,其特征在于,所述第一指令接收模块具体用于:The device according to any one of claims 11-17, wherein the first instruction receiving module is specifically configured to:
    通过异步通讯层同时接收所述交通工具诊断设备发送的所述至少2个第一指令。The at least two first instructions sent by the vehicle diagnostic device are simultaneously received by the asynchronous communication layer.
  19. 根据权利要求11-18任一项所述的装置,其特征在于,所述装置还包括:The device according to any one of claims 11 to 18, wherein the device further comprises:
    第二指令接收模块,用于接收所述交通工具诊断设备发送的至少2个第二指令,所述第二指令包括数据以及通道标识;a second instruction receiving module, configured to receive at least two second instructions sent by the vehicle diagnostic device, where the second instruction includes data and a channel identifier;
    逻辑通道确定模块,用于根据所述至少2个第二指令中各自的通道标识,确定至少2个逻辑通道,所述第二指令与所述逻辑通道一一对应;a logic channel determining module, configured to determine at least two logical channels according to respective channel identifiers of the at least two second instructions, where the second instruction corresponds to the logical channel one-to-one;
    第一数据发送模块,用于通过所述至少2个逻辑通道,将所述至少2个第二指令中的数据发送至所述至少2个逻辑通道各自对应的ECU。And a first data sending module, configured to send, by using the at least two logical channels, data in the at least two second instructions to an ECU corresponding to each of the at least two logical channels.
  20. 根据权利要求11-19任一项所述的装置,其特征在于,所述装置还包括:The device according to any one of claims 11 to 19, wherein the device further comprises:
    数据接收模块,用于接收至少2个ECU各自发送的数据;a data receiving module, configured to receive data sent by each of at least two ECUs;
    第二数据发送模块,用于通过至少2个逻辑通道,将所述数据发送至所述交通工具诊断设备;其中,所述ECU与所述逻辑通道一一对应。And a second data sending module, configured to send the data to the vehicle diagnostic device through at least two logical channels; wherein the ECU is in one-to-one correspondence with the logical channel.
  21. 一种交通工具通信接口VCI,其特征在于,包括:A vehicle communication interface VCI, comprising:
    至少一个处理器;以及,At least one processor; and,
    与所述至少一个处理器通信连接的存储器;其中,a memory communicatively coupled to the at least one processor; wherein
    所述存储器存储有可被所述至少一个处理器执行的指令;The memory stores instructions executable by the at least one processor;
    所述至少一个处理器用于调用所述指令,以执行权利要求1-10任一项所 述的方法。The at least one processor is operative to invoke the instructions to perform the method of any of claims 1-10.
  22. 一种非易失性计算机可读存储介质,其特征在于,所述非易失性计算机可读存储介质存储有计算机可执行指令,当所述计算机可执行指令被交通工具通信接口VCI调用时,使所述交通工具通信接口VCI执行权利要求1-10任一项所述的方法。A non-transitory computer readable storage medium, wherein the non-transitory computer readable storage medium stores computer-executable instructions, when the computer-executable instructions are invoked by a vehicle communication interface VCI, The vehicle communication interface VCI is caused to perform the method of any of claims 1-10.
PCT/CN2019/077125 2018-03-16 2019-03-06 Method and device for establishing a logical channel, and vehicle communication interface (vci) WO2019174504A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201810217879.3A CN108536121B (en) 2018-03-16 2018-03-16 Method and device for establishing logical channel and vehicle communication interface VCI
CN201810217879.3 2018-03-16

Publications (1)

Publication Number Publication Date
WO2019174504A1 true WO2019174504A1 (en) 2019-09-19

Family

ID=63483836

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/077125 WO2019174504A1 (en) 2018-03-16 2019-03-06 Method and device for establishing a logical channel, and vehicle communication interface (vci)

Country Status (2)

Country Link
CN (1) CN108536121B (en)
WO (1) WO2019174504A1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112600711A (en) * 2020-12-21 2021-04-02 上海星融汽车科技有限公司 Real vehicle bus data remote cloning system and method
CN113900428A (en) * 2021-10-25 2022-01-07 深圳市元征科技股份有限公司 Vehicle diagnosis method, diagnosis node, device, and storage medium

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108536121B (en) * 2018-03-16 2021-04-23 深圳市道通科技股份有限公司 Method and device for establishing logical channel and vehicle communication interface VCI
CN109725921B (en) * 2019-01-07 2021-06-08 深圳市道通科技股份有限公司 Method and device for updating firmware of VCI (virtual vehicle interface) equipment and automobile fault diagnosis instrument
CN110850841A (en) * 2019-10-30 2020-02-28 深圳市元征科技股份有限公司 Fault diagnosis method and related device
CN112927392A (en) * 2021-01-19 2021-06-08 深圳市元征科技股份有限公司 Communication method, vehicle communication interface device and readable storage medium
CN113194550B (en) * 2021-04-30 2022-12-02 深圳市道通科技股份有限公司 Data channel construction method, server and data cluster system
CN113791605B (en) * 2021-09-13 2023-10-27 一汽解放汽车有限公司 Test method, device, equipment and storage medium
CN114979239A (en) * 2022-05-24 2022-08-30 深圳市元征科技股份有限公司 Remote diagnosis method, device and related equipment
CN115733871A (en) * 2022-11-21 2023-03-03 深圳市道通科技股份有限公司 Communication interaction method, device, equipment and storage medium
CN116088488B (en) * 2023-04-12 2023-06-23 深圳市星卡科技股份有限公司 Multi-channel-based communication method and system and electronic equipment

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100262334A1 (en) * 2009-04-13 2010-10-14 Honda Motor Co., Ltd. Rewriting system for a vehicle
CN103869800A (en) * 2012-12-07 2014-06-18 北汽福田汽车股份有限公司 Vehicle diagnosis device
CN104483960A (en) * 2014-11-10 2015-04-01 深圳市元征科技股份有限公司 Automobile diagnosis communication module data transceiving parallel processing method
CN105068528A (en) * 2015-07-10 2015-11-18 深圳市元征科技股份有限公司 Communication device of automobile diagnosis system
CN105389235A (en) * 2015-10-28 2016-03-09 致象尔微电子科技(上海)有限公司 Heterogeneous multi-core debug system and method
CN107168296A (en) * 2017-06-30 2017-09-15 东南(福建)汽车工业有限公司 A kind of automotive diagnostic installation software systems
CN108536121A (en) * 2018-03-16 2018-09-14 深圳市道通科技股份有限公司 Method for building up, device and the vehicle communication interface VCI of logical channel

Family Cites Families (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4082306B2 (en) * 2003-08-08 2008-04-30 三菱ふそうトラック・バス株式会社 Fault diagnosis device
JP5298800B2 (en) * 2008-11-19 2013-09-25 パナソニック株式会社 Power storage device
CN202077063U (en) * 2010-12-13 2011-12-14 斯必克机电产品(苏州)有限公司 Automobile network diagnostic system
CN102073319B (en) * 2011-01-25 2013-02-27 武汉理工大学 Multifunctional comprehensive type electric control automobile fault diagnosis system
CN103576668A (en) * 2012-07-26 2014-02-12 博世汽车检测设备(深圳)有限公司 Method and device for vehicle diagnosis
EP2741452A1 (en) * 2012-12-10 2014-06-11 Robert Bosch Gmbh Method for data transmission among ECUs and/or measuring devices
CN103257648B (en) * 2013-04-11 2016-12-28 北京经纬恒润科技有限公司 Automobile calibration system
US9477628B2 (en) * 2013-09-28 2016-10-25 Intel Corporation Collective communications apparatus and method for parallel systems
CN104516736A (en) * 2013-10-08 2015-04-15 上海通用汽车有限公司 Development platform of after-sale diagnosis system
US9082242B2 (en) * 2013-10-11 2015-07-14 GM Global Technology Operations LLC Vehicle network health assessment
FR3013458B1 (en) * 2013-11-21 2015-12-04 Peugeot Citroen Automobiles Sa VIRTUAL COMMUNICATION INTERFACE FOR DIAGNOSTIC OF MOTOR VEHICLE
CN104932480A (en) * 2015-04-29 2015-09-23 深圳市元征软件开发有限公司 Automobile diagnostic system design method and apparatus
CN106131111A (en) * 2016-06-14 2016-11-16 重庆邮电大学 A kind of improvement 4S service system towards car networking
US20180295011A1 (en) * 2017-04-05 2018-10-11 GM Global Technology Operations LLC Architectures and methods for management of in-vehicle networked controllers and devices
CN207020527U (en) * 2017-05-17 2018-02-16 深圳市正德友邦科技有限公司 A kind of auto communication interface

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100262334A1 (en) * 2009-04-13 2010-10-14 Honda Motor Co., Ltd. Rewriting system for a vehicle
CN103869800A (en) * 2012-12-07 2014-06-18 北汽福田汽车股份有限公司 Vehicle diagnosis device
CN104483960A (en) * 2014-11-10 2015-04-01 深圳市元征科技股份有限公司 Automobile diagnosis communication module data transceiving parallel processing method
CN105068528A (en) * 2015-07-10 2015-11-18 深圳市元征科技股份有限公司 Communication device of automobile diagnosis system
CN105389235A (en) * 2015-10-28 2016-03-09 致象尔微电子科技(上海)有限公司 Heterogeneous multi-core debug system and method
CN107168296A (en) * 2017-06-30 2017-09-15 东南(福建)汽车工业有限公司 A kind of automotive diagnostic installation software systems
CN108536121A (en) * 2018-03-16 2018-09-14 深圳市道通科技股份有限公司 Method for building up, device and the vehicle communication interface VCI of logical channel

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112600711A (en) * 2020-12-21 2021-04-02 上海星融汽车科技有限公司 Real vehicle bus data remote cloning system and method
CN113900428A (en) * 2021-10-25 2022-01-07 深圳市元征科技股份有限公司 Vehicle diagnosis method, diagnosis node, device, and storage medium

Also Published As

Publication number Publication date
CN108536121A (en) 2018-09-14
CN108536121B (en) 2021-04-23

Similar Documents

Publication Publication Date Title
WO2019174504A1 (en) Method and device for establishing a logical channel, and vehicle communication interface (vci)
WO2019192343A1 (en) Vehicle diagnosis method, related device and system
WO2019057188A1 (en) Remote diagnosis method and apparatus for vehicle, mobile terminal, electronic device and server
WO2020125591A1 (en) Vehicle diagnosis method, management server and diagnosis server
WO2019141121A1 (en) Vehicle diagnosis instrument and system operating method thereof, vehicle diagnosis system
WO2020088278A1 (en) Communication method and apparatus, and related devices
US20190349875A1 (en) Data transmission control method and apparatus, and terminal
CN113406946B (en) Automobile diagnosis method and device and automobile diagnosis equipment
WO2021052474A1 (en) Method and apparatus for establishing communication between automobile diagnostic device and vehicle, and automobile communication interface device
CN112684777A (en) Vehicle remote diagnosis system based on cloud platform
US8996248B2 (en) Virtual sensor network system and method for convergence of heterogeneous sensors
CN110473407A (en) A kind of vehicle admission monitoring method, server and system
CN109116832A (en) Vehicle diagnostic data wireless communication method
CN114815770A (en) Vehicle remote diagnosis method, device, server and storage medium
CN116614459B (en) Link aggregation group management method and device based on Ethernet RDMA protocol
CN113505056A (en) Vehicle diagnosis method, system, device and storage medium
US20180217953A1 (en) Method and apparatus for distributed computing using controller area network protocols
WO2022268100A1 (en) Diagnosis system and method for vehicle central controller
CN116319499A (en) Diagnostic method and device for vehicle, electronic equipment and storage medium
CN115167378A (en) Vehicle diagnosis mode control method, system, equipment and storage medium
CN114666363A (en) Information transmission method and device, electronic equipment, storage medium and product
WO2024026593A1 (en) Vehicle cooperative control method and related device
WO2024026592A1 (en) Data storage method and related apparatus
WO2021073501A1 (en) Resource configuration method, apparatus, and system for in-vehicle service slices
US20220335753A1 (en) Smart control device for vehicle factory and vehicle control method using the same

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19767309

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 19767309

Country of ref document: EP

Kind code of ref document: A1