CN213303013U - Control circuit for seamless compatibility of single-chip microcomputer watchdog and program downloading function - Google Patents

Control circuit for seamless compatibility of single-chip microcomputer watchdog and program downloading function Download PDF

Info

Publication number
CN213303013U
CN213303013U CN202022625851.9U CN202022625851U CN213303013U CN 213303013 U CN213303013 U CN 213303013U CN 202022625851 U CN202022625851 U CN 202022625851U CN 213303013 U CN213303013 U CN 213303013U
Authority
CN
China
Prior art keywords
pin
watchdog
program
gate
logic
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202022625851.9U
Other languages
Chinese (zh)
Inventor
王毅
张晓康
张续曜
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shanxi Xinyuan Intelligent Control Technology Co ltd
Original Assignee
Shanxi Xinyuan Intelligent Control Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shanxi Xinyuan Intelligent Control Technology Co ltd filed Critical Shanxi Xinyuan Intelligent Control Technology Co ltd
Priority to CN202022625851.9U priority Critical patent/CN213303013U/en
Application granted granted Critical
Publication of CN213303013U publication Critical patent/CN213303013U/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Debugging And Monitoring (AREA)

Abstract

The utility model discloses a seamless compatible control circuit of singlechip watchdog and program download function. The control circuit comprises a logic AND gate, a logic OR gate, a watchdog function chip and a program downloading interface, and the working principle of the control circuit is as follows: a program downloading line is accessed into a program downloading port to start downloading the program, and meanwhile, the function of the watchdog is automatically disabled; after the program is downloaded, the download line is removed, and the function of watchdog is automatically activated. The plug-and-play program downloading port is realized, and the situation that the program downloading is interrupted by resetting the single chip microcomputer by sending a reset signal because the watchdog does not receive the signal of feeding the dog of the main program is not needed to be worried about. The utility model discloses a simple digital circuit integrated design has solved "program download" and "watchdog" function conflict problem, provides a new circuit design for the technical staff.

Description

