Power panel power-up control device and method based on MCU (Microprogrammed Control Unit)
By designing a power-on control device based on MCU, using the MCU module to communicate with the power board, real-time monitoring and control of the power board voltage is achieved, and traditional fuses cannot deal with voltage fluctuations, overvoltage or undervoltage in time, effectively protecting and extending the service life of the later-stage devices.
Patent Information
- Application Number
- CN202411887011.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-20
- Publication Date
- 2025-04-15
AI Technical Summary
The existing power supply control devices realize circuit protection through fuses, but voltage fluctuations, overvoltage or undervoltage within the untriggered range cannot be dealt with in time, resulting in a reduction in service life of the subsequent precision devices.
A power-up control device based on MCU is designed to communicate with the power board through the MCU module, and the power supply status of the power board is controlled by using the relay module. It is equipped with a power module, a storage module, an alarm module, a reset module and a clock module to realize real-time monitoring and control of the power board voltage.
Real-time monitoring and rapid response to the power board voltage is realized, and the LED alarm can be turned on when overvoltage or undervoltage is overvoltage for a small amplitude and short period of time, and the power supply is cut off when overloading or undervoltage is overloaded for a long time, protecting the later-stage devices and extending their service life.
Smart Images

Figure CN119828537A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of electronic information communication and automatic control, and in particular to a power supply board power-on control device based on MCU and a method thereof. Background Art
[0002] Electric energy has been widely used in the field of automatic control. Whether it is a large industrial automation motor equipment or a micro circuit board, the control of power on and off is of vital importance, because it is related to the personal safety of the operator and the service life of the equipment. The power control device on the traditional PCB board often uses a micro fuse or fuse for protection. When the circuit is overvoltage or the circuit current is too large, the fuse is quickly cut off to protect the subsequent circuit. In this process, by controlling the selection of the fuse, it is prevented that the circuit load is too large due to some unknown reasons during the operation of the equipment, thereby preventing the components from being burned. The above power control method has been widely used in the field of embedded development. The existing power supply control device uses fuses to protect components on circuit boards, and can only achieve automatic switching when the current is too large during the expected selection. When the system is actually cascaded, due to the influence of the integrated analog circuit, the power supply may be overvoltage or undervoltage within the range where the fuse is not triggered. Frequent voltage fluctuations may significantly reduce the service life of the subsequent precision components. When the PCB design is completed, if the power supply output is occasionally unstable during the test, it is difficult to control the power supply on and off by changing the components, which will cause occasional circuit performance instability and affect the service life. The fuse method is not sensitive and cannot respond to voltage fluctuations, overvoltage or undervoltage within the untriggered range in time. Therefore, it is urgent to provide a power supply control device with quick response and sensitivity for the above usage scenarios. Summary of the invention
[0003] The problem to be solved by the present invention is to provide a responsive power-on control device for controlling the power supply of a PCB board.
[0004] In view of the deficiencies in the prior art, the technical solution adopted by the present invention to solve the technical problems is: a power board power-on control device based on MCU, including an MCU module, the MCU module communicates with the power board through a serial port module, and the MCU module controls the power board through a relay module; the MCU module is also connected to a power module, a storage module, an alarm module, a reset module and a clock module, the power module provides power for the device, the storage module stores the power board fault information in an SD card, and the alarm module includes an LED alarm and a voice alarm.
[0005] Preferably, the chip model of the MCU module is STM32F407. The MCU module exchanges information with the power board through the serial port pin and the RS422 level conversion chip, and then drives the relay through the common emitter amplifier circuit via the PA4 pin to control the power supply board, and exchanges information with the outside world through the remaining GPIO ports.
[0006] Preferably, the relay model is SRD-12VDC-SL-C. When the PA4 pin has no input level signal, or inputs a low level signal, the entire circuit is in an open circuit state; when the PA4 inputs a high level, the entire circuit is turned on, and the COM terminal is connected to the positive 12, thereby achieving the purpose of powering the power board.
[0007] Preferably, the serial port module uses a chip model ADM3076EARZ.
[0008] A working method of a power board power-on control device based on MCU, comprising the following steps:
[0009] S1: The power module supplies power to the device, the device is powered on and reset, and the MCU enters the working state;
[0010] S2: The MCU module obtains the power status of the power board through the serial port module to determine whether the voltage of the power board is normal;
[0011] S3: If the MCU module determines that the voltage of the power board is normal, it sends an instruction to the relay module, and the relay module controls the power board to continue supplying power;
[0012] S4: If the MCU module determines that the voltage of the power board is abnormal, the abnormal situation is divided into short-term overvoltage or undervoltage, long-term overvoltage or undervoltage. If the abnormal situation is short-term overvoltage or undervoltage, enter S5, and if the abnormal situation is long-term overvoltage or undervoltage, enter S6;
[0013] S5: The MCU module determines that the power board is over-voltage or under-voltage for a short time, then the alarm module LED alarm light will light up to prompt, and the relay module will control the power board to continue supplying power;
[0014] S6: The MCU module determines that the power board is over-voltage or under-voltage for a long time, then the alarm module LED alarm light flashes and voice alarm is sounded, and the MCU writes the fault information into the storage module through the SD card bus for subsequent maintenance work. At the same time, the relay module controls the power board to cut off the power supply to the upper PCB board.
[0015] The beneficial effects of the present invention are as follows:
[0016] (1) The present invention constructs a single-chip minimum system, uses an RS422 chip to communicate with a host computer, can control the on and off of the upper PCB board power supply in real time, monitor the power supply voltage of the upper PCB board, and when a small short-term overvoltage or undervoltage occurs, the LED light is on; when a long-term large overload or undervoltage occurs, the LED light flashes, the voice alarm chip is started, and the power supply of the upper PCB board is cut off;
[0017] (2) In the present invention, we select STM32F407 as the main control MCU chip, which has high performance, low power consumption and rich peripheral functions, and is suitable for a variety of embedded application scenarios;
[0018] (3) The present invention is provided with an alarm function: the LED light is turned on and off to display in real time whether the upper power supply voltage meets the standard. When a long-term and large-scale overload or undervoltage occurs, the power supply is cut off to achieve the purpose of protection. At this time, the LED light state is changed to strobe;
[0019] (4) A data storage module is set up, and an SD card is added to store fault information in real time to realize the data storage function, accurately understand when the system fails, so as to simulate and reproduce the fault situation. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] Figure 1 It is a hardware block diagram of the power-on control device of the present invention;
[0021] Figure 2 This is a circuit diagram of an MCU involved in the present invention;
[0022] Figure 3 This is a circuit diagram of an MCU involved in the present invention;
[0023] Figure 4 It is a relay module circuit diagram involved in the present invention;
[0024] Figure 5 It is a circuit diagram of a power module involved in the present invention;
[0025] Figure 6 It is a circuit diagram of a storage module involved in the present invention;
[0026] Figure 7 The present invention relates to a voice alarm circuit diagram;
[0027] Figure 8 The present invention relates to an LED alarm circuit diagram;
[0028] Fig. 9 It is a serial port module circuit diagram involved in the present invention;
[0029] Fig.10 It is a reset module circuit diagram involved in the present invention;
[0030] Fig.11 It is a clock module circuit diagram involved in the present invention;
[0031] Fig.12 It is the work flow chart of the device of the present invention. DETAILED DESCRIPTION
[0032] The present invention is further described in detail below in conjunction with the accompanying drawings and specific embodiments. The embodiments of the present invention are provided for the purpose of illustration and description, and are not intended to be exhaustive or to limit the present invention to the disclosed forms. Many modifications and variations will be apparent to those of ordinary skill in the art. The embodiments are selected and described in order to better illustrate the principles and practical applications of the present invention, and to enable those of ordinary skill in the art to understand the present invention and thereby design various embodiments with various modifications suitable for specific uses.
[0033] The present invention designs a PCB power on-off control board separately, which interacts with the host computer through a three-way RS422 serial port chip. When the power supply of the current level is unstable, the information is sent to the power-on control device in real time, and the next step of the process is carried out through the judgment and operation module of the program written in the MCU. The device of the present invention can exchange information with the host computer to achieve the purpose of controlling the power on and off.
[0034] like Figure 1 The figure shows a hardware block diagram of the power board power-on control device based on MCU of the present invention. The present invention adopts the STM32 series STM32F407 of ST company as the system main control module design chip. The MCU module is connected with a serial port module, a relay module, a power module, a storage module, an alarm module, a reset module and a clock module to form the entire power-on control board. At the same time, the serial port module and the relay module are both communicatively connected with the power board.
[0035] The core chip of the device is the STM32F407 chip of ST Company. In the device, information is exchanged with the power board through the serial port pin and RS422 level conversion chip, and then the relay is driven through the common emitter amplifier circuit through the PA4 pin to achieve the purpose of power-on control of the power board. Finally, information is exchanged with the outside world through the remaining GPIO ports, including SD cards, voice chips, etc. The device of the present invention can analyze the voltage information sent by the power board through the serial port module by programming the MCU chip. The data sent is different, and the instructions output by the control pin of the power control board to the relay module and the alarm module are also changed. When the message sent by the power board is a small short-term overvoltage or undervoltage situation, the control alarm module LED light is turned on; when it is overloaded or undervoltage for a long time, the LED alarm light flashes, the voice alarm chip is started, and the power supply of the upper PCB board is cut off. This can solve the problem of insensitive power on and off on the traditional power supply board controlled by fuses. At the same time, the STM32F407 chip timer supports a maximum frequency of 168MHz, and can process data at a speed of microseconds, with fast response and sensitive reaction. The circuit diagram of the STM32F407 chip is shown in the figure. Figure 2 and Figure 3 As shown, the PA4 pin of the STM32F407 chip is connected to the relay module, PA8, PA9, and PA10 are connected to the LED alarm module, the PB10 and PB11 pins are connected to the serial port module, the PC8, PC9, PC10, PC11, PC12, PC8, PC8, and PD2 pins are connected to the storage module, PC14 and PC15 are connected to the clock module, the NRST pin is connected to the reset module, and PB12 is connected to the voice alarm module.
[0036] Figure 4 This is the relay module circuit diagram. The device uses the SRD-12VDC-SL-C relay. Because the driving ability of the MCU pin is limited, a common emitter amplifier circuit is added to enhance the driving ability of the pin. The transistor uses S8050. When the PA4 pin has no input level signal or a low level signal is input, there is no current passing through the base of the transistor. At this time, it is in the cut-off state. The current of VCC reaches the collector and is cut off, and the entire circuit is in the open circuit state. When PA4 inputs a high level (greater than the minimum conduction voltage 0.7V), the base of the transistor has current, the transistor is turned on, and the VCC current flows from the collector and flows out from the emitter to the ground, and the entire circuit is connected. At this time, the COM terminal is connected to the positive 12, so as to achieve the purpose of powering the power board. The relay is used to control the on-off of the power board, and it can be quickly switched according to the result of the MCU controlling the PA4 pin. At the same time, the relay has a long service life and can help solve the problem of insensitive on-off control of the power supply.
[0037] Figure 5This is the schematic diagram of the power module circuit. The power board is powered by 12V, while the MCU and RS422 level conversion chip are powered by 3.3V. Therefore, an LDO circuit needs to be added to drive the components on the entire PCB board. The LDO chip uses the common AMS1117-5 and AMS1117-3. At the same time, it has stable voltage output conversion efficiency. Adding 0.1uf capacitors at both ends reduces noise and enhances the stability of the entire system.
[0038] Figure 6 The circuit schematic diagram of the storage module is shown in Figure 1. The peripheral pins of the STM32F407 have standard SD card bus pins, so only a standard SD card slot is needed to store the fault information. When the power board sends information through the serial port, the power control board stores the fault information in the SD card according to the specific content for later reading and maintenance. The use of storage modules can solve the problem that conventional fuses do not have the ability to store and read data.
[0039] The alarm module includes voice alarm and LED alarm. Figure 7 This is a schematic diagram of a voice alarm circuit according to the present invention; Figure 8 This is the LED alarm circuit diagram involved in the present invention; in this device, when the serial port receives a message from the power board, according to the program information burned by the MCU on the power control board, when the message sent by the power board is a small short-term overvoltage or undervoltage situation, the LED light is on. When it is overloaded or undervoltage for a long time, the LED light flashes, the voice alarm chip starts, and the power supply of the upper PCB board is cut off. The voice alarm chip model in the circuit is KT148A, and the burning program can be repeated. At the same time, the chip adopts a one-line serial port control to save resources. In the voice alarm circuit, when the 5th foot is short-circuited to the ground, voice download can be performed.
[0040] Fig. 9 This is the schematic diagram of the serial port module. The entire PCB board is equipped with three RS422 level conversion chips to communicate with the power board and the entire system. The serial port module uses the ADM3076EARZ chip, which supports a 16MPS data rate and ±15KVESD protection. At the same time, due to its wide operating temperature range and full-duplex communication capability, it is suitable for the working environment requirements of the system. The serial port module is the circuit basis for the information exchange between the power board and the power-on control board. At the same time, the excellent data transmission speed of the ADM3076EARZ chip ensures the rapid response of the MCU module, which together solves the problem of insensitive on and off control of the traditional fuse power supply.
[0041] like Fig.10The figure shows the circuit schematic of the reset module. The reset module is a resistor-capacitor reset. The STM32F407 chip is a low-level reset. At the moment of power-on, the C24 capacitor begins to charge, the capacitor is in a short-circuit state, and the voltage on the capacitor is low. At this time, the MCU reset pin is pulled low and the MCU performs a reset. When the button is pressed, the reset pin is short-circuited to the ground, completing a low-level reset. Fig.11 Clock module circuit schematic diagram. The clock module provides a high-precision clock signal to the device during serial communication.
[0042] The working method of the power-on control device of the present invention is as follows:
[0043] S1: The power module supplies power to the device, the device is powered on and reset, and the MCU enters the working state;
[0044] S2: The MCU module obtains the power status of the power board through the serial port module to determine whether the voltage of the power board is normal;
[0045] S3: If the voltage of the MCU module power board is normal, the command is given to the relay module, and the relay module controls the power board to continue supplying power;
[0046] S4: If the voltage of the MCU module power board is abnormal, the abnormal situation is divided into short-term overvoltage or undervoltage, long-term overvoltage or undervoltage. If the abnormal situation is short-term overvoltage or undervoltage, enter S5, and if the abnormal situation is long-term overvoltage or undervoltage, enter S6;
[0047] S5: The MCU module determines that the power board is over-voltage or under-voltage for a short time, then the alarm module LED alarm light will light up to prompt, and the relay module will control the power board to continue supplying power;
[0048] S6: The MCU module determines that the power board is over-voltage or under-voltage for a long time, then the alarm module LED alarm light flashes and voice alarm is sounded, and the MCU writes the fault information into the storage module through the SD card bus for subsequent maintenance work. At the same time, the relay module controls the power board to cut off the power supply to the upper PCB board.
[0049] In summary, the present invention constructs a single-chip minimum system, uses RS422 chip to communicate with the host computer, can control the on and off of the upper PCB board power supply in real time, monitor the power supply voltage of the upper PCB board, and when a small short-term overvoltage or undervoltage occurs, the LED light turns on; when a long-term large overload or undervoltage occurs, the LED light flashes, the voice alarm chip starts, and the power supply of the upper PCB board is cut off. Compared with the traditional fuse, it reacts quickly and sensitively, and can better guarantee the service life of components in the case of occasional circuit performance instability.
Claims
1. A power board power-on control device based on MCU, characterized in that: It includes an MCU module, which communicates with the power board through the serial port module and controls the power board through the relay module; the MCU module is also connected to a power module, a storage module, an alarm module, a reset module and a clock module. The power module provides power for the device, the storage module stores the power board fault information in the SD card, and the alarm module includes an LED alarm and a voice alarm.
2. The MCU-based power board power-on control device according to claim 1, characterized in that: The chip model of the MCU module is STM32F407. The MCU module exchanges information with the power board through the serial port pin and RS422 level conversion chip, and then drives the relay through the common emitter amplifier circuit via the PA4 pin to control the power supply board, and exchanges information with the outside world through the remaining GPIO ports.
3. The MCU-based power board power-on control device according to claim 2, characterized in that: The relay model is SRD-12VDC-SL-C. When there is no input level signal to the PA4 pin, or a low level signal is input, the entire circuit is in an open circuit state; when a high level signal is input to PA4, the entire circuit is turned on, and the COM terminal is connected to positive 12, thereby achieving the purpose of powering the power board.
4. The MCU-based power board power-on control device according to claim 3, characterized in that: The serial port module uses the chip model ADM3076EARZ.
5. A working method of a power board power-on control device based on MCU, characterized in that: The following steps are included: S1: The power module supplies power to the device, the device is powered on and reset, and the MCU enters the working state; S2: The MCU module obtains the power status of the power board through the serial port module to determine whether the voltage of the power board is normal; S3: If the MCU module determines that the voltage of the power board is normal, it sends an instruction to the relay module, and the relay module controls the power board to continue supplying power; S4: If the MCU module determines that the voltage of the power board is abnormal, the abnormal situation is divided into short-term overvoltage or undervoltage, long-term overvoltage or undervoltage. If the abnormal situation is short-term overvoltage or undervoltage, enter S5, and if the abnormal situation is long-term overvoltage or undervoltage, enter S6; S5: The MCU module determines that the power board is over-voltage or under-voltage for a short time, then the alarm module LED alarm light will light up to prompt, and the relay module will control the power board to continue supplying power; S6: The MCU module determines that the power board is over-voltage or under-voltage for a long time, then the alarm module LED alarm light flashes and voice alarm is sounded, and the MCU writes the fault information into the storage module through the SD card bus for subsequent maintenance work. At the same time, the relay module controls the power board to cut off the power supply to the upper PCB board.