BACKGROUND OF THE INVENTION 
     1. Field of the Invention 
     The present invention relates to a method and a device for detecting the tank fuel level of a motor vehicle. 
     2. Description of Related Art 
     Usually, for detecting a tank fuel level, a tank level sensor makes available a voltage signal as a function of the filling level, which is then evaluated by an instrument cluster, so that a driver may then be provided with a tank level display. Moreover, it is usual that a refueling process is also recorded with the aid of a tank fuel level sensor, by having an increase in the tank level by more than a predetermined boundary value evaluated as a sign of refueling. The tank level sensor is usually based on a potentiometer device, having a lever arm and a float gauge, in this context. 
     While this arrangement is technically simple and cost-effective to implement, it has the disadvantage that the lever usually has an upper dead-center position, as shown in  FIG. 1 , above which the tank level sensor signal U TSG     —     max  does not change any more, even in the case of a rising tank level, and a lower dead-center position, below which the tank level sensor signal U TSG     —     min  does not change any more, even in the case of a falling tank level. Consequently, there is an upper and a lower dead volume that cannot be detected, since the mechanical lever is at an end stop before this volume is reached. 
     Furthermore, deposits due to corrosion on the potentiometer path impair the accuracy and the reliability of such a tank level sensor. The corrosion problem intensifies without additional constructive measures, particularly when ethanol-based fuels are used. 
     A tank level sensor signal that is impaired in its reliability is not only uncomfortable for the driver, who is thus not able to estimate the cruising range to the next nearest filling station, but also leads to problems in the case of so-called FlexFuel systems, in which fuels having a different ethanol content are able to be used, and the control of the mixture is calculated as a function of the fuel used. For the calculation and determination of the ethanol content in the fuel used, detection of refueling using tank level sensor signals is used, among other things, in order to avoid unnecessary determination effort and calculation effort. Thus, a malfunction of the tank level sensor in such a FlexFuel system is able to impair the entire engine control. 
     Besides, the combustion of deviant fuels (such as E85 instead of gasoline) is able to be detected by monitoring changes in the engine response, such a fuel-type detection being admitted only after the detection of a refueling signal, for distinguishing actual fuel-conditioned changes in the engine response from sensor errors. In this connection, methods for detecting the fuel type are also conceivable which go back directly to the tank level signal or its change. 
     If an accurate and reliably detected tank level signal could be provided, it would be conceivable that exhaust gas-relevant pilot control functions and control functions would be supported by the tank level signal, and would thus use an additional, reliably detectable input parameter. This would further reduce the susceptibility, particularly of the exhaust gas-relevant control and regulating functions with respect to malfunctions of individual sensors or components. 
     BRIEF SUMMARY OF THE INVENTION 
     It is therefore an object of the present invention to provide a more accurate, more reliable method for tank level detection, in which, by using components that are already present in the motor vehicle, at most minor additional measures are required compared to the usual detection of the tank level. 
     Consequently, the present invention provides a method for detecting the tank level of a motor vehicle having an internal combustion engine, including the following steps:
         ascertaining the tank level sensor signal of a tank level sensor,   determining a calculated tank level as a function of a fuel quantity consumed by the internal combustion engine, and   providing a corrected tank level signal as a function of the tank level sensor signal and the calculated tank level.       

     A reliable tank level signal is provided by the method according to the present invention, which is able to be used for various control functions of the engine operation, without requiring the use of technically costly sensors or the like. Determining the fuel quantity consumed by the internal combustion engine may be done, in this connection, by evaluating signals which are already being monitored and ascertained in the internal combustion engine in any case, so that no additional components have to be installed to carry out the method according to the present invention. 
     Furthermore, no additional measures have to be carried out in the method according to the present invention, compared to the usual, inaccurate and unreliable detection of the tank level, and consequently, no additional costs are created as compared to the usual tank level detection. 
     According to one example embodiment of the present invention, the tank level sensor signal is smoothed and/or filtered, especially taking into account boundary conditions such as with respect to the vehicle position, the vehicle acceleration and the time interval since the last refueling. Artifacts in the raw data of the tank level sensor signal, which are conditioned upon the electrical and mechanical properties of the tank level sensor or by the sloshing of fuel may thereby be removed, and consequently, the accuracy of the tank level sensor signal is able to be improved. According to one example embodiment of the present invention, the tank level sensor signal may be linearized in this instance. 
     In order to be able to provide simply a calculated tank level, without additional components and sensors, according to one example embodiment of the present invention, the determination of the calculated tank level takes place by using the determination of the intake air quantity at a known fuel/air ratio and/or using the determination of the opening times of the injection valves and of the fuel pressure, and calculating a tank level from this. 
     In order to be able to provide as accurate as possible a value for the calculated tank level, the determination of the fuel quantity consumed by the internal combustion engine may further be carried out as a function of engine operating conditions, such as the engine temperature and/or the tank ventilation and/or the operating state of a lambda probe. 
     For the simple recalculation of the tank level sensor signal into a value for the tank level, which may then be compared to a calculated tank level, it is basically preferred that the raw data of the tank level sensor signal be linearized. However, if this is not possible for a certain case, based on the shape of the fuel tank or the properties of the tank level sensor used, it is also possible to use a nonlinear tank level sensor signal (particularly a smoothed or filtered one), one being then able to ascertain a value for the tank level from the tank level sensor signal, with the aid of a characteristics curve that was stored ahead of time in the engine control unit, without great additional calculation costs. 
     According to one example embodiment of the present invention, the slope of the tank level sensor signal is corrected as a function of the slope of the calculated tank level, so as to ascertain the corrected tank level signal. Such a slope correction may, for instance, be made by ascertaining, at two specified times, in each case one value for the tank level from the tank level sensor signal and a calculated tank level, and comparing to one another the difference of the two tank levels determined from the tank level sensor signals and the two calculated tank levels. If the difference of the tank level determined from the tank level sensor signals deviates from the difference of the calculated tank levels, the tank level sensor signal that was ascertained last is appropriately corrected and provided as the corrected tank level signal. 
     In this connection, in particular, a malfunction of the tank level sensor is emitted if the correction value for the slope of the tank level sensor signal exceeds a specified boundary value. Thereby a failure of the tank level sensor may be easily detected, and thus the reliability of the tank level sensor signal is able to be improved. 
     According to one example embodiment of the present invention, a check of the plausibility of the tank level sensor signal is also carried out, in order to detect malfunctions of the tank level sensor early, the plausibility check outputting a malfunction of the tank level sensor if the calculated fuel quantity used deviates by a certain amount or more from a fuel quantity ascertainable from the tank level sensor signal. A malfunction of the tank level sensor may especially be output if the tank level sensor signal is at its upper dead-center, and the calculated fuel quantity used since the last refueling is greater than the upper dead volume of the tank level sensor, or if the tank level sensor signal is at its lower dead-center and the calculated fuel quantity used since reaching the lower dead-center is greater than the lower dead volume of the tank level sensor. 
     Moreover, the present invention provides a device including an internal combustion engine, a fuel tank equipped with a tank level sensor, and an engine control unit, the engine control unit being developed in such a way that it carries out a method according to the present invention, for detecting the tank level, as described above. 
    
    
     
       BRIEF DESCRIPTION OF THE SEVERAL VIEWS OF THE DRAWING 
         FIG. 1  shows a graph which schematically illustrates the voltage signal emitted by a conventional, potentiometer-based tank level sensor as a function of the tank level. 
         FIG. 2  shows a schematic representation of the engine components and the sensors used in the method according to the present invention for tank level detection. 
         FIG. 3  shows a graph which shows a linearized tank level sensor signal together with a tank level calculated from the engine fuel consumption according to the present invention. 
         FIG. 4  shows a graph illustrating a slope correction of the tank level sensor signal. 
     
    
    
     DETAILED DESCRIPTION OF THE INVENTION 
     As shown schematically in  FIG. 2 , an engine  10  is connected to an engine control unit  14  in such a way that various engine components, such as fuel injectors  18 , intake manifolds  20  and a lambda probe  22  are monitored and controlled by engine control unit  14 . Furthermore, a fuel tank  12  has a tank level sensor  16 , which is developed, for instance, as a usual potentiometer device having a float and a lever, and which emits a voltage signal U TSG  to engine control unit  14  that is a function of the tank level. 
     In addition, there are further sensors  24  connected to engine control unit  14 , for instance, for measuring the engine temperature, the acceleration and the travel speed of the motor vehicle and the like. 
     The signal U TSG  emitted by tank level sensor  16  is smoothed by suitable filters and is linearized (U TSG     —     lin ), as shown in  FIG. 3 . Artifacts caused, for instance, by sloshing of the gasoline in the tank, can be removed by low-pass filtering, in this connection. Furthermore, the vehicle&#39;s position and the vehicle acceleration, which influence the liquid level in the vicinity of the tank level sensor float, are able to be taken into account by, for example, ascertaining correction values for the vehicle position and/or the vehicle acceleration from a stored characteristics map, and adding them to the filtered tank level sensor signal. Alternatively, the evaluation or the valuation of the tank level sensor signal may be suppressed or interrupted in such critical vehicle states. 
     At the same time, the fuel volume consumed in this time interval by engine  10  is calculated at regular time intervals, a pressure sensor in intake manifold  20  measuring the air required by engine  10 , and lambda probe  22  recording the fuel/air ratio. Using the lambda value and the air mass consumed, the fuel quantity consumed in the internal combustion engine may be calculated from the equation 
                 Q   engine     =         Q   airt     *   λ       Q   stoichiometric         ,         