Control circuit for seamless compatibility of single-chip microcomputer watchdog and program downloading function
Technical Field
The utility model relates to a microcomputer control system, concretely relates to seamless compatible control circuit of singlechip watchdog and program download function.
Technical Field
With the continuous development of the microcontroller technology of the single chip microcomputer, the application fields of the microcontroller are quite wide, such as intelligent household appliances, high-end instruments, precision machining equipment, real-time communication equipment, satellite positioning and navigation systems and the like. In order to prevent the singlechip from being interfered by an external electromagnetic field in work and prevent the singlechip from being incapable of continuously and normally working due to the fact that a program enters into dead circulation, a hardware watchdog circuit is arranged on the singlechip in a matching mode to monitor the running of a main program, and once the dead circulation or the PC pointer disorder occurs, the singlechip is reset and restarted. However, in the using process of the product, technology upgrading is often needed, and the singlechip needs to download the program again. In the program downloading process, the main program is interrupted, and the watchdog misjudges that the program flies, so that the singlechip is reset, and the program downloading is failed. In order to solve the problem, the watchdog function is generally prohibited by inserting a jumper cap or a dial switch before downloading the program, and the watchdog function is recovered by the jumper cap or the dial switch after the program is downloaded. The method is complex to operate and easy to make mistakes, and meanwhile, workload is added to technicians.
SUMMERY OF THE UTILITY MODEL
The utility model aims to provide a novel compatible type, seamless supporting circuit design to "program download" and "watchdog" function conflict problem.
In order to solve the technical problems, the technical scheme adopted by the invention is as follows:
a control circuit for seamless compatibility of a single chip microcomputer watchdog and a program downloading function comprises a logic AND gate, a logic OR gate, a watchdog function chip and a program downloading interface, wherein a first pin of the watchdog function chip
Figure BDA0002777447030000011
A fifth pin connected with the output end of the logic OR gate
Figure BDA0002777447030000012
Eighth pin
Figure BDA0002777447030000013
Respectively connected to the input end of the AND logic AND gate, the WDI pin of the sixth pin is connected to the single chip microcomputer, and the WDI pin of the seventh pin is connected to the input end of the AND logic AND gate
Figure BDA0002777447030000021
A fourth pin RESET of the program downloading interface 4 is accessed, the output end of the logic AND gate is accessed to one input end of the logic OR gate, the other input end of the logic OR gate is connected with a sixth pin DOWN of the program downloading interface, a second pin VCC of the watchdog function chip is connected with a power supply, a third pin GND is grounded, a fourth pin PFI is connected with the connection point of resistors R1 and R2, the other end of the resistor R1 is grounded, and the other end of the resistor R2 is connected with the power supply; the program downloading interface is characterized in that a first pin VCC of the program downloading interface is connected with a power supply, a second pin of the program downloading interface is connected with the power supply through a resistor R3, a third pin of the program downloading interface is grounded through a resistor R4, and a sixth pin of the program downloading interface is grounded through a resistor R5.
Further, the watchdog function chip is MAX706R chip.
Through the combined logic design of a logic AND gate and an OR gate, when a program downloading signal is not acquired, the working of the singlechip is monitored by matching with a watchdog control circuit, and once the program of the singlechip is found to run away, the singlechip is immediately reset to restart the program; after acquiring a program downloading signal, interrupting a watchdog function, preventing the reset caused by the stop of the running of the main program of the single chip microcomputer and interrupting the program downloading process; and after the program downloading signal disappears, the function of watchdog is recovered, and the running state of the singlechip is continuously monitored by matching with the watchdog.
Compared with the prior art, the invention has the following advantages:
the utility model discloses a simple digital circuit integrated design has solved "program download" and "watchdog" function conflict problem, provides a new circuit design for the technical staff.
Drawings
Fig. 1 is a circuit diagram of the present invention.
Detailed Description
The technical scheme of the invention is further explained by the specific embodiment in combination with the attached drawings. It should be understood by those skilled in the art that the specific embodiments are only for the understanding of the present invention and should not be construed as the specific limitations of the present invention.
A control circuit for seamless compatibility of a single-chip microcomputer watchdog and a program downloading function comprises a logic AND gate 1, a logic OR gate 2, a watchdog function chip 3 and a program downloading interface 4, wherein a first pin of the watchdog function chip 3
Figure BDA0002777447030000031
A fifth pin connected with the output terminal of the logic OR gate 2
Figure BDA0002777447030000032
Eighth pin
Figure BDA0002777447030000033
Respectively connected to the input end of the AND gate 1, the WDI pin of the sixth pin is connected to the singlechip, and the WDI pin of the seventh pin
Figure BDA0002777447030000034
A fourth pin RESET connected to the program download interface 4, an output terminal of the logic and gate 1 is connected to an input terminal of the logic or gate 2, another input terminal of the logic or gate 2 is connected to a sixth pin DOWN of the program download interface 4, a second pin VCC of the watchdog function chip 3 is connected to +3.3V of the power supply, a third pin GND is grounded, and a fourth pin PFI is connected to a connection point of resistors R1 and R2, wherein one ends of the resistors R1 and R2 are connected together, the other end of the resistor R1 is grounded, and the other end of the resistor R2 is connected to +3.3V of the power supply; the program downloading interface 4 is characterized in that a first pin VCC is connected with a power supply at +3.3V, a second pin is connected with the power supply at +3.3V through a resistor R3, and a third pin is grounded through a resistor R4. A capacitor C1 is connected between the power supply +3.3V and the ground GND.
The watchdog function chip 3 adopts a MAX706R chip.
The working principle of the utility model is as follows:
1. when the program downloading line is not accessed to the program downloading interface 4, the program downloading signal DOWN is at a low level and is input to the second pin of the or gate 2. The output result of the third pin of the logic or gate 2 is controlled by the first pin of the logic or gate 2 only. The normal operation of the watchdog circuit is not affected.
When the single chip microcomputer works normally, a jump signal is uninterruptedly sent to the sixth pin of the watchdog function chip 3 to feed the watchdog within a limited time, and the eighth pin of the watchdog function chip 3 outputs a high level to the first pin of the logic AND gate 1 normally. The fifth pin of the watchdog function chip 3 is a power supply voltage monitoring signal output end, and outputs a high level to the second pin of the logic and gate 1 when the power supply voltage is normal. And the third pin outputs high level to the first pin of the logic OR gate 2 after the AND operation of the chip logic AND gate 1. The second pin of the or gate 2 is high. After the logical or gate 2 performs the or operation, the third pin outputs a high level to the first pin of the watchdog function chip 3. The seventh pin of the watchdog function chip 3 outputs a high level signal.
When the singlechip generates abnormal work such as program runaway, pointer disorder and the like, the over-limit time does not send a jump signal to the sixth pin of the watchdog function chip 3 to feed the watchdog, and the eighth pin of the watchdog function chip 3 outputs low level to the first pin of the logic AND gate 1. And the fifth pin of the watchdog function chip 3 normally outputs a high level to the second pin of the logic AND gate 1. And the third pin outputs low level to the first pin of the logic OR gate 2 after the AND operation of the logic AND gate 1. The second pin of the or gate 2 is high. After the logical or gate 2 performs the or operation, the third pin outputs a low level to the first pin of the watchdog function chip 3. The seventh pin of the watchdog function chip 3 outputs a low level reset signal to the single chip microcomputer, so that the single chip microcomputer resets a restart program.
2. When the program downloading line is accessed to the program downloading interface 4, the downloading tool sends a high level signal to the sixth pin of the program downloading interface 4, and the signal DOWN becomes a high level and is input to the second pin of the logic or gate 2. The third pin of the logic or gate 2 always outputs high level and is not influenced by the high-low level change of the first pin. The watchdog circuit fails to function. And starting to download the program, and stopping the running of the main program of the single chip microcomputer.
3. When the program downloading is finished, the program downloading interface 4 removes the downloading line, and the signal DOWN is restored to the low level and input into the second pin of the logic or gate 2. The third pin of the logic or gate 2 or the gate is controlled by the first pin of the logic or gate 2. The function of the watchdog circuit is recovered, and the operation of the singlechip is normally detected.
The above description is only a preferred embodiment of the present invention, and is not intended to limit the present invention, and those skilled in the art can make various substitutions and modifications according to the technical solutions of the present invention. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention shall fall within the protection scope of the present invention.

