A high-speed DO and PWM output board based on MCU+FPGA

By combining MCU and FPGA, the problem of weak or no PWM output function in existing DO boards is solved, realizing high-precision, low-cost and short-development-cycle DO and PWM output, thus improving system performance and reliability.

CN110908948BActive Publication Date: 2024-11-05HANGZHOU WOLEI INTELLIGENT TECH
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
CN201911304033.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2019-12-17
Publication Date
2024-11-05
Estimated Expiration
2039-12-17

AI Technical Summary

Technical Problem

Existing DO boards suffer from weak or no functionality, high development difficulty, and high cost when implementing PWM output, especially when there are many output channels, and the development cycle of MCU+FPGA solutions is long.

Method used

The solution adopts a combination of microcontroller unit (MCU) and FPGA. The MCU is responsible for communication, calculation, and storage functions, while the FPGA is responsible for the transmission of DO and PWM signals. It is connected through SPI interface and IO port to achieve high-precision PWM output.

Benefits of technology

It achieves high-precision DO and PWM output, reduces costs and development cycle, and improves system performance and reliability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN110908948B_ABST
    Figure CN110908948B_ABST
Patent Text Reader

Abstract

The present invention discloses a high-speed DO and PWM output board based on MCU+FPGA. The present invention uses FPGA as a functional device for external expansion of a microcontroller unit MCU, and uses the SPI and IO ports of the microcontroller unit MCU to communicate with the FPGA in real time. The FPGA can be set accordingly according to the command of the microcontroller unit MCU, and the output mode is selected according to the setting. When it is DO output, the FPGA directly outputs the I / O port information, and the delay is only 10ns; when the PWM output mode is selected, the FPGA directly outputs the corresponding PWM signal. The beneficial effects of the present invention are: giving full play to the function of MCU+FPGA, and only needing to add a low-cost FPGA chip to the original MCU solution to achieve high-precision DO and PWM output, low cost, short development cycle, high performance and high reliability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of automobile detection, and in particular to a high-speed DO and PWM output board based on MCU+FPGA, which can be applied to the detection system of electronic components such as automobile controllers. Background Art

[0002] When testing electronic components such as automotive controllers, switch output signals and PWM signals are often required, and the real-time performance and accuracy are extremely high. Most domestic DO boards are implemented using MCU. Although the DO output has good real-time performance, the PWM output capability is extremely weak, and some DO boards do not even have this function. Some high-performance boards abroad are implemented using FPGA solutions, but the price is extremely high. If all functions are implemented using FPGA, the development difficulty and development cycle will increase exponentially.

[0003] In order to overcome the above-mentioned shortcomings, the existing microprocessor alone can no longer meet the PWM output requirements, especially when the number of output paths is large. The FPGA solution can be implemented, but the development cycle is long and the cost is high. The present invention uses a microcontroller unit MCU and FPGA as the control system of the board, and puts the functions of communication, calculation, storage, etc. on the microcontroller unit MCU for processing. The output of DO is also directly controlled by the microcontroller unit MCU, and the FPGA only plays a transmission role. The PWM function and output form are placed on the FPGA to achieve high-precision PWM output. Summary of the invention

[0004] In view of the deficiencies in the prior art, the present invention proposes a high-speed DO and PWM output board based on MCU+FPGA.

[0005] The purpose of the present invention is achieved through the following technical solutions:

[0006] A high-speed DO and PWM output board based on MCU+FPGA, comprising a microcontroller unit MCU and an FPGA unit; the microcontroller unit MCU is connected to the FPGA unit through 8 IO ports and a serial peripheral interface SPI; the FPGA unit is connected to a switch output unit DO;

[0007] In the DO output state, the microcontroller unit MCU sends the DO signal through the FPGA unit. The FPGA unit does not process the signal, but directly transmits the DO signal sent by the MCU to the switch output unit DO;

[0008] In the PWM output state, the microcontroller unit MCU sends output configuration information and PWM output information through the serial peripheral interface SPI, and the FPGA unit generates a corresponding PWM output signal according to the received output configuration information and PWM output information, and transmits the PWM output signal to the switch output unit DO;

[0009] The microcontroller unit MCU is connected with the host computer in real-time communication.

[0010] Furthermore, the micro control unit MCU is connected to the host in real-time communication via an EtherCAT communication unit.

[0011] Furthermore, the FPGA unit is connected to the switch output unit DO via 8 pairs of IO ports.

[0012] Furthermore, the configuration information and PWM output information include frequency, duty cycle and phase information.

[0013] The beneficial effects of the present invention are: giving full play to the functions of MCU+FPGA, only one low-cost FPGA chip needs to be added to the original MCU solution to achieve high-precision DO and PWM output, low cost, short development cycle, high performance and high reliability. BRIEF DESCRIPTION OF THE DRAWINGS

[0014] The technical solution of the present invention is further described below in conjunction with the accompanying drawings and embodiments.

[0015] Figure 1 It is the electrical schematic diagram of the present invention;

[0016] Figure 2 This is the top-level schematic diagram of the FPGA unit.

[0017] Wherein: POWER represents the power supply unit of the whole system, MCU represents the microcontroller unit, FPGA represents the FPGA unit, EtherCAT represents the EtherCAT communication unit, DO represents the switch output unit, and SPI represents the SPI communication unit. DETAILED DESCRIPTION

