A dual-chip communication data interaction method based on intelligent cockpit

By adopting a dual-chip communication data interaction method in smart cockpit technology and using data combination, offset messages and verification mechanisms, the reliability and efficiency issues of data transmission between chips are solved, achieving efficient, stable data transmission and rapid response.

CN115833996BActive Publication Date: 2024-09-20SHENZHEN NINGZHIYUAN AUTOMOBILE INTELLIGENT TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202211502569.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-11-28
Publication Date
2024-09-20
Estimated Expiration
2042-11-28

AI Technical Summary

Technical Problem

In the existing smart cockpit technology, high-performance chips have shortcomings in real-time performance and rapid response. Especially in the data interaction between the MCU chip and the main chip, it is difficult to ensure the reliability and efficiency of data transmission.

Method used

A dual-chip communication data interaction method is adopted to ensure stable transmission of data between the MCU chip and the main chip through data combination, offset message processing, data verification and error correction mechanisms, including data combination, offset message transmission, CRC8 checksum and heartbeat message detection reduce data transmission bandwidth usage and improve real-time performance.

Benefits of technology

It achieves efficient and stable data transmission between dual chips, reduces data bandwidth occupation, improves transmission efficiency and reliability, and ensures real-time processing capabilities, such as fast response to functions such as sleep wake-up and CAN message sending and receiving.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115833996B
    Figure CN115833996B
Patent Text Reader

Abstract

The present invention discloses a dual-chip communication data interaction method based on an intelligent cockpit, including: combining the data exchanged between the dual chips to synthesize offset message data; when the length of the offset message data packet is greater than or equal to the length of the data packet to be sent, sending a normal data packet to be sent, otherwise sending an offset message data packet; correcting the data, performing data content verification and connection validity detection, and discarding the message data that fails the verification and validity; the data that passes the verification and validity is transmitted between the dual chips. The present invention can establish an effective connection between the dual chips, realize the transmission of functional signals such as indicator lights, text alarms, driving information, fault codes, menu settings, etc., and also reduce the transmission bandwidth occupancy and improve the transmission efficiency by combining the data and processing the offset. At the same time, the method provides a certain error correction function to ensure the stability and reliability of the transmission.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of intelligent cockpits, and in particular to a dual-chip communication data interaction method based on an intelligent cockpit. Background Art

[0002] With the development of technology, chip performance has gradually improved. The car instrument and central control are combined into a smart cockpit, using one chip to drive the instrument and central control. However, although high-performance chips have outstanding computing power, they generally rely on the operating system and cannot guarantee real-time performance. An auxiliary MCU chip is often required to handle functions such as sleep wakeup and CAN message transmission and reception that require fast response and high real-time requirements. The MCU chip and the main chip are connected through UART, CAN bus, etc. In order to make the data interaction between the two chips more reliable and efficient, a dual-chip communication data interaction method is required. Summary of the invention

[0003] The purpose of the present invention is to overcome the deficiencies in the prior art and provide a dual-chip communication data interaction method based on an intelligent cockpit that can respond quickly and interact stably.

[0004] The objective of the present invention is achieved through the following technical solutions:

[0005] A dual-chip communication data interaction method based on an intelligent cockpit, comprising:

[0006] The data exchanged between the two chips are combined, and the data are arranged and combined into a message. When the intelligent cockpit is working, each time the data changes, the message will be resent. After each message is sent, the sent message data must be stored. When sending a message, the current sent data is compared with the previous data to obtain the difference data, and the difference data is recombined into the offset message data. When the length of the offset message data packet is ≥ the length of the data packet to be sent, a normal data packet to be sent is sent, otherwise an offset message data packet is sent. The offset message data packet is in the form of index plus data, the index is the signal in the message where the signal with data changes belongs to which signal, and the data is the corresponding changed data content. All the changed signals in the message are arranged from front to back to obtain the final offset message data packet. The receiving end needs to store the data message received last time. When receiving the offset message, the corresponding signal data value is replaced with the offset data according to the index. The data is corrected, the data content is checked and the connection validity is checked, and the message data that fails the check and validity is discarded. The data that passes the check and validity is transmitted between the two chips.

