KR100773076B1 - Method for transmitting and receiving dynamic can communication data - Google Patents
Method for transmitting and receiving dynamic can communication data Download PDFInfo
- Publication number
- KR100773076B1 KR100773076B1 KR1020060062541A KR20060062541A KR100773076B1 KR 100773076 B1 KR100773076 B1 KR 100773076B1 KR 1020060062541 A KR1020060062541 A KR 1020060062541A KR 20060062541 A KR20060062541 A KR 20060062541A KR 100773076 B1 KR100773076 B1 KR 100773076B1
- Authority
- KR
- South Korea
- Prior art keywords
- data
- message
- active
- compressed message
- compressed
- Prior art date
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L12/00—Data switching networks
- H04L12/28—Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
- H04L12/40—Bus networks
- H04L12/40006—Architecture of a communication node
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L69/00—Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
- H04L69/04—Protocols for data compression, e.g. ROHC
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L12/00—Data switching networks
- H04L12/28—Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
- H04L12/40—Bus networks
- H04L2012/40208—Bus networks characterized by the use of a particular bus standard
- H04L2012/40215—Controller Area Network CAN
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L12/00—Data switching networks
- H04L12/28—Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
- H04L12/40—Bus networks
- H04L2012/40267—Bus for use in transportation systems
- H04L2012/40273—Bus for use in transportation systems the transportation system being a vehicle
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Small-Scale Networks (AREA)
- Computer Security & Cryptography (AREA)
Abstract
Description
도 1은 종래 자동차 네트워크의 CAN 통신 압축 전 메시지 구성도,1 is a configuration diagram of a message before the CAN communication compression of a conventional vehicle network,
도 2는 종래 자동차 네트워크의 CAN 통신 압축 메시지 구성도,2 is a configuration diagram of a CAN communication compression message of a conventional vehicle network;
도 3은 종래 자동차 네트워크의 CAN 통신 압축 메시지의 복원 과정도,3 is a process for restoring a CAN communication compression message of a conventional vehicle network;
도 4는 본 발명의 실시 예가 적용되는 CAN 프로토콜을 이용한 자동차의 네트워크 시스템 구성도,4 is a diagram illustrating a network system configuration of a vehicle using a CAN protocol to which an embodiment of the present invention is applied;
도 5는 본 발명의 실시 예에 따른 CAN 통신 압축 메시지 송신 처리 흐름도,5 is a flowchart illustrating a CAN communication compression message transmission process according to an embodiment of the present invention;
도 6은 종래 자동차 네트워크의 CAN 통신 압축 전 메시지 구성도,6 is a configuration diagram of a message before the CAN communication compression of a conventional vehicle network,
도 7은 본 발명의 실시 예에 따른 CAN 통신 압축 메시지 구성도,7 is a configuration diagram of a CAN communication compression message according to an embodiment of the present invention;
도 8은 본 발명의 실시 예에 따른 CAN 통신 압축 메시지 수신 처리 흐름도,8 is a flowchart illustrating a CAN communication compression message reception process according to an embodiment of the present invention;
도 9는 본 발명의 실시 예에 따른 자동차 네트워크의 CAN 통신 압축 메시지의 복원 과정도.9 is a diagram illustrating a restoration process of a CAN communication compression message of a vehicle network according to an embodiment of the present invention.
본 발명은 자동차의 네트워크 시스템에 관한 것으로, 특히 CAN 프로토콜을 이용하여 자동차내 각종 전자장치간 효율적인 네트워킹이 가능하도록 하는 자동차 네트워크에서의 능동형 CAN 통신 데이터 송/수신 방법에 관한 것이다.BACKGROUND OF THE
최근 들어 생산 및 판매되고 있는 자동차에는 ABS 시스템, 에이백 시스템, 자세 제어 시스템(TCS), 전조등 제어시스템(AFS), 순항 제어 시스템(VCC), Throttle by wire, 첨단 고안전 자동차용 전자 장비들, 텔레매틱스, 지능형 교통시스템(ITS) 등 수많은 전자 제어 장치 등의 적용되고 있으며, 자동차의 안전 및 편리 등을 위하여 이와 같은 첨단 시스템은 갈수록 더 요구되어 관련 전자 장비들이 기하 급수적으로 늘어나게 될 것이다.Recently produced and sold automobiles include ABS system, A-back system, attitude control system (TCS), headlight control system (AFS), cruise control system (VCC), Throttle by wire, advanced high safety automotive electronic equipment, A number of electronic control devices such as telematics and intelligent transportation systems (ITS) are being applied, and such advanced systems are increasingly required for the safety and convenience of automobiles, and related electronic equipments will increase exponentially.
또한, 환경 규제 등에 따라 기존의 엔진과 배터리/연료전지 등과 결합되어 출시되고 있는 하이브리드 자동차는 기존의 화석연료 자동차를 대체할 것으로 전망되며, 이와 같은 하이브리드 자동차는 휠씬 더 많은 전자 장비들을 필요로 하게 되어 하이브리드 자동차의 출현으로 자동차의 첨단 시스템 구현에 따른 관련 전자 장비들의 수는 더욱더 가속화될 것으로 예상된다.In addition, due to environmental regulations, hybrid cars, which are being combined with existing engines and batteries / fuel cells, are expected to replace conventional fossil fuel cars, and such hybrid cars require much more electronic equipment. The advent of hybrid cars is expected to accelerate the number of related electronic devices in the implementation of advanced systems in the car.
이러한 전자 장비에 있는 각 ECU의 대부분은 CAN 통신 네트워크로 연결되지만, 기존에 비해 엄청난 양의 통신 데이터 증가와 함께, 고안전을 필요로 하기 때문에 기존의 전자 장비보다 더욱더 빠른 통신 속도가 요구될 것이므로, 기존의 CAN 통신 네트워크로는 기능구현에 있어서 어려움이 예상된다.Most of each ECU in such electronic equipment is connected to the CAN communication network, but because of the enormous amount of communication data increase and high safety, it will require faster communication speed than conventional electronic equipment. Existing CAN communication networks are expected to have difficulties in implementing the functions.
이를 해결하기 위해서는 여러 개의 네트워크 라인을 증설(CAN, LIN, MOST 등)하거나 보다 높은 대역폭 및 통신 속도가 가능한 새로운 통신 프로토콜(Flexlay 등)을 개발하는 경우, 비용 증가와 더불어 복잡한 배선으로 인한 잦은 고장, 유지보수 비용이 발생하는 문제점이 있었다.In order to solve this problem, the expansion of several network lines (CAN, LIN, MOST, etc.), or the development of new communication protocols (Flexlay, etc.) that enable higher bandwidth and communication speeds, increases the cost, and frequently causes failures due to complicated wiring. There was a problem incurred maintenance costs.
이에 대한 대안으로서 기존의 대역폭을 가진 네트워크를 그대로 활용하고, 네트워크의 통신량을 최소화할 수 있으며, 그에 따른 버스의 이용률을 향상시키는 등 네트워크의 효율을 위해 능동형 CAN 통신 데이터 압축 알고리즘이 필요하게 되었다.As an alternative, active CAN communication data compression algorithms are required for network efficiency, such as utilizing existing bandwidth networks, minimizing network traffic, and improving bus utilization.
위와 같은 자동차내 전자 제어 장치들은 센서 등과 같은 센싱부와 제어기 그리고 작동부 사이에 단방향 또는 양방향으로 통신이 이루어지게 되는데, 현재 각 전자 제어 장치의 ECU들은 CAN 통신 네트워크로 연결되어 각종 제어에 필요한 메시지가 전달되고 있다.The above electronic control devices in the vehicle are one-way or two-way communication between the sensing unit, the sensor, and the operating unit such as sensors, etc. Currently, ECUs of each electronic control device are connected to the CAN communication network so that messages necessary for various control are transmitted. It is delivered.
이하 CAN 통신 네트워크에서 데이터 송수신 동작을 살펴보면, CAN 통신 데이터는 메시지 단위로 이루어져 메시지 단위로 통신을 수행하는 것으로, 전자 장비에 탑재된 각 ECU는 여러 개의 메시지를 송신할 수 있으며, 각 메시지는 우선순위 및 식별자 기능을 가지는 고유의 메시지 ID와 8 Byte 이하로 이루어진 데이터, 그 외에 통신에 필요한 46 비트(CAN 2.0A의 경우)의 ID 필드 및 제어 비트로 구성된다.Referring to the data transmission / reception operation in the CAN communication network, the CAN communication data is composed of message units to perform communication in a message unit, and each ECU mounted in the electronic equipment can transmit several messages, and each message has priority. And a unique message ID having an identifier function, data consisting of 8 bytes or less, an ID field of 46 bits (for CAN 2.0A) necessary for communication, and a control bit.
또한, 각 ECU는 원하는 메시지 ID가 통신 버스에 발생할 경우 메시지를 수신할 수 있으며, ID 번호는 낮을수록 우선순위가 높다. 이때 데이터는 1 바이트, 2 바이트,..., 8 바이트까지 바이트 단위로 데이터를 구성할 수 있으며, 메시지 내의 송수신 데이터는 허용 데이터 크기 내에서 비트 단위로 자유자재로 구성할 수 있으며, 수신측 및 송신측이 미리 정의된 데이터 구성에 따라 데이터 송수신이 가능하 게 된다.In addition, each ECU can receive a message if a desired message ID occurs on the communication bus. The lower the ID number, the higher the priority. At this time, the data can be composed in byte unit up to 1 byte, 2 byte, ..., 8 byte, and the send / receive data in the message can be configured freely in bit unit within the allowable data size. The transmitting side can transmit and receive data according to a predefined data configuration.
이에 따라 종래에는 각 전자 장비에서 메시지를 전송하고자 할때, 전송직전의 데이터(t)와 전송하고자 하는 데이터(t+Δt)와의 변화량을 비교하여, 변화량이 미리 정해진 범위내에 있을 경우 변화량만으로 구성된 데이터로 압축 메시지를 전송하고 있다. 이때 압축 메시지의 ID는 압축 전 메시지 ID에다 '1의' 값을 빼게 되며, 즉, 예를 들어 압축 전 메시지 ID가 100일 경우 압축 메시지의 ID는 99가 된다.Accordingly, when a message is to be transmitted from each electronic device, the change amount between the data t immediately before the transmission and the data to be transmitted (t + Δt) is compared. If the change amount is within a predetermined range, the data includes only the change amount. Is sending a compressed message. At this time, the ID of the compressed message is subtracted from the value of '1' from the message ID before compression. That is, if the message ID before compression is 100, the ID of the compressed message is 99.
도 1 및 도 2는 종래 CAN 데이터 압축 처리 흐름을 도시한 것으로, 도 1에서처럼 엔진 스피드(2byte), 엔진 온도(1byte), 가스 레벨(1byte), 엔진 포스(2byte), 엔진 파워(2byte)로 정의된 8byte의 데이터와, ID가 100인 메시지가 있다고 가정하기로 한다.1 and 2 show the conventional CAN data compression process flow, and as shown in FIG. 1, the engine speed (2 bytes), engine temperature (1 byte), gas level (1 byte), engine force (2 bytes), and engine power (2 bytes) Assume that there are 8 bytes of data defined and a message with an ID of 100.
그러면, 통신하는 모든 메시지는 도 2에서와 같이 데이터 변화량만을 전송하기 위한 압축 메시지가 데이터 정렬 순서 및 크기로써 미리 정의되고, 압축 메시지의 ID는 압축 전 메시지 ID에서 1을 뺀 값으로 된다.Then, as shown in FIG. 2, the compressed message for transmitting only the amount of data change is predefined as the data sorting order and size, and the ID of the compressed message is obtained by subtracting 1 from the message ID before compression.
전송 ECU에서 임의의 시간 t에서의 전송데이터와 t+Δt에서의 전송데이터의 차이인 ΔMsg를 계산한다. 즉, 예를 들어 엔진 속도 데이터의 경우, ΔES= ESt+Δt-ESt 가 된다. 시간 t에서 전송되었던 데이터는 Tx-Buf에 미리 저장되어 있으며, 시간 t+Δt에서의 데이터는 현재 새로 발생한 신규데이터이다.The transfer ECU calculates ΔMsg, which is the difference between the transmission data at any time t and the transmission data at t + Δt. That is, for example, if the engine speed data, ΔES = t + Δt is the ES -ES t. Data transmitted at time t is previously stored in Tx-Buf, and data at time t + Δt is new data newly generated.
각각의 모든 ΔMsg값이 압축 메시지에서 정의된 데이터 크기보다 작을 경우 압축 메시지를 전송하고, 한 개의 데이터라도 정의된 크기보다 클 경우 '압축 전 메시지'를 전송한다. 압축 메시지일 경우 데이터의 첫 번째 바이트는 데이터 변화량 유무를 결정하는 RFC(Reduction Flag Code)로 사용된다.If each ΔMsg value is smaller than the data size defined in the compressed message, the compressed message is transmitted. If any one data is larger than the defined size, the message before the compression is transmitted. In the case of a compressed message, the first byte of data is used as a reduction flag code (RFC) to determine the amount of data change.
RFC내의 각 비트가 '1'인 경우 Rx-Buf에 데이터 변화량인 ΔMsg를 더하여 데이터를 생성하고, '0'일 경우 데이터 변화량이 없다는 것을 의미하기 때문에 Rx-Buf에 있는 값을 그대로 사용하게 된다.If each bit in the RFC is '1', data is generated by adding the data change amount ΔMsg to Rx-Buf. If the bit is '0', it means that there is no data change amount. Therefore, the value in Rx-Buf is used as it is.
도 3은 종래 EF(Engine Force), ES(Engine Speed), GL(Gas Level), ET(Engine Temp), EP(Engine Power)의 데이터 변화량이 각각, 0, 0, +5, -4, -14로서 미리 정의된 크기보다 데이터 변화량이 작다고 가정하는 경우 압축 메시지를 전송하고, 수신측에서는 시간 t에서 수신되었던 데이터를 저장하고 있던 Rx-Buf에 ΔMsg를 더하여 시간 t+Δt에서의 새로운 데이터가 생성되는 과정을 도시한 것이다.3 shows data changes of conventional engine force (EF), engine speed (ES), gas level (GL), engine temp (ET), and engine power (EP), respectively, 0, 0, +5, -4,- If it is assumed that the amount of data change is smaller than the predefined size as 14, a compressed message is transmitted, and at the receiving side, new data at time t + Δt is generated by adding ΔMsg to Rx-Buf that was storing data received at time t. The process is illustrated.
위 도 3에서 보여지는 바와 같이, EF와 ES는 데이터 변화량이 없으며, GL, ET, EP는 정의된 제한범위를 벗어나지 않았다고 가정하는 경우 압축 메시지의 구성 과정을 나타낸다. RFC내의 비트값을 보면, EF, ES는 0이므로 Rx-Buf 값을 그대로 사용하고, GL, ET, EP는 'Rx-Buf + ΔMsg'를 계산하여 신규 데이터를 생성하게 된다.As shown in FIG. 3, EF and ES have no data change amount, and GL, ET, and EP represent a process of constructing a compressed message when it is assumed that the data does not fall within a defined limit. In the bit value of the RFC, since EF and ES are 0, the Rx-Buf value is used as it is, and GL, ET, and EP calculate 'Rx-Buf + ΔMsg' to generate new data.
그러나, 위와 같은 종래 CAN 데이터의 압축 과정에서는 도 3에서와 같이 엔진 포스와 엔진 속도는 데이터 변화량이 없음에도 불구하고, 도 2에서와 같은 고정된 압축메시지에 각각 8비트의 크기를 가지고 전송되는 것을 알 수 있는데,However, in the compression process of the conventional CAN data as described above, although the engine force and the engine speed are transmitted as shown in FIG. 3 with 8 bit size, respectively, in the fixed compression message as shown in FIG. I can see that
이때 RFC에 필요한 비트는 5개 데이터의 변화량만을 표시하기 위해 5비트만 이 필요하지만, 항상 8비트를 차지하여 3비트가 낭비되는 문제점이 있었으며, 또한 메시지내 모든 데이터가 변화량이 없는 경우에도 항상 5바이트의 고정된 압축 메시지를 전송해야하는 등 압축 효율이 떨어지는 문제점이 있었다.At this time, only 5 bits are needed to display only the amount of change of 5 data, but there is always a problem that 3 bits are wasted because 8 bits are occupied. There is a problem in that compression efficiency is lowered, such as the need to transmit a fixed compressed message of bytes.
따라서, 본 발명의 목적은 CAN 프로토콜을 이용하여 자동차내 각종 전자장치간 효율적인 네트워킹이 가능하도록 하는 자동차 네트워크에서의 능동형 CAN 통신 데이터 송/수신 방법을 제공함에 있다.Accordingly, an object of the present invention is to provide an active CAN communication data transmission / reception method in an automobile network that enables efficient networking between various electronic devices in a vehicle using a CAN protocol.
상술한 목적을 달성하기 위한 본 발명은, 능동형 CAN 통신 데이터 송신방법으로서, (a)상기 CAN 프로토콜을 이용한 압축 메시지 송신 시 첫 메시지인 경우 압축 전 메시지를 전송하는 단계와, (b)전송 ECU에서 임의의 시간 t에서의 제어 데이터와 t+Δt에서의 제어 데이터의 차이인 ΔMsg를 계산하는 단계와, (c)상기 각각의 ΔMsg값이 압축 메시지의 정의된 데이터 크기보다 작은지 여부를 검사하는 단계와, (d)상기 각 ΔMsg값이 압축 메시지에서 정의된 데이터 크기보다 작은 경우 압축 메시지를 준비하고, 한 개의 데이터라도 정의된 크기보다 큰 경우 압축 전 메시지를 전송하는 단계와, (e)상기 압축 메시지 생성 시 시간 t+Δt에서 발생한 신규 데이터를 Tx-Buf에 저장하고 압축 메시지를 전송하는 단계를 포함하는 것을 특징으로 한다.In order to achieve the above object, the present invention provides an active CAN communication data transmission method comprising the steps of: (a) transmitting a pre-compression message when the first message is transmitted when the compressed message is transmitted using the CAN protocol; Calculating ΔMsg, which is the difference between the control data at any time t and the control data at t + Δt, and (c) checking whether each of the ΔMsg values is smaller than the defined data size of the compressed message. And (d) preparing a compressed message when each ΔMsg value is smaller than the data size defined in the compressed message, and transmitting a pre-compression message when any one data is larger than the defined size; and (e) the compressed message. Storing new data generated at the time t + Δt at the time of message generation in Tx-Buf and transmitting a compressed message.
또한 본 발명은 능동형 CAN 통신 데이터 수신방법으로서, (a')상기 CAN 프로토콜을 이용하여 시간 t에서 수신되는 압축 메시지를 Rx-Buf에 저장하는 단계와, (b')상기 CAN 압축 메시지로부터 데이터 변화량 정보를 읽어 들이는 단계와, (c') 상기 압축 메시지의 RFC를 이용하여 상기 CAN 압축 메시지로 전송되는 다양한 제어 관련 데이터의 데이터 변화량 유무를 판단하는 단계와, (d')상기 각 제어 데이터의 압축에 따른 데이터 변화량 ΔMsg을 추출하는 단계와, (e')상기 Rx-Buf에 저장된 시간 t에서 수신되었던 데이터에 데이터 변화량 ΔMsg를 더하여 시간 t+Δt에서의 데이터를 생성하는 단계를 포함하는 것을 특징으로 한다.In addition, the present invention is an active CAN communication data receiving method, (a ') using the CAN protocol to store the compressed message received at time t in Rx-Buf, and (b') the amount of data change from the CAN compressed message Reading information; (c ') determining whether there is a data change amount of various control-related data transmitted in the CAN compression message by using the RFC of the compressed message, and (d') Extracting the data change amount ΔMsg according to compression; and (e ') generating data at time t + Δt by adding the data change amount ΔMsg to the data received at time t stored in the Rx-Buf. It is done.
이하, 첨부된 도면을 참조하여 본 발명에 따른 바람직한 실시 예의 동작을 상세하게 설명한다.Hereinafter, with reference to the accompanying drawings will be described in detail the operation of the preferred embodiment according to the present invention.
도 4는 본 발명의 실시 예가 적용되는 CAN 프로토콜을 이용한 자동차의 네트워크 시스템 구성을 도시한 것이다. 4 is a diagram illustrating a network system configuration of a vehicle using a CAN protocol to which an embodiment of the present invention is applied.
위 도 4에 도시된 바와 같이, 자동차의 바디 부분과 관련된 데이터를 CAN 버스를 통해 각종 ECU 블록과 통신하는 BCM 블록(400)과, 미러의 동작신호, 폴드 동작신호, 윈도우 동작신호, 씨트 및 핸들의 틸트 신호, 메모리 관련 신호 등을 CAN 버스(408)를 통해 각종 ECU 블록과 통신하는 드라이브 도어 모듈 블록(402)과, 조수선 관련 도어의 잠금 여부, 개폐 여부 등을 CAN 버스(408)를 통해 각종 ECU 블록과 통신하는 어시스트 도어 모듈 블록(404)과, 자동차의 트랜스미션과 관련된 데이터 및 씨트의 제어를 위한 각종 모터와 관련된 데이터를 CAN 버스(408)를 통해 각종 ECU 블록과 통신하는 파워 씨트 ECU 블록(406)과 핸들의 틸트 제어, 텔레스코프 제어, 자동차 내부에 위치하는 인사이드 미러 제어 등과 관련된 데이터를 CAN 버스(408)를 통해 각종 ECU와 통신하는 틸트 ECU 블록(410) 등이 포함된다.As shown in FIG. 4, the
도 5 및 도 8은 본 발명의 실시 예에 따라 자동차내 구비되는 다수의 전자 제어장치 각 ECU간 CAN 데이터 통신 시 압축 메시지 송/수신 처리 흐름을 도시한 것이다. 5 and 8 illustrate a flow of compressed message transmission / reception during CAN data communication between each ECU of a plurality of electronic control apparatuses provided in an automobile according to an exemplary embodiment of the present invention.
이하 먼저 도 5를 참조하여 본 발명의 CAN 프로토콜에서의 압축 메시지 송신 처리 흐름을 설명하면, 전송 ECU는 자동차내 다른 ECU로 CAN 프로토콜을 이용하여 자동차의 각종 제어 관련 데이터에 대한 압축 메시지를 송신하고자 하는 경우 전송하는 압축 메시지가 첫 메시지인지 여부를 검사하여(S500), 첫 메시지인 경우 Tx-Buf에 저장하고(S502), 압축 전 메시지를 전송한다(S504).Hereinafter, referring to FIG. 5, the flow of a compressed message transmission process in the CAN protocol according to the present invention will be described. A transmission ECU attempts to transmit a compressed message for various control-related data of a vehicle using a CAN protocol to another ECU in the vehicle. In this case, it is checked whether the compressed message to be transmitted is the first message (S500), and if the first message is stored in the Tx-Buf (S502), the pre-compression message is transmitted (S504).
위 자동차 제어 관련 데이터는 예를 들어 도 6에서 보여지는 바와 같이, 엔진 속도(Engine Speed : ES), 엔진 온도(Engine Temp: ET), 가스 레벨(Gas Level : GL), 엔진 포스(Engine Force : EF), 엔진 파워(Engine Power : EP) 데이터 등이 있으며, 상기 데이터를 압축했을 때의 데이터 구성은 EF(8Bit)→ES(8Bit)→GL(4Bit)→ET(4Bit)→EP(8Bit)로 정의되며, 압축 메시지의 ID는 압축 전 메시지 'ID-1'로함. As shown in FIG. 6, the vehicle control-related data includes an engine speed (ES), an engine temperature (Engine Temp: ET), a gas level (GL), and an engine force: EF), Engine Power (EP) data, etc., and the data structure when the data is compressed is EF (8Bit) → ES (8Bit) → GL (4Bit) → ET (4Bit) → EP (8Bit). The ID of compressed message is defined as 'ID-1' before compression.
이때 전송 ECU는 전송하는 압축 메시지가 첫 메시지가 아닌 경우에는 임의의 시간 t에서의 전송 데이터와 t+Δt에서의 전송 데이터의 차이인 ΔMsg를 계산하여 시간 t에서의 데이터와 t+Δt에서의 데이터를 비교한다(S506). 위 ΔMsg 계산에서는 예를 들어 엔진 속도(ES)의 경우, ΔES = ESt+Δt - ESt 와 같이 계산될 수 있다.At this time, if the transmission message to be transmitted is not the first message, the transmitting ECU calculates ΔMsg, which is the difference between the transmission data at any time t and the transmission data at t + Δt, and the data at time t and the data at t + Δt. Is compared (S506). In the above ΔMsg calculation, for example, the engine speed ES may be calculated as ΔES = ES t + Δt − ES t .
위 시간 t에서 전송되었던 데이터는 Tx-Buf에 미리 저장되어 있으며, 시간 t+Δt에서의 데이터는 현재 새로 발생한 신규 데이터가 된다.The data transmitted at the time t is stored in Tx-Buf in advance, and the data at the time t + Δt is newly generated new data.
이어 전송 ECU는 모든 데이터 변화량의 크기가 압축 메시지에서 정의된 데이터 크기보다 작은지 여부를 검사하여(S508) 각각의 모든 ΔMsg값이 압축 메시지에서 정의된 데이터 크기보다 큰 경우에는 압축 전 메시지를 전송한다(S504). Subsequently, the transmission ECU checks whether the magnitude of all data changes is smaller than the data size defined in the compressed message (S508), and transmits the pre-compression message when all ΔMsg values are larger than the data size defined in the compressed message. (S504).
그러나 이와 달리 각각의 모든 ΔMsg값이 압축 메시지에서 정의된 데이터 크기보다 작은 경우에는 압축 메시지를 위한 RFC 값을 준비하고, 데이터 변화량 유무에 따른 코드를 작성한다(S510). On the other hand, if each ΔMsg value is smaller than the data size defined in the compressed message, an RFC value for the compressed message is prepared, and a code according to the amount of data change is prepared (S510).
이어 전송 ECU는 알고리즘에 의한 압축 메시지 준비 시 RFC를 탑재하고 변화량이 있는 데이터만 탑재시켜 도 7에서와 같은 압축 메시지를 생성시킨다(S512). 즉, 압축 메시지 생성 시 각 데이터 변화량 유무를 확인하여 RFC내 해당 Bit에 '0'과 '1'을 기재한다. 그런 후, 전송 ECU는 t+Δt에서 발생한 신규 데이터를 Tx-Buf에 저장하고(S514), 압축 메시지를 전송하게 된다(S516). Subsequently, the transmission ECU mounts an RFC and prepares a compressed message as shown in FIG. In other words, when generating the compressed message, check whether there is any data change and record '0' and '1' in the corresponding bit in the RFC. Thereafter, the transmission ECU stores new data generated at t + Δt in Tx-Buf (S514) and transmits a compressed message (S516).
다음으로 도 8을 참조하여 본 발명의 CAN 프로토콜에서의 압축 메시지 수신 처리 흐름을 설명하기로 한다.Next, the compressed message reception processing flow in the CAN protocol of the present invention will be described with reference to FIG. 8.
먼저, 전송 ECU로부터 CAN 프로토콜을 통해 전송되는 자동차 제어 관련 데이터의 압축 메시지를 수신하는 경우 ECU는 수신된 압축 메시지가 첫 메시지인지 여부를 검사하고, 첫 메시지인 경우 Rx-Buf에 메시지를 저장시킨다.First, when receiving a compression message of vehicle control-related data transmitted through the CAN protocol from the transmitting ECU, the ECU checks whether the received compression message is the first message, and if it is the first message, stores the message in the Rx-Buf.
도 9는 압축 메시지 수신 시 원래 데이터 생성 과정을 도시한 것으로, 위 도 9의 RFC는 맨 왼쪽 Bit부터, EF, ES, GL, ET, EP 데이터 변화량 유무를 나타내며, EF, ES는 데이터 변화량이 없으므로 해당 Bit가 '0'으로 되어 있음을 알 수 있고, 이에 따라 도 7를 보면 압축 메시지에 GL, ET, EP 데이터 변화량만이 첨부되어 있음을 알 수 있다.FIG. 9 illustrates a process of generating original data when a compressed message is received. The RFC of FIG. 9 shows the presence or absence of EF, ES, GL, ET, and EP data changes from the leftmost bit, and EF and ES have no data changes. It can be seen that the corresponding bit is '0'. Accordingly, it can be seen from FIG. 7 that only GL, ET, and EP data change amounts are attached to the compressed message.
한편, 수신 ECU는 수신된 압축 메시지가 첫 메시지가 아닌 경우 메시지 ID를 검사한다. 이때 수신측에서는 '99'의값을 가지는 메시지 ID가 수신되었을 경우 압축 메시지 유무를 판단하게 된다(S804). 즉, 데이터 수신측에서는 '99'의 값을 가지는 메시지 ID가 수신되었을 경우 기 정의된 데이터 구성에 따라 첫 5Bit로써, EF, ES, GL, ET, EP의 변화량 유무를 판단하게 되고(S806), 해당 Bit값이 '1'인 데이터를 정해진 크기대로 추출하게 된다.On the other hand, the receiving ECU checks the message ID when the received compressed message is not the first message. At this time, when the message ID having a value of '99' is received, the receiving side determines whether there is a compressed message (S804). That is, when a message ID having a value of '99' is received at the data receiving side, the first 5 bits are used to determine whether there is a change amount of EF, ES, GL, ET, and EP according to a predefined data configuration (S806). It extracts data whose bit value is '1' with the fixed size.
즉, 위 도 9는 수신측에서 압축 메시지를 전송받아 5개의 데이터 EF, ES, GL, ET, EP 중에서 GL, ET, EP만의 변화량이 전송되었다는 것을 인지하고 그 변화량을 추출하여 시간 t에서 수신되었던 데이터를 저장하고 있던 Rx-Buf에 ΔMsg를 더하여 시간 t+Δt에서의 새로운 데이터를 생성하는 과정을 도시한 것이다.That is, FIG. 9 recognizes that the change amount of only GL, ET, and EP is transmitted among the five data EF, ES, GL, ET, and EP by receiving the compressed message from the receiving side, extracts the change, and receives the received change at time t. The process of generating new data at time t + Δt by adding ΔMsg to Rx-Buf that stores data.
이에 따라 수신 ECU는 데이터의 압축에 따른 데이터 변화량 ΔMsg을 계산하여(S808) 시간 t에서 수신되었던 데이터를 저장하고 있던 Rx-Buf에 ΔMsg를 더하여 시간 t+Δt에서의 새로운 데이터를 Msgt+Δt = Msgt + ΔMsg 와 같이 계산하고(S810), Rx-Buf에 메시지를 저장한다(S812).Accordingly, the receiving ECU calculates the data change amount ΔMsg according to the compression of the data (S808), adds ΔMsg to Rx-Buf that was storing data received at time t, and adds new data at time t + Δt = Msg t + Δt = Calculate as Msg t + ΔMsg (S810), and store the message in Rx-Buf (S812).
즉, 기존의 알고리즘을 적용하면 도 2에서와 같이 5바이트 크기의 압축 메시지를 필요로 하게 되지만, 본 발명의 알고리즘을 적용하는 경우 위 도 7에서와 같이 3바이트 크기의 압축 메시지가 필요하다는 것을 알 수 있다. 이때 만일 모든 데 이터의 변화량이 '0'인 경우에는 RFC값만 필요하므로 1바이트 크기의 압축 메시지만을 전송하게 되어, 본 발명의 알고리즘을 적용하는 경우 최적 1바이트에서 최고 5바이트의 압축메시지 데이터의 생성이 가능하게 된다.That is, if the existing algorithm is applied, a compressed message of 5 bytes is required as shown in FIG. 2, but when the algorithm of the present invention is applied, a compressed message of 3 bytes is required as shown in FIG. 7. Can be. At this time, if the change amount of all data is '0', only RFC value is needed, so only compressed message of 1 byte size is transmitted. When applying the algorithm of the present invention, the compressed message data of optimal 1 byte to maximum 5 bytes is generated. This becomes possible.
한편 상술한 본 발명의 설명에서는 구체적인 실시 예에 관해 설명하였으나, 여러 가지 변형이 본 발명의 범위에서 벗어나지 않고 실시될 수 있다. 즉, 본 발명에서는 CAN 통신을 이용한 자동차의 엔진 속도, 엔진 온도, 가스 레벨 등의 제어 데이터 송수신에 대해 설명하였으나, 공장 자동화, 자동차 네트워크, 기차, 선박, 항공 등 CAN 통신이 사용되는 다른 분야에서도 동일하게 적용이 가능하다. 따라서 발명의 범위는 설명된 실시 예에 의하여 정할 것이 아니고 특허청구범위에 의해 정하여져야 한다.Meanwhile, in the above description of the present invention, specific embodiments have been described, but various modifications may be made without departing from the scope of the present invention. That is, the present invention has been described for the transmission and reception of control data, such as engine speed, engine temperature, gas level of the vehicle using CAN communication, but the same in other fields such as factory automation, automotive network, train, ship, aviation, CAN communication is used. It is possible to apply. Therefore, the scope of the invention should be determined by the claims rather than by the described embodiments.
이상에서 설명한 바와 같이, 본 발명은 능동형 CAN 통신 데이터 압축 알고리즘을 이용하여 자동차의 ECU간 메시지 송/수신에 적용함으로써, 메시지 전송율, 버스 로드, 메시지 평균 길이 등을 상당부분 감소시킬 수 있게 되며, 이에 따라 통신 트래픽을 최소화하여 기존 CAN 통신 네트워크의 사용량을 극대화할 수 있고, 네트워크 증설 문제를 최소화할 수 있는 이점이 있다.As described above, the present invention can be applied to message transmission / reception between ECUs of an automobile using an active CAN communication data compression algorithm, thereby significantly reducing the message transmission rate, bus load, and average message length. Therefore, it is possible to maximize the usage of the existing CAN communication network by minimizing the communication traffic, and has the advantage of minimizing the network expansion problem.
Claims (22)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
KR1020060062541A KR100773076B1 (en) | 2006-07-04 | 2006-07-04 | Method for transmitting and receiving dynamic can communication data |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
KR1020060062541A KR100773076B1 (en) | 2006-07-04 | 2006-07-04 | Method for transmitting and receiving dynamic can communication data |
Publications (1)
Publication Number | Publication Date |
---|---|
KR100773076B1 true KR100773076B1 (en) | 2007-11-15 |
Family
ID=39060728
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
KR1020060062541A KR100773076B1 (en) | 2006-07-04 | 2006-07-04 | Method for transmitting and receiving dynamic can communication data |
Country Status (1)
Country | Link |
---|---|
KR (1) | KR100773076B1 (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR101138248B1 (en) | 2010-12-31 | 2012-04-24 | 자동차부품연구원 | System and method for compressing variable length of signal for can communication message compression and restoring therefor |
KR101714227B1 (en) * | 2015-09-22 | 2017-03-08 | 현대자동차주식회사 | vehicle data communication method and apparatus using the same |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR20030010890A (en) * | 2001-07-27 | 2003-02-06 | 주식회사 현대오토넷 | Network system of automobile using a CAN protocol |
KR20030042241A (en) * | 2001-11-22 | 2003-05-28 | 현대자동차주식회사 | Hybrid electric vehicle of control system |
JP2004256065A (en) | 2003-02-27 | 2004-09-16 | Japan Climate Systems Corp | Air-conditioner for vehicle |
JP2004280407A (en) | 2003-03-14 | 2004-10-07 | Canon Inc | Information transfer device |
-
2006
- 2006-07-04 KR KR1020060062541A patent/KR100773076B1/en not_active IP Right Cessation
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR20030010890A (en) * | 2001-07-27 | 2003-02-06 | 주식회사 현대오토넷 | Network system of automobile using a CAN protocol |
KR20030042241A (en) * | 2001-11-22 | 2003-05-28 | 현대자동차주식회사 | Hybrid electric vehicle of control system |
JP2004256065A (en) | 2003-02-27 | 2004-09-16 | Japan Climate Systems Corp | Air-conditioner for vehicle |
JP2004280407A (en) | 2003-03-14 | 2004-10-07 | Canon Inc | Information transfer device |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR101138248B1 (en) | 2010-12-31 | 2012-04-24 | 자동차부품연구원 | System and method for compressing variable length of signal for can communication message compression and restoring therefor |
KR101714227B1 (en) * | 2015-09-22 | 2017-03-08 | 현대자동차주식회사 | vehicle data communication method and apparatus using the same |
US10020916B2 (en) | 2015-09-22 | 2018-07-10 | Hyundai Motor Company | Method and apparatus for data communication of vehicle |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US20180141439A1 (en) | Onboard vehicle communication system | |
US20160359545A1 (en) | Vehicle-mounted control device | |
JP2007038904A (en) | Car-mounted gateway device and message forwarding method used in gateway device | |
CN103959718A (en) | Transmission message generating device and vehicle on-board transmission system | |
WO2018196655A1 (en) | Public network communication method for on-board electronic processing unit system | |
US20160234037A1 (en) | Communication system and communication method | |
JPWO2011055425A1 (en) | Vehicle gateway device | |
JP4880035B2 (en) | In-vehicle relay connection unit | |
US20080306647A1 (en) | In-vehicle network system and control method thereof | |
KR101033793B1 (en) | A vehicle integrated control system | |
WO2009110502A1 (en) | Relay device, communication system, and communication method | |
KR100696889B1 (en) | inner vehicle communication system and gateway | |
JP2006352201A (en) | Communication conversion control device | |
JP2008277873A (en) | Relay connection system | |
CN101770234A (en) | Diagnostic system for car body controller based on SAEJ1939 | |
KR100773076B1 (en) | Method for transmitting and receiving dynamic can communication data | |
CN206096835U (en) | Formula automobile communication system is monopolized to non - | |
Camek et al. | An automotive Side-View system based on Ethernet and IP | |
Kessler | The can bus in the maritime environment–technical overview and cybersecurity vulnerabilities | |
KR100775516B1 (en) | Control system of flexray and can and method thereof | |
Xun et al. | An experimental study towards the in-vehicle network of intelligent and connected vehicles | |
Long | Automobile electronic control network design based on can bus | |
Elhadeedy et al. | 60 GHz Wi-Fi as a Tractor-Trailer Wireless Harness | |
JP3442633B2 (en) | Vehicle multiplex transmission equipment | |
KR20190106069A (en) | Apparatus and method for testing function between automobile equipments using can/lin integrated module and its system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A201 | Request for examination | ||
E902 | Notification of reason for refusal | ||
E701 | Decision to grant or registration of patent right | ||
GRNT | Written decision to grant | ||
FPAY | Annual fee payment |
Payment date: 20111018 Year of fee payment: 5 |
|
FPAY | Annual fee payment |
Payment date: 20121009 Year of fee payment: 6 |
|
LAPS | Lapse due to unpaid annual fee |