Distributed MCU software burning control machine and control method
By using a distributed MCU software programming controller controlled by the main MCU, a one-to-many programming link and independent channel configuration are achieved, which solves the problem of high manpower and time costs in distributed MCU systems and improves programming efficiency and stability.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- CHINA SHIPBUILDING IND CORP NO 723 RESEARCH INSTITUTE
- Filing Date
- 2025-12-12
- Publication Date
- 2026-04-17
AI Technical Summary
Existing technologies require sequential connection to an emulator for programming operations in distributed MCU systems, resulting in high manpower and time costs, as well as a lack of anti-interference and stability.
The distributed MCU software programming controller, controlled by the main MCU, communicates with the host computer through a bus transceiver to realize a one-to-many programming link. It is configured with independent power supply and digital signal isolation channels, uses GPIO level output to control the power supply and digital signal isolation circuit, and performs programming operations in conjunction with the SWD interface.
It improves programming efficiency, saves labor costs, enhances anti-interference capabilities and programming stability, and eliminates the need for frequent plugging and unplugging of the emulator interface.
Smart Images

Figure CN121879783A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of distributed system software management technology, and in particular to a distributed MCU software programming controller and control method. Background Technology
[0002] A microcontroller unit (MCU), also known as a single-chip microcomputer or microcontroller, is a chip-level computer that integrates a central processing unit (CPU) with a reduced frequency and specifications, along with peripheral interfaces such as memory, counters, USB, A / D converters, UART, PLC, DMA, and even LCD driver circuitry, all on a single chip. This allows for different control combinations for various applications. With the widespread adoption of embedded technology, MCUs are now widely used in modern systems to meet diverse needs for control, monitoring, and processing. MCUs operate based on software code, which needs to be programmed into the MCU's memory using an emulator. Common programming methods include JTAG and SWD.
[0003] Modern electronic systems, such as radar array systems, often adopt a distributed architecture. For distributed MCUs, during programming, it is usually necessary to connect the emulator to the MCU's programming interface one by one to perform the programming operation. When there are many distributed units, it will consume a lot of manpower and time costs.
[0004] Therefore, there is an urgent need to invent a distributed MCU programming system that is easy to use, saves labor costs, and has high programming efficiency to meet the software programming needs of distributed MCUs. Summary of the Invention
[0005] The purpose of this invention is to provide a distributed MCU software programming controller and control method that is easy to use, saves labor costs, has high programming efficiency, and has strong anti-interference and stability.
[0006] The technical solution to achieve the purpose of this invention is: a distributed MCU software programming controller, including a main MCU, a bus transceiver, a programming and communication interface, and multiple MCU software programming subsystems, wherein each MCU software programming subsystem includes a digital signal isolation circuit, a power control circuit, and an MCU programming interface;
[0007] The main MCU establishes communication with the host computer via a bus transceiver, receives the MCU programming selection message from the host computer, intercepts the MCU software programming subsystem information, triggers GPIO level output to control the power control circuit of the MCU software programming subsystem to turn on, thereby starting the digital signal isolation circuit, and sends a configuration response message through the bus transceiver; after receiving a valid configuration response, the host computer controls the emulator to perform the software programming operation. The programming and communication interface receives data from the emulator through the SWD interface and sends it to the MCU programming interface of the corresponding MCU software programming subsystem to program the corresponding MCU.
[0008] Furthermore, the main MCU uses the emulator's output power as the power supply for the programming controller. At any given time, only one MCU software programming subsystem's power control circuit is turned on, while other power control circuits are turned off.
[0009] Furthermore, the on / off state of each power control circuit is controlled by the main MCU.
[0010] Furthermore, the main MCU connects the emulator's SWD programming interface to the MCU programming interface of the MCU software programming subsystem. At any given time, only one digital signal isolation circuit of the MCU software programming subsystem is in the conducting state, while other digital signal isolation circuits are disconnected.
[0011] Furthermore, the switching on and off of each digital signal isolation circuit is controlled by the main MCU.
[0012] Furthermore, the main MCU includes a UART peripheral interface, which, together with the bus transceiver, forms an RS485 communication circuit.
[0013] Furthermore, the MCU programming interface of the MCU software programming subsystem adopts the SWD interface.
[0014] Furthermore, the SWD interface of the MCU software programming subsystem is a 4-pin interface, of which 2 pins are used to power the MCU, and the other 2 pins are used for programming clock signals and data signals, respectively.
[0015] Furthermore, the power control circuit of the MCU software programming subsystem is disconnected by default, and the digital signal isolation circuit is not started. When a distributed MCU needs to be programmed, the main MCU receives the channel number through the RS485 interface and triggers the power control circuit of the MCU software programming subsystem to turn on through the GPIO port. At the same time, the digital signal isolation circuit is powered on and started. At this time, it is equivalent to directly connecting the emulator's SWD interface to the MCU's SWD interface.
[0016] A distributed MCU software programming and control method includes the following steps:
[0017] Step 1: After powering on the distributed MCU software programming controller, initialize it.
[0018] Step 2: The host computer sends the MCU programming selection message, and the main MCU captures the channel selection message on the RS485 bus;
[0019] Step 3: After the main MCU captures the message, it intercepts the MCU software programming subsystem information, triggers the GPIO level output to control the power control circuit of the MCU software programming subsystem information to be turned on, thereby starting the digital signal isolation circuit of the MCU software programming subsystem information.
[0020] Step 4: The main MCU sends a configuration response message via the RS485 bus;
[0021] Step 5: After receiving a valid configuration response, the host computer controls the emulator to perform the software burning operation;
[0022] Step 6: The programming and communication interface receives data from the emulator through the SWD interface and sends it to the MCU programming interface of the corresponding MCU software programming subsystem to program the corresponding MCU.
[0023] Compared with the prior art, the present invention has the following significant advantages: (1) It adopts a communication and control circuit based on MCU to realize a one-to-many programming link, which eliminates the need for frequent plugging and unplugging of the simulator interface and improves the efficiency of software management; (2) It configures an independent power supply channel and a digital signal isolation output channel for each distributed MCU unit, which enhances the anti-interference capability of the programming process and improves the stability of distributed MCU software programming. Attached Figure Description
[0024] Figure 1 This is a schematic diagram of the structure of a distributed MCU software programming controller according to the present invention.
[0025] Figure 2 This is a flowchart illustrating a distributed MCU software programming control method according to the present invention.
[0026] Figure 3 This is a schematic diagram illustrating the principle of using a distributed MCU software programming controller to program distributed MCU software in an embodiment of the present invention. Detailed Implementation
[0027] like Figure 1 As shown, the present invention provides a distributed MCU software programming controller, including a main MCU, a bus transceiver, a programming and communication interface, and multiple MCU software programming subsystems, wherein each MCU software programming subsystem includes a digital signal isolation circuit, a power control circuit, and an MCU programming interface;
[0028] The main MCU establishes communication with the host computer via a bus transceiver, receives the MCU programming selection message from the host computer, intercepts the MCU software programming subsystem information, triggers GPIO level output to control the power control circuit of the MCU software programming subsystem to turn on, thereby starting the digital signal isolation circuit, and sends a configuration response message through the bus transceiver; after receiving a valid configuration response, the host computer controls the emulator to perform the software programming operation. The programming and communication interface receives data from the emulator through the SWD interface and sends it to the MCU programming interface of the corresponding MCU software programming subsystem to program the corresponding MCU.
[0029] As a specific example, the main MCU uses the emulator's output power as the power supply for the programming controller. At any given time, only one MCU software programming subsystem's power control circuit is turned on, while other power control circuits are turned off. The on / off state of each power control circuit is controlled by the main MCU.
[0030] As a specific example, the main MCU connects the emulator's SWD programming interface to the MCU programming interface of the MCU software programming subsystem. At any given time, only one digital signal isolation circuit of the MCU software programming subsystem is in the on state, while other digital signal isolation circuits are off. The on / off state of each digital signal isolation circuit is controlled by the main MCU.
[0031] As a specific example, the main MCU includes a UART peripheral interface, which, together with a bus transceiver, forms an RS485 communication circuit.
[0032] As a specific example, the MCU programming interface of the MCU software programming subsystem adopts the SWD interface, which is a 4-pin interface, of which 2 pins are used to power the MCU, and the other 2 pins are used for programming clock signals and data signals respectively.
[0033] As a specific example, the power control circuit of the MCU software programming subsystem is disconnected by default, and the digital signal isolation circuit is not started. When a distributed MCU needs to be programmed, the main MCU receives the channel number through the RS485 interface and triggers the power control circuit of the MCU software programming subsystem to turn on through the GPIO port. At the same time, the digital signal isolation circuit is powered on and started. At this time, it is equivalent to directly connecting the emulator's SWD interface to the MCU's SWD interface.
[0034] like Figure 2 As shown, the present invention provides a distributed MCU software programming and control method, comprising the following steps:
[0035] Step 1: After power-on, the distributed MCU software is programmed and the controller is initialized.
[0036] Step 2: The host computer sends the MCU programming selection message, and the main MCU captures the channel selection message on the RS485 bus;
[0037] Step 3: After the main MCU captures the message, it intercepts the MCU software programming subsystem information, triggers the GPIO level output to control the power control circuit of the MCU software programming subsystem information to be turned on, thereby starting the digital signal isolation circuit of the MCU software programming subsystem information.
[0038] Step 4: The main MCU sends a configuration response message via the RS485 bus;
[0039] Step 5: After receiving a valid configuration response, the host computer controls the emulator to perform the software burning operation;
[0040] Step 6: The programming and communication interface receives data from the emulator through the SWD interface and sends it to the MCU programming interface of the corresponding MCU software programming subsystem to program the corresponding MCU.
[0041] The present invention will now be described in further detail with reference to the accompanying drawings and specific embodiments.
[0042] Example
[0043] This embodiment demonstrates a specific application scheme for distributed MCU software programming using a distributed MCU software programming controller, such as... Figure 3 As shown, the distributed MCU software programming controller is built into each integrated unit, acting as a parent unit connected to each MCU unit via the SWD interface, and providing external connectivity through programming and communication interfaces. When programming is required, the emulator and USB-to-485 debugging tool are connected to the plug-in interface, and then sequentially connected to each integrated unit. The computer is used to input the channel number to program the distributed MCUs within the integrated unit sequentially. This eliminates the need to plug and unplug the emulator to connect to each MCU unit, saving time and manpower during the programming process.
[0044] The above are merely preferred embodiments of the present invention. It should be noted that those skilled in the art can make various improvements and modifications without departing from the principle of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.
Claims
1. A distributed MCU software programming controller, characterized in that, It includes a main MCU, a bus transceiver, a programming and communication interface, and multiple MCU software programming subsystems, each of which includes a digital signal isolation circuit, a power control circuit, and an MCU programming interface; The main MCU establishes communication with the host computer via a bus transceiver, receives the MCU programming selection message from the host computer, intercepts the MCU software programming subsystem information, triggers GPIO level output to control the power control circuit of the MCU software programming subsystem to turn on, thereby starting the digital signal isolation circuit, and sends a configuration response message through the bus transceiver; after receiving a valid configuration response, the host computer controls the emulator to perform the software programming operation. The programming and communication interface receives data from the emulator through the SWD interface and sends it to the MCU programming interface of the corresponding MCU software programming subsystem to program the corresponding MCU.
2. The distributed MCU software programming controller according to claim 1, characterized in that, The main MCU uses the emulator's output power as the power supply for the programming control unit. At any given time, only one MCU software programming subsystem's power control circuit is turned on, while other power control circuits are turned off.
3. The distributed MCU software programming controller according to claim 2, characterized in that, The on / off state of each power control circuit is controlled by the main MCU.
4. The distributed MCU software programming controller according to claim 1, characterized in that, The main MCU connects the emulator's SWD programming interface to the MCU programming interface of the MCU software programming subsystem. At any given time, only one digital signal isolation circuit of the MCU software programming subsystem is in the on state, while other digital signal isolation circuits are off.
5. The distributed MCU software programming controller according to claim 4, characterized in that, The on / off state of each digital signal isolation circuit is controlled by the main MCU.
6. The distributed MCU software programming controller according to claim 1, characterized in that, The main MCU includes a UART peripheral interface, which, together with the bus transceiver, forms an RS485 communication circuit.
7. The distributed MCU software programming controller according to claim 1, characterized in that, The MCU programming interface of the MCU software programming subsystem adopts the SWD interface.
8. The distributed MCU software programming controller according to claim 7, characterized in that, The SWD interface of the MCU software programming subsystem is a 4-pin interface, of which 2 pins are used to power the MCU, and the other 2 pins are the clock signal and data signal for programming.
9. The distributed MCU software programming controller according to claim 1, characterized in that, The power control circuit of the MCU software programming subsystem is disconnected by default, and the digital signal isolation circuit is not started. When a distributed MCU needs to be programmed, the main MCU receives the channel number through the RS485 interface and triggers the power control circuit of the MCU software programming subsystem to be turned on through the GPIO port. At the same time, the digital signal isolation circuit is powered on and started. At this time, it is equivalent to directly connecting the emulator's SWD interface to the MCU's SWD interface.
10. A distributed MCU software programming and control method, characterized in that, Includes the following steps: Step 1: After powering on the distributed MCU software programming controller as described in any one of claims 1 to 9, perform initialization; Step 2: The host computer sends the MCU programming selection message, and the main MCU captures the channel selection message on the RS485 bus; Step 3: After the main MCU captures the message, it intercepts the MCU software programming subsystem information, triggers the GPIO level output to control the power control circuit of the MCU software programming subsystem information to be turned on, thereby starting the digital signal isolation circuit of the MCU software programming subsystem information. Step 4: The main MCU sends a configuration response message via the RS485 bus; Step 5: After receiving a valid configuration response, the host computer controls the emulator to perform the software burning operation; Step 6: The programming and communication interface receives data from the emulator through the SWD interface and sends it to the MCU programming interface of the corresponding MCU software programming subsystem to program the corresponding MCU.