SYSTEM AND METHOD FOR CALIBRATING A SENSOR
This disclosure includes a software appendix of 44 pages, the entirety of which is copyrighted. The copyright owner has no objection to the facsimile reproduction by anyone of the patent disclosure, as it appears in the Patent and Trademark Office patent files or records, but otherwise reserves all copyright rights whatsoever.
CROSS-REFERENCE TO RELATED APPLICATIONS
This application claims priority to U.S. Provisional Patent Application No. 60/098,755, filed September 1, 1998, which is incorporated herein by reference.
BACKGROUND OF THE INVENTION
1. Field of the Invention
The subject invention relates to calibration systems for measuring instruments, and more particularly to an improved calibration system and method for point level sensors which are used to determine the level of materials such as liquids, caustics, powders, bulk solids and free flowing materials disposed within a container. 2. Background of the Related Art
Point level sensors have been widely used and are well known in the art.
They are used to detect the presence, absence and/or level of a free flowing material in a container. In use, the output of the sensor varies with the level of the material in the container. This information is used to monitor and maintain specified desirable conditions, e.g., full or empty.
Techniques for sensing the level of a material in a vessel include the use of capacitance probes, radio frequency (e.g., "RF") admittance probes or the like. Examples of such probes are described in detail in U.S. Patent No. 4,555,941 to Fathauer et al. and U.S. Patent No. 4,166,388 to Sun et al. In the prior art, in order to prevent undesirable overfilling or underfilling conditions, a sensor reading is compared to a stored reference value (e.g., "switch set point") to determine the condition or "state" of the point level sensor. The switch set point is a calibration data point which insures the sensor readings are accurate. When the substance contacts the sensor, this state is referred to as "covered" or "full". Likewise, when the sensor is not in contact with the substance, this state is referred to as "exposed", "uncovered" or "empty". These terms will be used interchangeably throughout the specification which follows.
It is well known to calibrate a measuring instrument to maintain the switch set point centrally between the two states of covered and exposed. Typically, a switch set point is established by a user adjusting a potentiometer. Generally, user adjustment processes are inconvenient, time-consuming and prone to error.
As a result of these difficulties, several systems have been developed to more efficiently calibrate measuring instruments. For example, U.S. Patent No. 5,553,479 to Rauchwerger discloses a circuit which averages two readings to determine the switch set point, thus reducing user intervention. In U.S. Patent No. 4,499,766 to Fathauer et al., an operator pushbutton establishes reference readings of a preselected material condition
(e.g., covered or exposed). U.S. Patent No. 4,624,139 to Collins further combined operator pushbuttons with capacitance bridge networks to allow a user initiated calibration. U.S. Patent No. 5,756,876 to Wetzel et al. discloses a method which includes
computing a second reference point by adding a predetermined amount to a first reference point. All of the foregoing patents are herein incorporated by reference.
Despite their utility, there are still problems associated with these prior art systems and methods. For example, if the switch set point is too low, the sensor reading may exceed the switch set point by slight variations of the measurement device rather than a state change. This could be the result of formation of deposits on a capacitance probe or a change in the capacitance of the material disposed in the container. If the switch set point is too high, the sensor may not achieve a reading above the switch set point when the probe becomes covered. As a result, erroneous sensor readings occur. Prior art systems require the step of properly adjusting the level of material to a required state before a calibration can occur. Furthermore, variations in probe readings, depending upon the direction of the state change, (e.g., "hysterisis"), can cause incorrect measurements leading to a poor calibration and erroneous sensor readings.
In view of the deficiencies of prior measuring instruments, there is a need in the art for an improved measuring instrument calibration system and method which permits efficient and error free calibration for a variety of applications and operating conditions.
SUMMARY OF THE INVENTION
One aspect of the present invention is directed to a system for calibrating a measurement device used to indicate a level of a free-flowing material within
a container. The system includes a first signal generator operatively associated with a measurement device for initiating a measurement of a covered state of the measurement device. A second signal generator operatively associated with the measurement device for initiating a measurement of an exposed state of the measurement device. A memory for
storing data including the measurements corresponding to the covered and exposed states of the measurement device. A microcontroller in communication with the memory, wherein the microcontroller is operative to monitor an input signal from the measurement device corresponding to the level of the free-flowing material within the container, receive an input signal from the first signal generator to initiate a measurement of the covered state, and thereupon store in the memory a covered data point based upon the input signal from the measurement device, receive an input signal from the second signal generator to initiate a measurement of the exposed state, and thereupon store in the memory an exposed data point based upon the input signal from of the measurement device and calibrate the measurement device based upon at least one of the covered and exposed data points stored in the memory. The system further includes a relay for controlling an external apparatus operatively associated with the container, wherein the microcontroller is further operative to communicate with the relay and calculate a hysterisis value from using the input signals from the first and second switches.
Another aspect of the present invention is directed toward a method for calibrating a point level sensor. The method includes the steps of providing a point level sensor for defining a level of a free-flowing material in a container, receiving input signals from a probe associated with the container, determining a point level sensor hysterisis value based upon the input signals from the probe and calculating data relating to the calibration of the point level sensor using, the input signal from the probe and the
point level sensor hysterisis value. The method is further defined wherein the receiving step comprises the steps of receiving an input signal indicating actuation of a first switch relating to an exposed condition and receiving an input signal indicating actuation of a second switch relating to a covered condition.
BRIEF DESCRIPTION OF THE DRAWINGS
So that those having ordinary skill in the art to which the disclosed system and method appertain will more readily understand how to make and use the same, reference may be had to the drawings wherein:
FIG. 1 is a schematic representation of a preferred embodiment of the smart calibration system of the subject invention;
FIG. 2 is a flowchart illustrating a preferred embodiment of a process for the subject invention; FIG. 3 is a schematic diagram of the oscillator circuitry in a preferred embodiment of the capacitance to frequency converter of the point level sensor;
FIG. 4 is a schematic diagram of the sine wave to square wave converter circuitry in a preferred embodiment of the microcontroller of the point level sensor;
FIG. 5 is a schematic diagram of the counter circuitry in a preferred embodiment of the microcontroller of the point level sensor;
FIG. 6 is a schematic diagram of the port one interface circuitry in a preferred embodiment of the point level sensor;
FIG. 7 is a schematic diagram of the port zero interface circuitry in a preferred embodiment of the point level sensor; FIG. 8 is a schematic diagram of the microprocessor circuitry in a preferred embodiment of the microcontroller of the point level sensor;
FIG. 9 is a schematic diagram of the port three interface circuitry in a preferred embodiment of the point level sensor;
FIG. 10 is a schematic diagram of the time delay circuitry in a preferred embodiment of the microcontroller of the point level sensor; and
FIG. 11 is a schematic diagram of the output circuitry in a preferred embodiment of the point level sensor. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENT
This invention relates to an improved system and method for calibrating measuring instruments. The system and method are particularly applicable to point level sensors, although the system and method may be utilized in many applications, such as motor control, as would be readily appreciated by those skilled in the art. The present invention overcomes many problems of the prior art associated with point level sensors. The advantages, and other features of the system and method disclosed herein, will become more readily apparent to those having ordinary skill in the art from the following detailed description of certain preferred embodiments taken in conjunction with the drawings which set forth representative embodiments of the present invention and wherein like reference numerals identify similar structural elements.
Referring to FIG 1, there is shown a block diagram of a preferred embodiment of the smart calibration system of the subject invention. In general, the system includes a point level sensor 100 constructed in accordance with the subject invention, an external apparatus 185, which can take the form of a valve, pump or the like, a vessel 195 containing a volume of a free-flowing material to be used in an operation 101 and a probe 190 in the form of a capacitance sensor operatively associated with the interior
of the vessel 195.
In operation, the capacitance of probe 190 varies as the level of material in the vessel 195 increases and decreases. The point level sensor 100 monitors the
capacitance of the probe 190 in the vessel 195. Probe 190 can be disposed at the top or bottom of the vessel 195 depending upon the desired application. For example, the vessel 195 may be a storage tank containing bulk solids such as grain, powdered chemicals, cement, or liquids. In an exemplary embodiment, a probe 190 could be placed in the top of a tank, either vertically or horizontally, to indicate that the tank is full when the probe 190 is covered by the material.
As a result of the capacitance variation of the probe 190, the point level sensor 100 monitors a signal indicative of the level of the material. When the switch set points are exceeded, the point level sensor 100 drives the external apparatus 185. The external apparatus 185 will adjust the material level within the vessel 195 in accordance with certain specifications of the operation 101.
With continuing reference to FIG. 1, the point level sensor 100 comprises a microcontroller 105 which serves to acquire data, process data, and execute instructions. Pushbutton switches 150 and 155 are associated with the microcontroller 105 to provide a user with the ability to initiate a calibration sequence. A fail safe signal 145 is associated with microcontroller 105 to provide a user with the ability to semi-permanently select a mode of operation to avert unsafe operating conditions. The point level sensor 100 includes system status indicators, i.e. light emitting diodes ("LED's") 160, 165 and 170, which provide a visual indication of system status. A relay 175 allows the point level sensor 100 to drive external apparatus 185 which requires a greater electrical load than the microcontroller 105 can supply.
The microcontroller 105 includes a memory 110 for stores the instruction set for the subject calibration method. The memory 110 comprises RAM 111 and electronically erasable programmable read only memory ("EEPROM") 115 to allow for
volatile and non-volatile storage. Microprocessor 120 executes the instruction set of the subject invention.
Microcontroller 105 also includes a capacitance to frequency converter 122 oscillates at a frequency that varies with the capacitance of the sensor in order to allow the microcontroller 105 to monitor the level of material disposed in the container. A sine to square wave converter 125 is provided for changing the output of the capacitance to frequency converter 122 into a square wave which the microprocessor 120 can effectively evaluate. An A/D converter 135 modifies the fail safe signal 145 to allow microprocessor 120 to process it. Timer delay and output field effect transistor ("FET") 140 dampen the microprocessor 120 response to prevent the output state LED 170 and relay 175 from changing state inadvertently over minor fluctuations. A counter 126, timer 127 and clock 130 are also provided to facilitate microprocessor 120 operations.
During normal operation, the probe 190 capacitance is an element of an oscillator circuit within the capacitance to frequency converter 122. The probe 190 capacitance sets the frequency of the oscillator circuit. As a result, the frequency of the oscillator circuit varies as the level of material increases and decreases. In the preferred embodiment, the frequency decreases as the capacitance increases. Thus, the higher the probe 190 capacitance, the lower the converter 180 frequency, the higher the level of the material in the container. Similarly, the lower the probe 190 capacitance, the higher the converter 180 frequency, the lower the level of material in the container.
The sine to square wave converter 125 of the microcontroller 105 receives the output from the capacitance to frequency converter 122, and changes the sine wave
output into a square wave. (see FIG. 4) A counter circuit 126 divides the resulting square
wave signal. (see FIG. 5) The microprocessor 120 then determines a count based upon the divided square wave.
The microcontroller 105 monitors the status of the fail safe signal 145, covered switch 150 and exposed switch 155, and controls the relay 175. The fail safe signal 145 determines the states upon which states the relay 175 is energized. When the fail safe signal 145 is in high fail safe mode, the microprocessor 120 maintains the material level above the probe 190 position, i.e. covered. To accomplish this, if the probe 190 reading is below the set switch point for the covered state, the microprocessor 120 outputs a signal to energize the relay. However, the timer delay and output FET 140 filter out the minor output signal fluctuations which cause undesirable state changes. Thus, the state must substantially change to another state before the relay 175 is energized. When the relay 175 is energized, the external apparatus 185 fills the vessel 195. Conversely, in low fail safe mode, the microprocessor 120 maintains the material level below the probe 190, i.e. exposed. For the energized and de-energized conditions of the relay 175, the microcontroller 105 turns output state LED 170 on and off respectively. Further, during normal operation, the microcontroller 105 illuminates the system health LED 165, thus indicating that no faults are detected. If the system self-test detects a fault, the system health LED 165 flashes until the condition is corrected. Still further, the microcontroller 105 illuminates the calibration LED 160, when a valid calibration has been performed. If the system is performing a calibration, the calibration LED 160 flashes until the operation
is completed.
The system can enter the calibration mode upon initialization or actuation of either the covered or exposed calibration switches 150 and 155. Upon initialization, the
microprocessor 120 reads the EEPROM 115 to see if valid calibration data exists. If so, normal operation can resume based upon the prior valid calibration data.
Using the system of the subject invention, a user can initiate calibration in several ways. For example, the material level can be dropped to reach the exposed state. At such a time, the user actuates the exposed pushbutton switch 155. The microcontroller 105 then acquires a probe 190 reading, stores it in the EEPROM 115 and utilizes it as an exposed data point. If the exposed data point is the only valid data point, the relay 175 energize points are determined solely therefrom. Similarly, if the material level is adjusted to the covered state and the covered pushbutton switch is actuated, the microcontroller 105 acquires and stores a covered data point. If the covered data point is the only valid data point, the relay 175 energize points are determined solely therefrom. Thus, the point level sensor 100 can be calibrated in either state, covered or exposed. In a preferred embodiment of the subject invention, if the calibration values are reversed as a result of the user pressing a switch under the wrong condition, the calibration values are exchanged to correct the error. However, if valid exposed and covered data points exists, the two data points are used to determine the relay 175 energize points. If no valid data points exist, default data for the relay 175 energize points is used. Thus, one of the objects of the present invention is fulfilled in that it is not necessary to adjust the material level to a predetermined state before calibration or operation. Preferably, the probe 190 includes a drive guard system. As is well known in the art, the drive guard system prevents accumulated build up on the probe 190 from causing incorrect readings. The drive guard system comprises an element of the probe 190 which protrudes into the vessel and supporting circuitry. U.S. Patent No. 4,166,388 to Sun et al. discloses such a drive guard system and is herein incorporated by reference.
Referring now to FIG. 2, the system initializes at step 200. An initialization routine is executed which sets system parameters to default states that allow for successful calibration and operation. For example, system counters will be set to null values in order to prevent subsequent erroneous operations. In this described embodiment, the initialization routine initializes the RAM 1 11 and option registers, determines output state on relay 175, configures the interrupt registers and reads EEPROM 1 15. If the voltage on GPO line of microprocessor 120 is erroneous, a fail safe condition occurs.(see FIG. 8)
At step 210. the microcontroller 105 reads the EEPROM 1 15 to determine if prior valid calibration data is present. If valid calibration is present, it is utilized and operation proceeds. The microcontroller 105 reads the fail safe signal 145 at step 215. The fail safe mode is operator selectable according to the specification of the operation 101. In a preferred embodiment, a jumper is provided to allow the user to select low or high fail safe mode. A jumper is an electrical device that connects two or more electrical pins. Removal of the jumper eliminates the electrical connection. Generally, a user can remove and replace the jumper without difficulty.
At step 220, the microcontroller 105 polls the switches current state. If a switch is depressed, the microcontroller 105 stores a corresponding data point in memory 110. Accordingly, the microcontroller 105 updates the output state, calibration and system health LEDs 160 and 165. The main calibration loop of the program commences at step 225. The main loop interrupts operations based upon the data gathered at steps 220. For
example, when the exposed switch 155 is pressed, the microcontroller 105 initiates the routine for making calibration calculations. At such a time, the calibration LED 160 flashes. Thus, the operator is aware that a calibration is occurring.
At step 230, the microcontroller 105 determines if the data representing a probe 190 reading in the covered state (e.g., "covered data point") is valid. The covered data point may be valid due to a previously performed covered calibration. For example, a valid covered calibration occurs when the covered switch 150 is depressed during the covered state. In the preferred embodiment, the microcontroller 105 will take the average of approximately 256 probe 190 readings as a valid data point. Alternatively, the covered data may not be valid, i.e. a covered calibration has not yet been performed.
If the covered data point is determined to be valid, the microcontroller 105 proceeds to step 235. If the covered data is determined to be not valid, the microcontroller 105 proceeds to step 242. The microcontroller 105 determines if the data representing a probe 190 reading in the exposed state (e.g., "exposed data point") is valid at step 235. The exposed data point may be valid due to a previously performed exposed calibration. An exposed calibration occurs when the exposed switch 155 is depressed during the exposed state. Alternatively, the exposed data may not be valid, i.e. an exposed calibration has not yet been performed. If the exposed data point is determined to be valid, the microcontroller 105 proceeds to step 239. If the exposed data is determined to be not valid, the microcontroller 105 proceeds to step 237.
The microcontroller 105 performs a calibration based only upon the covered data point at step 237. Two parameters, "TRIPON" and "TRIPOFF", are determined. TRIPON is used to determine when the relay 175 energizes. TRIPOFF is used to determine when the relay 175 de-energizes. When the relay 175 energizes in high
fail safe mode, the material level within vessel 195 increases until the state of the probe 190 changes from exposed to covered. When the relay 175 energizes in low fail safe mode, the material level within vessel 195 decreases until the state of the probe 190
changes from covered to exposed. In the preferred embodiment, TRIPON equals the covered data point minus 5 counts where each count equals 0.5pF. Similarly, TRIPOFF equals the covered data point minus 10 counts.
At step 239, the microcontroller 105 performs a calibration based upon the covered and exposed data points stored in the memory 110. In the preferred embodiment,
TRIPON equals the covered data point minus the hysterisis. TRIPOFF equals the exposed data point plus the hysterisis. The hysterisis equals the difference between the covered and exposed data points divided by eight with a minimum hysterisis value of four counts.
Similar to step 235, the microcontroller 105 determines if the exposed data point is valid at step 242. If the exposed data point is determined to be valid, the microcontroller 105 proceeds to step 245. If the exposed data point is determined to be not valid, the microcontroller 105 proceeds to step 250. Similar to step 237, the microcontroller 105 performs a calibration based only upon the exposed data point at step 245. In the preferred embodiment, TRIPON equals the exposed data point plus 10 counts. Similarly, TRIPOFF equals the exposed data point plus 5 counts. At step 250, no valid data points exist. As a result, the microcontroller 105 uses default TRIPON and TRIPOFF values.
The microcontroller 105 determines if the fail safe signal 145 is set in low mode at step 255. If the fail safe signal 145 is in low mode, the microcontroller 105 proceeds to step 260. If the fail safe signal 145 is in high mode, the microcontroller 105 proceeds to step 270. At step 260, the system is in low fail safe mode. The
microcontroller 105 determines if the material level in the vessel 195 is above the relay 175 energize point, i.e. TRIPON. If the material level is above TRIPON, the microcontroller 105 proceeds to step 267. If the material level is not above TRIPON, the
microcontroller 105 proceeds to step 262. At step 267, the material level is above TRIPON, indicating a covered state. The relay 175 is then turned on to allow the external apparatus 185 to adjust the material level in the vessel 195 to the exposed state.
At step 262, the material level is below TRIPON and the microcontroller 105 determines if the material level in the vessel 195 is below the relay 175 de-energize point, i.e. TRIPOFF. If the material level is below TRIPOFF, the microcontroller 105 proceeds to step 263. At step 263, the relay 175 is de-energized and the external apparatus 185 does not change the material level. If the material level is not below TRIPOFF, the microcontroller 105 proceeds to step 280 and the current state of the relay is unchanged. At step 270, the system is in high fail safe mode. The microcontroller 105 determines if the material level is below TRIPON. If the material level is below TRIPON, the microcontroller 105 proceeds to step 273. If the material level is not below TRIPON, the microcontroller 105 proceeds to step 276.
At step 276, the material level is not below TRIPON and the microcontroller 105 determines if the material level in the vessel 195 is above TRIPOFF. If the material level is not below TRIPOFF, the microcontroller 105 proceeds to step 280 and the current state of the relay is unchanged. If the material level is above TRIPOFF, the microcontroller 105 proceeds to step 277. At step 277, the microcontroller 105 de- energizes relay 175.
The material level is below the TRIPON, indicating an exposed state at step
273. The relay 175 is turned on to allow the external apparatus 185 to adjust the material level in the vessel 195.
At step 277, the material level is above TRIPOFF, indicating an acceptable level and as a result, the relay 175 is de-energized. At step 280, the microcontroller 105 restarts a continuous loop by proceeding to step 220.
Referring now to FIGS. 3-11, there are illustrated several electronic components of the calibration system of the subject invention. The denoted values of the disclosed components are in no way intended to limit the subject invention, as they can be adjusted by those skilled in the art to achieve performance in dependence upon specific application requirements.
Referring to FIG. 3, the oscillator circuit is a portion of the capacitance to frequency converter 122. Its sine wave output varies with the capacitance of the probe 190. The oscillator circuit is an astable multivibrator. Capacitor C9 terminates the circuit input to a known condition if the probe 190 becomes open. Resistor R10 provides circuit protection in that the resistor limits in rush currents during voltage transients. Diodes Dl, D2, and D3 provide circuit protection by clamping voltage transients to Vcc or ground. Capacitor C8 allows the circuit to continue to oscillate with the input shorted to ground, i.e. water covering the probe 190. Resistor Rl l isolates the inverting input of amplifier U4 from the capacitive input circuit. The circuit oscillates by continually charging or discharging the input capacitors (including the probe 190 capacitor) depending on amplifier U4's output state through resistors R8, R6, and the combination of resistors R4, R5, and R7. The amplifier U4 output changes state when the voltage at the junction of capacitor C8 and resistor Rl 1 exceeds or drops below the trip-point established by resistor network, consisting of R14, R15, R17, and R18, which is connected to the non-inverting input of amplifier U4. Resistor R15 varies the trip-point by feeding back the output of amplifier U4 to resistor network R14, R17, and R18. Capacitor Cl l provides wave
shaping for the signal to the probe guard drive circuit (see FIG. 12). Resistor R5, a negative tempco thermistor, corrects the output frequency for changes in ambient temperature. Capacitor C2 provides circuit output wave shaping. The oscillator circuit output, a quasi-sine wave, is input to the sine to square wave converter 125. Referring to FIG. 4, the sine wave to square wave converter circuit 125 converts the output of the oscillator circuit into a 0-5 VDC square wave as is well known in the art. Resistors Rl and R9 set the trip voltage for comparator circuit Ul . The output is connected to the CLK line of counter 126. (see FIG. 5) In the preferred embodiment, the output ranges from 2.08 kHz with the probe 190 shorted to 2.137 MHz with the probe 190
open.
Referring to FIG. 5, the counter 126 circuit is a portion of microcontroller 105. It provides a fourteen stage ripple counter U3 to divide the frequency of the input signal by 1024. Resistor R29 is installed and connects the counter 126 output to the microprocessor 120 port line GP2.(see FIG. 8) Resistor R30 is not installed. Capacitor C3 is a filter capacitor on the power supply line. In the preferred embodiment, the output ranges from 2.09 kHz with the probe 190 open to 16.25 Hz with the 0.033 uF on the probe 190.
Referring to FIG. 6, the port one interface circuit is a portion of the point level sensor 100. It provides the signal from the covered switch 150 to the microprocessor 120 port line GPl and also illuminates either or both of the calibration and system health LED's 160 and 165. When the software sets GPl in the input mode, the state of covered switch 150 is read. Resistor R3 provides a valid logic low on the port line when covered switch 150 is not depressed but the port line is in the input mode. Resistor R39 provides a valid logic high on the port line when the covered switch 150 is depressed when the port
line is in the input mode. The value of R39 is high enough that the system health LED 165 does not turn on when the covered switch 150 is depressed. A removable jumper JP2 is provided to disable the covered switch 150.
Still referring to FIG. 6, when the microprocessor 120 port line GPl is in the output mode, the software can illuminate either of the calibration or system health LED's 160 and 165. When the port line is a logic low, the calibration LED 160 illuminates. Resistors R12 and R13 provide the correct bias voltage for this illumination. When the port line is a logic high, the system health LED 165 illuminates. Resistor R2 and diodes D10 and D8 provide the correct bias voltage for this illumination. Referring to FIG. 7, the port zero interface circuit is a portion of the point level sensor 100. It provides the state of the fail safe jumper JP5 to the microprocessor 120 port line GPO as well as allow the microprocessor 120 to turn on the output FET Q2. When the software sets GPO in the input mode, the microcontroller 105 A/D converter 135 reads the state of the fail safe jumper JP5. When the Fail Safe jumper JP5 is installed, resistors R19 and R34 set the GPO port line at greater than .25 VDC, which is the trip level set in software for high fail safe mode. When the Fail Safe jumper JP5 is not installed, resistor R19 sets the GPO port line to 0 VDC, which is the trip level for low fail safe mode.
Referring to FIG. 8, the microprocessor 120 circuit is a portion of microcontroller 105. It executes the software program in accordance with the subject invention. Microprocessor 120 contains a central processing unit (e.g., CPU) for controlling the operations of the microcontroller 105. The microprocessor 120 operation is
well known in the art and therefore not further described herein. Crystal Yl and capacitors C5 and C6 set the microcontroller 105 oscillator frequency. Capacitor C4 is a filter capacitor on the power supply line.
Referring to FIG. 9, the port three interface circuit is a portion of the microcontroller 105. It provides the circuitry so that the microprocessor 120 , at port line
GP3, can read the state of the exposed switch 155. Resistor R20, a pull up resistor, prevents shorting the power supply voltage to ground when the exposed switch 155 is depressed. Removable jumper JP6 can be used to disable the exposed switch 155.
Referring to FIG. 10, the time delay circuit is a portion of microcontroller 105. It allows the user to adjust the time delay between microprocessor 120 port line GPO turning on or off and the output FET Q2 turning on or off in order to filter the output state as described above. Resistor R26 is not installed. Resistors R21, R38 and variable resistor R25 control the charge/discharge time of capacitor C14. Variable resistor R25 is set by the user for the particular application. Resistor R38 guarantees that if the variable resistor R25 is adjusted to zero ohms, there always is a small amount of resistance between capacitor C14 and the microprocessor 120 port line GPO to prevent loading. Amplifier U5A provides high impedance buffering of capacitor C14 to prevent discharge. U5A is configured as a voltage follower so that it's output voltage equals the voltage across capacitor C14. Amplifier U5B is configured as a comparator and its' output changes state to either turn on or off FET Q2 when the U5A output (i.e. capacitor C14 voltage) meets the trip requirements. Resistors R23 and R28 set the voltage on the comparator reference input to half of the supply voltage. Resistors R41 and R42 set the comparator circuit hysterisis.
Referring to FIG. 11, the output circuit is a portion of point level sensor 100. The microprocessor 120 can turn FET Q2 on or off in accordance with the subject invention. A high current sink to ground is established when FET Q2 turns on. As a result, current flows and the relay 175 is energized. A high impedance to ground is
established when FET Q2 is turned off and accordingly no current flows and the relay 175 is de-energized. Output state LED 170 provides a visual indication of the relay 175 condition, energized or de-energized. Resistor R35 and diode D9 set the bias voltage of LED D9. Resistor R37 provides impedance in series with the gate of FET Q2. Resistor R40 is not installed. Capacitor C21 provides EMI filtering and transient suppression of the output. The output may be used to drive a relay 175, which in turn allows an apparatus with a heavy electrical load requirement to be driven. As is known in the art, a device other than a relay 175 may be controlled by the microprocessor 120 as the operation requires. While the invention has been described with respect to preferred embodiments, those skilled in the art will readily appreciate that various changes and/or modifications can be made to the invention without departing from the spirit or scope of the invention as defined by the appended claims.