Data processing method, device and system, electronic equipment and storage medium

By using a second processor to parse data frames and dynamically configure the frame format using a configuration file, the problems of low efficiency and long development cycle of data transmission between boards in embedded devices are solved, achieving efficient and flexible data processing and decoupling of driver software.

CN121144243APending Publication Date: 2025-12-16CONTEMPORARY AMPEREX FUTURE ENERGY RES INST (SHANGHAI) LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410775961.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-14
Publication Date
2025-12-16

AI Technical Summary

Technical Problem

In existing embedded devices, when multiple boards transmit data through optical fiber, there are problems such as long parsing time, high overhead, poor versatility, and long development cycle. In particular, the development flexibility of FPGA processors for FT3 protocol integrated SoC devices is poor.

Method used

By parsing data frames with a second processor and dynamically configuring the frame format of the communication interface using a configuration file, the communication protocol and driver software are decoupled, simplifying the development process of the first processor and improving the accuracy and efficiency of data parsing.

Benefits of technology

It shortens the parsing time, improves the real-time performance and parsing efficiency of the data, reduces development costs, enhances the versatility and portability of the driver software, and adapts to the compatibility of multiple frame formats.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121144243A_ABST
    Figure CN121144243A_ABST
Patent Text Reader

Abstract

The invention provides a data processing method, device and system, electronic equipment and a storage medium, the method is applied to a first processor of a first board card, and the method comprises the following steps: determining a second data frame based on a first data frame transmitted by a second board card through a first communication interface of the first board card; wherein the first board card further comprises a second processor and at least one communication interface, the type of the second processor is different from that of the first processor, each communication interface is used for transmitting a data frame with a corresponding frame format, and each data frame is generated according to a target communication protocol. The frame format corresponding to each communication interface is generated based on a preset configuration file; and sending the second data frame to the second processor, so that the second processor determines first target data from the second data frame according to a frame format corresponding to the first communication interface.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present disclosure relates to, but is not limited to, the embedded field, and particularly relates to a data processing method, device and system, electronic equipment and storage medium. BACKGROUND

[0002] In the related art, most embedded devices include multiple boards (or multiple devices), and the multiple boards are connected through optical fibers to realize stable transmission of data. Data transmitted based on a link layer (for example, FT3) is generally processed by a first processor (for example, FPGA) for an embedded device with a fusion Soc (System on Chip), which has problems such as long analysis time, large overhead, poor universality, long development cycle, and the like. SUMMARY

[0003] Therefore, the present disclosure provides a data processing method, device and system, electronic equipment and storage medium, which analyzes data frames by a second processor according to corresponding frame formats, shortens the analysis time, simplifies the development of the driving software of the first processor, improves the stability of the overall driving, dynamically configures the frame formats corresponding to each communication interface through a configuration file, realizes the decoupling between the communication protocol and the driving software, and increases the universality, reusability and portability of the driving software, thereby reducing the development cost and improving the development efficiency.

[0004] The technical solutions of the embodiments of the present disclosure are implemented as follows:

[0005] The present disclosure provides a data processing method applied to a first processor of a first board, and the method comprises the following steps:

[0006] determining a second data frame based on a first data frame transmitted by a second board through a first communication interface of the first board; wherein the first board further comprises a second processor and at least one communication interface, the type of the second processor is different from the type of the first processor, each communication interface is used to transmit a data frame with a corresponding frame format, each data frame is generated according to a target communication protocol, and the frame format corresponding to each communication interface is generated based on a preset configuration file;

[0007] sending the second data frame to the second processor, so that the second processor determines a first target data from the second data frame according to the frame format corresponding to the first communication interface.

[0008] In the embodiments of the present disclosure, first, the first processor sends the data frame transmitted by the other board card to the second processor for processing. Since the first processor does not need to parse the data frame, the development of the driving software of the first processor is simplified, and the stability of the overall driving is improved. At the same time, even if the frame format corresponding to the communication interface changes, since the driving software does not need to be redeveloped or modified, the development cost is reduced, and the development efficiency is improved. Second, the second processor parses the target data of the data frame according to the corresponding frame format for use by the application software in the second processor. The hardware performance of the second processor is fully utilized, the data parsing accuracy and efficiency are improved while the parsing time is shortened. For the application software in the second processor, the target data is directly obtained from the second processor, compared with obtaining the target data from the first processor, the communication link between the two is shortened, the real-time performance of the data is improved, and the complexity of the development of the application software of the second processor is reduced since the second processor only needs to parse the data frame and does not need to pay attention to the transmission of the data frame. Finally, the frame format corresponding to each communication interface is dynamically configured through the configuration file. The accuracy of the frame format corresponding to each communication interface is improved, the decoupling between the communication protocol and the driving software is realized, and the universality, reusability and portability of the driving software are improved, thereby reducing the development cost and improving the development efficiency. At the same time, by modifying the configuration file, multiple frame formats of the target communication protocol can be compatible, further improving the development efficiency.

[0009] In some embodiments, the determining the second data frame based on the first data frame transmitted by the second board card through the first communication interface comprises: decoding the first data frame according to the encoding information corresponding to the first communication interface to obtain a decoded first data frame; checking the decoded first data frame to obtain a checking result; and in a case where the checking result represents that the checking is passed, taking the decoded first data frame as the second data frame.

[0010] In the embodiments of the present disclosure, on the one hand, the accuracy of the decoded data frame is improved by decoding the data frame according to the corresponding encoding information. On the other hand, the possibility of abnormal data flow is reduced by checking the transmitted data frame to ensure the integrity and accuracy of the data frame.

[0011] In some embodiments, the method further comprises: receiving a third data frame transmitted by the second processor; wherein the third data frame is generated by the second processor based on a second target data and a frame format corresponding to a second communication interface according to the target communication protocol; generating a fourth data frame based on the third data frame; and transmitting the fourth data frame to a third board card through the second communication interface.

[0012] In the embodiments of the present disclosure, first, data interaction between the boards is performed through a unified target communication protocol, which greatly reduces the development cost and improves the reusability and portability of the software and hardware, compared with developing different protocols to support data interaction for various communication data and multiple communication interfaces; second, the second processor generates corresponding data frames according to the frame formats corresponding to the communication interfaces, which improves the accuracy of the data frames; and finally, the first processor transmits the data frames through the corresponding communication interfaces, which improves the accuracy of data frame transmission.

[0013] In some embodiments, the generating the fourth data frame based on the third data frame comprises: generating a fifth data frame based on the third data frame and the check information corresponding to the third data frame; encoding the fifth data frame according to the encoding information corresponding to the second communication interface to obtain an encoded fifth data frame, and taking the encoded fifth data frame as the fourth data frame.

[0014] In the embodiments of the present disclosure, on the one hand, the corresponding check information is added to the data frame to facilitate the receiving end to check the data frame, thereby reducing the possibility of abnormal data flow; on the other hand, the data frame is encoded according to the corresponding encoding information, which improves the accuracy of the data frame and also improves the confidentiality of the data frame.

[0015] In some embodiments, the method further comprises: receiving a configuration instruction; wherein the configuration instruction is generated based on the configuration file, and the configuration instruction includes communication information of each communication interface; for each communication interface, configuring the communication interface based on the communication information of the communication interface to obtain a configuration result; in the case that each configuration result indicates that the configuration is successful, transmitting a preset configuration completion instruction to the second processor, so that the second processor establishes a corresponding relationship between at least one communication interface and at least one frame format based on the configuration completion instruction; in the case that at least one configuration result indicates that the configuration fails, reporting the corresponding configuration result.

[0016] In the embodiments of the present disclosure, first, the first processor dynamically initializes each communication interface according to the configuration file, which not only improves the accuracy of the initialization, but also realizes the decoupling of the communication interface and the driving software, and improves the reusability and portability of the communication interface and the driving software; second, in the case that the initialization of each communication interface is successful, the second processor establishes a corresponding relationship between each communication interface and each frame format according to the configuration file, so as to facilitate subsequent accurate parsing of each data frame; and finally, in the case that the initialization of at least one communication interface fails, the first processor reports the configuration result in a timely manner, so as to facilitate timely processing and reduce the possibility of communication abnormality between the boards due to abnormal communication interfaces.

[0017] The embodiment of the present disclosure provides a data processing method, applied to a second processor of a first board card, and the method comprises the following steps:

[0018] receiving a second data frame transmitted by a first processor of the first board card; wherein the second data frame is determined based on a first data frame transmitted by a second board card through a first communication interface, the type of the second processor is different from the type of the first processor, the first board card further comprises at least one communication interface, each communication interface is used for transmitting a data frame with a corresponding frame format, each data frame is generated according to a target communication protocol, and the frame format corresponding to each communication interface is generated based on a preset configuration file;

[0019] parsing the first data frame according to the frame format corresponding to the first communication interface to obtain first target data.

