Abstract:
A method and apparatus allows fault recovery in a digital computer based control system whereby system upsets induced by external transient noise conditions can be accommodated. A CPU is coupled to its main memory and its I/O interfaces by a common address/data bus, these three elements being susceptible to having data thereon or therein corrupted by transient noise. Also coupled to the bus, but in a hardened environment, are first and second supplemental memories which, under memory control, operate on alternating even and odd computational frames defined by the CPU&#39;s real-time clock to store the same words as are then being entered into the CPU&#39;s main memory. As computational frames are entered into one or the other of these two memories by eaves-dropping on the common bus, the other supplemental memory is transferring its contents to a backup memory which is also housed in the noise-immune environment. The backup memory is connected in a read-only mode to the address/data bus and, because of the manner of operation, always contains the computational frame that is delayed one cycle of the CPU&#39;s real-time clock from the frame in progress. Should a transient upset occur, it may be followed by a transfer of the information from the backup memory into the computer&#39;s main memory such that computations can then continue with data that is uncorrupted.

Description:
BACKGROUND OF THE INVENTION 
     I. Field of the Invention 
     This invention relates generally to a method and apparatus for increasing the reliability of digital computing systems, and more particularly to an improved error recovery technique in complex digital computer based control systems. 
     II. Discussion of the Prior Art 
     As the reliability and performance of digital computers have steadily improved, they have become the predominant technology for control systems. For example, in avionics systems, digital computers are now considered for such concepts as fly-by-wire or autoland in which a digital computer is interposed between the pilot and the aircraft control surfaces. In such systems, the safety of the aircraft depends on continued faultless performance of the digital control system. 
     To achieve the requisite reliability in such applications, prior art systems have typically resorted to hardware redundancy with majority voting. Typically, a minimum of three identical processing elements are configured to perform identical control computations on identical data inputs. In the event a disparity occurs between the multiple processing elements, the minority result(s) is ignored and one of the majority results is used to effect the control function. A majority-of-three voting allows the system to tolerate a single failure while majority-of-five allows the system to tolerate up to two failures. In more elaborate systems, a persistently failing unit may be voted out of the system and replaced with a so-called &#34;hot spare&#34;. 
     Various forms of redundancy synchronization, voting and fault monitoring have been proposed or employed in the past. However, while it is recognized that these mechanisms influence the type of recovery technique a particular system may employ, this invention addresses only a manner of recovery and not these other mechanisms. 
     A fault condition may be induced by a permanent failure of the digital circuitry, in which case it is considered a &#34;hard fault&#34;. Alternatively, it may be induced by a transient phenomena which results in an incorrect result, but does not, in fact, damage or alter the subsequent operation of the circuitry. This condition is classified as a &#34;soft fault&#34; or &#34;soft error&#34;. Soft errors may be induced by various transient conditions, such as electromagnetic interference (EMI), inherent noise, lightning, electromagnetic pulses (EMP), or high energy radio frequency (HERF). In this specification, the term &#34;external transient noise condition&#34; is intended to include all of the above sources. 
     As newer digital technology is introduced, the trend seems to be that the amount of energy necessary to change the state of a memory element or a logic element is reduced, thereby making these elements more susceptible to upset due to EMI, lightning, EMP, or HERF. With careful design, the susceptibility of the control system circuitry to such transient conditions can be greatly reduced. However, it is generally not practical to harden the entire control system to the extremes of any and all interference which may be encountered in an avionics application. It is, therefore, important that safety-critical digital control systems be able to tolerate transient upsets without affecting the performance of the critical application. 
     Recognizing that transient upsets will occur in certain applications, it is highly desirable to provide an error recovery mechanism whereby a processing element can be restored to a functional condition following a soft error. With an error recovery mechanism, the hardware redundancy can be reserved to cover only the hard error conditions, thereby increasing the overall system reliability. The error recovery mechanism further provides a clear diagnostic distinction between soft and hard errors and, therefore, practically eliminates the incidences of unconfirmed removal whereby a functionally good processing element is falsely suspected of being faulty due to upsets. 
     One well-known method of effecting soft error recovery is to design the control algorithm around a computational frame where the time interval of the computational frame generally corresponds to the sampling interval of the control system. When a soft error is detected, the computer is reset to a known state corresponding to the beginning of the current computational frame and the control algorithm is restarted. Soft error recovery in a majority-voting redundant system imposes yet another constraint. The faulty computing element must not only be rolled back to the beginning of the computational frame, but must also be restarted in synchrony with the other computing elements. While it is recognized that the relationships between the redundancy elements within a system impact the operation of the system, this invention defines a method of fault recovery and does not address redundancy management concerns. 
     Prior art redundant digital systems have provided recovery from transient disturbances to the digital circuitry with a &#34;transfusion&#34; of data. Following the detection of a digital circuit upset, &#34;transfused&#34; data is transmitted from the unaffected redundant digital circuits to the upset digital circuits in order to restore the upset circuitry to the identical state as the unaffected circuits. For example, in a system comprised of three digital processing lanes, if one lane is determined to be faulty by the voting logic, it is isolated. The remaining two lanes then transmit the current state variables necessary to complete the recovery. The isolated lane then resumes processing in synchrony with the active lanes and is readmitted to the system after performing a given number of computation frames without another detected fault. It is possible that a single transient disturbance might cause an upset in each of the redundant processing elements. In this instance, the redundancy is defeated and the system crashes, since there is no source of valid data available for transfusion. 
     A further limitation of prior art approaches is that the software required to perform the data transfusion, in the event of a fault, is specific to both the application being performed and the level of redundancy and the redundant architecture employed in the system. 
     It is highly desirable, and in some instances imperative, that fault-tolerant techniques such as soft-error recovery be totally transparent to the software and independent of the context of the control application. 
     OBJECTS OF THE INVENTION 
     It is an object of the invention to provide a soft error recovery mechanism by which a single processing element can be restored to a functional state without interaction between any other redundant processing elements. 
     It is another object of the invention to provide a soft error recovery mechanism which is transparent to the operational software. 
     It is a further object of the invention to provide a soft error recovery mechanism which is applicable to a wide range of fault tolerate architectures. 
     It is yet a further object of the invention to provide a soft fault error recovery mechanism which will enable a redundant digital system to operate without error, even in the event of a transient disturbance which causes simultaneous upsets in each of the redundant processing elements. 
     SUMMARY OF THE INVENTION 
     The foregoing objects and advantages are achieved by providing a real-time control system having a central processing unit (CPU) having an address/data bus coupling it to a main random access memory and I/O devices also coupled to the bus. Also associated with the bus is soft error recovery circuitry which is effectively shielded and protected from upset due to external transient noise sources. This latter soft error recovery circuitry includes a first, &#34;even&#34; supplemental RAM, a second, &#34;odd&#34; supplemental RAM, a backup RAM and the memory control circuits for operating same. 
     During each computational frame in which data words are written into the main RAM, they are simultaneously copied from the address/data bus into either the first or the second supplemental RAM on an alternating basis. Because of the manner in which the memory control toggles the first and second supplemental RAMs back and forth, one is made to contain memory elements which have been updated in the current computational frame while the other contains memory elements which were updated in the immediately preceding computational frame. While main memory entries are being entered into one or the other of the first and second supplemental RAMs, the contents of the other supplemental RAM, which were updated in the previous frame, are transferred into the backup RAM. Should an external transient disturbance or upset occur which might impact the address/data bus, the CPU or the main RAM, recovery is achieved by transferring the contents of the backup RAM into the main RAM so as to effectively place the system in the same operating mode as it existed at the beginning of the computational frame in which the transient upset occurred. 
    
    
     DESCRIPTION OF THE DRAWINGS 
     The foregoing objects, advantages as well as the principles of operation of the present invention will become apparent to those skilled in the art from the following detailed description of the preferred embodiment, especially when considered in conjunction with the accompanying drawings in which: 
     FIG. 1 is a general block diagram of the fault recovery mechanism in accordance with the present invention; 
     FIG. 2 is a general block diagram showing the interconnections of the error recovery circuit during even computational frames; 
     FIG. 3 is a general block diagram showing the interconnections of the error recovery circuit during odd computational frames; 
     FIG. 4 is a more detailed block diagram of the interconnections between the various memory modules in accordance with a first embodiment of the invention; 
     FIG. 5 shows the portions of the block diagram of FIG. 4 active during even computational frames; 
     FIG. 6 is a detailed block diagram showing the system configuration during odd computational frames; 
     FIG. 7 is a detailed block diagram of the error recovery system comprising an alternative embodiment in which FIFO memories are utilized; 
     FIG. 8 is a block diagram showing the active portions of the embodiment of FIG. 6 during even computational frames; and 
     FIG. 9 is a block diagram similar to that of FIG. 8, but during odd computational frames. 
    
    
     DESCRIPTION OF THE PREFERRED EMBODIMENT 
     FIG. 1 shows a block diagram of a processing element employing the novel soft error recovery mechanism. This processing element could be used as a unit processor or as one of a number of processing elements in a redundant system. Central processing unit (CPU) 10 executes a stored program contained in program read-only memory (ROM) 12 to perform the real-time control algorithm. Inputs from sensors in the control system (not shown) are sampled on input lines 14, via I/O circuitry 16, and control actions for the system are effected, via outputs 18 and I/O circuitry 16. Operand storage is provided by scratchpad random access memory (RAM) 20 which may be considered as the CPU&#39;s main memory. Data is transferred between the CPU, ROM, RAM and I/O via address/data bus 22. Control signals required to execute a read or a write cycle on the main RAM memory 20 are provided by memory control circuit 24. 
     The circuitry described thus far comprises a conventional digital processing system, including such systems used, say, for avionics control applications. To this conventional arrangement is added the soft error recovery circuitry shown enclosed by broken line box 26. This circuitry should be hardened to possible noise sources, such as EMI, lightning, EMP and HERF, to assure that in the worst case, no transient disturbance will cause an upset in any part of that circuit. Where as it would generally be impractical to harden the entire control system to this level, it is practical to harden the relatively small amount of circuitry implementing the soft error recovery hardware 26 in that the volume and power required for this circuitry is a relatively small fraction of the total volume and power required for the processing element. EMI hardening techniques are well understood in the art and would include, at a minimum, extensive shielding and conditioning of all input and output lines, e.g., by the use of opto-isolators 28 or the like to eliminate conducted interference. 
     The soft error recovery approach of this invention requires that all variables which define the state of the digital function be stored in scratchpad RAM 20. Each of these variables must be written into scratchpad RAM 20 during the same computational frame that is updated. Soft error recovery is, thus, the restoration of the contents of scratchpad RAM 20 to the state that existed at the beginning of the computational frame in which a fault or upset is detected. Soft error recovery circuitry 26 restores scratchpad RAM 20 in the event of a fault by copying the contents of a backup RAM 30 to scratchpad RAM 20. Backup RAM 30 operates so as to maintain a valid copy of scratchpad RAM 20, but delayed one frame, for later rollback to the beginning of the present computational frame. It is maintained in this state by eaves-dropping by the supplemental RAMs on address/data bus 22 and control lines 32 to capture the address and the data of each write into RAM 20 during a given computational frame. Data transfers from the address/data bus 22 to a first supplemental memory referred to as &#34;even memory&#34; 34 and a second supplemental memory referred to as &#34;odd memory&#34; 36 and backup RAM 30 are managed by the memory control circuitry 38 to assure that backup RAM 30 is continuously updated in a manner that assures that it is always ready for a rollback. 
     To better understand the data recording techniques carried out in the implementation of the present invention, reference is made to FIGS. 2 and 3 which respectively show the manner in which the even and odd RAM memories 34 and 36 become coupled to the address/data bus 22 at successive times established by the CPU&#39;s real-time clock. With reference to FIG. 2, it can be seen that during even computational frames, any writes which occur to the main memory (scratchpad RAM 20) are simultaneously entered into the even supplemental RAM 34. An update log 40 is associated with the even RAM 34 and comprises an n-word memory one bit wide. It is therefore capable of storing a flag or update bit in a bit position (address) corresponding to those words which are altered in the main memory 20 by a write operation during the even computational frames. 
     In a similar fashion, as illustrated in FIG. 3, during odd computational frames, the odd supplemental memory 36 is written into in parallel with entries made in the main RAM 20, with the write occurrence being recorded in an odd update log 42. 
     With continued reference to FIG. 2, it is also evident that during an even frame when the even supplemental memory 34 is being updated during writes into the main memory 20, any data in the odd supplemental memory 36 which was updated during the previous computational frame, i.e., an odd frame, as indicated by the contents of the odd update log 42 is transferred into the backup RAM 30. In like fashion, and as illustrated by FIG. 3, during an odd computational frame, while the odd supplemental memory 36 is being updated during writes into the main memory 20, any data in the even supplemental memory 34 which was updated during the previous computational frame, i.e., an even frame, as indicated by the contents of the even update log 40 is transferred into the backup RAM 30. It can be seen, then, that the backup RAM 30 will always contain an identical copy of the main memory 20, but delayed by one computational frame, i.e., one real-time clock frame interval of the CPU. 
     While the general block diagrams of FIGS. 1 through 3 are deemed helpful in understanding the underlying principles of the soft error recovery system of the present invention, a better understanding of the overall organization can be obtained from consideration of the more detailed block diagrams of FIGS. 4 through 6. FIG. 4 illustrates the memory and bus configuration when the system is implemented with RAMs. The conventional microprocessor (not shown) has associated with it an address bus 44 and a data bus 46 which is m-bits wide. A main or scratchpad memory 20 receives its address inputs from the address bus 44 and its data inputs from the data bus 46. Also shown connected to the address bus and the data bus is the backup RAM 30 which too is an n-word by m-bit wide memory. The symbol 48 in FIG. 4 is intended to indicate that the bus in question is bidirectional. 
     So that the even RAM 34 and the odd RAM 36 can eavesdrop on what is being entered into the scratchpad RAM 20, each has its respective address inputs coupled to the address bus via the lines in cables 50 and 52. Similarly, data may be transferred into the supplemental RAMs 34 and 36 over the bidirectional buses 54 and 56. 
     For controlling data transfers from the even and odd supplemental memories to the backup RAM 30, latches 58 and 60 are included in the data lines joining the output of the supplemental RAMs to the input of the backup RAM. 
     The memory control 38 is capable of sensing the occurrence of writes into the scratchpad RAM 20 and injects, via lines 62 and 64, a one-bit into the update logs 40 and 42 at the same address as the word being written has on even and odd computational frames. Memory control 38 also provides inputs to the backup RAM, and each of the even and odd supplemental RAMs as well as their associated update logs. 
     The data recording which takes place during a &#34;even&#34; computational frame is shown in FIG. 5. To facilitate the understanding, the buses which are inactive during the even computational frame are not shown. The memory control 38 monitors all accesses to the main memory 20 and during a write access, the memory control causes an identical write to occur in parallel in the even RAM 34. At this same time, the memory control writes a &#34;1&#34; into the even update log 40 at the same address that the write took place in its associated supplemental RAM. It is to be noted that the update log contains all &#34;0s&#34; at the beginning of each computational frame. In this manner, all words written into the main memory 20 are duplicated in the even supplemental RAM 34 with the associated memory address in the even update log 40 being toggled to a &#34;1&#34;, which is a flag bit signifying the presence of updated data in the even supplemental RAM 34 at the corresponding addresses. 
     During this same &#34;even&#34; computational frame, the main memory data which had been updated in the previous &#34;odd&#34; frame is transferred from the odd supplemental RAM 36 to the backup RAM 30 under control of memory control 38. The transfer operation is automatic and will continue to completion. That is, it will not be suspended by the detection of a processing system disruption. 
     During the &#34;even&#34; computational frame, as determined by the toggling of the real-time clock, the memory control 38 polls every address of the odd update log 42. While the memory control asserts a given address (n), it reads the odd update log bit and latches the data from the odd supplemental RAM into latch 60. If the odd update log bit is a &#34;1&#34;, as perceived by the memory control 38, the data from the latch is written to the backup RAM 30 and the memory control writes a &#34;0&#34; to the odd update log to clear the flag bit at address n. This process continues until all of the addresses in the odd update log have been polled. 
     FIG. 6 is illustrative of the data recording which takes place during an &#34;odd&#34; computational frame. Again, inactive buses are not shown. The memory control 38 records odd frame data and transfers even frame data as earlier described. Combination of memories 34 and 36 assures that for each computational frame, backup memory 30 is provided with a valid set of update data to bring it to the correct state corresponding to the next computational frame. This is because the transfer to backup memory 30 does not begin until a complete set of error-free data has been accumulated in supplemental RAMs 34 or 36, and once accumulated, the data is protected from upset until the transfer to backup memory 30 is completed. 
     ALTERNATIVE EMBODIMENT 
     Where the CPU&#39;s real-time clock establishes relatively long frame times, e.g., 100 ms or longer, the system of the present invention may well be implemented using RAM memories throughout. For systems with relatively moderate to short real-time clock computational frame times, e.g., less than 100 ms, it is found expedient to utilize FIFO memories for the even supplemental memory and the odd supplemental memory. The main memory and the backup memory would remain as conventional random access memories each n-words by m-width. The even and odd update logs are implemented by the address FIFOs. 
     Illustrated in FIG. 7 is the memory and bus configuration of the error recovery system in accordance with the present invention, but using such FIFO memories. Specifically, the even and odd supplemental memories 62 and 64 and the update logs 66 and 68 associated therewith are FIFO memories. Four FIFOs are required: Two for &#34;even&#34; frames and two for &#34;odd&#34; frames. One FIFO is used to store the address and one is used to store the data when an update occurs to the main memory 20. 
     For a main memory of a size nxm (n-words of m-width), the even and odd data FIFOs 62 and 64 are of width m; the depths of the FIFOs being dependent on the amount of main memory activity expected during a computational frame. The even and odd address FIFOs are the same width as the address bus and are the same depth as the data FIFOs. The backup memory 30 is again a RAM of size nxm. 
     As with the earlier embodiment, the main memory 20 is tied to the address bus 44 and the data bus 46 as are the even and odd data FIFOs 62 and 64 and the even and odd address FIFOs 66 and 68. The backup RAM 30 also receives address inputs from the bus 44 and data inputs from the bus 46 as indicated by the symbol 70, the data bus coupling the backup RAM to the system bus 46 is bidirectional in nature. 
     The data recording which takes place during an &#34;even&#34; computational frame is shown in the block diagram of FIG. 8. Again, for ease in understanding, inactive buses are purposely omitted. As before, the memory control monitors accesses to the main memory 20. During a write access to the main memory, control 38 causes data and the address resident on the buses to be stored in the even FIFOs 62 and 66, respectively. 
     During the &#34;even&#34; computational frame, main memory RAM data which had been updated in the previous &#34;odd&#34; frame is transferred from the odd FIFO 64 to the backup RAM 30 under control of the memory control 38. The transfer operation is automatic and will continue to completion, i.e., it will not be suspended by the detection of a processing system disruption. 
     In much the same fashion, during an &#34;even&#34; computational frame, the memory control 38 performs a succession of read operations on the odd FIFOs. During each read operation, the FIFOs place the address and data of a main memory write access which had occurred during the previous &#34;odd&#34; computational frame. Memory control 38 writes this data to the backup RAM 30, at the given address supplied by FIFO 68. This process continues until the odd FIFOs are empty. 
     The data recording which takes place an &#34;odd&#34; computational frame is shown in FIG. 9. Again, inactive buses are not shown. The memory control 38 here records odd frame data and transfers even frame data as previously described in connection with the discussion of FIG. 7. 
     Irrespective of which embodiment is employed, when a disturbance to digital computation occurs, it must be detected by the digital system monitors 1 (FIG. 1). The recovery mechanism of the present invention requires that the fault be detected in the same computational frame that it occurs. While the technique of this invention requires immediate detection of any faulty conditions in the digital circuit, it is the manner of recovery, and not the detection mechanism or the EMI protection mechanism that is involved. 
     The system monitors notify memory control 38 of the occurrence of an upset. The memory control logic then suspends operation of the automatic data recording function. However, the data transfer function to the backup RAM must continue unabated until complete. The bus switches are maintained in their current state. During the disturbance, the main memory and the associated even or odd supplemental memory currently being written into in parallel are assumed to be overwritten by the faulty data. Memory control 38 prevents spurious writes from occurring to the remaining even or odd supplemental memories which is currently downloading data to the backup RAM. 
     Because the backup RAM 30 is not written to from the external interface, this RAM is robust to EMI conditions. However, it is imperative that the disturbance be detected and the memory control be notified during the same computational frame as the upset occurrence. 
     Following the disturbance to the digital system, the data in the main memory has been corrupted. However, it is still intact in the backup RAM, one frame delayed. This data may now be transferred to the main memory 20, via a read-only transfer from the backup memory over the address/data bus 22 (FIG. 1). During this time, the backup memory is protected from spurious write operations. If a second disturbance should occur during the data recovery sequence, it can be restarted. Once the main memory state has been restored to its non-faulty contents, the CPU can resume computations based upon these correct variables. 
     The data restoration function is identical for the two embodiments heretofore described. Following the upset of the system and the restart of the CPU, the software determines that upset had occurred by polling the backup memory status. Following this determination, the software performs a data transfer of the contents of the backup RAM to the main memory. When this transfer is complete, the system software then restarts the control function of the digital system and resumes processing while the data recording function of the recovery mechanism described continues to operate. 
     This invention has been described herein in considerable detail in order to comply with the Patent Statutes and to provide those skilled in the art with the information needed to apply the novel principles and to construct and use such specialized components as are required. However, it is to be understood that the invention can be carried out by specifically different equipment and devices, and that various modifications, both as to equipment details and operating procedures, can be accomplished without departing from the scope of the invention itself.