DE3604734A1 - Circuit to monitor the progress of a program in a microprocessor - Google Patents
Circuit to monitor the progress of a program in a microprocessorInfo
- Publication number
- DE3604734A1 DE3604734A1 DE19863604734 DE3604734A DE3604734A1 DE 3604734 A1 DE3604734 A1 DE 3604734A1 DE 19863604734 DE19863604734 DE 19863604734 DE 3604734 A DE3604734 A DE 3604734A DE 3604734 A1 DE3604734 A1 DE 3604734A1
- Authority
- DE
- Germany
- Prior art keywords
- transistor
- microprocessor
- voltage
- circuit according
- program
- 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.)
- Withdrawn
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/0703—Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
- G06F11/0751—Error or fault detection not based on redundancy
- G06F11/0754—Error or fault detection not based on redundancy by exceeding limits
- G06F11/0757—Error or fault detection not based on redundancy by exceeding limits by exceeding a time limit, i.e. time-out, e.g. watchdogs
Abstract
Description
Die Erfindung betrifft eine Schaltung zur Überwachung des Programmablaufs in einem Mikroprozessor, an dessen Ausgang bei jedem Programmdurchlauf mindestens ein Prüf signal abgegeben wird, wobei jedes Prüfsignal ein Zeit glied zurücksetzt, das nach Ablauf ein Rücksetzsignal an den Mikroprozessor abgibt, wobei die Laufzeit des Zeitglieds länger ist als der Abstand zwischen zwei Rücksetzimpulsen bei ungestörtem Programmablauf.The invention relates to a circuit for monitoring the program flow in a microprocessor, on the Output at least one test for each program run signal is given, each test signal a time member resets that a reset signal after expiration passes to the microprocessor, the term of the Timer is longer than the distance between two Reset pulses if the program runs undisturbed.
Eine derartige Schaltung ist aus der DE-OS 34 17 825 bekannt. Bei Geräten mit Mikroprozessoren kann es vor kommen, daß beispielsweise durch einen Störimpuls ein Programm unterbrochen, das heißt nicht ordnungsgemäß abgearbeitet wird. Unter Umständen blockiert sich dann der Mikroprozessor selbst, d.h. er erledigt überhaupt keine weiteren Aufgaben mehr. Um dies zu verhindern, ist eine Programmüberwachung zweckmäßig, die den Mikropro zessor, insbesondere dessen Programm-Counter, auf eine definierte Anfangsadresse zurücksetzt. Bei der bekannten Anordnung ist das Zeitglied mit einem Multivibrator oder mit einem Zähler aufgebaut.Such a circuit is from DE-OS 34 17 825 known. Devices with microprocessors can do this come that, for example, by a glitch Program interrupted, that is not properly is processed. Under certain circumstances then blocked the microprocessor itself, i.e. he does at all no more tasks. To prevent this from happening a program monitoring expedient that the Mikropro processor, especially its program counter, to a resets the defined start address. With the known Arrangement is the timer with a multivibrator or built with a counter.
Aufgabe der Erfindung ist es, die eingangs genannte Schaltung so auszuführen, daß sie mit weniger Bauelemen ten auskommt.The object of the invention is the one mentioned Circuit so that they with fewer components get along.
Diese Aufgabe wird erfindungsgemäß dadurch gelöst, daß das Zeitglied ein RC-Glied ist, das die Basis eines Transistors ansteuert, der den Mikroprozessor freigibt. This object is achieved in that the timing element is an RC element that forms the basis of an Drives transistor that releases the microprocessor.
Das Zeitglied kann damit mit besonders geringem Schaltungs aufwand realisiert werden. In einer vorteilhaften Ausfüh rungsform ist die Basis des Transistors über das RC-Glied in Reihenschaltung mit einer Spannungsquelle verbunden, wobei der Kondensator des RC-Glieds mit jedem Prüfsignal entladen wird.The timing element can thus with a particularly low circuit effort can be realized. In an advantageous embodiment The form of the transistor is based on the RC element connected in series with a voltage source, the capacitor of the RC element with each test signal is discharged.
Zweckmäßigerweise ist dabei dem Kondensator ein Tran sistor parallel geschaltet, dessen Basis über ein RC- Glied mit einem Ausgang des Mikroprozessors verbunden ist.A capacitor is expediently a tran sistor connected in parallel, the base of which is connected via an RC Link connected to an output of the microprocessor is.
In einer vorteilhaften Ausführungsform steuert eine systeminterne Taktspannung einen Transistor an, der im angesteuerten Zustand den Mikroprozessor zurücksetzt, wobei der vorher genannte Transistor bei Ansteuerung die Taktspannung kurzschließt. Damit wird der Mikro prozessor nach dem Rücksetzen periodisch wieder frei gegeben.In an advantageous embodiment, a system internal clock voltage to a transistor, which in controlled state resets the microprocessor, the aforementioned transistor when driven short-circuits the clock voltage. So that is the mic processor periodically released after the reset given.
Einen besonders geringen Schaltungsaufwand erreicht man, wenn die systeminterne Taktspannung eine aus der Netzspannung abgeleitete Rechteckspannung ist.A particularly low circuit effort is achieved one if the internal clock voltage is one of the Line voltage is derived from square wave voltage.
Der vorher genannte Transistor kann einen weiteren Tran sistor ansteuern, der über einen Widerstand an einer Versorgungsspannung liegt, wobei am Verbindungspunkt von Widerstand und Transistor ein Rücksetzsignal abgeleitet wird.The aforementioned transistor can be another Tran control sistor, which is connected to a resistor Supply voltage is at the connection point of Resistor and transistor derived a reset signal becomes.
Bei einer Schaltung, bei der aus einer ungeregelten Ver sorgungsspannung eine geregelte Versorgungsspannung abge leitet wird, kann der weitere Transistor über eine Schwellwertstufe durch die ungeregelte Versorgungspan nung angesteuert werden. Damit wird gleichzeitig sicher gestellt, daß der Mikroprozessor nur bei ausreichender Spannungsversorgung durch die geregelte Versorgungs spannung freigegeben wird.In a circuit in which an unregulated Ver supply voltage a regulated supply voltage conducts, the further transistor can Threshold value level due to the unregulated supply voltage can be controlled. This makes it safe at the same time asked that the microprocessor only with sufficient Power supply through the regulated supply voltage is released.
Ein Ausführungsbeispiel der Erfindung wird nachfolgend anhand der Fig. 1 und 2 näher erläutert.An embodiment of the invention is explained below with reference to FIGS. 1 and 2.
Fig. 1 zeigt die Schaltung eines Ausführungsbeispiels. Dabei wird aus einer Spannungsquelle U über ein RC-Glied 21, 22 eine ungeregelte Versorgungsspannung U 1 abgelei tet, aus der mit einem Regler 23 eine geregelte Versor gungsspannung U 2 für den Mikroprozessor 1 gebildet wird. Die Versorgungsspannung U 2 ist über die Reihenschaltung eines Kondensators 2 und eines Widerstands 14 mit der Basis eines Transistors 8 verbunden. Parallel zum Kon densator 2 ist die Reihenschaltung eines Transistors 3 und eines Widerstands 18 angeordnet. Die Basis des Tran sistors 3 wird von einem Anschluß P 1 des Mikroprozessors 1 über die Reihenschaltung eines Kondensators 4 und eines Widerstands 5 angesteuert. Zwischen Emitter und Basis des Transistors 3 liegt die Parallelschaltung eines Wi derstands 7 und einer Diode 6, deren Kathode am Emit teranschluß des Transistors 3 anliegt, falls dieser ein PNP-Transistor ist. Fig. 1 shows the circuit of an embodiment. In this case, an unregulated supply voltage U 1 is derived from a voltage source U via an RC element 21 , 22 , from which a regulated supply voltage U 2 for the microprocessor 1 is formed with a regulator 23 . The supply voltage U 2 is connected to the base of a transistor 8 via the series connection of a capacitor 2 and a resistor 14 . In parallel to the capacitor 2 , the series connection of a transistor 3 and a resistor 18 is arranged. The base of the transistor 3 is driven by a terminal P 1 of the microprocessor 1 via the series connection of a capacitor 4 and a resistor 5 . Between the emitter and the base of the transistor 3 is the parallel connection of a Wi resistor 7 and a diode 6 , the cathode of which is connected to the terminal 3 of the transistor 3 if this is a PNP transistor.
Ferner ist an die geregelte Versorgungsspannung U 2 die Reihenschaltung eines Widerstands 16 und eines Tran sistors 10 angeschlossen, deren Verbindungspunkt mit dem Rücksetzeingang R des Mikroprozessors 1 verbunden ist. Falls der Mikroprozessor 1 einen invertierenden Rücksetzeingang R aufweist, so ist an die geregelte Ver sorgungsspannung U 2 zusätzlich noch (in Fig. 1 gestri chelt angedeutet) die Reihenschaltung eines Widerstands 17 und eines Transistors 11 angeschlossen, wobei die Basis des Transistors 11 mit dem Verbindungspunkt von Widerstand 16 und Transistor 10 anliegt. In diesem Fall entfällt die Verbindung zum Rücksetzeingang R, dafür ist der Verbindungspunkt von Widerstand 17 und Transistor 11 mit dem invertierenden Rücksetzeingang R verbunden.Furthermore, the series connection of a resistor 16 and a transistor 10 is connected to the regulated supply voltage U 2, the connection point of which is connected to the reset input R of the microprocessor 1 . If the microprocessor 1 has an inverting reset input R , the series connection of a resistor 17 and a transistor 11 is also connected to the regulated supply voltage U 2 (indicated by dashed lines in FIG. 1), the base of the transistor 11 being connected to the connection point of resistor 16 and transistor 10 is present. In this case, the connection to the reset input R is omitted, but the connection point of resistor 17 and transistor 11 is connected to the inverting reset input R.
Zwischen Basis und Emitter des Transistors 10 ist die Kollektor-Emitter-Strecke eines Transistors 9 angeordnet, dessen Basis über einen Widerstand 24 mit einer Takt spannung UT beaufschlagt ist. Die Taktspannung UT kann beispielsweise eine aus der Netzspannung abgeleitete 50 Hz-Rechteckspannung sein. Zwischen Basis und Emitter des Transistors 9 ist die Kollektor-Emitter-Strecke des bereits erwähnten Transistors 8 angeordnet.Between the base and emitter of transistor 10 , the collector-emitter path of a transistor 9 is arranged, the base of which is supplied with a clock voltage UT via a resistor 24 . The clock voltage UT can be, for example, a 50 Hz square-wave voltage derived from the mains voltage. The collector-emitter path of the transistor 8 already mentioned is arranged between the base and emitter of the transistor 9 .
An die ungeregelte Versorgungsspannung U 1 ist die Reihen schaltung einer Z-Diode 19 und eines Widerstands 20 ange schlossen. Der Verbindungspunkt dieser Elemente ist über einen Widerstand 12 an die Basis des Transistors 10 und über einen Widerstand 13 an die Basis des Transistors 8 angeschlossen. Der Basis-Emitter-Strecke des Transistors 10 ist ein Kondensator 15 parallel geschaltet.At the unregulated supply voltage U 1 , the series circuit of a Zener diode 19 and a resistor 20 is connected. The connection point of these elements is connected via a resistor 12 to the base of transistor 10 and via a resistor 13 to the base of transistor 8 . A capacitor 15 is connected in parallel to the base-emitter path of transistor 10 .
Die Funktion der Schaltung, die gleichzeitig als Versor gungsspannungsüberwachung wirkt, wird nachfolgend anhand des Diagramms nach Fig. 2 erläutert. Fig. 2 zeigt den zeitlichen Verlauf der ungeregelten Versorgungsspannung U 1 und der geregelten Versorgungsspannung U 2 beim Ein- und Ausschalten der Versorgungsspannung U. Beim Einschal ten wird der Ladekondensator 22 aufgeladen. Um Fehler zu vermeiden darf der Programmablauf des Mikroprozessors erst freigegeben werden, wenn der Mikroprozessor ausrei chende Zeit an Spannung liegt. Vor der Freigabe muß näm lich der interne Oszillator anspringen, die internen Ver sorgungsspannungen müssen aufgebaut und verschiedene Spei cher gesetzt werden. Bei der Schaltung nach Fig. 1 wird der Mikroprozessor 1 erst freigegeben, wenn zum Zeitpunkt t 2 die ungeregelte Versorgungsspannung U 1 die Zenerspann ung U z überschreitet und nach Ablauf der Zeitspanne Δt2 die Spannung am Kondensator 15 die Schaltschwelle des Transistors 10 erreicht. Zum Freigabezeitpunkt, der in Fig. 2 mit t 3 bezeichnet ist, springt die dargestell te Spannung UR am invertierenden Rücksetzeingang R auf 1, da der Transistor 10 leitend und somit der Transistor 11 gesperrt wird. Falls der Mikroprozessor 1 einen nicht invertierenden Rücksetzeingang R aufweist, springt die in Fig. 2 nicht dargestelle Spannung U R am Rücksetzein gang R zum Zeitpunkt t 3 auf "0".The function of the circuit, which also acts as supply voltage monitoring, is explained below with reference to the diagram in FIG. 2. Fig. 2 shows the time course of the unregulated supply voltage U 1 and the regulated supply voltage U 2 during connection and disconnection of the supply voltage U. When switched on, the charging capacitor 22 is charged. In order to avoid errors, the program execution of the microprocessor may only be released if the microprocessor is live for a sufficient period of time. Before the release, the internal oscillator has to start, the internal supply voltages have to be built up and various memories have to be set. In the circuit of Fig. 1, the microprocessor 1 will not be released until the time t 2, the unregulated supply voltage U 1 exceeds Zenerspann ung U z and after the time interval Δ, the tension t 2 the capacitor 15, the switching threshold of the transistor 10 is reached. At the time of release, which is designated in FIG. 2 with t 3 , the voltage UR shown at the inverting reset input R jumps to 1, since the transistor 10 is conductive and thus the transistor 11 is blocked. If the microprocessor 1 has a non-inverting reset input R , the voltage U R not shown in FIG. 2 at the reset input R jumps to "0" at time t 3 .
Beim Einschalten wird der Mikroprozessor also erst dann freigegeben, wenn die geregelte Spannung U 2 bereits einen stabilen Wert erreicht hat.When switched on, the microprocessor is only released when the regulated voltage U 2 has already reached a stable value.
Beim Abschalten der Spannungsversorgung wird das Reset signal bereits dann gegeben, wenn zum Zeitpunkt t 4 die ungeregelte Spannung U 1 die Zenerspannung U z der Z-Diode 19 unterschreitet. Bis zum Zeitpunkt t 5, wo auch die geregelte Spannung U 2 absinkt, kann der Mikroprozessor noch den letzten Befehl vollständig abarbeiten.When the voltage supply is switched off, the reset signal is already given when the unregulated voltage U 1 falls below the Zener voltage U z of the Zener diode 19 at the instant t 4 . Up to time t 5 , when the regulated voltage U 2 also drops, the microprocessor can still process the last command completely.
Im folgenden wird nun die Überwachung des Programmab laufs erläutert. Bei jedem Programmdurchlauf gibt der Mikroprozessor mindestens einmal ein Prüfsignal am Aus gang P 1 ab. Der Kondensator 4 differenziert das Signal, wobei die Diode 6 die positive Spitze kurzschließt. Die negative Spitze steuert den Transistor 3 durch, so daß der Kondensator 2 über den Widerstand 18 und den Tran sistor 3 entladen wird. Gleichzeitig wird über den Wider stand 14 auch der Transistor 8 durchgeschaltet. Durch den nachfolgend über den Kondensator 2 fließenden Lade strom bleibt der Transistor 8 für eine begrenzte Über wachungszeit durchgesteuert. Diese Überwachungszeit ist so bemessen, daß sie länger als der Abstand zwischen zwei Prüfsignalen ist, so daß im Normalbetrieb der Tran sistor 8 stets durchgesteuert bleibt. Damit wird die Taktspannung U T kurzgeschlossen, der Transistor 9 bleibt gesperrt und der Transistor 10 wird über die Z-Diode 19 und den Widerstand 12 angesteuert. Damit bleibt das Rücksetzsignal UR "0", während ein evtuelles invertier tes Rücksetzsignal UR "1" bleiben würde.The monitoring of the program sequence is now explained below. With each program run, the microprocessor emits a test signal at the output P 1 at least once. The capacitor 4 differentiates the signal, the diode 6 short-circuiting the positive tip. The negative peak controls the transistor 3 , so that the capacitor 2 is discharged through the resistor 18 and the transistor 3 . At the same time, the transistor 8 was also connected through the counter 14 . Due to the charging current flowing through the capacitor 2 , the transistor 8 remains on for a limited monitoring time. This monitoring time is dimensioned such that it is longer than the distance between two test signals, so that the transistor 8 is always activated in normal operation. The clock voltage U T is thus short-circuited, the transistor 9 remains blocked and the transistor 10 is controlled via the Zener diode 19 and the resistor 12 . Thus, the reset signal UR remains "0", while a possible inverted reset signal UR would remain "1".
Wenn durch eine Störung des Programmablaufs am Ausgang P 1 keine Prüfsignale mehr erscheinen, lädt sich der Kondensator 2 auf die volle Versorgungsspannung U 2 auf und es kann kein Ladestrom mehr fließen, so daß der Transistor 8 sperrt. Damit wird die Taktspannung UT nicht mehr kurzgeschlossen, sondern über den bei einem 50 Hz-Takt ca. 10 ms langen "1"-Impuls der Transistor 8 durchgesteuert und damit über die Transistoren 9 und 10 sowie evtl. 11 für diese Zeit ein Rücksetzsignal gegeben. In den folgenden 10 ms, in denen am Transistor 9 ein "0"-Signal anliegt, wird das Rücksetzsignal wieder aufge hoben. Während dieser Zeit kann der Mikroprozessor 1 neu starten. Wenn nunmehr ein ungestörter Programmablauf stattfindet, erscheinen am Ausgang P 1 wieder Prüfsignale, so daß der Kondensator 2 wieder entladen wird. Damit wird der Transistor 8 wieder leitend und die Taktspan nung UT kurzgeschlossen, so daß kein Rücksetzsignal auf tritt. Bleibt der Programmablauf jedoch gestört, so er folgt während der Störung periodisch ein Wechsel zwischen Rücksetzsignal und Neustart. Dabei hat das Rücksetzsignal über das Abschalten der Spannungsversorgung über die Transistoren 10 und gegebenenfalls 11 Vorrang.If no more test signals appear at the output P 1 due to a disturbance in the program sequence, the capacitor 2 charges up to the full supply voltage U 2 and a charging current can no longer flow, so that the transistor 8 blocks. Thus, the clock voltage UT is no longer short-circuited, but ms long on the case of a 50 Hz clock 10 by controlled "1" pulse of the transistor 8 and hence through transistors 9 and 10 and possibly 11 if a reset signal for this time . In the following 10 ms, in which a "0" signal is present at transistor 9 , the reset signal is canceled again. During this time, the microprocessor 1 can restart. If an undisturbed program sequence now takes place, test signals appear again at the output P 1 , so that the capacitor 2 is discharged again. So that the transistor 8 is again conductive and the clock voltage UT short-circuited, so that no reset signal occurs. However, if the program flow remains disrupted, it periodically changes between reset signal and restart during the malfunction. The reset signal has priority over switching off the voltage supply via the transistors 10 and 11 if necessary.
Claims (7)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
DE19863604734 DE3604734A1 (en) | 1986-02-14 | 1986-02-14 | Circuit to monitor the progress of a program in a microprocessor |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
DE19863604734 DE3604734A1 (en) | 1986-02-14 | 1986-02-14 | Circuit to monitor the progress of a program in a microprocessor |
Publications (1)
Publication Number | Publication Date |
---|---|
DE3604734A1 true DE3604734A1 (en) | 1987-08-20 |
Family
ID=6294120
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
DE19863604734 Withdrawn DE3604734A1 (en) | 1986-02-14 | 1986-02-14 | Circuit to monitor the progress of a program in a microprocessor |
Country Status (1)
Country | Link |
---|---|
DE (1) | DE3604734A1 (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP0467719A2 (en) * | 1990-07-20 | 1992-01-22 | Honeywell Inc. | Integrated low voltage detect and watchdog circuit |
DE4138015A1 (en) * | 1991-11-19 | 1993-05-27 | Ako Werke Gmbh & Co | Watchdog circuit for microcomputer programme execution - has synchronising circuit generating square wave input and detector circuit monitoring output during pulse period |
DE19731086A1 (en) * | 1997-07-19 | 1999-01-28 | Satronic Ag | Electronic safety circuit |
-
1986
- 1986-02-14 DE DE19863604734 patent/DE3604734A1/en not_active Withdrawn
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
EP0467719A2 (en) * | 1990-07-20 | 1992-01-22 | Honeywell Inc. | Integrated low voltage detect and watchdog circuit |
EP0467719A3 (en) * | 1990-07-20 | 1993-01-27 | Honeywell Inc. | Integrated low voltage detect and watchdog circuit |
DE4138015A1 (en) * | 1991-11-19 | 1993-05-27 | Ako Werke Gmbh & Co | Watchdog circuit for microcomputer programme execution - has synchronising circuit generating square wave input and detector circuit monitoring output during pulse period |
DE19731086A1 (en) * | 1997-07-19 | 1999-01-28 | Satronic Ag | Electronic safety circuit |
DE19731086C2 (en) * | 1997-07-19 | 2001-09-13 | Satronic Ag Dielsdorf | Electronic safety circuit |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
DE3340008A1 (en) | POWER SUPPLY CIRCUIT FOR A CONTROL UNIT | |
EP1148623A2 (en) | Power supply device | |
EP0284606B2 (en) | Device for resetting computer equipment | |
DE3322242A1 (en) | DEVICE FOR FUNCTION MONITORING OF ELECTRONIC DEVICES, IN PARTICULAR MICROPROCESSORS | |
EP0143313B1 (en) | Safety device for an electronically, microcomputer-controlled combustion engine | |
DE3240706C2 (en) | ||
DE3604734A1 (en) | Circuit to monitor the progress of a program in a microprocessor | |
DE3214006A1 (en) | DEVICE FOR RESETTING CALCULATIONS | |
EP0026869A1 (en) | Device for the surveillance of the maintenance of an installation | |
DE3240707A1 (en) | Circuit arrangement for monitoring electronic computing chips | |
DE3130307C2 (en) | ||
DE3026787A1 (en) | INTRINSICALLY SAFE FLAME GUARD | |
DE2064350A1 (en) | Monitoring device for signal-controlled steering devices | |
DE3300222A1 (en) | System and device for resetting a circuit containing a microprocessor | |
DE4023700C2 (en) | Circuit arrangement for monitoring the frequency of a signal sequence of an electronic device, in particular a microcomputer | |
DE3527619C1 (en) | Self-testing proximity switch | |
DE3240704A1 (en) | Circuit arrangement for monitoring electronic computer chips | |
EP0023695B1 (en) | Surveillance circuitry for an input voltage | |
CH646289A5 (en) | CIRCUIT TO RELEASE A MICRO PROCESSOR. | |
DE2356021C3 (en) | Triggerable sawtooth generator with controllable trigger blocking phase | |
WO2010108899A1 (en) | Dc voltage transformer for a motor vehicle | |
EP0254875B1 (en) | Circuit arrangement for the supply of current to electronic devices | |
DE3020300A1 (en) | TRANSISTOR SWITCH WITH OVERCURRENT PROTECTION AND AUTOMATIC RESET | |
DE3332383C2 (en) | ||
DE2715681C2 (en) | Protection circuit for a self-regulating horizontal deflection circuit for cathode ray tubes |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
8139 | Disposal/non-payment of the annual fee |