[0020] In the embodiment of the present disclosure, first, the first processor transmits the data frame transmitted by the other board card to the second processor for processing, since the first processor does not need to parse the data frame, the development of the driving software of the first processor is simplified, and the stability of the overall driving is improved, and at the same time, even if the frame format corresponding to the communication interface changes, since the driving software does not need to be redeveloped or modified, the development cost is reduced and the development efficiency is improved; second, the second processor parses the target data of the data frame according to the corresponding frame format, for the internal application software, not only the hardware performance of the second processor is fully utilized, the data parsing accuracy and efficiency are improved while the parsing time is shortened, and for the application software in the second processor, the target data is directly obtained from the second processor, compared with obtaining the target data from the first processor, the communication link between the two is shortened, the real-time performance of the data is improved, and since the second processor only needs to parse the data frame and does not need to pay attention to the transmission of the data frame, the complexity of the development of the application software of the second processor is reduced; finally, the frame format corresponding to each communication interface is dynamically configured through the configuration file, not only the accuracy of the frame format corresponding to each communication interface is improved, but also the decoupling between the communication protocol and the driving software is realized, the versatility, reusability and portability of the driving software are increased, so that the development cost is reduced and the development efficiency is improved, and at the same time, by modifying the configuration file, multiple frame formats of the target communication protocol can be compatible, and the development efficiency is further improved.

[0021] In some embodiments, the method further comprises: generating, according to the target communication protocol, a third data frame based on a frame format corresponding to the second communication interface and second target data; and delivering the third data frame to the first processor, so that the first processor delivers a fourth data frame to the third board card through the second communication interface, the fourth data frame being generated based on the third data frame.

[0022] In the embodiments of the present disclosure, first, data interaction between board cards is performed through a unified target communication protocol, which greatly reduces development cost and improves software and hardware reusability and portability, compared with developing different protocols to support data interaction for various communication data and various communication interfaces; second, the second processor generates corresponding data frames according to frame formats corresponding to communication interfaces, which improves the accuracy of data frames; and finally, the first processor delivers data frames through corresponding communication interfaces, which improves the accuracy of data frame transmission.

[0023] In some embodiments, the method further comprises: in response to receiving a configuration completion instruction delivered by the first processor, establishing a correspondence between at least one communication interface and at least one frame format based on the configuration file.

[0024] In the embodiments of the present disclosure, after receiving the configuration completion instruction, the second processor establishes a correspondence between each communication interface and each frame format according to the configuration file, so as to facilitate subsequent accurate parsing of each data frame.

[0025] The embodiments of the present disclosure provide a data processing system, which comprises a first board card and a second board card, the first board card comprising a first processor, a second processor and at least one communication interface, the type of the second processor being different from the type of the first processor, each communication interface being configured to deliver a data frame having a corresponding frame format, each data frame being generated according to a target communication protocol, and the frame format corresponding to each communication interface being generated based on a preset configuration file, wherein:

[0026] The first processor is configured to determine a second data frame based on a first data frame delivered by the second board card through a first communication interface, and send the second data frame to the second processor.

[0027] The second processor is configured to parse the first data frame according to a frame format corresponding to the first communication interface, and obtain first target data.

[0028] In the embodiments of the present disclosure, first, the first processor sends the data frame transmitted by the other board card to the second processor for processing, since the first processor does not need to parse the data frame, the development of the driving software of the first processor is simplified, the stability of the overall driving is improved, and even when the frame format corresponding to the communication interface changes, since the driving software does not need to be redeveloped or modified, the development cost is reduced and the development efficiency is improved; second, the second processor parses the target data of the data frame according to the corresponding frame format, for the internal application software, not only the hardware performance of the second processor is fully utilized, the data parsing time is shortened, and the data parsing accuracy and efficiency are improved, and for the application software in the second processor, the target data is directly obtained from the second processor, compared with obtaining the target data from the first processor, the communication link between the two is shortened, the real-time performance of the data is improved, and since the second processor only needs to parse the data frame and does not need to pay attention to the transmission of the data frame, the complexity of the development of the application software of the second processor is reduced; finally, the frame format corresponding to each communication interface is dynamically configured through the configuration file, not only the accuracy of the frame format corresponding to each communication interface is improved, but also the decoupling between the communication protocol and the driving software is realized, the versatility, reusability and portability of the driving software are increased, so that the development cost is reduced and the development efficiency is improved, and at the same time, by modifying the configuration file, multiple frame formats of the target communication protocol can be compatible, further improving the development efficiency.

[0029] In some embodiments, the system further includes a third board card, and the second processor is further configured to generate a third data frame based on the frame format corresponding to the second communication interface and the second target data according to the target communication protocol, and transmit the third data frame to the first processor; and the first processor is further configured to generate a fourth data frame based on the third data frame, and transmit the fourth data frame to the third board card through the second communication interface.

[0030] In the embodiments of the present disclosure, first, the data interaction between the board cards is carried out through a unified target communication protocol, compared with developing different protocols to support the data interaction for multiple communication data and multiple communication interfaces, the development cost is greatly reduced, and the reusability and portability of the software and hardware are improved; second, the second processor generates the corresponding data frame according to the frame format corresponding to the communication interface, and the accuracy of the data frame is improved; finally, the first processor transmits the data frame through the corresponding communication interface, and the accuracy of the data frame transmission is improved.

[0031] In some embodiments, the first processor is further configured to receive configuration instructions, wherein the configuration instructions are generated based on the configuration file, and the configuration instructions include communication information of each communication interface; for each communication interface, the first processor is configured to configure the communication interface based on the communication information of the communication interface, to obtain a configuration result; in a case where at least one configuration result represents a configuration failure, the first processor is configured to report the configuration result; in a case where each configuration result represents a configuration success, the first processor is configured to deliver a preset configuration completion instruction to the second processor; and the second processor is configured to, in response to receiving the configuration completion instruction delivered by the first processor, establish a correspondence between at least one communication interface and at least one frame format based on the configuration file.

[0032] In the embodiments of the present disclosure, first, the first processor dynamically initializes each communication interface according to the configuration file, which not only improves the accuracy of initialization, but also realizes decoupling of the communication interface and the driving software, and improves the reusability and portability of the communication interface and the driving software; second, in a case where the initialization of at least one communication interface fails, the first processor timely reports the configuration result, so as to timely process and reduce the possibility of communication abnormality between boards caused by communication interface abnormality; and finally, in a case where the initialization of each communication interface succeeds, the second processor establishes a correspondence between each communication interface and each frame format according to the configuration file, so as to accurately parse each data frame in the future.

[0033] In some embodiments, the first board card integrates a system on chip (SOC), and the first processor, the second processor and the at least one communication interface are located in the SOC.

[0034] In the embodiments of the present disclosure, by integrating the SOC in the first board card, the characteristics of different processors in the SOC are fully utilized to adapt and compatible to the transmission of data frames of different frame formats, which not only realizes efficient transmission of data, but also improves the development efficiency while reducing the development cost.

[0035] The embodiments of the present disclosure provide a data processing apparatus, which is applied to a first processor of a first board card, and the apparatus comprises:

[0036] A first determination module is configured to determine a second data frame based on a first data frame transmitted by a second board card through a first communication interface of the first board card, wherein the first board card further comprises a second processor and at least one communication interface, the type of the second processor is different from the type of the first processor, each communication interface is configured to transmit a data frame having a corresponding frame format, each data frame is generated according to a target communication protocol, and the frame format corresponding to each communication interface is generated based on a preset configuration file.

[0037] The sending module is configured to send the second data frame to the second processor, so that the second processor determines first target data from the second data frame according to the frame format corresponding to the first communication interface.

[0038] The present disclosure provides a data processing device, which is applied to a second processor of a first board card, and the device comprises:

[0039] The receiving module is configured to receive a second data frame transmitted by a first processor of the first board card, wherein the second data frame is determined based on a first data frame transmitted by a second board card through a first communication interface, the type of the second processor is different from the type of the first processor, and the first board card further comprises at least one communication interface, each communication interface is configured to transmit a data frame with a corresponding frame format, each data frame is generated according to a target communication protocol, and the frame format corresponding to each communication interface is generated based on a preset configuration file.

[0040] The processing module is configured to parse the first data frame according to the frame format corresponding to the first communication interface to obtain first target data.

[0041] The present disclosure provides an electronic device, which comprises a processor and a memory, the memory stores a computer program capable of running on the processor, and the processor implements the method described in any of the above embodiments when executing the computer program.

[0042] The present disclosure provides a computer readable storage medium, which stores a computer program, and the computer program is executed by a processor to implement the method described in any of the above embodiments.

[0043] The present disclosure provides a computer program product, which comprises a computer program or instructions, and the computer program or instructions are executed by a processor to implement the method described in any of the above embodiments.

[0044] It should be understood that the above general description and the following detailed description are only exemplary and explanatory, but not limiting the present disclosure. BRIEF DESCRIPTION OF DRAWINGS

[0045] The accompanying drawings, which are incorporated into the specification and constitute a part of the specification, illustrate embodiments consistent with the present disclosure and, together with the specification, serve to explain the technical solutions of the present disclosure.

[0046] Figure 1 The present disclosure provides a data processing method, and an implementation flowchart of the data processing method is shown in FIG. 2. Figure One

[0047] Figure 2 ​An implementation flowchart of a data processing method provided by an embodiment of the present disclosure Figure Two ;

[0048] Figure 3A An implementation flowchart of a data processing method provided by an embodiment of the present disclosure Figure One ;

