Abstract:
An apparatus and method for a pitch state estimator is provided. The pitch state estimator generates a pitch state signal for establishing the orientation used in the control of a ground-traversing vehicle. The vehicle has a support for supporting a load which is preferably a human passenger. In one embodiment, the pitch state estimator includes a pitch sensor connected to the vehicle producing a pitch signal representing an estimate of a pitch angle of the vehicle. The pitch angle is associated with a coordinate system referenced to gravity. The pitch state estimator also includes at least one inertial reference sensor connected to the vehicle producing an inertial orientation signal with respect to the vehicle. Further included is a state estimator module for receiving the pitch signal and the inertial orientation signal and calculating a pitch state signal from the inertial orientation signal and the pitch signal sensor. The pitch state signal is provided to a control loop of the vehicle for dynamically maintaining stability of the vehicle.

Description:
This application claims priority from U.S. Provisional Application, Ser. No. 60/142,007, filed Jun. 30, 1999, which is incorporated herein by reference. 
    
    
     TECHNICAL FIELD 
     The present invention pertains to a device and methods for estimating the pitch state of a personal vehicle for purposes of control of the vehicle. 
     BACKGROUND 
     Various methods and devices exist for measuring pitch of a vehicle. Pitch is defined as the angle, denoted as Θ, between a specified vehicle-fixed substantially vertical axis, denoted as R and the true vertical axis as defined by gravity. R may be defined, for example, by a seat back or other vehicle-fixed structure. The term pitch is synonymous with inclination within the following disclosure and appended claims. Pitch sensing devices include accelerometers, inclinometers, pendulous reference sensors, also known as tilt sensors, and distance probes. 
     Single axis state estimators (SASEs), can provide an estimate of the pitch of a vehicle over regular surfaces under most expected conditions. The pitch state becomes inaccurate where the vehicle makes certain changes in direction, such as, turning the vehicle around on a sloped surface. In such a situation, a SASE may indicate that the vehicle still has a positive pitch even though the vehicle is facing downward where the inclinometer should indicate a negative pitch. The sensors saturate if the pitch suddenly changes so that the pitch rate is above the temporal threshold at which the device may measure change. 
     SUMMARY OF THE INVENTION 
     In accordance with one embodiment of the invention, an apparatus and method for a pitch state estimator is provided. The pitch state estimator generates a pitch state signal for establishing the orientation used in the control of a ground-traversing vehicle. The vehicle has a support for supporting a load which is preferably a human passenger. In one embodiment, the pitch state estimator includes a pitch sensor connected to the vehicle producing a pitch signal representing an estimate of a pitch angle of the vehicle. The pitch angle is associated with a coordinate system referenced to gravity. The pitch state estimator also includes at least one inertial reference sensor connected to the vehicle producing an inertial orientation signal with respect to the vehicle. Further included is a state estimator module for receiving the pitch signal and the inertial orientation signal and calculating a pitch state signal from the inertial orientation signal and the pitch signal sensor. The pitch state signal is provided to a control loop of the vehicle for dynamically maintaining stability of the vehicle. 
     In another embodiment, a pitch-angle error signal is calculated based on the pitch signal and the inertial orientation signal and is fed back to the state estimator module to adjust the inertial orientation signal. In other embodiments the at least one inertial reference sensor is a gyroscope. 
     The pitch state estimator may further include a virtual gyro construction module for receiving the inertial orientation signals of the gyroscopes and outputting to the state estimator module three rotation rate signals. Each rotation rate signal represents a rotation rate about one axis of three perpendicular axes having an origin at the center of gravity of the vehicle. 
     The state estimator module may further include a rotation correction module which transforms the three rotation rate signals producing three corrected rotation rates so that the three rotation rate signals correspond to the coordinate system of the pitch signal. The state estimator module also may include an integrator module for producing orientation angles based on the three corrected rotation rate signals and a summer which receives the inertial orientation signals. The state estimator module further includes a gyro-bias integrator which calculates a bias signal based at least on the pitch signal and the orientation angles, the bias signal being output to the summer. In this embodiment, the output signal of the summer is fed back into the rotation correction module. 
     In another related embodiment, a fault detection module is included for detecting erroneous inertial orientation signals produced by an inertial reference sensor. Once an erroneous inertial orientation signal is detected, the fault detection module determines that a gyroscope has failed. 
     In another embodiment, the state estimator module performs a single axis estimate of the pitch state if a gyroscope has failed. 
     A pitch state signal may be generated in one embodiment by first measuring an estimated pitch of the vehicle with respect to gravity using an inclination sensor. The estimated pitch measurement is converted into a digital estimated pitch signal and then the inertial orientation rates of the vehicle are measured using at least three inertial sensors positioned in three or more distinct orientations on the vehicle. The inertial orientation rate measurements of the three or more inertial orientation sensors are converted into three or more digital inertial orientation signals. Finally, a pitch state signal is calculated in a state estimator module based in part on the digital inertial orientation signals and the digital pitch signal. 
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS 
     The invention will be more readily understood by reference to the following description, taken with the accompanying drawings, in which: 
     FIG. 1 is a block diagram of a prior art control loop for dynamically controlling the stability of a vehicle in the fore-aft plane. 
     FIG. 2 is a diagram showing a land-based vehicle and corresponding vehicle frame (V-frame) coordinate axes in the presence of a pitch angle along with the Earth frame (E-frame) coordinate axes of the earth. 
     FIG. 3 is a diagram showing the relation of the E-frame to the V-frame when the pitch angle is zero; and the roll angle is non-zero. 
     FIG. 4 is a block diagram showing the system architecture for one embodiment of the invention. 
     FIG. 5 is a block diagram of the fault detection module 
     FIG. 6 is a functional block diagram for a three axis state estimator module in one embodiment of the invention. 
    
    
     DETAILED DESCRIPTION OF THE EMBODIMENTS 
     U.S. Pat. Nos. 5,701,965 and 5,791,425 describe personal vehicles that require measurement of instantaneous pitch state for active control of vehicle stability. These patents are incorporated by reference herein in their entirety. Various embodiments of the methods and apparatus disclosed herein for estimating the pitch state of a vehicle may be used with these vehicles. “Pitch state” as used in this description and the appended claims includes both the pitch in the fore-aft plane and the pitch rate of the vehicle, i.e. Θ and Θ r , where Θ r  is the time rate of change of Θ. 
     Such vehicles may include a control loop as shown in FIG. 1 for dynamically maintaining stability of the vehicle in the fore-aft plane so that the vehicle remains upright. This control loop requires the pitch state as input. 
     The plant of FIG. 1 is equivalent to the equations of motion of a locomotion system driven by a single motor. T identifies the wheel torque. In addition to pitch the character Θ identifies the fore-aft inclination i.e. the pitch angle, X identifies the fore-aft displacement along the surface relative to a reference point, and the subscript r denotes a variable differential with respect to time. The remaining portion of the figure is the control used to achieve balance. The boxes  62  and  63  indicate differentiation. To achieve dynamic control and to insure stability of the system, and to keep the system in the neighborhood of a reference point on the surface, the wheel torque T in this embodiment is set to satisfy the following equation: 
     
       
         T=K 1 Θ+K 2 Θ r +K 3 X+K 4 X r   
       
     
     The gains K 1 , K 2 , K 3 , and K 4  are dependent on settings of the control loop, physical parameters of the system, and other effects such as gravity. 
     The dynamic behavior of a vehicle may be described through reference to a coordinate system. Two such coordinate systems are used in describing the motion of a vehicle about irregular surface: the Earth reference frame, “E-frame”, and the vehicle reference frame “V-frame”. 
     The E-frame defines the vertical axis, Z, to be co-linear to the direction of gravity and passing through the center of gravity of the occupied vehicle as shown in FIG.  2 . The position of the origin of the axes about the center of gravity is an arbitrary choice and it should be understood by those skilled in the art that the origin may be positioned about other points on the vehicle. The E-frame defines the roll axis, X, as a component in the direction of travel perpendicular to the vertical axis and passing through the center of gravity of the occupied vehicle, and the E-frame defines the pitch axis, Y, to be orthogonal to both the Z and X axes and passing through the center of gravity of the occupied vehicle. Rotation around the Z axis is described by the angle “Ψ”, also known as the yaw angle. Rotation around the X axis is described by the angle “Φ”, also known as the roll angle. Rotation around the Y axis is described by the angle “Θ”, also known as the pitch angle. 
     The axes associated with the V-frame have an origin positioned at the center of gravity of the vehicle. In other embodiments, the origin of the axes may be situated at another point on the vehicle. The axes are fixed with respect to the vehicle. The relative vertical axis, R, is a specified vehicle-fixed substantially vertical axis and may be defined by a line passing through the center of gravity of the vehicle and the support/backrest/head of the operator of the vehicle. The relative horizontal axis, P, is perpendicular to the relative vertical axis and has a component parallel to the direction of movement of the vehicle. The third axis, Q, is orthogonal to both R and P. The relative orientation of the R,P,Q frame varies with respect to the Z,X,Y frame as the vehicle tilts. As shown in FIG. 2, the Q and Y axes are co-linear however R and Z, and X and P are not. In such a case, the vehicle is “pitching” and thus it has a non-zero value for Θ. FIG. 3 shows P and X axes to be co-linear where the R and Z and Q and Y axes are not. In this configuration, there is a non-zero roll angle, Φ. 
     The equations below present the rate transformations between the E-frame and V-frame under a small angle approximation for the respective rotation rates, denoted by the subscript r. These transformations will be referred to as small angle Euler transforms (SAETs) and inverse SAETs respectively.          [           Φ   r               Θ   r               Ψ   r           ]     =           [         1       ΘΦ         -   Θ             0       1       Φ           0         -   Φ         1         ]                [           P   r               Q   r               R   r           ]                [           P   r               Q   r               R   r           ]     =       [         1       0       Θ           0       1         -   Φ             0       Φ       1         ]                [           Φ   r               Θ   r               Ψ   r           ]                              
     Rate sensors such as angular rate sensors or rate gyroscopes, hereinafter referred to as gyros are used to provide pitch state information to a vehicle. The rate sensors measure the rate of change of the orientation of the vehicle about the V-frame and produce a signal which is representative of the rate of change of the pitch, roll, and yaw angles of the vehicle. The rate sensors need to be adjusted regularly due to sensor drift. Thus, tilt sensors are incorporated into the system for providing a stable angular value from which bias errors of the rate sensors may be compensated for. In a preferred embodiment of the invention the rate sensors are gyros, however in other embodiments they may be any other inertial measurement devices. Through various signal transformations, as explained below, a system for accurately measuring the pitch state based in part on the pitch rate signal obtained from the orientation sensors and the pitch signal from the inclinometer may be calculated. 
     FIG. 4 shows the system architecture of one embodiment of the invention. Absolute reference sensors  400  send signals to the transformation module  401  where the signal produced by the sensor is converted to a useful digital data format and adjusted for known sources of error. Absolute reference sensors  400  which are a special case of accelerometers include sensors that measure quantities with respect to the E-frame such as pendulous reference sensors, also known as tilt sensors. Absolute reference sensors also include sensors capable of measuring the rotation of the wheels of a vehicle to produce a signal of the difference in wheel velocities. 
     The transformation module  401  provides to the state estimator  402  information corresponding to the pitch angle and roll angle when the vehicle is unaccelerated except for the force of gravity, and the difference in wheel velocities. The difference in wheel velocities provides an absolute value for the yaw rate assuming the wheels do not slip. 
     Relative reference sensors  403  measure quantities with respect to the V-frame and may include gyroscopes such as mechanical or solid-state gyroscopes. In order to provide information on the three orientations, at least three single axes gyroscopes are required. Additional gyroscopes may be used to provide fault-tolerance capability. FIG. 4 shows one embodiment of the invention where the relative reference sensors  403  consists of gyro L  404 , gyro D  405 , gyro E  406 , and gyro F  407 . In the preferred embodiment four one-degree-of-freedom gyroscopes are used. Gyro L  404  may be mounted on the vehicle such that it measures Q r  of the vehicle. In such an embodiment, the remaining three gyros  405   406   407  are mounted on the vehicle at various orientations and measure a combination of the Q r , P r , and R r . The selection of the mounting orientations balance factors such as sensor signal range and accuracy. The gyroscopes may be placed on the principle axis of the vehicle, but in a preferred embodiment the gyroscopes are placed off the axis and non-colinear to each other. This provides redundancy among the gyroscopes. If one of the gyroscopes fails, a value for P r , Q r , or R r  may still be calculated, since the other gyroscopes measure P r , Q r , and R r  components. Additionally, the gyroscopes are set off axes in a preferred embodiment because the vehicles capabilities may be greater than the measurement range of the gyroscopes. For example, the angular rate during a sharp turn could be beyond the measurement range of the gyroscopes. By canting the gyroscopes, the measured rate is scaled by the cosine of the angle between the rotation axis and the canted axis and also resulting in the cross coupling of other orthogonal rate components. 
     The relative reference sensors  403  transform the angular rate sensed into a digital signal of the represented angular rate and pass the signal to a virtual-gyro construction module  408 . Since the orientation of the gyroscopes may not be aligned with the Q, P, and R axes each signal produced by the gyroscope may be comprised of rate information about multiple axes. The virtual gyro construction module  408  transforms the signals to produce three output signals that correspond to the signals that three virtual gyros would produce if oriented to measure the rotation about the P, Q, and R axes. This operation on the gyro signals produces the virtual gyro Q r , P r , and R r  information. The virtual gyro construction module performs the matrix equation, V=M G where V is the virtual gyro vector, G is the gyro output vector, and M is a 3×4 construction matrix that converts the four gyro signals in G to the virtual gyro vector, V. The construction matrix is not unique and can be the inverse least squares solution, or the output of any one of the four combinations of three of the four gyros or any combination of the solutions. The coefficients of the construction matrix are determined during the calibration of the vehicle and contain both corrections for gyro alignment and for the individual gyro characteristics. In the preferred embodiment, the construction matrix provides greater fault tolerance for gyroscopes D, E, and F through a combination of the solutions selected from the least squares solution and the four three-gyroscope combinations. 
     A gyro fault detection signal from the gyro fault detection module  409  is also generated from the raw signals which is passed to the state estimator  402 . The gyro fault detection module will be explained below with regard to FIG.  5 . 
     The state estimator  402  takes the signals from the virtual gyro-construction module  408 , the gyro fault detection module  409 , and the calibration-transformation module  401  and estimates the pitch state of the vehicle. The state estimator  402  also estimates the roll state and yaw state of the vehicle, but in a preferred embodiment of the invention, only the pitch state of the vehicle is passed on to the control loop for balancing the vehicle about the vehicle&#39;s center of gravity. 
     Although FIG. 4 illustrates the use of four gyros in one embodiment of the invention, any number above three may be used to provide increasing fault-tolerant capability to the system. 
     FIG. 5 provides a detailed view of the fault detection module  409  which shows multiple fault detectors. Each of the four gyroscopes produces a signal which is the raw signal from the gyroscope. The raw signals are passed through filters which are represented by  805 ,  806 ,  807  and  808 . The coefficients of the filters are configured upon assembly so that the resulting sum should be ideally zero at summer  809 . If the gyroscopes move out of alignment, drift out of specification, or fail, the sum will not be equal to zero. In the preferred embodiment, the input to the summer is the difference between two pitch rates. The pitch rates are determined based upon a selection of the pitch components of three of the four gyroscopes. The sum resulting from  809  is then compared in  810  to a rate error threshold  811 . If the pitch rate exceeds the worst case pitch error rate a gyroscope fault is declared and the system defaults to a single axis state estimator mode. 
     The sum from summer  809  is passed into summer  812  and then integrated to produce a pitch error. The pitch angle is then compared in the angle comparator  814  to the angle error threshold of  815 . The angle error threshold  815  allows an error due to the aging of the gyroscope or any angle deviation to be rejected that is capable of being corrected while still declaring a gyroscope fault if the error cannot be corrected. As explained below, gyroscope drift is reduced over time by the feedback loop filter of FIG. 6 which includes signal attenuator  560 . As with the drift error, the angle error due to the aging is slowly reduced through the same feedback loop. In the preferred embodiment the feedback loop is designed to compensate for inaccuracies over the course of several minutes. If the gyroscope loses too much sensitivity and becomes very inaccurate then the pitch angle may be such that it is uncomfortable or unsafe for the user during the several minutes in which the filter is compensating for the inaccuracy. Therefore, even though the error could be compensated for given a long enough period of time, the system recognizes that a large pitch angle is indicative of a gyroscope failure. The error angle threshold is determined by user comfort considerations and safety and is set at 3.2 degrees in the preferred embodiment although the system may variably adjust the error angle threshold based upon the orientation of the vehicle. A threshold set to the lower range would require more accurate components or would result in more gyroscope faults. A higher threshold would result in less gyroscope faults but would be more apparent to the rider. If the error angle is exceeded, a gyro fault is declared and the system resorts to a single axis state estimation mode. 
     Two additional filters are placed in the module  816  and  817 . These filters are the same as the signal attenuators of FIG. 5 540  and  560  respectively. The angle output is then attenuated in gain  817  and then integrated in integrator  818  which provides the bias adjustment. Filter  817  accounts for long term bias drift. Filter  816  provides attenuation of the angle signal which is passed back to summer  812  and is provided to stabilize the second order filter and prevent oscillation. 
     Multiple rate bias correction signals are provided from the state estimator, explained below, and include signals for P, Q, and R from integrator  570  and the local gyroscope bias error from local gyro bias error module  650 . The rate bias correction signals are compared in bias comparator  819  to a maximum correction rate. A gyroscope failure is declared when a rate bias correction signal exceeds the maximum correction rate. Gyroscopes that are failing slowly or that have gone out of specification are identified by this comparison. In the preferred embodiment the maximum correction rate allowed is greater than 10 degrees per second although other maximum correction rates may be used. If the threshold is exceeded, a gyroscope fault is declared and the system resorts to the single axis estimation mode. 
     FIG. 6 shows a functional block diagram of the state estimator  402 . The rotation rate signals  501 , represented by P r , Q r , and R r , from the virtual gyro construction  408 , are first passed into a summer  502  which corrects for bias errors through a feedback loop. The corrected rotation rates are coordinate transformed from the V-frame to the E-frame using a small angle Euler transform (SAET)  503  thereby producing the E-frame pitch rate, roll rate, and yaw rate information  504 , designated by Θ r , Φ r  and Ψ r . Θ r  is then provided to the control loop of the vehicle. The E-frame rotation rates from the SAET  503  are passed into a summer  520  and are then integrated in the integration module  505  to produce the E-frame orientation angles  506  designated by Θ,Φ. Θ is then passed to the control loop of FIG. 1 of the vehicle. Θ, Φ are also passed back for use in subsequent SAET transforms in SAET module  503 . The integration module  505  at summer  525  takes the difference between Θ and the pitch angle  507  and Φ and the roll angle  507  respectively to generate pitch and roll error signals  530 . The pitch angle and the roll angle  507  are provided by the tilt sensors  400 . The error signals  530  are then passed to the inverse Euler transform  508  along with the E-frame orientation angles, Θ,Φ  506 . The pitch and roll error signals  530  are also fed back and passed through a filter  540  which attenuates the signal&#39;s strength. The attenuated signal is passed into the summer  520 . The feedback loop is provided to correct for inaccuracies due to transients, so as to move the output readings of  506  in the direction of the tilt sensors. The attenuation of the signal attenuator  540  is provided to limit a large erroneous absolute reference sensor value from affecting the E-frame orientation angles. A large erroneous absolute reference sensor value may occur, for example, where the vehicle goes over a sudden bump. As the vehicle goes over a bump the absolute reference sensors will produce extraneous signals in the form of a transients which inaccurately reflect the pitch rate and the pitch angle. 
     In the inverse SAET  508  an inverse SAET is performed on the pitch, roll and yaw error information. In this inverse transform the error signals  530  of the pitch and roll are inserted in the inverse equation at Θ r ,Φ r  and the yaw error signal  580  is inserted at Ψ r  where one would expect to find the respective rates. Ψ 1   r  is provided from summer  620  as the difference between Rr and the difference in the velocity of the wheels  550 . Performing the inverse SAET on the error signals rather than the rates has the effect of partitioning the error information. The inverse SAET transforms the E-frame signals into the V-frame coordinate system. This signal is then passed through an attenuation filter  560 . After the attenuation filter  560 , the signals are placed in a integrator  570  and the then passed back to the summer  502 . This feedback loop accounts for the long term bias drift of the gyroscopes. The attenuation filter  560  allows the tilt sensors which are more stable over long periods of time to assist in correcting for the drift of the gyroscopes while still allowing the gyroscopes to control short term changes. 
     Unlike the p r  and Q r  corrections which are proportional to the error signal, the yaw rate, R r , correction is performed only up to a preset error level designated as X. This comparison is done in comparator  610 . If the yaw rate error signal becomes larger than the preset error level X, correction to R r  is suspended under the assumption that the wheels no longer represent the yaw rate and a suspension timer is started. The gyro rate value, R r  is still compared to the delta wheel rate  550  during the suspension to calculate a yaw error signal  580 . If after a predetermined amount of time the difference between the value of R r  and that of the delta wheel rate is not below the preset error level, an alarm occurs  600  which in one embodiment is a visual signal. If after a second predetermined time on the suspension timer the difference does not fall below the preset error level, the yaw correction is shut off and an alarm sounds indicating that the system cannot distinguish between a fault and the drift error of the gyroscopes. If the second time limit is reached, the system must be reset. The preset error limit is imposed to prevent erroneous R data from being incorporated into the pitch state estimate when, for example, the vehicle is stationary on a moving platform that is turning. 
     To provide for accurate readings of the pitch state, upon initialization, the pitch state estimator attempts to align the gyroscopes to the tilt sensor as long as the system is non-accelerated. This is accomplished by adjusting the corner frequencies through the two signal attenuators  540  and  560  to orient the system to the tilt sensors. In the preferred embodiment, this is accomplished by adaptively adjusting the gain in response to an error signal. If during initialization the gyroscopes and the tilt sensors do not align, the system may pause and then re-measure the values for the tilt sensor and gyroscopes to see if they have aligned. If they do not align, the system may reverse the process and begin again until alignment is achieved. 
     If a gyro failure is detected, the state estimator  402  performs a single axis estimate of the pitch state which is described in U.S. Pat. Nos. 5,701,965 and 5,791,425. The same components and filters of the three axis state estimator are used in the single axis estimate as shown in FIG.  6 . In the case of the single axis estimate, only the pitch rate for a selected gyroscope from the virtual gyro construction module  408  is passed into box  501 . A further distinction is that in the single axis state estimator the difference in the velocities of the wheels which provides the yaw rate and rate for the three axis state estimator is used in the single axis state estimator only to assist in compensating for misalignment of the gyroscope for the pitch angle. A limiter is placed on this yaw rate to overcome situations where the wheels slip. In the single axis state estimator the yaw angle derived from the delta wheel velocities is passed to a summer for removing this component from the calculations and is passed into box  501 . Additionally in box  501  a calibration module is added which corrects for misalignment of the gyroscope. To provide a smooth transition between the three axis state estimator and the single axis state estimator, the local gyro bias indicator  650  provides an initial condition for the integrator of  570  in single axis mode. Another difference between the three axis state estimator and the single axis estimator is that there is no SAET module  503  and inverse SAET  508  because the single axis state estimator must assume that Q=θ r  as there is no need to map the pitch in the V frame to the pitch in the E frame as the system is operating in a single plane as opposed to three dimensions. Additionally, the tilt sensor, which is preferably a two axis pendulous sensor, which provides a signal for both the pitch and roll is only used for the pitch signal and the roll signal is disregarded. 
     In a preferred embodiment there are six gyroscopes. Three gyroscopes are configured about the pitch axis of the V frame and the remaining three gyroscopes are set along a combination of the roll and yaw axes of the V frame. In such a fashion partially triple redundancy is provided. Each gyroscope situated about the pitch axis has an associated processor and tilt sensor the processor capable of providing a single axis state estimate from the associated gyroscope and tilt sensor. The processor receives signals from its associated gyroscope along with the signals from the three gyroscopes which mounted to sense rotation about the yaw and roll axes. The redundancy provides another failsafe system for the vehicle. Each of the three processors independently estimates the pitch state using either the associated gyroscope alone for a single axis state estimate or using both the associated gyroscope and the three remaining gyroscopes for a three axis state estimate. If all the gyroscopes are operating properly, the state estimates produced by the three processors will all agree. However, if one of the associated gyroscopes fails, the state estimates produced by the three processors will not agree. A voting mechanism may be implemented such that the processor producing the erroneous estimate shuts itself off. For further details concerning redundant failure prevention see U.S. Provisional Patent Application entitled FAULT-TOLERANT ARCHITECTURE FOR A PERSONAL VEHICLE, Ser. No. 60/105,069, filed on Oct. 21, 1998. 
     In another embodiment of the invention, if a gyro failure is detected, the signals to the wheel motors are automatically capped to limit the maximum rate of turn of the vehicle. Limiting the maximum rate of turn, limits the yaw rate and reduces the error arising from using a single axis state estimator. 
     In another embodiment of the invention, the roll angle is estimated by keeping track of the torque required to maintain zero pitch which corresponds to an estimate of ground slope and the amount of total turn since startup. For example, if ground slope is estimated at 10° up and then the machine is turned 90° left, roll can be estimated as 10° left. 
     Preferred embodiments of the invention may be implemented as a computer program product for use with a computer system or processor. Such implementation may include a series of computer instructions fixed either on a tangible medium, such as a computer readable media (e.g., a diskette, CD-ROM, ROM, or fixed disk) or transmittable to a computer system or processor, via a modem or other interface device, such as a communications adapter connected to a network over a medium. Medium may be either a tangible medium (e.g., optical or analog communications lines) or a medium implemented with wireless techniques (e.g., microwave, infrared or other transmission techniques). The series of computer instructions embodies all or part of the functionality previously described herein with respect to the pitch estimator. Those skilled in the art should appreciate that such computer instructions can be written in a number of programming languages for use with many computer architectures or operating systems. Furthermore, such instructions may be stored in any memory device, such as semiconductor, magnetic, optical or other memory devices, and may be transmitted using any communications technology, such as optical, infrared, microwave, or other transmission technologies. It is expected that such a computer program product may be distributed as a removable media with accompanying printed or electronic documentation (e.g., shrink wrapped software), preloaded with a computer system (e.g., on system ROM or fixed disk), or distributed from a server or electronic bulletin board over the network (e.g., the Internet or World Wide Web). 
     Although the invention has been described with reference to several preferred embodiments, it will be understood by one of ordinary skill in the art that various modifications can be made without departing from the spirit and the scope of the invention, as set forth in the claims below.