[0018] Figure 1 The electrical schematic diagram of the high-speed DO and PWM output board of the present invention includes a microcontroller unit MCU, an EtherCAT communication unit, an FPGA unit and a switch output unit DO.

[0019] The EtherCAT communication unit is connected to the microcontroller unit MCU to realize real-time communication with the host; the microcontroller unit MCU is connected to the FPGA unit through 8 IO ports and one SPI; the FPGA unit is connected to the switch output unit through 8 pairs (16) of IO ports.

[0020] The microcontroller unit MCU includes multiple communication interfaces, RAM, ROM, and timers to realize real-time communication, data calculation, and storage template self-checking functions of the core unit. The microcontroller unit MCU communicates with the host in real time through the EtherCAT communication unit. The main data include output configuration information, DO output value, and frequency and duty cycle of PWM signal. The microcontroller unit MCU has a storage function, and the relevant configuration information will not be lost after power failure, ensuring that the board can work normally when powered on. The microcontroller unit MCU also has a self-checking function and displays in real time through indicator lights to facilitate troubleshooting.

[0021] The FPGA unit is the core of this design. The present invention uses FPGA as a functional device for external expansion of the microcontroller unit MCU. The FPGA and the microcontroller unit MCU are connected in two ways, one is 8-way IO port connection, and the other is SPI interface. The SPI interface is mainly used for the transmission of configuration information. The configuration information has a relatively low requirement for delay. The SPI interface fully meets the performance requirements. When configured as PWM output, the FPGA will generate a PWM signal according to the specific configuration information and output it through 8 pairs (16) of IO ports. When configured as DO output, the output port is directly controlled by the 8 input IO ports, and the delay is only 10ns.

[0022] The switch output unit can determine whether it is push-pull output, source output, drain output or high-impedance output according to the output signal of the FPGA (mainly determined by a pair of IO signals, which also has a dead zone control function to ensure that the upper and lower tubes are not turned on at the same time). The switch output unit has built-in overcurrent protection and short-circuit protection functions to ensure that the module will not be damaged when the wiring is wrong or there is a problem with the input signal.

[0023] Figure 2 This is the top-level schematic diagram of the FPGA unit (only one channel is taken as an example, there are actually 8 channels). It is mainly composed of two modules, one unit is the SPI communication module, and the other module is the PWM and DO output module. The SPI communication module can perform corresponding communication and extract the frequency, duty cycle, phase and corresponding configuration information of each channel. The PWM and DO output modules determine the output type and mode according to the configuration information. If it is a PWM output, this module will generate the corresponding PWM signal to drive DO_H and DO_L. This pair of signals has its own dead zone control, and the dead zone time can be modified according to the configuration information. If it is a DO output, DO_H and DO_L are directly controlled by the input signal DI (the dead zone and output mode are still determined by the configuration information).

[0024] The described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of the present invention.

Claims

1. A high-speed DO and PWM output board based on MCU+FPGA, characterized in that: It includes a microcontroller unit MCU and an FPGA unit; the microcontroller unit MCU is connected to the FPGA unit through 8 IO ports and a serial peripheral interface SPI; the FPGA unit is connected to a switch output unit DO; In the DO output state, the microcontroller unit MCU sends the DO signal through the FPGA unit. The FPGA unit does not process the signal, but directly transmits the DO signal sent by the MCU to the switch output unit DO; In the PWM output state, the microcontroller unit MCU sends output configuration information and PWM output information through the serial peripheral interface SPI, and the FPGA unit generates a corresponding PWM output signal according to the received output configuration information and PWM output information, and transmits the PWM output signal to the switch output unit DO; The microcontroller unit MCU is connected to the host in real-time communication; The top layer of the FPGA unit is composed of two modules, one module is the SPI communication module, and the other module is the PWM and DO output module; The SPI communication module can perform corresponding communication and extract the frequency, duty cycle, phase and corresponding configuration information of each channel; The PWM and DO output modules determine the output type and mode based on the configuration information. When PWM is output, this module will generate corresponding PWM signals to drive DO_H and DO_L. This pair of signals has its own dead zone control, and the dead zone time can be modified according to the configuration information; When it is DO output, DO_H and DO_L are directly controlled by the input signal DI, and the dead zone and output mode are still determined by the configuration information.

2. A high-speed DO and PWM output board based on MCU+FPGA as claimed in claim 1, characterized in that: The micro control unit MCU is connected to the host computer in real-time communication via the EtherCAT communication unit.

3. A high-speed DO and PWM output board based on MCU+FPGA as claimed in claim 1, characterized in that: The FPGA unit is connected to the switch output unit DO via 8 pairs of IO ports.

4. A high-speed DO and PWM output board based on MCU+FPGA as claimed in claim 1, characterized in that: The configuration information and PWM output information include frequency, duty cycle and phase information.

Citation Information

Patent Citations

  • Method for rapidly implementing action of emergency protective system of steam turbine

    CN101788802A

  • Board card for flexible alternating-current power transmission device

    CN102368611A

  • Computer hardware platform design method based on DSP (digital signal processor) and FPGA (field programmable gate array)

    CN102567280A

  • Double SVC coordination control device

    CN103840473A

  • Chopping expansion controller

    CN105867241A