[0049] Figure 3B An implementation flowchart of a data processing method provided by an embodiment of the present disclosure Figure Two ;

[0050] Figure 3C An implementation flowchart of a data processing method provided by an embodiment of the present disclosure

[0051] Figure 3D An implementation flowchart of a data processing method provided by an embodiment of the present disclosure

[0052] Figure 4 An implementation flowchart of a data processing method provided by an embodiment of the present disclosure Figure One ;

[0053] Figure 5 An implementation flowchart of a data processing method provided by an embodiment of the present disclosure Figure Two ;

[0054] Figure 6 An implementation flowchart of a data processing method provided by an embodiment of the present disclosure DETAILED DESCRIPTION

[0055] In order to make the purpose, technical solutions and advantages of the present disclosure clearer, the present disclosure will be further described in detail below with reference to the drawings, and the described embodiments should not be regarded as limiting the present disclosure, and all other embodiments obtained by those of ordinary skill in the art without making creative efforts belong to the scope of protection of the present disclosure.

[0056] In the following description, "some embodiments" are described, which describe a subset of all possible embodiments, but it can be understood that "some embodiments" can be the same subset or different subset of all possible embodiments, and can be combined with each other without conflict.

[0057] In the following description, the terms "first\second\third" are only to distinguish similar objects, and do not represent a specific order of the objects, and it can be understood that "first\second\third" can be interchanged with a specific order or sequence as allowed, so that the embodiments of the present disclosure described herein can be implemented in an order other than that illustrated or described herein.

[0058] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this disclosure belongs. The terminology used herein is for the purpose of describing embodiments of this disclosure only and is not intended to be limiting of this disclosure.

[0059] In the related art, most embedded devices include multiple boards (or multiple devices), and the multiple boards are connected through optical fibers to realize stable data transmission. FT3 is a link layer-based transmission mode, which conforms to the protocol standard of IEC60044-8.

[0060] For embedded devices with a fusion Soc, the integrated FT3 interface is often not implemented through a dedicated chip to realize communication. Since the physical carrier is an optical fiber (data is converted into an electrical signal through an optical module), communication transmission can generally be realized only through a first processor (for example, an FPGA). In implementation, the FPGA completes data transmission and reception, and the FPGA parses the transmitted data according to the FT3 protocol and sends the obtained payload data to an application of a second processor (for example, an ARM, a CPU, etc.) for processing. There are the following problems:

[0061] (1) The FPGA processes data in a stream manner, and the capability of protocol parsing is relatively weak. If the data is stored and then processed, the overhead is increased and the performance is reduced.

[0062] (2) Since FT3 does not have a mandatory constraint protocol, it is possible to communicate using a standard FT3 protocol, or it is also possible to communicate using a custom FT3 protocol. For different FT3 interfaces (different FT3 interfaces support different FT3 protocols), different driver software needs to be developed, and when a certain FT3 protocol changes, the entire driver software of the corresponding FT3 interface needs to be updated, which has the problems of poor flexibility, poor universality, long development cycle, etc.

[0063] The embodiment of the present disclosure provides a data processing method, first, the first processor sends the data frame transmitted by the other board card to the second processor for processing, since the first processor does not need to parse the data frame, the development of the driving software of the first processor is simplified, and the stability of the overall driving is improved, and at the same time, even if the frame format corresponding to the communication interface changes, since the driving software does not need to be redeveloped or modified, the development cost is reduced, and the development efficiency is improved; secondly, the second processor parses the target data of the data frame according to the corresponding frame format, for the internal application software, not only the hardware performance of the second processor is fully utilized, the data parsing accuracy and the parsing efficiency are improved while the parsing time is shortened, and for the application software in the second processor, the target data is directly obtained from the second processor, compared with obtaining the target data from the first processor, the communication link between the two is shortened, the real-time performance of the data is improved, and since the second processor only needs to parse the data frame, the transmission of the data frame does not need to be concerned, the complexity of the application software development of the second processor is reduced; finally, the frame format corresponding to each communication interface is dynamically configured through the configuration file, not only the accuracy of the frame format corresponding to each communication interface is improved, but also the decoupling between the communication protocol and the driving software is realized, the versatility, the reusability and the portability of the driving software are increased, so that the development cost is reduced and the development efficiency is improved, and at the same time, by modifying the configuration file, a plurality of frame formats of the target communication protocol can be compatible, and the development efficiency is further improved. The method provided by the embodiment of the present disclosure can be executed by an electronic device, and the electronic device can be a notebook computer, a tablet computer, a desktop computer, a set-top box, a mobile device (for example, a mobile phone, a portable music player, a personal digital assistant, a dedicated message device, a portable game device) and various types of terminals. It can also be implemented as a server. The server can be a standalone physical server, a server cluster or a distributed system composed of multiple physical servers, or a cloud server providing cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content distribution networks (Content Delivery Network, CDN), and big data and artificial intelligence platforms. Basic cloud computing services such as platform.

[0064] In the following, the technical solutions in the embodiments of the present disclosure will be clearly and completely described with reference to the drawings in the embodiments of the present disclosure.

[0065] Figure 1 The implementation process of the data processing method provided by the embodiment of the present disclosure Figure One The first processor applied to the first board card, as shown in Figure 1 The method comprises steps S11 to S12, wherein:

[0066] In step S11, the second data frame is determined based on the first data frame transmitted by the second board card through the first communication interface; wherein the first board card further comprises a second processor and at least one communication interface, each communication interface is configured to transmit a data frame with a corresponding frame format, each data frame is generated according to a target communication protocol, and the frame format corresponding to each communication interface is generated based on a preset configuration file.

[0067] Here, the board card (including the first board card and other board cards hereinafter) can be a board card implementing any function. For example, a board card implementing a control function, a board card implementing a communication function, etc. Different board cards can implement the same or different functions.

[0068] The first processor can be any suitable processor, for example, an FPGA (Field Programmable Gate Array) and the like.

[0069] The second processor can be any suitable processor, for example, an ARM (Advanced RISC Machines) processor, a CPU (Central Processing Unit), a DSP (Digital Signal Processing) and the like. The type of the second processor is different from the type of the first processor.

[0070] The communication interface (including the first communication interface and other communication interfaces mentioned hereinafter) can be any suitable interface supporting a target communication protocol. The communication protocol can be any suitable protocol for a link layer, for example, an FT3 protocol and the like. The communication protocol refers to rules and agreements that must be followed by both entities to complete communication or services. The communication protocol can set protocol format, protocol content, etc. For example, for the data frame of the FT3 protocol, it can include but is not limited to frame header, frame length, frame format, etc., and the frame format can define any number of data blocks. In implementation, if the target communication protocol is the FT3 protocol, the communication interface can refer to an FT3 interface, and different FT3 interfaces are used to support different frame formats of the FT3 protocol. In some embodiments, a system on chip can be integrated in the first board card, and the first processor, the second processor and the at least one communication interface are located in the system on chip.

[0071] The configuration file can be any form of file, for example, an XML (Extensible Markup Language) file, a WORD, an EXCEL, an HTML (Hyper Text Markup Language) file, etc. In some embodiments, different board cards can correspond to different configuration files.

[0072] In some embodiments, the configuration file can include association information of the target communication protocol, and a correspondence between the frame format and the communication interface is dynamically generated according to the association information. The association information can include, but is not limited to, communication information of the communication interface, the frame format, etc. The communication information can include, but is not limited to, an identifier, a rate, encoding information, etc. of the communication interface. The encoding information can include, but is not limited to, an encoding mode, a polarity, etc. The encoding mode can include, but is not limited to, a Manchester encoding, a differential Manchester encoding, etc. The polarity can include, but is not limited to, 0, 1, etc., 1 can represent a low-to-high transition, and 0 can represent a high-to-low transition.

[0073] Taking the configuration file shown below as an example:

[0074]

[0075]

[0076] The first board card includes two FT3 interfaces, namely FT3_1 and FT3_2. The communication information of the FT3_1 interface is that the rate is 10M (mega) and the polarity is Manchester encoding of 1. The communication information of the FT3_2 interface is that the rate is 12M and the polarity is Manchester encoding of 0. The frame format corresponding to the FT3_1 interface includes three data blocks block, and the length and content of each data block are different. The frame format corresponding to the FT3_2 interface includes two data blocks block, and the length and content of each data block are different.

[0077] The first data frame is generated by the second board card according to the target communication protocol. In implementation, the second board card generates the first data frame according to the frame format corresponding to the first communication interface and the data to be sent according to the target communication protocol. The first communication interface can be one of the at least one communication interface.

[0078] The second data frame can be a decoded first data frame or other data frame.

[0079] In some embodiments, the step S11 includes steps S111 to S113, wherein:

[0080] In step S111, the first data frame is decoded according to the encoding information corresponding to the first communication interface to obtain a decoded first data frame.