Claims (2)

1. The utility model provides a singlechip watchdog and seamless compatible control circuit of program download function which characterized in that: the device comprises a logic AND gate (1), a logic OR gate (2), a watchdog function chip (3) and a program downloading interface (4), wherein a first pin of the watchdog function chip (3)
Figure FDA0002777447020000011
A fifth pin connected with the output end of the logic OR gate (2)
Figure FDA0002777447020000012
Eighth pin
Figure FDA0002777447020000013
Respectively connected to the input end of an AND logic AND gate (1), a sixth pin WDI is connected to the singlechip, and a seventh pin
Figure FDA0002777447020000014
A fourth pin RESET of a program downloading interface (4) is accessed, the output end of the logic AND gate (1) is accessed to one input end of the logic OR gate (2), the other input end of the logic OR gate (2) is connected with a sixth pin DOWN of the program downloading interface (4), and a second pin VCC of the watchdog function chip (3) is connected with a power supplyThe third pin GND is grounded, the fourth pin PFI is connected with the connection point of the resistors R1 and R2, the other end of the resistor R1 is grounded, and the other end of the resistor R2 is connected with a power supply; the program downloading interface (4) is characterized in that a first pin VCC is connected with a power supply, a second pin is connected with the power supply through a resistor R3, a third pin is grounded through a resistor R4, and a sixth pin is grounded through a resistor R5.
2. The control circuit of claim 1, wherein the one-chip watchdog is seamlessly compatible with the program downloading function, and the control circuit comprises: the watchdog function chip (3) adopts a MAX706R chip.
CN202022625851.9U 2020-11-13 2020-11-13 Control circuit for seamless compatibility of single-chip microcomputer watchdog and program downloading function Active CN213303013U (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202022625851.9U CN213303013U (en) 2020-11-13 2020-11-13 Control circuit for seamless compatibility of single-chip microcomputer watchdog and program downloading function

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202022625851.9U CN213303013U (en) 2020-11-13 2020-11-13 Control circuit for seamless compatibility of single-chip microcomputer watchdog and program downloading function

Publications (1)

Publication Number Publication Date
CN213303013U true CN213303013U (en) 2021-05-28

Family

ID=76016340

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202022625851.9U Active CN213303013U (en) 2020-11-13 2020-11-13 Control circuit for seamless compatibility of single-chip microcomputer watchdog and program downloading function

Country Status (1)

Country Link
CN (1) CN213303013U (en)

Similar Documents

Publication Publication Date Title
US8650332B2 (en) Method for switching working mode, USB device, and host device
CN102331959A (en) Server system
CN110569148A (en) system and method for realizing automatic restart recovery of dead halt of RK3399 mainboard
CN112099412B (en) Safety redundancy architecture of micro control unit
CN112306752A (en) Automatic power-down restart circuit and corresponding Internet of things gateway
CN213303013U (en) Control circuit for seamless compatibility of single-chip microcomputer watchdog and program downloading function
CN210348469U (en) Nested watchdog device
CN110750374A (en) Watchdog circuit and control method thereof
CN207571691U (en) Reset control system and sign acquisition equipment
CN100419693C (en) Computer system state monitoring circuit
CN110794804B (en) System, ECU, motor vehicle and method for flashing ECU
CN217606356U (en) Switching control circuit, mainboard and electronic equipment
CN108388481B (en) Intelligent watchdog circuit system of OLT equipment
CN113835510A (en) Power supply control method and system
CN109117348B (en) Method and system for controlling server UID LED indicator light
CN216817348U (en) Watchdog reset circuit and device
CN112925681A (en) Timing detection circuit of vehicle-mounted split type touch screen
CN214098364U (en) Reset circuit of single chip microcomputer
CN111382822A (en) Chip and method for manufacturing the same
CN211479102U (en) Automatic reset circuit of microprocessor
CN213462077U (en) Television box starting circuit, television system circuit and television system
CN203191966U (en) Watchdog control circuit
CN213690605U (en) Adapter for converting USB interface into SPI interface
CN211427328U (en) Watchdog circuit
CN220121165U (en) Control circuit, device and chip

Legal Events

Date Code Title Description
GR01 Patent grant
GR01 Patent grant