[0007] Further, the message includes a data header, a data type, a data length, a data packet, a check value, and a data separator. The message data is in the ascii code format. The data length is used to identify the number of bytes of the data packet. The data length is escaped, and the actual length after escape is twice the data length. The check value is used to check the values ​​in the message except the check value itself and the data separator. CRC8 check analysis is used here, and the length of the information field and the check field can be selected arbitrarily. The data separator uses a control character to distinguish it from other message data, so that the program can separate the data stream into data messages. Other message data are represented by English letters or Arabic numerals.

[0008] Furthermore, the data content verification is to separate the data stream according to the data separator and convert the ascii data into hexadecimal data.

[0009] Furthermore, the data type, data length, data packet, and check value are checked for the converted data. The first byte of the converted data is obtained as the data type, and the correct data length is obtained by looking up the table according to the data type. Then, the second byte of data is obtained as the data length obtained by the message. The obtained data length is equal to the data length obtained by looking up the table. If the length does not match, the message data is discarded. If the length matches, the total length of the message is calculated.

[0010] Furthermore, the data type, data length, and check value length are 1 byte, and the total length of the converted message data is equal to the data length + 3. If the length does not match, the message data is discarded. If the length matches, the check value is calculated, and the last byte of data is obtained as the check value obtained by the message. The MCU chip end is used as the sending end, and the main chip end is used as the receiving end. If the check value calculated by the receiving end itself is consistent with the check value sent by the sending end, it is judged that the message data transmission is correct. If the check value calculated by the receiving end itself is inconsistent with the check value sent by the sending end, it is judged that the message data transmission is wrong and the message data is discarded, which effectively reduces the bandwidth occupancy of data transmission and handles sleep wake-up, CAN message sending and receiving, and other functions that require fast response in real time.

[0011] Furthermore, each time the sending end sends a message, if the receiving end receives it successfully, it needs to reply with a message to verify the transmission accuracy between the two chips.

[0012] Furthermore, the reply content of the receiving end also includes the corresponding sending message type, which is used to match the sending message. When the sending end does not receive the feedback message from the receiving end for more than 5 sending cycles, it is considered that the message sending has failed, and the sending end needs to resend this type of message.

[0013] Furthermore, the connection validity detection is performed by the sending end periodically sending a heartbeat message. The heartbeat message type is heartbeat, and the data content is accumulated from 0, and 1 is added each time a heartbeat message is sent. The overflow is restarted from 0. When an abnormality occurs in the dual-chip communication, such as the receiving end cannot receive the heartbeat message from the sending end, or the data sent by the heartbeat message remains unchanged, or the sending end cannot receive a reply from the receiving end, the error chip is reset after a certain period of time.

[0014] Compared with the prior art, the present invention has the following advantages and beneficial effects:

[0015] The present invention can establish an effective connection between the two chips, realize the transmission of indicator lights, text alarms, driving information, fault codes, menu settings and other functional signals, and also reduce the transmission bandwidth occupancy and improve the transmission efficiency by combining and offsetting data. At the same time, the method provides a certain error correction function to ensure the stability and reliability of transmission. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] Figure 1 It is a flow chart of a dual-chip communication data interaction method based on a smart cockpit;

[0017] Figure 2 To send a flow chart;

[0018] Figure 3 It is a data verification flow chart;

[0019] Figure 4 It is a message structure diagram;

[0020] Figure 5 This is the structure diagram of the offset message data packet. DETAILED DESCRIPTION

[0021] It should be understood that the specific embodiments described herein are only used to explain the present invention, and are not used to limit the present invention.

[0022] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0023] It should be noted that the terms "include", "comprises" and "have" and any variations thereof in the specification and claims of the present invention and the above-mentioned drawings are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units that are not listed, or may optionally include other steps or units that are inherent to these processes, methods, products or devices. In the claims, specifications and drawings of the present invention, relational terms such as "first" and "second" are merely used to distinguish one entity / operation / object from another entity / operation / object, and do not necessarily require or imply any such actual relationship or order between these entities / operations / objects.