[0081] The encoding information corresponding to different communication interfaces can be the same or different. In some embodiments, the correspondence between the communication interfaces and the encoding information can be dynamically established according to a configuration file. For example, the first board card includes two FT3 interfaces, the encoding information corresponding to the first FT3 interface can include a Manchester encoding mode and a positive polarity, and the encoding information corresponding to the second FT3 interface can include a Manchester encoding mode and a negative polarity. In implementation, the first data frame is decoded according to the corresponding encoding mode according to the polarity, and the decoded first data frame can be obtained. For example, if the first communication interface is the first FT3 interface, the first data frame is decoded according to the Manchester mode according to the positive polarity, and the decoded first data frame is obtained.

[0082] In step S112, the decoded first data frame is checked to obtain a check result.

[0083] Here, the check can be any suitable check, for example, cyclic redundancy check (CRC), parity check, etc. In implementation, for the FT3 protocol, the decoded first data frame can be checked by CRC to obtain a check result.

[0084] The check result can include but is not limited to a first check result and a second check result. The first check result indicates that the check passes, and the second check result indicates that the check fails. In some embodiments, the first data frame can include a first check code generated by the second board card, if the first check code and a second check code are inconsistent, the second check result is taken as the check result, wherein the second check code is generated by the first processor according to the first data frame; if the first check code and the second check code are consistent, the first check result is taken as the check result.

[0085] In step S113, the decoded first data frame is taken as the second data frame when the check result indicates that the check passes.

[0086] Here, if the check passes, it indicates that the transmission of the data frame does not appear to be abnormal, at this time, the decoded first data frame can be taken as the second data frame; if the check fails, it indicates that the transmission of the data frame appears to be abnormal, at this time, the first processor can report abnormal information and discard the first data frame.

[0087] In the embodiments of the present disclosure, on the one hand, the accuracy of the decoded data frame is improved by decoding the data frame according to the corresponding encoding information; on the other hand, the integrity and accuracy of the data frame are ensured by checking the transmitted data frame, so as to reduce the possibility of abnormal data flow.

[0088] In step S12, the second data frame is sent to the second processor, so that the second processor determines the first target data from the second data frame according to the frame format corresponding to the first communication interface.

[0089] Here, the second data frame at least includes the first target data. The transmission manner of the second data frame can be any suitable manner, for example, a bus, an in-board interface, etc. The bus can include but is not limited to a CAN (Controller Area Network) bus, an Ethernet bus, etc. The in-board interface can be any suitable interface, for example, a CAN interface, an Ethernet interface, etc. For example, the first processor sends the second data frame to the second processor through the CAN interface.

[0090] The target data (including the first target data and other target data mentioned later) can be any suitable data. In some embodiments, the first target data can refer to payload data, which mainly includes data in each data block in the frame format.

[0091] In implementation, the second processor parses the second data frame according to the frame format corresponding to the first communication interface to obtain the first target data. In some embodiments, the first processor can also send the identification of the first communication interface to the second processor, so that the second processor determines the target frame format (i.e., the frame format corresponding to the first communication interface) from a plurality of frame formats according to the identification of the first communication interface.

[0092] In the embodiments of the present disclosure, first, the first processor sends the data frame transmitted by the other board card to the second processor for processing. Since the first processor does not need to parse the data frame, the development of the driving software of the first processor is simplified, and the stability of the overall driving is improved. At the same time, even if the frame format corresponding to the communication interface changes, since the driving software does not need to be redeveloped or modified, the development cost is reduced, and the development efficiency is improved. Second, the second processor parses the target data of the data frame according to the corresponding frame format for use by the internal application software. The hardware performance of the second processor is fully utilized, the data parsing time is shortened, the data parsing accuracy and efficiency are improved, and for the application software in the second processor, the target data is directly obtained from the second processor, compared with obtaining the target data from the first processor, the communication link between the two is shortened, the real-time performance of the data is improved, and since the second processor only needs to parse the data frame and does not need to pay attention to the transmission of the data frame, the complexity of the development of the application software of the second processor is reduced. Finally, the frame format corresponding to each communication interface is dynamically configured through the configuration file, which improves the accuracy of the frame format corresponding to each communication interface, realizes the decoupling between the communication protocol and the driving software, and increases the universality, reusability and portability of the driving software, thereby reducing the development cost and improving the development efficiency. At the same time, by modifying the configuration file, multiple frame formats of the target communication protocol can be compatible, further improving the development efficiency.

[0093] In some embodiments, the method further comprises steps S131 to S134, wherein:

[0094] Step S131, receiving a configuration instruction; wherein the configuration instruction is generated based on a configuration file, and the configuration instruction includes communication information of each communication interface.

[0095] Here, the configuration instruction can be any suitable instruction. The configuration instruction is mainly used for configuring each communication interface. In implementation, the configuration instruction at least includes the communication information of each communication interface.

[0096] The configuration instruction can be sent by the first board card, or by other board cards or devices. The sending mode of the configuration instruction can be any suitable mode, for example, direct sending, service calling, broadcasting, etc. In some embodiments, during the initialization process of the first board card, the first board card can dynamically generate the configuration instruction by reading the communication information of each communication interface in the configuration file. The acquisition mode of the configuration file can be any suitable mode. For example, the configuration file is pre-stored in the first board card. For another example, the configuration file is sent to the first board card by other devices or other board cards.

[0097] Different communication interfaces can have different communication information. For example, the rates of the respective communication interfaces are different, the encoding information is the same. For another example, the rates and the encoding information of the respective communication interfaces are different.

[0098] Step S132, for each communication interface, configuring the communication interface based on the communication information of the communication interface, to obtain a configuration result.

[0099] Here, the configuration result can include but is not limited to a first configuration result, a second configuration result, etc. The first configuration result represents a configuration failure, and the second configuration result represents a configuration success. In implementation, if the configuration of the communication interface does not appear abnormal, the second configuration result is taken as the configuration result; otherwise, if the configuration of the communication interface appears abnormal (for example, the rate configuration fails), the first configuration result is taken as the configuration result.

[0100] Step S133, in the case that each configuration result represents a configuration success, delivering a preset configuration completion instruction to the second processor, so that the second processor establishes a correspondence between at least one communication interface and at least one frame format based on the configuration completion instruction.

[0101] Here, the configuration completion instruction can be any suitable instruction, which is used to represent that each communication interface of the first board is configured successfully. The delivery mode of the configuration completion instruction can be any suitable mode, for example, a bus, an internal interface, etc.

[0102] The second processor receives the configuration completion instruction, reads the associated information of the target communication protocol in the configuration file, to establish a correspondence between each communication interface and each frame format. For example, in the configuration file shown above, the first board card includes two FT3 interfaces, the frame format corresponding to the FT3_1 interface includes three blocks, and the frame format corresponding to the FT3_2 interface includes two blocks. In implementation, the correspondence includes the relationship between the two FT3 interfaces and the two frame formats.

[0103] Step S134, in the case that at least one configuration result represents a configuration failure, reporting the corresponding configuration result.

[0104] Here, if the configuration of at least one communication interface appears abnormal, the first processor needs to report the configuration result to the board card, so that personnel can handle it in time.

[0105] In the embodiments of the present disclosure, first, the first processor dynamically initializes each communication interface according to the configuration file, which not only improves the accuracy of the initialization, but also realizes the decoupling of the communication interface and the driving software, and improves the multiplexing and portability of the communication interface and the driving software; second, in the case that the initialization of each communication interface is successful, the second processor establishes the correspondence between each communication interface and each frame format according to the configuration file, so as to facilitate the subsequent accurate parsing of each data frame; and finally, in the case that the initialization of at least one communication interface fails, the first processor timely reports the configuration result, so as to timely process and reduce the possibility of communication abnormality between boards due to communication interface abnormality.

[0106] In some embodiments, the method further comprises steps S141 to S143, wherein:

[0107] Step S141, receiving a third data frame transmitted by the second processor; wherein the third data frame is generated by the second processor according to a target communication protocol, based on a frame format corresponding to the second communication interface and second target data.

[0108] Here, the third data frame can be any suitable data frame, and the third data frame at least includes the second target data. The second target data can be referred to as payload data. In implementation, the application software in the second processor frames the second target data according to the frame format corresponding to the second communication interface to generate the third data frame. The second communication interface is one of the at least one communication interface. The second communication interface can be the same as or different from the first communication interface. For example, the first board includes two FT3 interfaces, wherein the first communication interface can be the first FT3 interface, and the second communication interface can be the second FT3 interface. In some embodiments, the application software can set the communication interface for transmitting the data frame.

[0109] The transmission mode of the third data frame can be any suitable mode, such as bus, Ethernet, broadcast, etc.

[0110] Step S142, generating a fourth data frame based on the third data frame.

[0111] Here, the fourth data frame can be the third data frame, or a data frame processed from the third data frame.

[0112] In some embodiments, the step S142 comprises steps S1421 to S1422, wherein:

[0113] Step S1421, generating a fifth data frame based on the third data frame and the check information corresponding to the third data frame.

[0114] Here, the check information can be any suitable information, which can be dynamically generated according to the check manner. For example, the check information can be a check code generated according to a CRC calculation.

[0115] The fifth data frame can refer to a data frame to which check information is added. In some embodiments, the first processor can calculate check information corresponding to the data in each data block in the third data frame, and add the corresponding check information after each data block to obtain the fifth data frame. In some embodiments, the first processor can calculate check information according to the data in each data block in the third data frame, and add the check information to the third data frame to obtain the fifth data frame.

