Interface for connecting a computer system to an activator module
This invention is concerned with an interface that connects a computer module to an activator that needs to be driven by electrical power supplied by means of a power circuit, the activating and de-activating switch of which is controlled by said computer module. 
     It is well known, for example, that in the case of control systems for railroad switches, for security reasons the activator of the switch is only powered up when certain specific conditions have been met. Each of these conditions is usually defined by the electrical state of a relay. When a relay is turned on, for example, it will initiate the opening or closing of a contact mounted in the power circuit of the electric motor that drives the activator. 
     These systems that are based on the use of relays present certain inefficiencies and inconveniences. Special security relays, i.e., relays that are equipped with their own intrinsic security features, have to be used so as to insure proper functioning of the elements of the system. These relays are relatively expensive. Furthermore, the systems that are based on these relays do not have the capability, except by complicated methods, to detect and eliminate defective or erroneous commands that might result, for example, from a short in the power circuit. 
     The object of this invention is to alleviate these inefficiencies and inconveniences. 
     In order to achieve this objective, the interface, in summary, in accordance with this invention, includes circuit elements that are capable of performing an AND logic function, a monitoring circuit arrangement that monitors the functioning of these circuit elements and has outputs tied to a controller circuit on the computer side, and means of testing this monitoring setup. The controller circuit on the computer side is equipped with a comparator circuit that checks the states of the logic circuit elements. This comparator circuit is responsive to an output of the monitoring circuit arrangement and to the existing command state. The controller circuit has signal inhibitors that prevent a command signal from being sent when the two compared command states don&#39;t match. 
     In practice of the invention, the circuit elements that perform the logic function can be off-the-shelf electrical or electronic components that have no specific security requirements, and at the same time are inexpensive, yet at the same time are able to guarantee the functional integrity of the interface. 
     According to an advantageous characteristic of the invention, the power circuit of the activator, which includes two lines that transmit electrical power at two different levels, has in at least one of these lines an element that can carry out an AND function, as well as act as a switch, so that transfer of power to the activator upon receipt of a command signal from the controller is accomplished, and further has a monitoring mechanism to check the output state of the AND element. 
     According to another advantageous characteristic of this invention, a circuit element capable of performing an AND logic function is mounted in each power transmission line of the activator&#39;s power circuit. Each such circuit element is controlled by an appropriate command mechanism from the controller. A monitoring circuit is also associated with each AND element, each monitoring circuit being equipped with means to monitor said element, and being in turn connected to the command mechanism for said element and/or another element. 
     According to another advantageous characteristic of this invention, the two transmission lines of the activator&#39;s power circuit are connected from the outputs of the logic elements to the inputs of the primary winding of a transformer, while the activator itself is hooked up to the circuit of the transformer&#39;s secondary winding. 
     According to another characteristic of the invention, each monitoring circuit is connected to a test circuit that provides a test signal at the inputs of the monitoring circuit. In response to the test signal the monitoring circuit generates an output signal as if a power level where present at the output of the AND element. 
     According to this invention it is possible to employ a transformer that is characterized by a perceptible rectangular hysteresis curve. The transformer primary winding is designed so that the current that flows in a direction that is inversely related to the function of the command signals that are applied to the AND elements power transmission lines of the activator, in such a way that there is no power transmission in the secondary circuit of the transformer wherever there is a constant voltage applied to at least one of the power lines. 
    
    
     The invention will be more easily understood, and the other objectives, characteristics, details and advantages that are applicable will become clearer in the context of the explanatory discussion that follows, and which refers to the attached schematical drawings that are meant to serve as illustrations of the invention in two different configurations. 
     FIG. 1 shows the electrical diagram of the first configuration of the interface, according to this invention. 
     FIG. 2 shows the electrical diagram of the second configuration of this interface, according to this invention. 
     FIG. 3 shows a modification that applies to the configuration shown in FIG. 1. 
    
    
     FIG. 1 shows the first configuration of the interface according to this invention. In the illustrated example are D1 and D1&#39; which are two computer modules, and an activator A which is fed electric power from a generator G which produces two different power levels E1 and E2, each one of which is transmitted to the activator A by means of power transmission lines LT1 and LT2. The interface is identified by the reference IF. According to this invention, the above-described interface consists of two parts: a part labeled IF1 which forms that part of the interface which has externally controlled security meachanisms, and a part labeled IF2 which has intrinsic, or built-in security mechanisms. 
     The interface has, for each computer module D1 and D1&#39; an input/output mechanism labeled DES and DES&#39;, which consists of such elements as coders, decoders and output registers. Each one of these mechanisms DES and DES&#39; has a certain number of outputs labeled Si. In FIG. 1 a single output S1 is used for sending commands to the power circuit that feeds the activator A. Of course, it would be possible to use other outputs for sending commands to the power circuits of other activators. The outputs S1 and S1&#39; are respectively tied to inputs on control units C1 and C1&#39;, the outputs of which in turn are connected to respective inputs of switching units C2 and C2&#39;. The switching units C2 and C2&#39; also have inputs connected to the power circuit of the activator, i.e., to the power transmission lines LT1 and LT2, respectively. Each of these switching units C2 and C2&#39; assures the transfer of electric power to the activator A in response to a command signal issued from the command units C1 and C1&#39;. It is observed that these switching units C2 and C2&#39; are performing AND logic functions. They consist of discrete electrical components such as transistors and other semiconductor parts or sub-assemblies. 
     From the outputs of switching units C2 and C2&#39;, the power transmission lines LT1 and LT2 are connected to respective inputs of the primary winding of a transformer TR. The activator A is connected in the secondary winding circuit of the same transformer. 
     In order to monitor the functioning of switching units C2 and C2&#39;, two monitoring units K1 and K1&#39; are provided, each having an input circuit connected between the output of a corresponding one of the switching units C2 and C2&#39; and the power transmission line receiving input of the other one of the switching units, as shown. The outputs Sk and Sk&#39; of the units K1 and K1&#39; are tied to respective inputs Ek and Ek&#39; of the two modules DES and DES&#39;. The monitoring units K1 and K1&#39; can be assembled in any one of several ways. In the present example they consist of photocoupler circuits the inputs of which are equipped with resistors R1 and R1&#39; which are in turn tied to the two power transmission lines LT2 and LT1, respectively. The output circuits of these photocouplers include respective resistors R2 and R2&#39;, and are connected between ground and a positive voltage level. 
     The interface according to the present invention further includes test units K2 and K2&#39;, which are meant to monitor the functioning of control units K1 and K1&#39;, respectively. The respective inputs of test units K2 and K2&#39; are tied to corresponding test outputs St and St&#39; of the modules DES and DES&#39;. The respective ouputs of test units K2 and K2&#39; are connected through associated resistors R3 and R3&#39; to the outputs of switching units C2 and C2&#39;, respectively, and the corresponding monitoring units K1 and K1&#39;. To complete the test circuit of each unit K1 and K1&#39;, the input circuits of the units K1 and K1&#39; are, by way of the corresponding power transmission lines LT2 and LT1, connected to a positive voltage source by diodes D and D&#39;, respectively. 
     In addition to the security measures that have just been described, the circuit of FIG. 1 includes system security modules DS and DS&#39; for computer modules D1 and D1&#39; respectively. These modules are termed &#34;watchdogs&#34; and act upon corresponding relays R and R&#39;, which can be built-in security relays that insure the opening of associated relay contacts CR and CR&#39; mounted in the power transmission lines LT1 and LT2, in response to command signals sent from the corresponding computer modules D1 and D1&#39;. 
     The system represented in FIG. 1 which has been described above functions as follows: the activator A, i.e., an electric motor, cannot be fed power unless a power level is applied to each of the inputs to the primary winding of the transformer TR, and each of these power levels is different from the other. In order for the power to reach the inputs of the transformer, the two switching units C2 and C2&#39; have to be closed, i.e., allowing current to pass at the same time. In other words these two switches have to receive simultaneously at their command inputs appropriate signals from corresponding modules DES and DES&#39; via command circuits C1 and C1&#39;. 
     It will thus be appreciated that an order cannot reach the activator unless three conditions are met simultaneously (two power levels; different levels; two command signals). For security in operation, however, it is desirable that the inadvertent ocurrence of one or several of these conditions also be prevented. 
     The transformer TR is a primary means to protect the activator against such a risk, as will now be explained. 
     In practice, several activators each equipped with a power circuit that has switching units like units C2 and C2&#39; would be controlled by a single module such as module DES. If the activators were simply connected across the outputs of their associated switching units, false triggering of one or more activators could occur under certain conditions. For example, it would be possible for a short circuit to occur between the outputs of switching units (more particularly, between the associated transmission lines connected to the ouputs) of two or more activator power circuits. The regular presence of a power level on the shorted transmission line of one activator would thus generate a power level in the line of the other activator (or activators) to which it is shorted, thus applying a false input signal to one input of the other activator (or activators). It would then only take the application of a power level to the remaining input of the other activator as a result of a normal command signal sent via the appropriate switching unit to turn on that activator. In other words, the activator would be turned on by a command from only one of the two associated computer systems, instead of both systems at the same time as contemplated in the design of the interface. A similar risk of false triggering would be presented by the inadvertent grounding of one of the power transmission lines connected to an input of an activator. In this case, the application of a power level to the remaining input could energize the activator. 
     This risk of inadvertently powering up an activator A in the manner described above is eliminated by inclusion of the activator in to the secondary winding circuit of a transformer TR, as shown in FIG. 1. With such a setup the activator will not be inadvertently turned on by a short circuit or the grounding of one of its inputs. It is still mandatory for all three of the security conditions mentioned above and required by the interface to be preliminarily fulfilled. Even a simultaneous grounding of the two activator inputs could, in the worst case, only cause a malfunction of the activator, which is not really considered a breach of security. Furthermore, the activator could not be turned on unless two different power levels were applied simultaneously to the two inputs to the transformer TR&#39;s primary winding. In view of all of the above explanations, the transformer can be considered, in accordance with this invention, as an intrinsic security constituent of the interface. 
     The monitoring units K1 and K1&#39; allow for the detection, separately and at any given time, of the inadvertent presence of a power level beyond the outputs of the switching units C2 and C2&#39;. A presence of this nature would place the entire security system in default. In particular the inadvertent and perhaps permanent power level at one of the outputs of one of the switching units C2 or C2&#39; would results the activator being energized on command from the other switching unit C2&#39; or C2, i.e., by means of only one computer system. 
     As can be seen from FIG. 1, the separate control for each power transmission line beyond the power circuit switching unit outputs is assured by the arrangement of the units K1 and K1&#39; in the manner described earlier. If, for example, a power level were to be applied to the output of the switching unit C2, the monitoring unit K1, consisting of a photocoupler, would cause a difference in power levels to be applied across the inputs of K1, which would in turn excite the photocoupler. This would produce a specific output signal at the output Sk, which would be transmitted to each of the two computer systems D1 and D1&#39;--more specifically to their input/output modules DES and DES&#39;. The computer system D1 could then determine if the state of output &#34;1&#34; represents an inadvertent power level or one that originated from a command signal it had sent to switching unit C2. In the other computer system D1&#39;, the output signal coming from unit K1 is used to inhibit the transmission of a command signal to the switching unit C2&#39; as long as an inadvertent power level is present beyond the output of the switching unit C2. 
     Another possibility is that the monitoring units K1 and K1&#39; could be themselves defective. It would constitute a breach of the system&#39;s security if the defect in the control units prevented them from going to the &#34;1&#34; state from the &#34;0&#34; state, that is, from producing output signals even when there is a power difference applied across their input terminals. In such a case, one power level could be applied inadvertently to the output of one switching unit and the corresponding control unit would not be able to communicate this fact to the computer system of the other switching unit. Thus there would be no signal to prevent this latter computer system from sending a command signal to its switching unit, even through an inadvertent power level is applied to the output of the first-mentioned switching unit. The result would be the inadvertent powering of activator A upon receipt of a command from only one of the computer systems. 
     The purpose of test units K2 and K2&#39; is to eliminate this risk. For this purpose, the units K2 and K2&#39;, which in the present example consist of photocouplers, are connected so that they can operate to test the control units K1 and K1&#39; at any time. To this end the security interface according to this invention is equipped with a test circuit for each control unit K1 and K1&#39; the test circuit utilizing a continuous current. If the unit K1 is to be tested, the module DES will generate a test signal at its St output that will close the output circuit of the photocoupler K2 and insure that a continous current will flow in the input circuit of the monitoring unit or photocoupler K1 across diode D&#39;. If the control unit functions correctly, it will change states and thereby send an appropriate output signal to the computer systems. 
     It should be noted that in the example of the configuration that was just described and is shown in the figure, the test signals are constituted by a continuous current so that they will not influence the functioning of the system, i.e., cause an inadvertent activation of the activator. Of course, the test signals can consist of any type of arrangement as long as they meet this criterion. 
     This invention further includes security measures to effect an overall power cutoff if, for example, a default has already been detected and there is risk of a second default. It is for this eventuality that the security relays R and R&#39; have been installed. Of course, a single relay could easily accomplish the same task. Whether one or two relays are used, the principle of security may be provided for without building redundance into the overall system. 
     These relays can be common to the entire installation regardless of the number of activators that are involved. 
     It can be seen from FIG. 1 that the interface is configured for programmed logic. The same design principle can be used for an interface using hardwired logic. In this case, the assembly shown in FIG. 3 is interposed between the command unit C1 and the switching unit C2. The illustrative assembly includes an AND gate P1, with two inputs receiving respectively the command signal Sc1 from the command unit C1 and the signal Sk1 from the monitoring unit K1, and a memory unit M1. 
     If the unit K1 produces a &#34;0&#34; output signal representing a &#34;0&#34; level at the output of switching unit C2 that is being controlled, the gate P1 will pass command signals that come from C1 to cause C2 to switch. In order to insure that even though the switching unit C2 changes state and blocks the gate P1, the signal from unit C1 will always reach unit C2, the unit M1 is provided to maintain the output of C2 in the &#34;1&#34; state while the command unit C1 sends a command signal. 
     FIG. 2 shows a second configuration of an interface according to this invention. This configuration is based on the use of a transformer with a rectangular hysteresis curve. 
     In FIG. 2, all of the elements that correspond to the same elements already described for FIG. 1 carry the same references. The activator A is connected as before to the secondary circuit of a transformer TR. However, a midpoint of the primary winding is now tied to positive voltage source Up by means of a resistor R5. The two inputs of the primary winding are respectively connected to the outputs of corresponding switching units C2 and C2&#39;, each of which in this case consists of a transistor. The emitters of the two transistors are tied to a negative voltage source Un. The base of each transistor C2 and C2&#39; is commanded by a module DES or DES&#39; by means of an associated AND gate P2 and P2&#39;. AND gates P2 and P2&#39;  have first inputs respectively connected to the S1 and S1&#39; outputs of the modules DES and DES&#39;, and second inputs connected to the output of an impulse generator G1. Regarding the gate P2&#39;, it is observed that an inverter IN is placed between the output of generator G1 and the corresponding gate input. In this configuration, only one monitoring unit K1 is needed to track the output states of the switching units C2 and C2&#39;. The control unit can be configured any number of ways. In the present example shown in FIG. 2, it consists of a photocoupler such as was described for FIG. 1, the input of which is connected to resistor R5. The output Sk of this photocoupler is connected to each of the two modules DES and DES&#39; by means of respective input terminals EK and EK&#39;. Connected to module K1 is a test module K2 as in the case shown in FIG. 1. The purpose of this test module is to monitor the function of module K1. The input circuit of the test module includes an OR gate P3 with two inputs tied respectively to the test outputs St and St&#39; of the two modules DES and DES&#39;. 
     The interface shown in FIG. 2 functions as follows: It is observed that each transistor C2 or C2&#39; is conducting current when its input gate P2 or P2&#39; is open (i.e., passes a signal). Each of the gates P2 and P2&#39; opens when a positive impulse is received at its input connected to generator G1 simultaneously with the arrival of a command signal transmitted by its corresponding module DES or DES&#39;. Given that the impulses produced by generator GI, before arriving at transistor C2&#39; pass through an inverter IN and undergo a change in polarity, the transistor C2&#39; is open while transistor C2 is closed and vice versa. As a result, the two halves of the primary winding of transformer TR undergo successive current flows that are in the opposite direction to current generated by the positive voltage source Up towards the negative voltage source Un at a frequency that is determined by that of the impulses from generator C1. This permits the activator A to receive power. 
     If one of the two transistors C2 and C2&#39; is closed (off) because its module DES or DES&#39; has not sent a command signal, or is constantly open (on) inadvertently due to a default, no current will flow continuously. Because of the rectangular hysteresis curve of the transformer TR, this latter remains insensitive to such states, and does not cause the activator A to receive power. Because a default state is characterized by current flowing in the corresponding primary winding half and therefore across resistor R5, this state will be detected by the control module K1, which will then signal the two modules DES and DES&#39;. This will allow for inhibiting the transmission of a command signal to the other switch, which might cause an inadvertent powering up of activator A in conjunction with parasitic phenomena (in the circuit). As in the first configuration, in order to test the control module K1, one or the other of the modules DES or DES&#39; sends an appropriate test signal. In the present example, a negative voltage with respect to source Up is applied to the free terminal of resistor R5, which causes the &#34;1&#34; state to appear the output of the control module K1. It would be possible as an alternative to disconnect the module K1 from the resistor R5 as appropriate for the duration of the test. It would also be possible to choose a different test signal than that of the operating current of the system, to which this latter is insensitive. Another very easy method to verify the function of monitoring module K1 when there is a &#34;1&#34; state permanently at the output of this module, would consist of causing the output of one of the modules DES or DES&#39; to pass to the &#34;0&#34; state for a couple of milliseconds, or even microseconds, and then to read to information coming back from the module K1. Given that the response times of the elements in the activator module are comparatively long, the activator will remain insensitive to such a brief state change. 
     It is observed that in the second configuration the three indicated conditions in the first configuration still need to be met simultaneously: two power levels Up and Un are needed; the two levels must be different; and two simultaneous command signals from the modules DES and DES&#39; are needed. 
     Of course, there are several modifications that can be adapted to the configurations that have been described above. It is possible to make the interfaces more complex by incorporating other units capable of generating logic functions, and to which it would then be necessary to add control modules and other means to allow verification of proper functioning of these modules. In the case of the first configuration, it is possible to divide the interface represented in FIG. 1 into two parts, that is to have only one switching unit hooked up to a power transmission line. In the case of the second configuration it is possible to design the interface not as a programmed logic circuit, but as a hardwired logic circuit using elements analogous to those in the layout shown in FIG. 3. Furthermore, the different modules can be assembled in other ways in order to perform the indicated functions. 
     In all cases, an adapter module for the output voltage as well as a filter module or rectifier module can be interposed between the transformer TR and the activator A. 
     It should be further noted that in the case of the two configurations presented in FIGS. 1 and 2, the monitoring units K1 and K1&#39; can be separated into single units, so that the signals sent to the computer modules are mutually isolated. This will allow for limiting the risk of interaction between the two computer systems.