A data transmission method, device and equipment based on a parallel bus and a medium
By using memory mapping and data conversion techniques, the data to be transmitted is mapped to the virtual address space and split into logical unit data. The problem of low write efficiency of parallel bus is solved by using synchronous burst transmission mode, thus realizing high-efficiency data transmission.
Patent Information
- Application Number
- CN202611029526.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-10
- Publication Date
- 2026-11-24
AI Technical Summary
In FPGA-based industrial data processing, image acquisition, or automated inspection systems, existing technologies struggle to achieve continuous synchronous burst transmission when writing data to the FPGA via a parallel bus, resulting in low actual transmission efficiency.
The physical address space of the FPGA is directly mapped to the virtual address space of the user process through memory mapping. The data to be transmitted is converted into logic unit data, and its bit width is an integer multiple of the physical data bit width of the parallel bus. Continuous write cycle signals are generated through storage operations, which are split into multiple continuous data beats. Finally, the data is written into the physical address space of the FPGA in a synchronous burst transmission mode.
This improves the actual transmission efficiency of writing data to the FPGA via the parallel bus, makes full use of the bus physical bandwidth, reduces the overhead of small-granularity access transactions, and realizes continuous, high-granularity data transmission.
Smart Images

Figure CN123157642A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of embedded communication technology, and in particular to a data transmission method, apparatus, device and medium based on a parallel bus. Background Technology
[0002] In FPGA-based industrial data processing, image acquisition, or automated inspection systems, processors typically need to write image frame data, control data, or other large amounts of data to the FPGA via a parallel bus. Parallel buses are limited by physical data bit width, bus timing, and access protocols, resulting in a typically small data bit width for a single write operation. When upper-layer applications require writing large amounts of data, existing solutions often write the data sequentially to the FPGA address space via driver interfaces, ordinary memory copying, or discrete write operations.
[0003] However, in the existing technology, the data to be transmitted is easily broken down into multiple independent small-granularity access transactions during the process of writing to the FPGA. Each access may be accompanied by an address phase, a waiting phase, or a turnaround delay, making it difficult to form a continuous synchronous burst transmission on the parallel bus. This results in the bus physical bandwidth not being fully utilized, and there is a problem of low actual transmission efficiency when writing data to the FPGA through the parallel bus. Summary of the Invention
[0004] This application provides a data transmission method, apparatus, device, and medium based on a parallel bus, which can improve the actual transmission efficiency of writing data to an FPGA via a parallel bus to a certain extent.
[0005] A first aspect of this application provides a data transmission method based on a parallel bus, characterized in that data to be transmitted is written to an FPGA via a parallel bus. The method includes: directly mapping the physical address space of the FPGA to the virtual address space of a user process via memory mapping; converting the data to be transmitted into logic unit data; the bit width of the logic unit data being an integer multiple of the physical data bit width of the parallel bus; performing a storage operation to write the logic unit data into the virtual address space of the user process; the storage operation including generating continuous write cycle signals to the parallel bus; splitting the logic unit data into multiple consecutive data blocks in response to the continuous write cycle signals; the bit width of the multiple consecutive data blocks being the physical data bit width of the parallel bus; and performing synchronous burst transmission to write the multiple consecutive data blocks into the physical address space of the FPGA.
[0006] A second aspect of this application provides a data transmission device based on a parallel bus, characterized in that it is used to write data to be transmitted into an FPGA via a parallel bus. The data transmission device includes: a memory mapping module for directly mapping from the physical address space of the FPGA to the virtual address space of a user process via memory mapping; a data conversion module for converting the data to be transmitted into logic unit data; the bit width of the logic unit data is an integer multiple of the physical data bit width of the parallel bus; a storage operation module for performing a storage operation to write the logic unit data into the virtual address space of the user process; the storage operation includes generating continuous write cycle signals to the parallel bus; a data splitting module for splitting the logic unit data into multiple consecutive data blocks in response to the continuous write cycle signals; the bit width of the multiple consecutive data blocks is the physical data bit width of the parallel bus; and a data writing module for performing synchronous burst transmission to write the multiple consecutive data blocks into the physical address space of the FPGA.
[0007] A third aspect of this application provides an industrial device including an ARM processor and an FPGA, wherein the ARM processor and the FPGA are connected via a parallel bus. The ARM processor is configured to perform the following operations: directly map from the physical address space of the FPGA to the virtual address space of a user process via memory mapping; convert the data to be transmitted into logic unit data; the bit width of the logic unit data is an integer multiple of the physical data bit width of the parallel bus; perform a storage operation to write the logic unit data into the virtual address space of the user process; the storage operation includes generating continuous write cycle signals to the parallel bus; and splitting the logic unit data into multiple consecutive data blocks in response to the continuous write cycle signals; the bit width of the multiple consecutive data blocks is the physical data bit width of the parallel bus. The FPGA is configured to perform the following operations: receive the multiple consecutive data blocks from the parallel bus performing synchronous burst transmission and write them into the physical address space of the FPGA.
[0008] A fourth aspect of this application provides a computer-readable storage medium having a computer program stored thereon, characterized in that the program, when executed by a processor, implements the above-described data transmission method.
[0009] The data transmission method, apparatus, device, and medium based on a parallel bus disclosed in this application directly maps the physical address space of an FPGA to the virtual address space of a user process through memory mapping. It converts the data to be transmitted into logic unit data with a bit width that is an integer multiple of the physical data bit width of the parallel bus. Then, through storage operations, it generates continuous write cycle signals, causing the logic unit data to be split into multiple continuous data blocks corresponding to the physical data bit width of the parallel bus. These blocks are then written into the physical address space of the FPGA using a synchronous burst transmission method. This achieves continuous, high-granularity transmission of the data to be transmitted on the parallel bus, thereby improving the actual transmission efficiency of writing data to the FPGA via the parallel bus. Attached Figure Description
[0010] The embodiments of this application are further described below with reference to the accompanying drawings and specific implementation details.
[0011] Figure 1 This is a schematic diagram illustrating the steps of a data transmission method based on a parallel bus provided in an embodiment of this application.
[0012] Figure 2 This is a schematic diagram of the structure of an industrial device provided in an embodiment of this application. Detailed Implementation
[0013] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of them. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the protection scope of the embodiments of this application.
[0014] In the description of the embodiments of this application, it should be understood that the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Therefore, features defined with "first" and "second" may explicitly or implicitly include one or more of the stated features. In the description of the embodiments of this application, "multiple" means two or more, unless otherwise explicitly specified.
[0015] In related technologies, in FPGA-based industrial data processing, image acquisition, or automated inspection systems, processors typically need to write image frame data, control data, or other data to be transmitted into the FPGA via a parallel bus. Specifically, the processor can use the FPGA's memory space, register space, or other physical address space as external access space, and write the data to be transmitted into the FPGA through address signals, data signals, and control signals of the parallel bus. Since the physical data bit width of the parallel bus is usually fixed, the amount of data that can be carried in a single data transmission cycle is limited by the physical data bit width of the parallel bus. Therefore, when the amount of data to be transmitted is large, multiple bus accesses are usually required to complete the write operation.
[0016] In some conventional schemes, the processor can write the data to be transferred sequentially into the FPGA address space through a driver interface, ordinary memory copy, or discrete write operations. While this method can achieve the basic function of the processor writing data to the FPGA, in actual transmission, the data to be transferred is easily broken down into multiple independent small-granularity access transactions. Each small-granularity access transaction usually needs to go through address establishment, write control, waiting, or bus turnaround processes, making it difficult to maintain continuity between adjacent access transactions, thus preventing the parallel bus from stably forming a continuous write cycle signal. For example, those skilled in the art generally believe that to increase the bandwidth of the parallel bus, one can take intuitive measures such as increasing the data bus width (e.g., expanding from 16 bits to 32 bits) or increasing the clock frequency. At the same time, to achieve high-throughput peripheral access and reduce CPU load, using DMA is a recognized essential path. The SDMA controller built into the i.MX6 processor therefore became the preferred direction to try. However, it is precisely under these "consensus" that the actual performance of the EIM bus has long been constrained by the following structural defects and has not been able to be improved.
[0017] Furthermore, when the parallel bus supports synchronous burst transmission, if the data to be transmitted cannot be effectively organized into logical unit data with a bit width corresponding to the physical data bit width of the bus, the write operation generated on the processor side is difficult to be converted into multiple consecutive data blocks on the bus side. Thus, even if the parallel bus itself has a certain theoretical bandwidth, in the actual write process, the physical transmission capacity of the parallel bus cannot be fully utilized due to the small transaction granularity, multiple access intervals, and large bus turnaround overhead.
[0018] Furthermore, if access between the user process and the FPGA physical address space still relies on conventional driver calls or data transfer methods, additional data copying and context switching overhead may be introduced during the process of writing data from the user process to the FPGA. This overhead in the software path, combined with the small-granularity transactions at the bus access level, further reduces the real-time performance and transmission efficiency when writing large amounts of data to the FPGA.
[0019] In summary, when writing data to the FPGA via the parallel bus, it is difficult for the data to be transmitted to form a continuous synchronous burst transmission on the parallel bus, resulting in low actual transmission efficiency, which requires further improvement.
[0020] like Figure 1 As shown, one embodiment of this application provides a data transmission method based on a parallel bus, which writes data to be transmitted into an FPGA via a parallel bus. The method includes: S1: The physical address space of the FPGA will be directly mapped to the virtual address space of the user process through memory mapping; S2: Convert the data to be transmitted into logic unit data; the bit width of the logic unit data is an integer multiple of the physical data bit width of the parallel bus; S3: Perform a storage operation to write the data of the logical unit into the virtual address space of the user process; the storage operation includes generating continuous write cycle signals to the parallel bus; S4: In response to the continuous write cycle signal, the logic unit data is split into multiple consecutive data blocks; the bit width of the multiple consecutive data blocks is the physical data bit width of the parallel bus; S5: Perform synchronous burst transmission to write the multiple consecutive data packets into the physical address space of the FPGA.
[0021] In this embodiment, the parallel bus-based data transmission method is used to write data to be transmitted into the FPGA via the parallel bus. The data to be transmitted may be image frame data, control data, or other data that needs to be written from the processor side to the FPGA side. The parallel bus can be used to transmit address signals, data signals, and control signals between the processor and the FPGA. The physical address space of the FPGA may include the frame buffer space, register space, or other memory space accessible via the parallel bus on the FPGA side.
[0022] In this embodiment, the FPGA's physical address space can be directly mapped to the user process's virtual address space via memory mapping. Memory mapping establishes a correspondence between the virtual address accessible to the user process and the FPGA's physical address space, allowing the user process to access the FPGA's physical address space through the virtual address space. Therefore, when writing data to be transmitted, the user process does not need to first transfer the data to the kernel buffer via a conventional driver interface and then write it to the FPGA from the kernel buffer. Instead, it can use the mapped virtual address space as the target address space, thus providing a direct addressing basis for subsequent continuous writing of data to be transmitted. This hardware-software co-operation method, which enables direct access from the application layer to the hardware under 16-bit narrow data bus conditions and fully releases the EIM synchronous burst capability, maximizes the conservation of FPGA pin resources while bringing the actual transmission bandwidth close to the physical limit of the 16-bit bus, fundamentally solving the problems of SDMA architecture bottlenecks, data copy latency, and low bus transaction efficiency. It completely abandons SDMA, consciously adopts CPU assembly instructions to actively take over data handling, and deliberately retains a 16-bit data width to save valuable FPGA I / O resources. The overall architecture constructs an end-to-end acceleration pipeline consisting of "ARM-side instruction-level synchronous bulk transfer + zero-copy memory mapping + FPGA-side synchronous mode and flexible addressing". These three components form an inseparable rigid closed loop, achieving actual bandwidth comparable to 32-bit bus solutions on a 16-bit bus, while minimizing hardware costs.
[0023] In this embodiment, the data to be transmitted can be converted into logical unit data. Logical unit data refers to data units organized according to a preset bit width on the processor side or user process side, with a bit width that is an integer multiple of the physical data bit width of the parallel bus. The physical data bit width of the parallel bus refers to the number of data bits that the parallel bus can transmit in a single data clock. For example, the physical data bit width of the parallel bus can be 16 bits, and the bit width of the logical unit data can be 32 bits, 64 bits, 128 bits, or other bit widths that are integer multiples of 16 bits. By converting the data to be transmitted into logical unit data, the data to be transmitted can be organized into transmission units larger than a single physical data clock before being written, avoiding the direct discrete writing of the data to be transmitted as multiple independent small-granularity data.
[0024] In this embodiment, after the logic unit data is formed, a storage operation can be performed to write the logic unit data into the virtual address space of the user process. Since the virtual address space of the user process has already established a correspondence with the physical address space of the FPGA through memory mapping, performing a storage operation on this virtual address space can trigger the parallel bus to perform a write access to the physical address space of the FPGA. The storage operation can be understood as the operation of writing data to the target address on the processor side, such as writing data stored in a register, data organized in a cache, or data prepared in the user process to the mapped virtual address. This storage operation does not only produce a single discrete write, but also includes generating continuous write cycle signals to the parallel bus. The continuous write cycle signals refer to multiple write cycle control signals that appear consecutively during the data writing phase of the parallel bus, used to instruct the parallel bus to continuously execute multiple data writing processes.
[0025] In this embodiment, in response to consecutive write cycle signals, the logic unit data can be divided into multiple consecutive data blocks. A data block refers to a data unit transmitted by the parallel bus in one data transmission cycle. The bit width of multiple consecutive data blocks is the physical data bit width of the parallel bus. That is, although the logic unit data exists with a relatively wide bit width on the processor side or user process side, it can be divided into multiple consecutive data blocks according to the physical data bit width of the parallel bus when transmitted through the parallel bus. For example, when the bit width of the logic unit data is 128 bits and the physical data bit width of the parallel bus is 16 bits, one logic unit data can be divided into 8 consecutive 16-bit data blocks. This example is only used to illustrate the bit width correspondence between logic unit data and data blocks and is not intended to limit the specific bit width of the logic unit data and the parallel bus.
[0026] In this embodiment, synchronous burst transmission can be performed to write multiple consecutive data frames into the FPGA's physical address space. Synchronous burst transmission refers to a transmission method that continuously transmits multiple data frames according to a burst transmission protocol under synchronous clock constraints. Compared to multiple independent discrete write transactions, synchronous burst transmission can reduce the overhead of repeated address setup, waiting, or bus turnaround between consecutive data frames, enabling the parallel bus to continuously carry multiple data frames. The FPGA side can continuously receive multiple data frames according to the synchronous transmission timing of the parallel bus and write them into the corresponding physical address space. Specifically, multiple consecutive data frames can be sequentially written into the FPGA's frame buffer space to complete image frame data writing; alternatively, they can be written into the FPGA's register space to complete control data or configuration data writing.
[0027] Therefore, in this embodiment, a direct mapping relationship is established between the virtual address space of the user process and the physical address space of the FPGA through memory mapping. The data to be transmitted is converted into logic unit data with a bit width that is an integer multiple of the physical data bit width of the parallel bus. Then, continuous write cycle signals are generated through storage operations, causing the logic unit data to be split into multiple continuous data blocks corresponding to the physical data bit width of the parallel bus. These blocks are then written into the physical address space of the FPGA through synchronous burst transmission. Through the above process, the data to be transmitted can be transformed from discrete small-granularity write access into a synchronous burst write process suitable for continuous transmission on the parallel bus, thereby improving the actual transmission efficiency of writing data to the FPGA through the parallel bus.
[0028] In some implementations, the mapping attribute of the memory mapping is set to non-cached, and performing a storage operation to write the logical unit data into the virtual address space of the user process includes: performing a zero-copy access to the virtual address space of the user process through a storage operation.
[0029] In this embodiment, the memory mapping attribute can be set to non-cached. Non-cached means that when the processor accesses the mapped virtual address space, it does not save or return the data in that address space through a normal caching mechanism, but instead allows the access operation to directly act on the FPGA's physical address space. Since the FPGA's physical address space is used to carry parallel bus access, if a normal caching attribute is used, the processor may fail to initiate a write access to the parallel bus due to a cache hit, or the content read by the user process may be inconsistent with the actual state on the FPGA side. Therefore, setting the mapping attribute to non-cached allows the user process's storage operation on the mapped address to be more directly converted into a bus write access to the FPGA's physical address space. When performing a storage operation to write logic unit data to the user process's virtual address space, a zero-copy access to the user process's virtual address space can be performed through the storage operation. Zero-copy access can be understood as the user process's virtual address space having established a correspondence with the FPGA's physical address space through memory mapping. Therefore, although the target address of the storage operation appears as a virtual address that the user process can access, the actual access object corresponding to this virtual address is the FPGA's physical address space. In this way, when logic unit data is written to this virtual address space, it can directly trigger write access to the FPGA physical address space, without having to copy the logic unit data to the kernel buffer first, and then have the kernel buffer transfer it to the FPGA.
[0030] Specifically, the user process can obtain a virtual address pointer corresponding to the FPGA's physical address space and use this virtual address pointer as the target address for memory operations. When logic unit data is written to this target address, the processor-side memory operation can access the FPGA through the address mapping relationship corresponding to the parallel bus, thereby writing the logic unit data to the mapped FPGA address space. Thus, the data to be transmitted prepared by the user process, after being converted into logic unit data, can directly enter the parallel bus transmission process along the mapped virtual address space, avoiding increased access latency due to ordinary driver calls, data transfer between user mode and kernel mode, or repeated copying.
[0031] For example, when the data to be transmitted is image frame data, the user process can first organize the image frame data into logical unit data, and then write the logical unit data into the mapped virtual address space. Since this virtual address space corresponds to the FPGA's frame memory physical address space, the writing process can directly manifest as a write access to the FPGA frame memory, without needing to copy the image frame data to the kernel-side temporary buffer first. This shortens the software access path of the data to be transmitted from the user process to the FPGA's physical address space, enabling subsequent continuous write cycle signals and synchronous burst transmissions to be formed more efficiently.
[0032] In some implementations, directly mapping the physical address space of the FPGA to the virtual address space of a user process via memory mapping includes: obtaining the physical page frame number corresponding to the physical address space of the FPGA; setting the mapping attribute of the memory mapping to uncached; and directly mapping the physical address space of the FPGA to the virtual address space of the user process via the memory mapping.
[0033] In this embodiment, when directly mapping the FPGA's physical address space to the user process's virtual address space via memory mapping, the physical page frame number corresponding to the FPGA's physical address space can be obtained first. The physical page frame number can be used to characterize the page frame position corresponding to the FPGA's physical address space in the processor's physical address hierarchy. Since the FPGA's physical address space is usually connected to the processor's peripheral address space via a parallel bus, when establishing memory mapping, it is necessary to determine the corresponding physical page frame number based on the starting physical address and mapping length of the physical address space, so that the address range corresponding to the physical page frame number can be subsequently mapped to the user process's virtual address space.
[0034] Specifically, in some implementations, the driver can calculate the physical page frame number based on the FPGA's physical address space when processing a user process's memory mapping request. Subsequently, the driver uses a memory mapping mechanism to establish the FPGA physical address range corresponding to that physical page frame number into the user process's virtual address space. After mapping, the virtual address obtained by the user process can correspond to the FPGA's frame buffer space, register space, or other accessible spaces, enabling subsequent memory operations to be executed using that virtual address as the target address.
[0035] For example, when the FPGA's frame memory space is located within a certain range of physical addresses accessible to the processor, this physical address range can be converted into the corresponding physical page frame number. After the user process obtains the mapped virtual address pointer, when it writes logic unit data to that virtual address pointer, the processor will not simply write the data to the cache, but will initiate a write access to the corresponding physical address space of the FPGA via the parallel bus. In this way, a direct correspondence can be ensured between the memory operations on the user process side and the physical address access on the FPGA side, providing a reliable address mapping basis for the generation of subsequent continuous write cycle signals and synchronous burst transmissions.
[0036] In some implementations, performing a synchronous burst transfer to write the plurality of consecutive data packets into the physical address space of the FPGA includes: the controller of the parallel bus performing the synchronous burst transfer at the edge of a synchronous clock; and the FPGA latching the data at the same or another corresponding edge of the synchronous clock.
[0037] In this embodiment, when performing synchronous burst transmission to write multiple consecutive data packets into the FPGA's physical address space, the parallel bus controller can perform the synchronous burst transmission on the edge of the synchronous clock. The synchronous clock can be used to provide a unified timing reference for data transmission between the parallel bus controller and the FPGA. The edge of the synchronous clock can include a rising edge, a falling edge, or other valid sampling edges specified by the parallel bus protocol. When performing synchronous burst transmission, the parallel bus controller can continuously output multiple data packets according to the clock's tick, and coordinate with control signals such as address signals, write enable signals, and chip select signals to ensure that the multiple data packets appear sequentially on the parallel bus according to the burst transmission order.
[0038] In this embodiment, the FPGA can perform data latching at the same or another corresponding edge of the synchronous clock. Data latching refers to the FPGA sampling and saving the current data frame on the parallel bus to the internal receiving logic of the FPGA at the moment when the bus timing requirements are met. The same or another corresponding edge can be determined according to the timing protocol of the parallel bus. For example, in one implementation, the parallel bus controller can update the address signal and data frame at the rising edge of the synchronous clock, and the FPGA can latch the already stable data frame at the falling edge of the synchronous clock; in another implementation, the controller and FPGA can also complete the data output and sampling coordination on the same valid edge based on the protocol agreement. As long as the data setup time and hold time requirements can be met, the FPGA can stably receive continuous data frames.
[0039] Specifically, when the logic unit data is divided into multiple consecutive data frames, the parallel bus controller can output these data frames sequentially over multiple consecutive cycles of the synchronous clock. The FPGA-side receiving logic continuously latches each data frame according to the corresponding edge of the synchronous clock and writes them into the corresponding physical address space in the transmission order of the data frames. Since multiple data frames are transmitted and latched based on the same synchronous clock, the FPGA can continuously receive multiple data frames according to a defined timing relationship, avoiding data misalignment, missed sampling, or duplicate sampling caused by asynchronous sampling or timing mismatch.
[0040] For example, when the physical data width of the parallel bus is 16 bits and the logic unit data is divided into eight consecutive 16-bit data blocks, the parallel bus controller can sequentially output these eight data blocks within eight consecutive valid transmission cycles of the synchronous clock. The FPGA can sample the current 16-bit data block at the corresponding latch edge in each transmission cycle and write the eight data blocks into the FPGA's physical address space in burst transmission order. In this way, multiple consecutive data blocks can be stably transmitted under the constraint of the synchronous clock, improving the data reception reliability during synchronous burst transmission.
[0041] In some implementations, performing synchronous burst transmission to write the plurality of consecutive data packets into the physical address space of the FPGA includes: generating a byte valid mask signal based on the physical data bit width of the parallel bus and the consecutive write cycle signals; the byte valid mask signal includes multi-bit byte data corresponding one-to-one with the plurality of consecutive data packets; and updating the multi-bit byte data in real time according to the transmission progress of the plurality of consecutive data packets.
[0042] In this embodiment, when performing synchronous burst transmission to write multiple consecutive data frames into the FPGA's physical address space, a byte validity mask signal can be generated based on the physical data bit width of the parallel bus and the continuous write cycle signals. The byte validity mask signal can be used to indicate which bytes in each data frame are valid write bytes during the current synchronous burst transmission. Since the bit width of the logic unit data is an integer multiple of the physical data bit width of the parallel bus, the logic unit data is split into multiple consecutive data frames during transmission. Therefore, when the FPGA receives multiple consecutive data frames, it can identify the valid byte position corresponding to each data frame through the byte validity mask signal, thereby accurately writing the received data into the FPGA's physical address space.
[0043] In this embodiment, the byte validity mask signal may include multi-bit byte data corresponding one-to-one with multiple consecutive data blocks. The multi-bit byte data can be understood as multi-bit identifier data used to characterize the validity status of a byte, rather than the data to be transmitted itself. For example, when a data block includes multiple bytes, each bit in the multi-bit byte data can correspond to a different byte in that data block; when a bit is valid, it indicates that the byte corresponding to that bit needs to be written to the target address location of the FPGA; when a bit is invalid, it indicates that the byte corresponding to that bit will not participate in the current writing, and the FPGA can keep the original data at the corresponding address location or register field unchanged.
[0044] Specifically, during the sequential transmission of multiple consecutive data frames, the sequence number or transmission progress of the currently transmitted data frame can be determined based on the continuous write cycle signals, and the byte range covered by the current data frame can be determined by combining this with the physical data bit width of the parallel bus. Subsequently, the corresponding multi-byte data is updated in real time based on the byte range covered by the current data frame, so that the byte validity mask signal changes synchronously with the transmission progress of the data frame. Thus, when each data frame arrives, the FPGA can determine the valid byte in that data frame based on the currently updated multi-byte data and write the valid byte to the corresponding location in the FPGA's physical address space.
[0045] For example, when the physical data width of the parallel bus is 16 bits, each data block can include 2 bytes. If a logic unit's data is split into 8 consecutive data blocks, a byte validity mask signal corresponding to each of the 8 data blocks can be generated sequentially during synchronous burst transmission. When the FPGA receives the first data block, it can determine whether the two bytes in that data block are valid based on the corresponding multi-byte data. When receiving subsequent data blocks, it updates the multi-byte data in real time according to the transmission progress to determine the valid bytes in subsequent data blocks. In this way, valid byte identification of each data block can be achieved during continuous synchronous burst transmission, avoiding the mistaken writing of invalid bytes into the FPGA's physical address space and improving the accuracy of writing wide-bit logic unit data into the FPGA.
[0046] In some implementations, performing a storage operation to write the logical unit data into the virtual address space of the user process includes: executing a storage operation via a processor's multi-register storage instruction to write the logical unit data located in a plurality of general-purpose registers of the processor into the virtual address space of the user process at consecutive addresses; the storage operation generates consecutive write cycle signals on the parallel bus; the number of cycles of the consecutive write cycle signals corresponds to the number of the plurality of general-purpose registers, and the controller of the parallel bus does not insert address phases or turnaround cycles during the data writing phase.
[0047] As an example, the multi-register store instruction can be the ldmia / stmia multi-register load / store instruction of the ARM processor, or the vst1 instruction of the ARM NEON SIMD unit. The ldmia / stmia instruction loads multiple data segments from the logic unit data into four general-purpose registers respectively, and then uses the stmia instruction to write the data from the four general-purpose registers into the mapped virtual address space at a single, consecutive address. The data transfer method does not use a DMA controller for data movement; the processor actively takes over the data movement process through the multi-register store instruction, enabling the parallel bus to generate continuous burst transactions conforming to the synchronous burst protocol.
[0048] One embodiment of this application also provides a data transmission device based on a parallel bus, used to write data to be transmitted into an FPGA via a parallel bus. The data transmission device includes: a memory mapping module, used to directly map the physical address space of the FPGA to the virtual address space of a user process via memory mapping; a data conversion module, used to convert the data to be transmitted into logic unit data; the bit width of the logic unit data is an integer multiple of the physical data bit width of the parallel bus; a storage operation module, used to perform a storage operation to write the logic unit data into the virtual address space of the user process; the storage operation includes generating continuous write cycle signals to the parallel bus; a data splitting module, used to split the logic unit data into multiple consecutive data blocks in response to the continuous write cycle signals; the bit width of the multiple consecutive data blocks is the physical data bit width of the parallel bus; and a data writing module, used to perform synchronous burst transmission to write the multiple consecutive data blocks into the physical address space of the FPGA.
[0049] In this embodiment, a parallel bus-based data transmission device is used to write data to be transmitted into the FPGA via the parallel bus. This data transmission device can be deployed on the processor side or as a functional unit formed by the processor-side driver, user process, and parallel bus control logic. The data transmission device includes a memory mapping module, a data conversion module, a storage operation module, a data splitting module, and a data writing module. Each module can work collaboratively according to the transmission order of the data to be transmitted from the user process side to the FPGA physical address space, so that the data to be transmitted can be written into the FPGA via the parallel bus in the form of continuous data packets.
[0050] In this embodiment, the memory mapping module is used to directly map the FPGA's physical address space to the user process's virtual address space. After the user process initiates a mapping request, the memory mapping module establishes a correspondence between the virtual address accessible to the user process and the FPGA's physical address space. Once mapping is complete, the user process obtains the virtual address corresponding to the FPGA's physical address space, enabling subsequent modules to use this virtual address space as the data writing target. Thus, the memory mapping module provides the address basis for data to be transmitted to directly enter the parallel bus transmission process from the user process side.
[0051] In this embodiment, the data conversion module is used to convert the data to be transmitted into logical unit data. The bit width of the logical unit data is an integer multiple of the physical data bit width of the parallel bus. The data conversion module can group, concatenate, or align the data to be transmitted according to the physical data bit width of the parallel bus, forming logical unit data suitable for subsequent continuous writing. In this way, the data to be transmitted is no longer written independently as small-granularity data corresponding to a single physical data bit width, but is first organized into wider data units that can be further divided into multiple consecutive data blocks.
[0052] In this embodiment, the storage operation module performs storage operations to write logic unit data into the virtual address space of the user process. Since the user process's virtual address space has been mapped to the FPGA's physical address space by the memory mapping module, the storage operation module's write operation on this virtual address space triggers a write access to the FPGA's physical address space by the parallel bus. Furthermore, the storage operation includes generating continuous write cycle signals to the parallel bus. These continuous write cycle signals can be used to instruct the parallel bus to continuously transmit data across multiple consecutive write cycles, rather than breaking the logic unit data into multiple independent discrete write transactions.
[0053] In this embodiment, the data splitting module is used to split the logic unit data into multiple consecutive data blocks in response to continuous write cycle signals. The bit width of the multiple consecutive data blocks is the physical data bit width of the parallel bus. That is, the logic unit data formed by the data conversion module can have a wide bit width on the processor side or user process side, and the data splitting module can split the logic unit data into multiple data blocks adapted to parallel bus transmission according to the number of data bits that the parallel bus can carry in a single data block. The multiple data blocks maintain a continuous transmission relationship so that the data writing module can perform synchronous burst transmission subsequently.
[0054] In this embodiment, the data writing module performs synchronous burst transmission to write multiple consecutive data frames into the FPGA's physical address space. With the cooperation of a synchronous clock and parallel bus control signals, the data writing module sequentially transmits the multiple consecutive data frames obtained by the data splitting module to the FPGA, enabling the FPGA to continuously receive and write them into the corresponding physical address space according to the synchronous burst transmission timing. The physical address space can correspond to the FPGA's frame buffer space, register space, or other spaces accessible via the parallel bus.
[0055] For example, when the physical data width of the parallel bus is 16 bits, the data conversion module can organize the data to be transmitted into 64-bit or 128-bit logical units. When the storage operation module writes this logical unit data into the mapped user process virtual address space, it can generate continuous write cycle signals to the parallel bus. The data splitting module splits the logical unit data into multiple consecutive 16-bit data blocks according to the 16-bit physical data width. The data writing module then writes these 16-bit data blocks continuously into the FPGA's physical address space through synchronous burst transmission. In this way, the data transmission device can, through the cooperation of various modules, write the data to be transmitted into the FPGA in a continuous and high-granular manner via the parallel bus, thereby reducing the bus turnaround overhead caused by discrete small-granularity access transactions.
[0056] In this embodiment, the specific functions and effects of the data transmission device based on the parallel bus can be explained by referring to other embodiments of this application, and will not be repeated here.
[0057] like Figure 2 As shown, one embodiment of this application also provides an industrial device, including an ARM processor and an FPGA, wherein the ARM processor and the FPGA are connected via a parallel bus. The ARM processor is configured to perform the following operations: directly mapping from the physical address space of the FPGA to the virtual address space of a user process via memory mapping; converting the data to be transmitted into logic unit data; the bit width of the logic unit data is an integer multiple of the physical data bit width of the parallel bus; performing a storage operation to write the logic unit data into the virtual address space of the user process; the storage operation includes generating continuous write cycle signals to the parallel bus; and splitting the logic unit data into multiple consecutive data blocks in response to the continuous write cycle signals; the bit width of the multiple consecutive data blocks is the physical data bit width of the parallel bus. The FPGA is configured to perform the following operations: receive the multiple consecutive data blocks from the parallel bus performing synchronous burst transmission and write them into the physical address space of the FPGA.
[0058] In this embodiment, the industrial equipment can be a device that requires data reception, buffering, control, or processing via an FPGA. This industrial equipment includes an ARM processor and an FPGA, which are connected via a parallel bus. The ARM processor acts as the master of the parallel bus, organizing the data to be transmitted and initiating write accesses to the FPGA's physical address space. The FPGA acts as a slave of the parallel bus, receiving data packets transmitted via the parallel bus and writing the received data into its physical address space. The parallel bus can transmit address signals, data signals, and write control signals between the ARM processor and the FPGA, enabling the ARM processor to access the FPGA's frame buffer space, register space, or other accessible spaces via the bus.
[0059] In this embodiment, the ARM processor can directly map the FPGA's physical address space to the user process's virtual address space via memory mapping. After mapping, the user process running on the ARM processor can obtain the virtual address corresponding to the FPGA's physical address space, and thus use this virtual address as the target for writing data to be transmitted. In this way, the data writing process in industrial equipment can directly enter the parallel bus access link from the user process side, reducing the impact of conventional driver relay processes on transmission efficiency.
[0060] In this embodiment, the ARM processor can also convert the data to be transmitted into logic unit data. The bit width of the logic unit data is an integer multiple of the physical data bit width of the parallel bus. The ARM processor can organize the data to be transmitted according to the number of data bits that the parallel bus can transmit in a single data cycle, so that the data to be transmitted forms a wider data unit suitable for continuous writing. Subsequently, the ARM processor performs a storage operation, writing the logic unit data into the virtual address space of the user process. Since there is a mapping relationship between this virtual address space and the physical address space of the FPGA, this storage operation can further trigger write accesses to the FPGA by the parallel bus and generate continuous write cycle signals on the parallel bus.
[0061] In this embodiment, the ARM processor can respond to consecutive write cycle signals by splitting logic unit data into multiple consecutive data blocks. Specifically, this splitting process can be implemented by the parallel bus controller in the ARM processor based on the physical data width of the parallel bus. The bit widths of the multiple consecutive data blocks correspond to the physical data widths of the parallel bus, thereby enabling wider logic unit data to be converted into a data format that can be transmitted on a block-by-block basis on the parallel bus. The multiple data blocks maintain a continuous relationship, allowing them to appear continuously on the parallel bus during subsequent synchronous burst transmissions.
[0062] In this embodiment, the FPGA is configured to receive multiple consecutive data frames from a parallel bus performing synchronous burst transmission, and write these consecutive data frames into the FPGA's physical address space. Specifically, the FPGA can latch the data frames on the parallel bus at the corresponding clock edge according to the synchronous transmission timing of the parallel bus, and write them into the target physical address space according to the transmission order of the data frames. If the data to be transmitted is image frame data, multiple consecutive data frames can be written into the FPGA's frame memory space; if the data to be transmitted is control data, multiple consecutive data frames can be written into the FPGA's register space. Thus, the logic unit data organized on the ARM processor side can be continuously transmitted through the parallel bus and received on the FPGA side.
[0063] For example, in image inspection scenarios in industrial equipment, the ARM processor can organize image frame data to be written to the FPGA frame memory into logical unit data and initiate continuous storage operations through the mapped user process virtual address space. The parallel bus controller splits the logical unit data into multiple data packets corresponding to the physical data bit width and continuously outputs them to the FPGA through synchronous burst transmission. The FPGA continuously receives these data packets according to the synchronous transmission timing and writes them into the corresponding frame memory physical address space. In this way, industrial equipment can improve the actual transmission efficiency of the ARM processor writing data to the FPGA without changing the physical data bit width of the parallel bus.
[0064] The specific functions and effects achieved by the industrial equipment in this embodiment can be explained by referring to other embodiments of this application, and will not be repeated here.
[0065] In some implementations, the ARM processor includes a plurality of general-purpose registers, and the execution of the storage operation to write the logic unit data to the virtual address space of the user process includes: the ARM processor writing the data located in the plurality of general-purpose registers to the virtual address space of the user process at consecutive addresses.
[0066] In this embodiment, when the ARM processor performs a memory operation to write logic unit data into the virtual address space of the user process, the ARM processor may include multiple general-purpose registers, and write the data located in the multiple general-purpose registers into the virtual address space of the user process at consecutive addresses. The general-purpose registers can be used to temporarily store data to be written during the execution of instructions by the ARM processor. Multiple general-purpose registers can respectively store different parts of the logic unit data, enabling the logic unit data to be organized into register data groups suitable for continuous writing within the processor.
[0067] Specifically, the ARM processor first loads logic unit data into multiple general-purpose registers, with each register storing different data segments of the logic unit data. Then, the ARM processor performs a memory operation, writing the data from the multiple general-purpose registers into the user process's virtual address space in consecutively increasing target addresses. Since the user process's virtual address space is already mapped to the FPGA's physical address space, writing data from the multiple general-purpose registers into this virtual address space at consecutive addresses can further trigger the parallel bus to generate consecutive write cycle signals, enabling the FPGA to receive the corresponding consecutive data cycles via the parallel bus.
[0068] In this embodiment, consecutive addresses can be understood as multiple write target addresses arranged sequentially according to a preset address step size. This preset address step size can correspond to the data width of each write operation. By writing data in multiple general-purpose registers at consecutive addresses, the overhead of the processor constructing discrete write accesses one by one can be reduced, and the parallel bus controller can more easily convert the memory operation into a consecutive write cycle. In this way, multiple data segments in the logic unit data can be written into the mapped virtual address space in a single consecutive memory process, thereby providing a basis for subsequently splitting into multiple consecutive data cycles and performing synchronous burst transfers.
[0069] For example, when the logic unit data includes multiple word data segments, the ARM processor can load these word data segments into multiple general-purpose registers respectively, and then write the data from these general-purpose registers sequentially to a mapped contiguous virtual address space through a single multi-register store operation. If this virtual address space corresponds to the FPGA's frame buffer physical address space, the data in the multiple general-purpose registers can be continuously written to the FPGA frame buffer via a parallel bus. In this way, the contiguous storage capability of multiple general-purpose registers within the ARM processor can be utilized to more efficiently transform the logic unit data into a continuous write process on a parallel bus.
[0070] In some implementations, the storage operation includes generating a continuous write cycle signal to the parallel bus, specifically including: the period of the continuous write cycle signal corresponds to the number of the plurality of general-purpose registers; the controller of the parallel bus does not insert an address phase or a turnaround cycle during the data write phase.
[0071] In this embodiment, when the ARM processor writes data from multiple general-purpose registers to the virtual address space of a user process in consecutive addresses, the period of the generated consecutive write cycle signal can correspond to the number of general-purpose registers. Specifically, the data in the multiple general-purpose registers can be used as different data segments in the consecutive write process. When the ARM processor performs a memory operation, the data in each general-purpose register can trigger one or more write cycles on the parallel bus, so that the number of consecutive write cycle signals can be determined according to the number of general-purpose registers involved in the write. Thus, a single consecutive memory operation on the ARM processor side can form a consecutive write process on the parallel bus corresponding to the data output order of the multiple general-purpose registers.
[0072] In this implementation, the parallel bus controller does not insert address phases or turnaround cycles during the data write phase. An address phase can be understood as the phase in which the parallel bus outputs or updates address information to determine the target address; a turnaround cycle can be understood as the interval between adjacent bus transactions caused by direction switching, bus release, or re-establishment of access states. When data in multiple general-purpose registers is written with consecutive addresses, the parallel bus controller can maintain the current burst write state, allowing subsequent data cycles to be transmitted sequentially according to consecutive addresses, without needing to repeatedly insert address phases or turnaround cycles between each data cycle. This reduces the invalid bus occupancy time between multiple data cycles, allowing the continuous write cycle signals to drive the parallel bus data transmission more compactly.
[0073] Specifically, an ARM processor can write data from multiple general-purpose registers as a contiguous storage sequence into a mapped virtual address space. Because the target addresses are consecutive, the parallel bus controller can transmit subsequent data chunks in an ascending order of address after the initial address is determined. During the data write phase, the controller can continuously output data chunks corresponding to the data in the multiple general-purpose registers, allowing the FPGA to continuously receive these data chunks during synchronous burst transmission. By avoiding re-entering the address phase or inserting turnaround cycles between data chunks, the transaction overhead caused by small-granularity discrete accesses can be reduced.
[0074] For example, when four general-purpose registers in an ARM processor store four data segments of logic unit data respectively, the ARM processor can sequentially write the data from these four registers to consecutive virtual addresses in a single continuous store operation. The parallel bus controller can generate corresponding continuous write cycle signals based on this continuous store operation and continuously transmit the data content corresponding to the four general-purpose registers during the data write phase, instead of initiating an independent address access for each register separately. This allows logic unit data to be more stably converted into multiple consecutive data cycles and improves the bus utilization of synchronous burst transmissions.
[0075] In some implementations, the ARM processor includes an online dynamic adjustment interface; the online dynamic adjustment interface is used to input timing configuration parameters; the ARM processor writes the timing configuration parameters into the controller of the parallel bus in real time to adjust the timing of synchronous burst transmissions.
[0076] In this embodiment, the ARM processor in the industrial equipment may further include an online dynamic adjustment interface. The online dynamic adjustment interface can be used to receive timing configuration parameters during the operation of the industrial equipment and provide these parameters to the configuration logic in the ARM processor related to parallel bus control. The timing configuration parameters can be used to characterize the timing relationships between address signals, data signals, write control signals, wait signals, or synchronization clocks during synchronous burst transmissions, such as data setup time, data hold time, write cycle length, number of wait cycles, or control parameters related to burst transmissions.
[0077] Specifically, the online dynamic adjustment interface can receive timing configuration parameters from user processes, drivers, or device control programs. After obtaining these timing configuration parameters, the ARM processor can perform a validity check to determine whether they meet the timing constraints of the parallel bus controller and the FPGA. If the check passes, the ARM processor can immediately write the timing configuration parameters into the parallel bus controller, enabling the parallel bus controller to perform synchronous burst transmissions according to the updated timing. This immediate writing can be understood as writing the timing configuration parameters into the relevant configuration registers of the parallel bus controller without changing the hardware connections, so that the updated parameters in these registers can be applied to subsequent synchronous burst transmissions.
[0078] In this embodiment, adjusting the timing of synchronous burst transmissions via an online dynamic adjustment interface allows industrial equipment to adapt to different operating states or the bus timing requirements of different FPGA devices. Since the FPGA needs to meet data setup and hold time requirements when receiving multiple consecutive data packets, if the timing of synchronous burst transmissions is too fast, the FPGA may be unable to stably latch data; if the timing is too slow, the effective transmission efficiency of the parallel bus will be reduced. Therefore, the ARM processor can input appropriate timing configuration parameters through the online dynamic adjustment interface and write these parameters into the parallel bus controller to achieve a balance between transmission reliability and transmission efficiency.
[0079] For example, in one implementation where the parallel bus is an EIM parallel bus, the online dynamic adjustment interface can correspond to the timing configuration commands provided by the driver. The user process can pass parameters related to synchronous burst transmissions on the EIM parallel bus through these timing configuration commands. After verification, the ARM processor writes these parameters into the relevant timing registers of the EIM controller. Thus, when industrial equipment replaces FPGAs with different rate levels, or when the synchronous burst transmission rhythm needs to be adjusted for different data transmission tasks, the timing configuration of the parallel bus controller can be updated through the online dynamic adjustment interface without changing the parallel bus connection between the ARM processor and the FPGA. This improves the adaptability of industrial equipment to perform synchronous burst transmissions under different FPGA timing conditions.
[0080] One embodiment of this application also provides a computer-readable storage medium having a computer program stored thereon that, when executed by a processor, implements the data transmission method as described above.
[0081] In this embodiment, the computer-readable storage medium can be used to store a computer program. The computer program may include program instructions that can be read and executed by a processor. When the processor executes the computer program, it can implement any of the aforementioned data transmission methods to write data to be transmitted into the FPGA via a parallel bus. The computer-readable storage medium can be a non-transitory storage medium capable of storing program instructions, such as a read-only memory, random access memory, flash memory, solid-state drive, disk, or other processor-accessible storage medium.
[0082] In this embodiment, when the computer program is executed by the processor, the processor can directly map the physical address space of the FPGA to the virtual address space of the user process through memory mapping, and convert the data to be transmitted into logic unit data. Subsequently, the processor can perform a storage operation to write the logic unit data into the virtual address space of the user process, and generate continuous write cycle signals to the parallel bus through this storage operation. Further, in response to the continuous write cycle signals, the processor or the controller of the parallel bus can split the logic unit data into multiple consecutive data blocks, and write the multiple consecutive data blocks into the physical address space of the FPGA through synchronous burst transmission.
[0083] In some embodiments, the computer program can also cause the processor to execute further implementations of the aforementioned data transmission method. For example, the processor can perform zero-copy access to the virtual address space of the user process through storage operations; it can obtain the physical page frame number corresponding to the physical address space of the FPGA and set the memory mapping attribute to non-cached; it can also control the controller of the parallel bus to perform synchronous burst transmission on the edge of the synchronous clock, or generate a byte valid mask signal based on the physical data bit width of the parallel bus and continuous write cycle signals. The above program instructions can be combined and stored in the same computer-readable storage medium, or stored separately in multiple computer-readable storage media, as needed.
[0084] In this embodiment, the specific functions and effects implemented by the computer-readable storage medium can be explained by referring to other embodiments of this application, and will not be repeated here.
[0085] It is understood that the specific examples in this document are only intended to help those skilled in the art better understand the embodiments of this application, and are not intended to limit the scope of the invention.
[0086] It is understood that in the various embodiments of this application, the sequence number of each process does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.
[0087] It is understood that the various implementation methods described in this application can be implemented individually or in combination, and the implementation methods in this application are not limited in this respect.
[0088] Unless otherwise stated, all technical and scientific terms used in the embodiments of this application have the same meaning as commonly understood by one of ordinary skill in the art. The terminology used in this application is for the purpose of describing particular embodiments only and is not intended to limit the scope of this application. The term "and / or" as used in this application includes any and all combinations of one or more of the associated listed items. The singular forms "a," "the," and "the" as used in the embodiments of this application and the appended claims are also intended to include the plural forms unless the context clearly indicates otherwise.
[0089] The above description is merely a specific embodiment of this application, but the scope of protection of this invention is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this invention should be determined by the scope of the claims.
Claims
1. A data transmission method based on a parallel bus, characterized in that, The data transmission method involves writing the data to be transmitted into the FPGA via a parallel bus, and includes: Memory mapping directly maps the physical address space of the FPGA to the virtual address space of the user process. The data to be transmitted is converted into logic unit data; the bit width of the logic unit data is an integer multiple of the physical data bit width of the parallel bus. A storage operation is performed to write the data of the logical unit into the virtual address space of the user process; the storage operation includes generating a series of write cycle signals to the parallel bus; In response to the continuous write cycle signals, the logic unit data is split into multiple consecutive data blocks; the bit width of the multiple consecutive data blocks is the physical data bit width of the parallel bus; Perform synchronous burst transmission to write the multiple consecutive data packets into the physical address space of the FPGA.
2. The data transmission method according to claim 1, characterized in that, The memory mapping attribute is set to non-cached, and performing a storage operation to write the logical unit data into the virtual address space of the user process includes: Zero-copy access is performed on the virtual address space of the user process through storage operations.
3. The data transmission method according to claim 1, characterized in that, Memory mapping directly maps the physical address space of the FPGA to the virtual address space of the user process, including: Obtain the physical page frame number corresponding to the physical address space of the FPGA; The memory mapping directly maps the FPGA's physical address space to the user process's virtual address space based on the corresponding physical page frame number.
4. The data transmission method according to claim 1, characterized in that, Performing synchronous burst transmissions to write the multiple consecutive data packets into the physical address space of the FPGA includes: The controller of the parallel bus performs synchronous burst transmissions on the edge of the synchronous clock. The FPGA performs corresponding data latching at the same or another corresponding edge of the synchronous clock.
5. The data transmission method according to claim 1, characterized in that, Performing synchronous burst transmissions to write the multiple consecutive data packets into the physical address space of the FPGA includes: A byte valid mask signal is generated based on the physical data bit width of the parallel bus and the consecutive write cycle signals; the byte valid mask signal includes multi-bit byte data that corresponds one-to-one with the plurality of consecutive data cycles; The multi-byte data is updated in real time based on the transmission progress of the multiple consecutive data snapshots.
6. The data transmission method according to claim 1, characterized in that, Performing a storage operation to write the logical unit data into the virtual address space of the user process includes: Memory operations are performed using the processor's multi-register memory instruction; The data of the logical units located in multiple general-purpose registers of the processor are written to the virtual address space of the user process at consecutive addresses; The number of cycles of the continuous write cycle signal corresponds to the number of the plurality of general-purpose registers.
7. The data transmission method according to claim 6, characterized in that, The data transmission method further includes: The controller of the parallel bus does not insert an address phase or a turnaround cycle during the data writing phase.
8. A data transmission device based on a parallel bus, characterized in that, The data transmission device is used to write data to be transmitted into the FPGA via a parallel bus, and includes: A memory mapping module is used to directly map the physical address space of the FPGA to the virtual address space of the user process through memory mapping. A data conversion module is used to convert the data to be transmitted into logic unit data; the bit width of the logic unit data is an integer multiple of the physical data bit width of the parallel bus; A storage operation module is used to perform storage operations to write the data of the logical unit into the virtual address space of the user process; the storage operation includes generating continuous write cycle signals to the parallel bus; Data splitting module: used to split the logic unit data into multiple consecutive data blocks in response to the continuous write cycle signals; the bit width of the multiple consecutive data blocks is the physical data bit width of the parallel bus; The data writing module is used to perform synchronous burst transmission to write the multiple consecutive data packets into the physical address space of the FPGA.
9. An industrial device comprising an ARM processor and an FPGA, wherein the ARM processor and the FPGA are connected via a parallel bus, characterized in that, The ARM processor is configured to perform the following operations: directly map the physical address space of the FPGA to the virtual address space of the user process via memory mapping; convert the data to be transmitted into logic unit data; the bit width of the logic unit data is an integer multiple of the physical data bit width of the parallel bus; perform a storage operation to write the logic unit data into the virtual address space of the user process; the storage operation includes generating consecutive write cycle signals to the parallel bus; and splitting the logic unit data into multiple consecutive data blocks in response to the consecutive write cycle signals; the bit width of the multiple consecutive data blocks is the physical data bit width of the parallel bus. The FPGA is configured to perform the following operations: receive the multiple consecutive data packets that are synchronously burst-transmitted by the parallel bus and write them into the physical address space of the FPGA.
10. An industrial equipment according to claim 9, characterized in that, The ARM processor includes an online dynamic adjustment interface; the online dynamic adjustment interface is used to input timing configuration parameters; the ARM processor writes the timing configuration parameters into the controller of the parallel bus in real time to adjust the timing of synchronous burst transmission.
11. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by the processor, it implements the data transmission method as described in any one of claims 1 to 7.