[0116] Step S1422, encode the fifth data frame according to the encoding information corresponding to the second communication interface to obtain an encoded fifth data frame, and take the encoded fifth data frame as the fourth data frame.

[0117] Here, different communication interfaces can correspond to the same or different encoding information. In implementation, the encoding information corresponding to the second communication interface can be obtained according to the correspondence between the communication interface and the encoding information established in advance. For example, in the configuration file of the above example, if the second communication interface is FT3_1, the encoding information can include a Manchester encoding encoding manner and a negative polarity. In implementation, the fifth data frame is encoded according to the encoding information to obtain the fourth data frame.

[0118] In some embodiments, the second processor can send the identification of the second communication interface to the first processor, so that the first processor determines the target encoding information (i.e., the encoding information corresponding to the second communication interface) from a plurality of encoding information according to the identification of the second communication interface.

[0119] In the embodiments of the present disclosure, on the one hand, by adding corresponding check information in the data frame, the receiving end can check the data frame, thereby reducing the possibility of abnormal data flow; on the other hand, the data frame is encoded according to the corresponding encoding information, which improves the accuracy of the data frame and also improves the confidentiality of the data frame.

[0120] Step S143, transmit the fourth data frame to the third board card through the second communication interface.

[0121] Here, the third board card can be the same as or different from the second board card. In implementation, the first processor transmits the fourth data frame through the second communication interface.

[0122] In the embodiments of the present disclosure, first, data interaction between the boards is performed through a unified target communication protocol, compared with developing different protocols to support data interaction for various communication data, multiple communication interfaces, etc., the development cost is greatly reduced, and the software and hardware reusability and portability are improved; second, the second processor generates corresponding data frames according to the frame formats corresponding to the communication interfaces, the accuracy of the data frames is improved; and finally, the first processor transmits the data frames through the corresponding communication interfaces, the accuracy of the data frame transmission is improved.

[0123] Figure 2 An implementation flowchart of a data processing method provided by the embodiments of the present disclosure Figure Two The second processor applied to the first board, as shown in Figure 2 The method comprises steps S21 to S22, wherein:

[0124] Step S21, receiving a second data frame transmitted by a first processor of a first board; wherein the second data frame is determined based on a first data frame transmitted by a second board through a first communication interface, the first board further comprises at least one communication interface, each communication interface is used for transmitting a data frame with a corresponding frame format, each data frame is generated according to a target communication protocol, and the frame format corresponding to each communication interface is generated based on a preset configuration file.

[0125] Here, the first processor can be any suitable processor, for example, FPGA, etc. The second processor can be any suitable processor, for example, ARM processor, CPU, DSP, etc. The type of the second processor is different from that of the first processor. In some embodiments, a system on chip can be integrated in the first board, and the first processor, the second processor and the at least one communication interface are located in the system on chip.

[0126] The first communication interface can be any suitable interface supporting the target communication protocol. The transmission process of the first data frame can refer to the specific embodiments of the foregoing step S11.

[0127] The configuration file can include association information of the target communication protocol, and the corresponding relationship between the frame format and the communication interface is dynamically generated according to the association information.

[0128] The second data frame can be a data frame after decoding the first data frame, or can be other data frames. The process of generating the second data frame by the first processor can refer to the specific embodiments of the foregoing step S11.

[0129] The transmission mode of the second data frame can be any suitable mode, for example, bus, board interface, etc.

[0130] Step S22, parsing the first data frame according to the frame format corresponding to the first communication interface to obtain the first target data.

[0131] Here, the second data frame at least includes the first target data. The process that the second processor obtains the first target data can refer to the specific embodiments of the foregoing step S12.

[0132] In the embodiments of the present disclosure, first, the first processor sends the data frame transmitted by the other board card to the second processor for processing. Since the first processor does not need to parse the data frame, the development of the driving software of the first processor is simplified, and the stability of the overall driving is improved. At the same time, even if the frame format corresponding to the communication interface changes, since it is not necessary to redevelop or modify the driving software, the development cost is reduced while the development efficiency is improved. Second, the second processor parses the target data of the data frame according to the corresponding frame format for use by the application software inside. Not only the hardware performance of the second processor is fully utilized, but also the data parsing accuracy and efficiency are improved while the parsing time is shortened. Moreover, for the application software in the second processor, the target data is directly obtained from the second processor, which shortens the communication link between the first processor and the second processor, improves the real-time performance of the data, and reduces the complexity of the development of the application software of the second processor since the second processor only needs to parse the data frame and does not need to pay attention to the transmission of the data frame. Finally, the frame format corresponding to each communication interface is dynamically configured through the configuration file, which not only improves the accuracy of the frame format corresponding to each communication interface, but also realizes the decoupling between the communication protocol and the driving software, increases the universality, reusability and portability of the driving software, thereby reducing the development cost while improving the development efficiency. At the same time, by modifying the configuration file, multiple frame formats of the target communication protocol can be compatible, further improving the development efficiency.

[0133] In some embodiments, the method further includes step S23, wherein:

[0134] Step S23, in response to receiving the configuration completion instruction transmitted by the first processor, establishing the correspondence between the at least one communication interface and the at least one frame format based on the configuration file.

[0135] Here, the configuration completion instruction can be any suitable instruction, and the configuration completion instruction is used to represent that the configuration of each communication interface of the first board is successful. The transmission mode of the configuration completion instruction can be any suitable mode, for example, bus, internal interface, etc.

[0136] The process that the second processor establishes the correspondence between each communication interface and each frame format can refer to the specific embodiments of the foregoing step S133.

[0137] In the embodiment of the present disclosure, after receiving the configuration completion instruction, the second processor establishes a correspondence between each communication interface and each frame format according to the configuration file, so as to facilitate subsequent accurate parsing of each data frame.

[0138] In some embodiments, the method further comprises steps S241 to S242, wherein:

[0139] Step S241, generating a third data frame based on the frame format corresponding to the second communication interface and the second target data according to the target communication protocol.

[0140] Here, the third data frame at least includes the second target data. The second target data can refer to the payload data. The process of generating the third data frame by the second processor can refer to the specific embodiments of the aforementioned step S141.

[0141] Step S242, transmitting the third data frame to the first processor, so that the first processor transmits a fourth data frame to the third board card through the second communication interface, the fourth data frame being generated based on the third data frame.

[0142] Here, the transmission mode of the third data frame can be any suitable mode, for example, bus, Ethernet, broadcast, etc. For example, the third data frame is transmitted to the first processor through Ethernet.

[0143] The process of generating the fourth data frame by the first processor can refer to the specific embodiments of the aforementioned step S142.

[0144] The third board card can be the same as or different from the second board card. In implementation, the first processor transmits the fourth data frame through the second communication interface.

[0145] In the embodiment of the present disclosure, first, data interaction between board cards is carried out through a unified target communication protocol, compared with developing different protocols to support data interaction for multiple communication data, multiple communication interfaces, etc., not only greatly reduces the development cost, but also improves the reusability and portability of software and hardware; second, the second processor generates corresponding data frames according to the frame format corresponding to the communication interface, which improves the accuracy of the data frame; finally, the first processor transmits the data frame through the corresponding communication interface, which improves the precision of data frame transmission.

[0146] Based on the above embodiments, the present disclosure further provides a data processing system, Figure 3A The composition structure of a data processing system provided by the embodiment of the present disclosure Figure One For example, Figure 3AAs shown, the data processing system 30 comprises a first board card 31 and a second board card 32, the first board card 31 comprises a first processor 311, a second processor 312 and at least one communication interface 313, the second processor is of a type different from that of the first processor, each communication interface is configured to transmit a data frame having a corresponding frame format, each data frame is generated according to a target communication protocol, and the corresponding frame format of each communication interface is generated based on a preset configuration file, wherein:

[0147] The first processor 311 is configured to determine a second data frame based on a first data frame transmitted by the second board card through the first communication interface, and send the second data frame to the second processor.

[0148] The second processor 312 is configured to parse the first data frame according to the frame format corresponding to the first communication interface to obtain first target data.

[0149] Here, the functions of the first board card and the second board card can be the same or different. In implementation, the first board card and the second board card are communicatively connected.

[0150] In some embodiments, the second board card can also comprise a first processor, a second processor, at least one communication interface, etc. In implementation, the correspondence between each communication interface and each frame format in the second board card can be established through a corresponding configuration file of the second board card.

[0151] The first data frame is generated by the second board card according to the target communication protocol. In implementation, the second board card generates the first data frame according to the frame format corresponding to the first communication interface and the data to be transmitted according to the target communication protocol.

[0152] The first processor can be any suitable processor, for example, an FPGA, etc. The process of determining the second data frame by the first processor can refer to the specific embodiments of step S11.

[0153] The transmission mode of the second data frame can be any suitable mode, for example, a bus, an in-board interface, etc.

[0154] The second processor can be any suitable processor, for example, an ARM processor, a CPU, a DSP, etc. The process of obtaining the first target data by the second processor can refer to the specific embodiments of step S22.