[0024] like Figure 1 As shown, the present invention provides a dual-chip communication data interaction method based on an intelligent cockpit for a full liquid crystal instrument, combines the data interacting between the dual chips, and arranges and combines the data into a message; in the development process of the actual project, we found that when the intelligent cockpit is working normally, the data change is not very large. For example, when the indicator lights and left and right turn indications are working, there is no need to send all the indicator light data. Often, the changed data only accounts for a very small part of all the data. Therefore, when the intelligent cockpit is working, the message will be resent each time the data changes. After each message is sent, the sent message data must be stored. When sending a message, the currently sent data is compared with the previous data to obtain the difference data, and the difference data is recombined into offset message data to reduce the transmission bandwidth and improve the transmission efficiency; Figure 2 As shown, the data stream is separated into messages and converted into hexadecimal data, and the data verification is checked to see if it passes. If not, the reply is timed out and the data is resent to the data stream. If it passes, a send data packet is generated, and it is checked whether the message of this type is sent. If not, an offset message data packet is generated according to the last sent data. When the length of the offset message data packet is less than the length of the data packet to be sent, the offset message data packet is sent; when the length of the offset message data packet is greater than or equal to the length of the data packet to be sent, a normal data packet to be sent is sent; as shown in FIG. Figure 5As shown, the offset message data packet is in the form of index plus data, the index is the signal number of the signal with data change in the message, the data is the corresponding changed data content, all the changed signals in the message are arranged from front to back in sequence to obtain the final offset message data packet, the receiving end needs to store the data message received last time, when receiving the offset message, according to the index, replace the corresponding signal data value with the offset data; correct the data, perform data content verification and connection validity detection, and discard the message data that fails the verification and validity; the data that passes the verification and validity is transmitted between the dual chips, and an efficient and stable data link is established between the dual chips, which effectively reduces the bandwidth occupancy of data transmission, while having a certain error correction capability to ensure the stability of interaction.

[0025] like Figure 4 As shown, the message in this case contains the data header, data type, data length, data packet, check value, and data separator. The message data is in ASCII format. The data length is used to identify the number of bytes in the data packet. The data length is escaped. The actual length after escape is twice the data length. The check value is used to check the values ​​in the message except the check value itself and the data separator. CRC8 check analysis is used here. The length of the information field and the check field can be selected arbitrarily. The data separator uses control characters to distinguish from other message data, so that the program can separate the data stream into data messages. Other message data is represented by English letters or Arabic numerals. For example, if you need to send a byte of data "0x1A", you need to escape it into two bytes of ASCII code, 0x31, 0x41 for sending. The data type indicates the type of message, such as vehicle speed, rotation speed, indicator light, text alarm, etc. In order to reduce the amount of interactive data, there is also a special type of data offset message; the data content check is to separate the data stream according to the data separator and convert the ascii data into hexadecimal data; for the converted data, check the data type, data length, data packet, and check value, such as Figure 3As shown, the first byte data of the converted data is obtained as the data type, and the ASCII code table is checked according to the data type to obtain the correct data length, and then the second byte data is obtained as the data length obtained by the message, and the obtained data length is equal to the data length obtained by looking up the table. If the length does not match, the message data is discarded, and if the length matches, the total length of the message is calculated; the data type, data length, and check value length are 1 byte, and the total length of the converted message data is equal to the data length+3. If the length does not match, the message data is discarded, and if the length matches, the check value is calculated, and the last byte data is obtained as the check value obtained by the message. The MCU chip end is used as the sending end, and the main chip end is used as the receiving end. If the check value calculated by the receiving end is consistent with the check value sent by the sending end, it is judged that the message data transmission is correct. If the check value calculated by the receiving end is inconsistent with the check value sent by the sending end, it is judged that the message data transmission is wrong, and the message data is discarded, which effectively reduces the bandwidth occupancy of data transmission, and processes sleep wake-up, CAN message transmission and reception and other functions that require fast response in real time.

[0026] One embodiment is that each time the sending end sends a message, the receiving end needs to reply with a message if the message is received successfully, so as to verify the transmission accuracy between the dual chips; the reply content of the receiving end also includes the corresponding sending message type, which is used to match the sending message. When the sending end does not receive the feedback message from the receiving end for more than 5 sending cycles, it is considered that the message sending has failed, and the sending end needs to resend this type of message; the connection validity detection is that the sending end sends a heartbeat message at regular intervals. The heartbeat message type is heartbeat, and the data content is accumulated from 0. Each time a heartbeat message is sent, 1 is added, and overflow is re-accumulated from 0. When an abnormality occurs in the dual-chip communication, such as the receiving end cannot receive the heartbeat message from the sending end, or the heartbeat message sending data remains fixed, or the sending end cannot receive the reply from the receiving end, after a certain period of time, the error chip is reset.