where Q engine  is the fuel quantity consumed by the engine, Q air  is the air quantity consumed by the engine, λ is the fuel/air ratio and Q stoichiometric  is the stoichiometric number. In making this calculation, additional boundary values, such as the engine temperature, the tank ventilation or the activity of the lambda probe may also be drawn upon.
 
     From the fuel quantity consumed that is calculated in this manner, a tank level F calc  is determined which, as shown in  FIG. 3 , is able to be compared to linearized tank level signal U TSG     —     lin  of tank level sensor  16 , for the same time period. Consequently, using calculated tank level F calc , in the range of the upper and the lower dead volumes, in which usually no exact tank level signal was able to be detected, the tank level may now also be given with improved accuracy, with the aid of signal F calc  that is calculated from the engine&#39;s fuel consumption. 
     Furthermore, tank level signal F calc , calculated from the engine&#39;s fuel consumption, is also able to be used for the correction and the plausibility check of the linearized tank level sensor signal U TSG     —     lin , as shown in  FIG. 4 . In this case, the absolute deviation of linearized tank level sensor signal U TSG     —     lin  from tank level signal T calc , calculated from the engine&#39;s fuel consumption, is compared to specified boundary values, and it is determined that a malfunction of tank level sensor  16  occurred if the deviation of signals U TSG     —     lin  and F calc  from each other is greater than the predefined boundary value respectively. Such a malfunction of tank level sensor  16  may then be signaled to the driver, for instance, by lighting up a warning signal. 
     An additional plausibility check of linearized tank level sensor signal U TSG     —     lin  may be made in the vicinity of the upper and the lower dead volume. A malfunction of tank level sensor  16  is also signaled to the driver if tank level sensor signal U TSG  is at its upper dead-center U TSG     —     max , and the calculated consumed fuel quantity since the last refueling is greater by a certain tolerance value than the upper dead volume of tank level sensor  16 , or if tank level sensor signal U TSG  is at its lower dead-center U TSG     —     max  and the calculated consumed fuel quantity since reaching this signal value U TSG     —     min  of tank level sensor signal U TSG  is greater by a certain tolerance value than the lower dead volume of tank level sensor  16 . 
     When it has become certain that there is no malfunction of tank level sensor  16 , the slope of tank level sensor signal U TSG     —     lin  may be corrected in a given time interval to the extent that it agrees with the slope of tank level F calc  calculated from the engine&#39;s fuel consumption for the same time interval. The accuracy of tank level sensor signal U TSG  is able to be improved by this correction, and consequently, in particular, the detection of a refueling (which is based upon an upward change in tank level sensor signal U TSG  by a specified minimum value, and is thus a function of the slope of tank level sensor signal U TSG ) may take place more reliably. Furthermore, with the aid of the corrected tank level sensor signal, an accurate tank level signal may be provided, without having to determine calculated tank level F calc  continuously. 
     Consequently, the method according to the present invention has the advantage that, without the necessity for new sensors and measuring methods, and only by using components that are already present in the engine compartment and in the fuel tank, a tank level signal is able to be provided which is substantially more accurate and reliable than was possible up to now. Thus, an altogether more reliable and more robust engine control is made possible, especially in FlexFuel systems, in which both a refueling signal and a tank level signal are able to be used in controlling the mixture.
A method for detecting the tank fuel level of a motor vehicle includes: ascertaining the tank level sensor signal (U TSG) of a tank level sensor, determining a calculated tank level (F calc) as a function of a fuel quantity consumed by the internal combustion engine, and providing a corrected tank level signal as a function of the tank level sensor signal (U TSG) and the calculated tank level (F calc).