[0155] In some embodiments, the SOC is integrated in the first board card, and the first processor, the second processor and the at least one communication interface are located in the SOC. In this way, by integrating the SOC in the first board card, the characteristics of different processors in the SOC are fully brought into play to adapt and be compatible with the transmission of data frames of different frame formats, so that not only efficient transmission of data is realized, but also development cost is reduced and development efficiency is improved.

[0156] In some embodiments, the SOC can also be integrated in the second board card, and the first processor, the second processor and the at least one communication interface of the second board card are located in the SOC.

[0157] Figure 3B A schematic structural diagram of a data processing system provided by an embodiment of the present disclosure Figure Two As shown in Figure 3B The data processing system includes a first board card 31 and a second board card 32. The SOC is integrated in the first board card 31, and the SOC includes an FPGA processor (corresponding to the first processor) 311, an ARM processor (corresponding to the first processor) 312, a first FT3 interface 313A (corresponding to the communication interface) and a second FT3 interface 313B (corresponding to the communication interface). Wherein:

[0158] The FPGA processor 311 is configured to: receive a first data frame transmitted by the second board card 32 through the first FT3 interface 313A; decode the first data frame according to the encoding information corresponding to the first FT3 interface 313A to obtain a decoded first data frame; perform CRC check on the decoded first data frame to obtain a check result; and in a case where the check result represents that the check is passed, send the decoded first data frame to the ARM processor 312 through an internal interface.

[0159] The ARM processor 312 is configured to: parse the decoded first data frame according to the frame format corresponding to the first FT3 interface 313A to obtain first target data; and send the first target data to application software for subsequent processing.

[0160] In some embodiments, the first processor 311 is further configured to receive a configuration instruction, wherein the configuration instruction is generated based on a configuration file, and the configuration instruction includes communication information of each communication interface; for each communication interface, the communication interface is configured based on the communication information of the communication interface to obtain a configuration result; in a case where at least one configuration result represents that the configuration fails, the configuration result is reported; in a case where each configuration result represents that the configuration succeeds, a preset configuration completion instruction is transmitted to the second processor; and the second processor is further configured to, in response to receiving the configuration completion instruction transmitted by the first processor, establish a correspondence between the at least one communication interface and the at least one frame format based on the configuration file.

[0161] Here, the configuration instruction can be any suitable instruction. The configuration instruction is mainly used for configuring the respective communication interfaces. The configuration instruction can be sent by the first board card or by other board cards or devices. The sending manner of the configuration instruction can be any suitable manner.

[0162] The different communication interfaces can have different communication information. For example, the rates of the respective communication interfaces are different, and the encoding information is the same. For another example, the rates and the encoding information of the respective communication interfaces are different.

[0163] The configuration result can include but is not limited to a first configuration result, a second configuration result, and the like. The process in which the first processor determines the configuration result can refer to the specific implementation of the foregoing step S132.

[0164] If the configuration of at least one communication interface is abnormal, the first processor needs to report the configuration result to the board card so as to facilitate personnel to handle in time.

[0165] The configuration completion instruction can be any suitable instruction, and the configuration completion instruction is used to represent that the respective communication interfaces of the first board card are all configured successfully. The transmission manner of the configuration completion instruction can be any suitable manner, for example, a bus, an internal interface, and the like. The process in which the second processor establishes the correspondence between the respective communication interfaces and the respective frame formats can refer to the specific implementation of the foregoing step S133.

[0166] In the embodiments of the present disclosure, first, the first processor dynamically initializes the respective communication interfaces according to the configuration file, which not only improves the accuracy of the initialization but also realizes the decoupling of the communication interfaces and the driving software, improves the multiplexing and portability of the communication interfaces and the driving software; second, in the case that the initialization of at least one communication interface fails, the first processor timely reports the configuration result so as to facilitate timely handling and reduce the possibility of communication abnormality between the board cards due to the abnormality of the communication interfaces; and finally, in the case that the initialization of the respective communication interfaces is all successful, the second processor establishes the correspondence between the respective communication interfaces and the respective frame formats according to the configuration file, so as to facilitate subsequent accurate parsing of the respective data frames.

[0167] In some embodiments, the data processing system further includes a third board card, and the second processor 312 is further configured to generate a third data frame according to a target communication protocol, based on the frame format corresponding to the second communication interface and second target data, and transmit the third data frame to the first processor; the first processor is further configured to generate a fourth data frame based on the third data frame, and transmit the fourth data frame to the third board card through the second communication interface.

[0168] Here, the third board card can be the second board card or other board cards.

[0169] The third data frame can be any suitable data frame, and it must include at least the second target data. The second target data can refer to the payload data. The process by which the second processor generates the third data frame can be found in the specific implementation of step S141 described above.

[0170] The third data frame can be transmitted in any suitable way, such as bus, Ethernet, broadcast, etc.

[0171] The fourth data frame can be the third data frame, or it can be a data frame processed from the third data frame. The process by which the first processor generates the fourth data frame can be found in the specific implementation of step S142 described above. The process by which the first processor transmits the fourth data frame can be found in the specific implementation of step S143 described above.

[0172] Figure 3C This is a schematic diagram of the composition structure of a data processing system provided in an embodiment of the present disclosure, as shown in Figure 3. Figure 3C As shown, the data processing system includes a first board 31 and a third board 33. The first board 31 integrates a System-on-a-Chip (SOC), which includes an FPGA processor (corresponding to the aforementioned first processor) 311, an ARM processor (corresponding to the aforementioned first processor) 312, a first FT3 interface 313A (corresponding to the aforementioned communication interface), and a second FT3 interface 313B (corresponding to the aforementioned communication interface), wherein:

[0173] The ARM processor 312 is also used to: receive second target data sent by the target application software; frame the second target data according to the frame format corresponding to the second FT3 interface 313B to obtain a third data frame; and send the third data frame to the FPGA processor 311 through the internal interface.

[0174] The FPGA processor 311 is also used to: perform CRC calculation on the third data frame to obtain verification information, fill the verification information into the third data frame to obtain the fifth data frame; perform Manchester encoding on the fifth data frame according to the encoding information corresponding to the second FT3 interface 313B to obtain the fourth data frame; and send the fourth data frame to the third board through the second FT3 interface 313B.

[0175] In the embodiment of the present disclosure, first, data interaction between boards is carried out through a unified target communication protocol, compared with developing different protocols to support data interaction for various communication data, various communication interfaces, etc., not only greatly reduces the development cost, but also improves the reusability and portability of software and hardware; second, the second processor generates corresponding data frames according to the frame format corresponding to the communication interface, which improves the accuracy of the data frames; finally, the first processor transmits the data frames through the corresponding communication interface, which improves the accuracy of the data frame transmission.

[0176] Figure 3D An implementation flowchart of a data processing method provided by the embodiment of the present disclosure is shown in Figure 3, which includes steps S301 to S318. Figure 3D

[0177] In step S301, the FPGA processor receives a configuration instruction, and configures each FT3 interface according to the communication information of each FT3 interface in the configuration instruction to obtain a configuration result of each FT3 interface.

[0178] Here, the FPGA processor can save the communication information of each FT3 interface to establish a corresponding relationship between each FT3 interface and various encoding information. The FPGA can also read a configuration file to dynamically generate a corresponding relationship between each FT3 interface and various encoding information.

[0179] In step S302, the FPGA processor determines whether the configuration result of each FT3 interface is the first configuration result, if yes, it proceeds to step S304, otherwise, it proceeds to step S303.

[0180] In step S303, the FPGA processor reports the FT3 interface with the second configuration result.

[0181] In step S304, the FPGA processor sends a configuration completion instruction to the ARM processor.

[0182] In step S305, the ARM processor receives the configuration completion instruction, and establishes a corresponding relationship between each FT3 interface and various frame formats according to the configuration file.

[0183] In step S306, the FPGA processor receives a first data frame transmitted by the second board through the first FT3 interface, decodes the first data frame according to the encoding information corresponding to the first FT3 interface to obtain a decoded first data frame.

[0184] In step S307, the FPGA processor performs CRC check on the decoded first data frame to obtain a check result.

[0185] ​Step S308, the FPGA processor judges whether the check result is the first check result, if yes, step S310 is entered, otherwise, step S309 is entered;

[0186] Step S309, the FPGA processor reports abnormal information and discards the first data frame, and step S306 is entered;

[0187] Step S310, the FPGA processor sends the decoded first data frame to the ARM processor through an internal interface;

[0188] Step S311, the ARM processor parses the decoded first data frame according to the frame format corresponding to the first FT3 interface, and obtains first target data;

[0189] Step S312, the ARM processor sends the first target data to the internal application software for subsequent processing;

[0190] Step S313, the ARM processor receives second target data sent by the internal application software;

[0191] Step S314, the ARM processor frames the second target data according to the frame format corresponding to the second FT3 interface, and obtains a third data frame;

[0192] Step S315, the ARM processor sends the third data frame to the FPGA processor through an internal interface;

[0193] Step S316, the FPGA processor performs CRC calculation on the third data frame, obtains check information, fills the check information into the third data frame, and obtains a fifth data frame;

[0194] Step S317, the FPGA processor encodes the fifth data frame according to the encoding information corresponding to the second FT3 interface to obtain a fourth data frame;