[0027] It should be noted that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in the present application can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solutions disclosed in the present disclosure can be achieved, and this document is not limited here. The above specific implementation methods are only preferred embodiments of the present invention and the technical principles used. Within the technical scope disclosed by the present invention, any changes, modifications, substitutions, combinations, and simplifications made by any technician familiar with the technical field without departing from the spirit and principles of the present invention should be equivalent replacement methods and should be covered within the protection scope of the present invention.

Claims

1. A dual-chip communication data interaction method based on an intelligent cockpit, characterized in that: include: Combine the data exchanged between the two chips and arrange and combine the data into a message; When the smart cockpit is working, each time the data changes, the message will be resent. After each message is sent, the sent message data must be stored. When sending a message, the current sent data is compared with the previous data to obtain the difference data, and the difference data is recombined into the offset message data; When the length of the offset message data packet is greater than or equal to the length of the data packet to be sent, a normal data packet to be sent is sent, otherwise an offset message data packet is sent; The offset message data packet is in the form of index plus data. The index is the signal number of the signal with data change in the message, and the data is the corresponding changed data content. All the changed signals in the message are arranged from front to back to obtain the final offset message data packet. The receiving end needs to store the data message received last time. When receiving the offset message, it replaces the corresponding signal data value with the offset data according to the index. The data is corrected for errors, the data content is verified and the connection validity is checked, and the message data that fails the verification and validity is discarded; the data that passes the verification and validity is transmitted between the two chips.

2. The dual-chip communication data interaction method based on the smart cockpit according to claim 1 is characterized in that: The message includes a data header, a data type, a data length, a data packet, a check value, and a data separator. The data length is used to identify the number of bytes in the data packet. The data length is escaped, and the actual length after escape is twice the data length. The check value is used to check the values ​​in the message except the check value itself and the data separator. The data separator uses a control character to distinguish it from other message data, so that the program can separate the data stream into individual data messages.

3. The dual-chip communication data interaction method based on the smart cockpit according to claim 2 is characterized in that: The data content verification is to separate the data stream according to the data separator and convert the ascii data into hexadecimal data.

4. The dual-chip communication data interaction method based on the intelligent cockpit according to claim 3 is characterized in that: Check the data type, data length, data packet, and check value of the converted data. Get the first byte of the converted data as the data type, look up the table according to the data type to get the correct data length, then get the second byte of data as the data length obtained by the message. The obtained data length is equal to the data length obtained from the table. If the length does not match, the message data is discarded. If the length matches, calculate the total length of the message.

5. The dual-chip communication data interaction method based on the smart cockpit according to claim 4 is characterized in that: The data type, data length, and check value length are 1 byte, and the total length of the converted message data is equal to the data length + 3. If the length does not match, the message data is discarded. If the length matches, the check value is calculated, and the last byte of data is obtained as the check value obtained by the message. The MCU chip end is used as the sending end, and the main chip end is used as the receiving end. If the check value calculated by the receiving end is consistent with the check value sent by the sending end, it is judged that the message data transmission is correct. If the check value calculated by the receiving end is inconsistent with the check value sent by the sending end, it is judged that the message data transmission is wrong and the message data is discarded.

6. The dual-chip communication data interaction method based on the smart cockpit according to claim 5 is characterized in that: Every time the sender sends a message, the receiver needs to reply with a message if it receives it successfully.

7. The dual-chip communication data interaction method based on the intelligent cockpit according to claim 6 is characterized in that: The reply content of the receiving end also includes the corresponding sending message type, which is used to match the sending message. When the sending end does not receive the feedback message from the receiving end for more than 5 sending cycles, it is considered that the message sending has failed, and the sending end needs to resend this type of message.

8. The dual-chip communication data interaction method based on the smart cockpit according to claim 7 is characterized in that: The connection validity detection is performed by the sending end periodically sending a heartbeat message. The heartbeat message type is heartbeat, and the data content is accumulated from 0. Each time a heartbeat message is sent, 1 is added. If there is an overflow, the data is accumulated again from 0. When an abnormality occurs in the dual-chip communication, such as the receiving end cannot receive the heartbeat message from the sending end, or the data sent by the heartbeat message remains unchanged, or the sending end cannot receive a reply from the receiving end, the error chip is reset after a certain period of time.