[0195] Step S318, the FPGA processor sends the fourth data frame to the third board card through the second FT3 interface.

[0196] In this embodiment, firstly, the first processor sends data frames transmitted from other boards to the second processor for processing. Since the first processor does not need to parse the data frames, the development of its driver software is simplified, improving the overall stability of the driver. Furthermore, even if the frame format corresponding to the communication interface changes, the driver software does not need to be redeveloped or modified, reducing development costs and increasing development efficiency. Secondly, the second processor parses the target data of the data frame according to the corresponding frame format for use by internal application software. This not only fully utilizes the hardware performance of the second processor, shortening the parsing time while improving the accuracy and efficiency of data parsing, but also allows the application software in the second processor to directly access the data from the first... The dual-processor acquisition of target data, compared to acquisition from the first processor, shortens the communication link between the two, improving data real-time performance. Furthermore, since the second processor only needs to parse data frames and does not need to concern itself with data frame transmission, the complexity of application software development for the second processor is reduced. Finally, dynamically configuring the frame format corresponding to each communication interface through configuration files not only improves the accuracy of the frame format for each communication interface but also decouples the communication protocol and driver software, increasing the versatility, reusability, and portability of the driver software. This reduces development costs while improving development efficiency. Additionally, by modifying the configuration file, compatibility with multiple frame formats of the target communication protocol can be achieved, further enhancing development efficiency.

[0197] Based on the above embodiments, this disclosure provides a data processing apparatus applied in a first processor of a first board. Figure 4 A schematic diagram of the composition structure of a data processing device provided in this embodiment of the disclosure. Figure One ,like Figure 4 As shown, the data processing device 40 includes a first determining module 41 and a sending module 42, wherein:

[0198] The first determining module 41 is used to determine the second data frame based on the first data frame transmitted by the second board through the first communication interface of the first board; wherein, the first board further includes a second processor and at least one communication interface, the type of the second processor is different from the type of the first processor, each communication interface is used to transmit a data frame with a corresponding frame format, each data frame is generated according to the target communication protocol, and the frame format corresponding to each communication interface is generated based on a preset configuration file.

[0199] The sending module 42 is used to send the second data frame to the second processor so that the second processor can determine the first target data from the second data frame according to the frame format corresponding to the first communication interface.

[0200] In some embodiments, the first determining module 41 is further configured to: decode the first data frame according to the encoding information corresponding to the first communication interface to obtain a decoded first data frame; check the decoded first data frame to obtain a check result; and in a case where the check result indicates that the check is passed, take the decoded first data frame as the second data frame.

[0201] In some embodiments, the apparatus further comprises a second determining module configured to: receive a third data frame transmitted by the second processor; wherein the third data frame is generated by the second processor according to the target communication protocol based on the frame format corresponding to the second communication interface and the second target data; generate a fourth data frame based on the third data frame; and transmit the fourth data frame to the third board card through the second communication interface.

[0202] In some embodiments, the second determining module is further configured to: generate a fifth data frame based on the third data frame and the check information corresponding to the third data frame; encode the fifth data frame according to the encoding information corresponding to the second communication interface to obtain an encoded fifth data frame, and take the encoded fifth data frame as the fourth data frame.

[0203] In some embodiments, the apparatus further comprises a third determining module configured to: receive a configuration instruction; wherein the configuration instruction is generated based on a configuration file, and the configuration instruction comprises communication information of each communication interface; for each communication interface, configure the communication interface based on the communication information of the communication interface to obtain a configuration result; in a case where each configuration result indicates that the configuration is successful, transmit a preset configuration completion instruction to the second processor to enable the second processor to establish a correspondence between at least one communication interface and at least one frame format based on the configuration completion instruction; and in a case where at least one configuration result indicates that the configuration fails, report the corresponding configuration result.

[0204] In some embodiments, the first board card integrates a system on chip, and the first processor, the second processor and the at least one communication interface are located in the system on chip.

[0205] The above description of the apparatus embodiments is similar to the description of the above method embodiments, and has similar beneficial effects to the method embodiments. For technical details not disclosed in the apparatus embodiments of the present disclosure, please refer to the description of the method embodiments of the present disclosure for understanding.

[0206] Based on the above embodiments, the present disclosure provides a data processing apparatus applied to a second processor of a first board card, Figure 5 The present disclosure provides a data processing apparatus Figure Two As Figure 5As shown, the data processing apparatus 50 comprises a receiving module 51 and a processing module 52, wherein:

[0207] The receiving module is configured to receive a second data frame transmitted by a first processor of a first board card, wherein the second data frame is determined based on a first data frame transmitted by a second board card through a first communication interface, the second processor is of a type different from that of the first processor, the first board card further comprises at least one communication interface, each communication interface is configured to transmit a data frame having a corresponding frame format, each data frame is generated according to a target communication protocol, and the frame format corresponding to each communication interface is generated based on a preset configuration file.

[0208] The processing module is configured to parse the first data frame according to the frame format corresponding to the first communication interface to obtain first target data.

[0209] In some embodiments, the apparatus further comprises a fourth determining module configured to: generate a third data frame based on the frame format corresponding to the second communication interface and the second target data according to the target communication protocol; and transmit the third data frame to the first processor, so that the first processor transmits a fourth data frame to a third board card through the second communication interface, the fourth data frame being generated based on the third data frame.

[0210] In some embodiments, the apparatus further comprises an establishing module configured to: in response to receiving a configuration completion instruction transmitted by the first processor, establish a correspondence between the at least one communication interface and the at least one frame format based on the configuration file.

[0211] In some embodiments, the first board card integrates a system on chip, and the first processor, the second processor and the at least one communication interface are located in the system on chip.

[0212] The above description of the apparatus embodiments is similar to that of the method embodiments, and has similar beneficial effects. For technical details not disclosed in the apparatus embodiments of the present disclosure, please refer to the description of the method embodiments of the present disclosure.

[0213] It should be noted that, in the embodiments of the present disclosure, if the above method is implemented in the form of a software function module and sold or used as an independent product, it can also be stored in a computer readable storage medium. Based on such understanding, the technical solutions of the embodiments of the present disclosure can be embodied in the form of a software product in essence or the part that contributes to the related art, which is stored in a storage medium, includes a number of instructions to make an electronic device (which can be a personal computer, a server, or a network device, etc.) execute all or part of the embodiments of the present disclosure. The foregoing storage medium includes: a U disk, a mobile hard disk, a read-only memory (ROM), a magnetic disk or an optical disk, and various media that can store program codes. Thus, the embodiments of the present disclosure are not limited to any specific hardware and software combination.

[0214] The embodiments of the present disclosure provide an electronic device, including a memory and a processor, the memory stores a computer program capable of running on the processor, and the processor implements the above method when executing the computer program.

[0215] The embodiments of the present disclosure provide a computer readable storage medium, which stores a computer program, and the computer program is executed by a processor to implement the above method. The computer readable storage medium can be transitory or non-transitory.

[0216] The embodiments of the present disclosure provide a computer program product, which includes a non-transitory computer readable storage medium storing a computer program, and the computer program is read and executed by a computer to implement some or all steps of the above method. The computer program product can be specifically implemented by hardware, software or a combination thereof. In an optional embodiment, the computer program product is specifically embodied as a computer storage medium, and in another optional embodiment, the computer program product is specifically embodied as a software product, such as a software development kit (Software Development Kit, SDK) and the like.

[0217] It should be noted that, Figure 6 A hardware entity schematic diagram of an electronic device provided by the embodiments of the present disclosure is shown in FIG. 6, which includes a processor 61, a communication interface 62 and a memory 63. Figure 6 The hardware entity of the electronic device 60 includes a processor 61, a communication interface 62 and a memory 63, wherein:

[0218] The processor 61 generally controls the overall operation of the electronic device 60.

[0219] The communication interface 62 can enable the electronic device to communicate with other terminals or servers through a network.

[0220] The memory 63 is configured to store instructions and applications executable by the processor 61, and can also cache data (e.g., image data, audio data, voice communication data, and video communication data) to be processed by the processor 61 and modules in the electronic device 60, and can be implemented by a FLASH or a Random Access Memory (RAM). The processor 61, the communication interface 62, and the memory 63 can perform data transmission through the bus 64.

[0221] It should be noted that the above description of the storage medium and device embodiments is similar to the description of the above method embodiments, and has similar beneficial effects as the method embodiments. For technical details not disclosed in the storage medium and device embodiments of the present disclosure, please refer to the description of the method embodiments of the present disclosure.

[0222] It should be understood that the "one embodiment" or "an embodiment" mentioned throughout the specification means that the specific features, structures or characteristics related to the embodiment are included in at least one embodiment of the present disclosure. Therefore, "in one embodiment" or "in an embodiment" appearing throughout the specification does not necessarily mean the same embodiment. In addition, these specific features, structures or characteristics can be combined in one or more embodiments in any suitable manner. It should be understood that in various embodiments of the present disclosure, the size of the sequence number of each process does not mean the order of execution, and the execution order of each process should be determined according to its function and inherent logic, and should not constitute any limitation on the implementation process of the embodiments of the present disclosure. The sequence number of the above embodiments of the present disclosure is only for description, not representing the advantages and disadvantages of the embodiments. It should be noted that in this paper, the term "include", "contain" or any other variant thereof is intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements not only includes those elements, but also includes other elements not explicitly listed, or includes elements inherent to such process, method, article or device. Without more limitations, the element defined by the statement "including a" does not exclude the presence of other identical elements in the process, method, article or device including the element.

[0223] In several embodiments provided by the present disclosure, it should be understood that the disclosed devices and methods can be implemented in other manners. The described device embodiments are merely schematic. For example, the division of the units is merely a logical function division. There can be another division manner for the actual implementation, for example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the displayed or discussed coupling, or direct coupling or communication connection between the components can be indirect coupling or communication connection through some interfaces, devices, or units, and can be electrical, mechanical, or in other forms.

[0224] The units described as separate components can or can not be physically separate, and the components shown as units can or can not be physical units; they can be located in one place, or distributed on multiple network units; and some or all of the units can be selected according to actual needs to achieve the purpose of the embodiment. In addition, each functional unit in the embodiments of the present disclosure can be integrated into one processing unit, or each unit can be a separate unit, or two or more units can be integrated into one unit; the integrated unit can be implemented in the form of hardware, or in the form of hardware plus software functional units.

[0225] Those of ordinary skill in the art can understand that all or part of the steps of the above-mentioned method embodiments can be completed by program instructions related to hardware, and the aforementioned program can be stored in a computer-readable storage medium, and when the program is executed, the steps of the method embodiments are executed; and the aforementioned storage medium includes mobile storage devices, read-only memories (ROM), magnetic discs or optical discs, and various storage media that can store program codes.

[0226] Alternatively, the integrated units of the present disclosure, if implemented in the form of software functional modules and sold or used as independent products, can also be stored in a computer-readable storage medium. Based on this understanding, the technical solutions of the present disclosure can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for making an electronic device (which can be a personal computer, a server, or a network device, etc.) execute all or part of the methods described in the embodiments of the present disclosure. The aforementioned storage medium includes mobile storage devices, ROM, magnetic discs or optical discs, and various storage media that can store program codes.

[0227] The above merely describes the embodiments of the present disclosure, but the protection scope of the present disclosure is not limited thereto, and any person skilled in the art can easily think of changes or replacements within the technical range disclosed by the present disclosure, which should be covered within the protection scope of the present disclosure.

Claims

1. A data processing method, characterized in that, The method, applied in a first processor of a first board, includes: Based on the first data frame transmitted by the second board through the first communication interface of the first board, a second data frame is determined; wherein, the first board further includes a second processor and at least one communication interface, the type of the second processor is different from the type of the first processor, each of the communication interfaces is used to transmit a data frame with a corresponding frame format, each of the data frames is generated according to the target communication protocol, and the frame format corresponding to each of the communication interfaces is generated based on a preset configuration file; The second data frame is sent to the second processor so that the second processor can determine the first target data from the second data frame according to the frame format corresponding to the first communication interface.

2. The data processing method according to claim 1, characterized in that, The determination of the second data frame based on the first data frame transmitted through the first communication interface by the second board includes: The first data frame is decoded according to the encoding information corresponding to the first communication interface to obtain the decoded first data frame. The decoded first data frame is verified to obtain the verification result; If the verification result indicates that the verification is successful, the decoded first data frame is used as the second data frame.

3. The data processing method according to claim 1, characterized in that, The method further includes: The third data frame is received from the second processor; wherein the third data frame is generated by the second processor according to the target communication protocol, based on the frame format corresponding to the second communication interface and the second target data. Based on the third data frame, a fourth data frame is generated; The fourth data frame is transmitted to the third board through the second communication interface.

4. The data processing method according to claim 3, characterized in that, The step of generating a fourth data frame based on the third data frame includes: A fifth data frame is generated based on the third data frame and the corresponding verification information. The fifth data frame is encoded according to the encoding information corresponding to the second communication interface to obtain the encoded fifth data frame, and the encoded fifth data frame is used as the fourth data frame.

5. The data processing method according to any one of claims 1 to 4, characterized in that, The method further includes: Receive configuration instructions; wherein the configuration instructions are generated based on the configuration file and include communication information for each of the communication interfaces; For each communication interface, the communication interface is configured based on the communication information of the communication interface to obtain the configuration result; If each configuration result indicates successful configuration, a preset configuration completion instruction is passed to the second processor, so that the second processor establishes a correspondence between at least one communication interface and at least one frame format based on the configuration completion instruction. If at least one configuration result indicates a configuration failure, the corresponding configuration result shall be reported.

6. A data processing method, characterized in that, The method, applied to a second processor of a first board, includes: The system receives a second data frame transmitted by the first processor of the first board; wherein the second data frame is determined based on the first data frame transmitted by the second board through the first communication interface, the type of the second processor is different from the type of the first processor, the first board further includes at least one communication interface, each of the communication interfaces is used to transmit a data frame with a corresponding frame format, each of the data frames is generated according to the target communication protocol, and the frame format corresponding to each communication interface is generated based on a preset configuration file; The first data frame is parsed according to the frame format corresponding to the first communication interface to obtain the first target data.

7. The data processing method according to claim 6, characterized in that, The method further includes: According to the target communication protocol, a third data frame is generated based on the frame format corresponding to the second communication interface and the second target data; The third data frame is transmitted to the first processor, so that the first processor transmits the fourth data frame to the third board through the second communication interface, the fourth data frame being generated based on the third data frame.

8. The data processing method according to claim 6 or 7, characterized in that, The method further includes: In response to receiving a configuration completion instruction from the first processor, a correspondence between at least one communication interface and at least one frame format is established based on the configuration file.

9. A data processing system, characterized in that, The system includes a first board and a second board. The first board includes a first processor, a second processor, and at least one communication interface. The type of the second processor is different from that of the first processor. Each communication interface is used to transmit data frames with a corresponding frame format. Each data frame is generated according to a target communication protocol. The frame format corresponding to each communication interface is generated based on a preset configuration file, wherein: The first processor is configured to determine a second data frame based on a first data frame transmitted by the second board through a first communication interface, and send the second data frame to the second processor. The second processor is used to parse the first data frame according to the frame format corresponding to the first communication interface to obtain the first target data.

10. The data processing system according to claim 9, characterized in that, The system also includes a third board, wherein: The second processor is further configured to generate a third data frame according to the target communication protocol, based on the frame format corresponding to the second communication interface and the second target data, and transmit the third data frame to the first processor; The first processor is further configured to generate a fourth data frame based on the third data frame; and to transmit the fourth data frame to the third board through the second communication interface.

11. The data processing system according to claim 9, characterized in that, The first processor is further configured to receive configuration instructions; wherein the configuration instructions are generated based on the configuration file, and the configuration instructions include communication information for each of the communication interfaces; for each communication interface, the communication interface is configured based on the communication information of the communication interface to obtain a configuration result; if at least one configuration result indicates configuration failure, the configuration result is reported; if each of the configuration results indicates configuration success, a preset configuration completion instruction is transmitted to the second processor. The second processor is further configured to, in response to receiving the configuration completion instruction transmitted by the first processor, establish a correspondence between at least one communication interface and at least one frame format based on the configuration file.

12. The data processing system according to any one of claims 9 to 11, characterized in that, The first board integrates a system-on-a-chip, and the first processor, the second processor, and the at least one communication interface are all located in the system-on-a-chip.

13. A data processing apparatus, characterized in that, The device, applied in a first processor of a first board, includes: The first determining module is used to determine a second data frame based on a first data frame transmitted by the second board through the first communication interface of the first board; wherein, the first board further includes a second processor and at least one communication interface, the type of the second processor is different from the type of the first processor, each of the communication interfaces is used to transmit a data frame with a corresponding frame format, each of the data frames is generated according to the target communication protocol, and the frame format corresponding to each communication interface is generated based on a preset configuration file; The sending module is used to send the second data frame to the second processor, so that the second processor can determine the first target data from the second data frame according to the frame format corresponding to the first communication interface.

14. A data processing apparatus, characterized in that, The device, used in a second processor of a first board, includes: A receiving module is used to receive a second data frame transmitted by a first processor of the first board; wherein the second data frame is determined based on the first data frame transmitted by the second board through a first communication interface, the type of the second processor is different from the type of the first processor, the first board further includes at least one communication interface, each of the communication interfaces is used to transmit a data frame with a corresponding frame format, each of the data frames is generated according to a target communication protocol, and the frame format corresponding to each communication interface is generated based on a preset configuration file; The processing module is used to parse the first data frame according to the frame format corresponding to the first communication interface to obtain the first target data.

15. An electronic device comprising a processor and a memory, the memory storing a computer program executable on the processor, characterized in that, When the processor executes the computer program, it implements the method according to any one of claims 1 to 8.

16. A computer-readable storage medium, characterized in that, It stores a computer program that, when executed by a processor, implements the method described in any one of claims 1 to 8.

17. A computer program product comprising a computer program or instructions, characterized in that, When the computer program or instructions are executed by a processor, they implement the method according to any one of claims 1 to 8.