Abstract:
A spark timing control circuit for eliminating abnormal vibrations in a spark ignition, fuel-injected internal combustion engine. The vibrations are created by twisting vibrations of the driving system ocurring when the engine operation is switched from deceleration to acceleration. In such cases, spark timing for the engine is calculated using a smoothed parameter of at least one of the vehicle speed and a fuel injection time duration which itself is calculated as a function of intake air flow rate.

Description:
BACKGROUND OF THE INVENTION 
     The present invention relates to a spark timing control apparatus for use with a spark ignition internal combustion engine, and more particularly to a spark timing control system of the type wherein a variable, corresponding to the engine speed, is used to determine the spark timing. More particularly, the present invention relates to a spark timing apparatus of the above type and having a device for preventing abnormal vibrations of the engine due to fluctuations in spark timing corresponding to fluctuations in the sensed engine speed occurring for a certain time after the engine operation is switched from deceleration to acceleration. 
     A spark timing control apparatus has been proposed which includes a microcomputer which calculates a basic fuel injection time duration using sensed current engine speed and sensed current flow rate of intake air into the engine. The basic fuel injection time duration is the adjusted according to other parameters, such as, for example, constants determined by the temperature of the engine cooling water, the battery voltage and the output of an oxygen meter provided in the exhaust system. The microcomputer within the control apparatus then retrieves the value of spark timing determined by engine speed from an engine speed--spark timing advance angle characteristic stored in a ROM when either (1) a throttle switch is detected to be on (i.e., the throttle valve is detected to be completely closed), or determined by engine speed and fuel injection time from an engine speed-fuel injection time-spark timing advance characteristic when the throttle switch is detected to be off (i.e., the throttle valve is detected to be not completely closed). Each time the crankshaft is rotated through 360 degrees, fuel injection is effected for the calculated injection time duration and spark ignition is effected at a calculated angular position before the top dead center position each time a certain numbers of references pulses are inputted into the computer. 
     When the engine operation is switched from the deceleration state where the throttle valve is closed to the acceleration state where the throttle is opened, the engine speed fluctuates for a time due to twisting vibrations of the driving system, including the engine and transmission. These vibrations are created by the fact that the driving system, which has been driven so far by the vehicle body during deceleration, begins to drive the vehicle body in an opposite sense during acceleration. Thus the value of engine speed sensed by the crank angle sensor fluctuates according to the frequency inherent in the driving system. 
     As described above, the optimal spark timing angular value when the throttle valve is open is retrieved according to the sensed current engine speed and the corrected fuel injection time duration, which is calculated according to engine speed. Thus when the engine speed fluctuates, the corrected fuel injection time duration also fluctuates so that the spark timing retrieved from the ROM according to the sensed actual engine speed and the fuel injection time duration greatly fluctuates. When the spark timing fluctuates, the output torque of the engine fluctuates also so that with prior control systems, for a short time after the vehicle operation changes from deceleration to acceleration, the vehicle tends to fluctuate in the fore-and-aft direction of the vehicle, resulting in an uncomfortable feeling for the passagers. 
     It is therefore an object of the present invention to provide a spark timing control apparatus for use with a spark ignition engine which prevents abnormal vibrations of the vehicle due to fluctuations of spark timing. 
     SUMMARY OF THE INVENTION 
     The present invention provides a spark timing control apparatus for use with a spark ignition combustion engine, comprising means for sensing the engine speed to output a first parameter indicative of the engine speed, and means for calculating a fuel injection amount using the first and a plurality of second operational parameters to output a third parameter indicative of the fuel injection amount. The apparatus also comprises means for smoothing at least one of the first and the plurality of second parameters and means for calculating a spark timing using the first and the plurality of second parameters at least one of which is smoothed by the smoothing means. 
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS 
     The features and advantages of the present invention will be apparent from the following description of preferred embodiments thereof when taken in conjunction with the accompanying drawings in which: 
     FIG. 1 is a schematic diagram of a conventional spark timing control system by which the present invention is carried out; 
     FIG. 2 shows the relationship between engine speed and spark timing advance angle before TDC; 
     FIG. 3 shows the relationship between engine speed, fuel injection time duration and spark timing advance angle before TDC; 
     FIG. 4 is a timing chart illustrating crank angle sensor output, first-register contents, first-counter contents, and fuel injection time duration; 
     FIG. 5 is a timing chart illustrating the relationship among crank angle sensor output, clock pulse signal, and second counter contents; 
     FIG. 6 is a flowchart showing execution of the calculation of the fuel injection time duration; 
     FIG. 7 is a flowchart showing execution of the calculation of the spark timing; 
     FIG. 8 is a two-dimensional graphic illustration of FIG. 3; 
     FIG. 9 is a flowchart modification of FIG. 6 showing calculation of the fuel injection time duration; 
     FIG. 10 is a flowchart modification of FIG. 7 showing calculation of the spark timing; 
     FIG. 11 is a further flowchart modification of FIG. 6; 
     FIG. 12 is a further flowchart modification of FIG. 7; and 
     FIG. 13 is an illustration of the respective characteristics of the basic fuel parameter, engine speed, spark timing advance angle before TDC, and vehicle acceleration, especially in the transient area after the vehicle is switched from deceleration to acceleration. 
    
    
     DETAILED DESCRIPTION OF PREFERRED EMBODIMENTS 
     Referring to FIG. 1, there is shown a spark timing control apparatus which carries out the spark timing control in accordance with the present invention. The apparatus includes a crank angle sensor 1 which produces a unit pulse each time the crankshaft, not shown, rotates through a unit angle, for example one degree, and a reference angle pulse each time the crankshaft rotates through a reference angle (120 degrees in the case of a 4-cycle-6 cylinders, and 180 degrees in the case of a 4-cycle-4-cylinders). The apparatus also includes an air flowmeter 2 which determines the flow rate of intake air into the engine, not shown, and a throttle switch 3 which detects whether or not the throttle valve, not shown, is completely open. 
     The apparatus further includes a microcomputer 4 which includes a clock pulse generator 5, an input/output (I/O) control unit 6, a central processing unit 7, a read only memory (ROM) 8, and a random access memory (RAM) 9. The apparatus also includes a fuel injection valve 10 connected to the I/O control circuit 6. The apparatus also includes a ignition device 11 which includes a transistor 12 connected to the I/O control circuit 6, an ignition coil 13 connected to the transistor 12, a distributer 14 connected to the ignition coil 13, and a plurality of spark plugs 15. The circuit may also include well known protection means such as a diode circuit (not shown). 
     In operation, the microcomputer 4 counts unit pulses supplied from the crank angle sensor 1, during a fixed time interval through the I/O control circuit 6 to calculate the engine speed N. The output of the air flowmeter 2 is subjected to analog to digital conversion at the I/O control circuit 6 to provide a signal Q indicative of the flow rate of intake air. The microcomputer operates in response to a stored program, stored in ROM 8, to determine the basic fuel injection amount. The calculation repetition rate may be made in response to the rotation of the engine crankshaft or at a fixed time interval. Most preferable, the microcomputer 4 calculates at constant time intervals, for example 10 ms, a basic fuel injection amount or pulse duration T p  and then a corrected fuel injection pulse amount of duration T i  given by 
     
         T.sub.p =K.sub.o (Q/N)                                     Eq. 1 
    
     
         T.sub.i =T.sub.p (1+K.sub.1)K.sub.2                        Eq. 2 
    
     where K o  is a constant determined according to the characteristics of the fuel injection valve 10 and the air flowmeter 2, K 1  is a correction constant determined according to the temperature of engine cooling water and the output voltage of a vehicle battery, and K 2  is a correction constant determined according to the oxygen sensor provided in the exhaust gas system. 
     The injection pulse duration T i , thus calculated, is set in a first register 6a of the I/O control circuit 6. The spark timing calculation may be preformed in the main program of the microcomputer 4 whereas the T p  calculation is done as an interrupt routine each time the computer system clock counts a predetermined time interval, for example, 10 ms. The main program is sometimes referred to as the background program. 
     The calculation of the spark timing may be done a number of ways as explained more fully below. Generally, it is first determined whether or not the throttle switch 3 is on. In one embodiment, when the switch 3 is on, that is, when the throttle valve is completely closed, a value of spark timing corresponding to the sensed engine speed N is retrieved from the characteristic data of FIG. 2 stored in the ROM 8. The retrieved data is stored in a second register 6b of the I/O control circuit 6. On the other hand, when the throttle switch 3 is off, that is, when the throttle valve is not completely closed, the calculated value T p  is smoothed or weighted so as to provide T p  &#39; as follows: ##EQU1## where n is a predetermined constant, and RAM.E 1  is the value of T p  obtained during the previous calculation and stored in the address E 1  of the RAM 9. Thus, the spark timing is determined by the smoothed injection time duration T p  &#39; and the sensed engine speed N from the characteristics of FIG. 3 stored in the ROM 8. 
     The value of the spark timing advance, thus calculated, is then stored in the second register 6b of the I/O control circuit 6. 
     The I/O control circuit 6 drives the fuel injection valve 10 for fuel injection according to the contents of the first registor 6a each time the crankshaft rotates; each time three reference angle pulses are inputted into the I/O control circuit 6 (in the case of 6-cylinder engine), or each time two reference angle pulses are inputted into the I/O control circuit 6 (in the 4-cylinder engine). For example, as shown in FIG. 4, each time three reference angle pulses S 1  are inputted into the I/O control circuit 6 in the case of the 6-cylinder engine, the contents A 1  of the first register 6a are set into a first counter 6c of the I/O control circuit, at which time the fuel injection valve 10 is formed. The counter 6c counts down in response to clock pulses of a high frequence clock which is available from the clock pulse generator 5. The clock pulses have a very short period compared with that of the reference angle pulse signal from the crank angle sensor 1, as may be seen in FIG. 5. These clock pulses are connected in counter 6c, and, when the contents of the counter 6c become zero the fuel injection valve 10 is shut off. The time duration during which the fuel injection valve 10 is open equals the fuel injection pulse duration Ti (see FIG. 4). 
     Each reference angle pulse S 1  is produced at a fixed angular position before TDC, for example, 70 degrees. The I/O control circuit 6 drives the ignition device 11 each time a reference angle pulse S 1  is inputted thereto according to the contents of the second register 6b. For example, as shown in FIG. 5, the reference angle pulse S 1  is inputted at an angular position of 70° before the top dead center T d . In response to this signal, the contents B 1  of the second register 6b is set into a second counter 6d. Counter 6d receives and counts down the clock pulses having a very short period compared with that of the reference angle pulse signal S 1 . At the same time, the electrical current begins to flow through the transistor 12 and the ignition coil 13. When the contents of the second counter 6d becomes zero, the transistor 12 is turned off, thereby performing a spark ignition. In this connection, the crank angle B&#39; from the spark timing T s  to the top dead center T d  designates a spark timing advance angle before T d . 
     FIGS. 6 and 7 illustrate one method of programming the microcomputer 4 to effect operation of the control apparatus. 
     Referring to FIG. 6, a flow chart of the interrupt routine is shown for calculating the injection pulse durations T i . At the step P 1 , the sensed current engine speed N and the flow rate of intake air Q are read into the I/O control circuit 6, and then at the step P 2 , T p  is calculated in the CPU 7 according to Equation 1. At step P 3 , it is determined whether or not the contents of RAM 9 at the address E 1  are zero, i.e., the value of T p  calculated during the previous calculation. When the determination indicates NO, the program proceeds to the step P 4  where it is determined whether or not the absolute value of the difference &#34;T p  -RAM.E 1  &#34;, where RAM.E 1  is the latest contents of T p  stored at the address E 1  of the RAM 9, is greater than a predetermined value M 1 . If the determination is NO, the program proceeds to the step P 5  where ##EQU2## is calculated and the result is stored in the address of RAM.E 1 . As described before, the calculated duration T p  &#39; consists of the sum of the weighted latest value stored in RAM.E 1  and the T p  calculated this time and weighted. When this routine of FIG. 6 is repeated every 10 ms, the appropriate value of n is a value within the range of 32 to 128, preferably 64. 
     On the other hand, if the determination at the step P 3  is YES, which indicates that the engine is just starting and an initial calculation is made, at which time the contents at the RAM address E 1  is 0, the program proceeds to the step P 6  where the value of T p  (calculated at the step P 2 ) is written in the RAM address E 1 . 
     If the determination at step P 4  is YES, it indicates that the difference in the absolute value of (T p  -RAM.E 1 ) is very great, and corresponds to a sudden change in the optimal value of spark timing, such as, for example at the moment when the throttle valve goes from a closed to open position. In such a situation, it is necessary to suddenly change the spark timing to follow a new optimal value so that the program proceeds to the step P 6  where the value of T p  as calculated at P 2  is written in the RAM address E 1 . 
     At the step P 7 , the actual fuel injection pulse duration T i  =T p  (1+K 1 )K 2  is calculated according to the value T p  calculated at the step P 2  and the result is set in the first register 6a of the I/O control circuit 6. After step P 7  the interrupt routine returns to the main program shown by the flowchart of FIG. 7. 
     When the main program of FIG. 7 is first started, various parameters are initialized such as, for example, E 1  =0. After initialization, at the step P 8 , it is determined whether or not the throttle valve is completely closed. If the determination is YES, the program proceeds to the step P 9  and calculates a spark timing corresponding to the actual engine speed N according to the characteristics of FIG. 2 stored in the ROM 8, by using a table look-up method. 
     On the other hand, when the determination is NO at the step P 8 , a spark timing is determined at the step P 10  corresponding to the contents of T p  or T p  &#39; stored at the RAM address E 1  and the sensed engine speed according to the FIG. 3 characteristics stored in the ROM 8. At the step P 11 , the value of the spark timing calculated at the step P 9  or P 10  is set in the second register 6b of the I/O control circuit 6. At the step P 12 , other calculations may be performed and the main program loops back to step P 8  to repeat the sequence. Each time a reference angle pulse is inputted to the microcomputer 4, the ignition device 11 is operated to count down the contents of the second register 6b as shown in FIG. 5. 
     The FIG. 3 characteristics can be changed into a two-dimensional representation such as shown in FIG. 8 in which each of the numeral values with a dot before it indicates a spark timing advance angle in degrees before TDC and each of the curves passes through equal spark timing angle degrees before TDC. In FIG. 8 when the gradient of the spark timing corresponding to changes in T p  is great and the gradient of the spark timing corresponding to changes in N is small, only T p  is required to be smoothed as shown in FIGS. 6 and 7. In a similar fashion, it is possible to smooth the value of engine speed N using a formula such as that shown in equation 3 with N replacing T p  and the contents stored in a designated register E 2 . When the gradient of spark timing corresponding to changes in T p  is small and the gradient of spark timing corresponding to changes in N is great, only N is required to be smoothed. When the gradient of spark timing corresponding to changes in both N and T p  is great, both N and T p  should be smoothed. 
     FIGS. 9 and 10 illustrate another method of programming the microcomputer 4 to effect operation of the control apparatus. FIG. 9 is an interrupt routine similar to that of FIG. 6, and FIG. 10 is a main program similar to that of FIG. 7. In steps P 13  and P 14  the values of Q and N are read and T P  calculated. Memory location E 2  is then examined in step P 15 , and if equal to zero, the value of N is written into location E 2  in step P 18 . Otherwise the program proceeds to step P 16  and the difference value (absolute value) N-RAM.E 2  is compared with a predetermined constant M 2 . If the difference value is less than M 2  the program performs a smoothing operation using a formula similar to equation 3, namely, ##EQU3## The smoothed value of N&#39; is stored in RAM.E 2 . The program then proceeds to step P 19  to calculate Ti. 
     In FIG. 10, a main program similar to that of FIG. 7 is illustrated with steps P 22  and P 21  utilizing the smoothed value of N&#39; as stored in RAM.E 2 . 
     FIGS. 11 and 12 illustrate another method of programming the microcomputer 4 to effect operation of the control apparatus. FIG. 11 combines the smoothing operation of FIGS. 6 and 9. In steps P 30  and P 31  the value of Q and N are read and T P  calculated. Steps P 33  -P 36  perform the T P  &#39; smoothing operation similar to steps P 3  -P 6  of FIG. 6. Further Steps P 37  -P 40  perform the smoothing operation of N&#39; similar to steps P 15  -P 18  of FIG. 9. In step P 41 , the fuel injected pulse amount Ti is calculated, and the program returns to the main program illustrated in FIG. 12. 
     In FIG. 12 the value of RAM addresses E 1  and E 2  are utilized in steps P 46  and P 47  as shown. Thus the smoothing operation is utilized for both T P  and N and for deriving the ignition timing. 
     In FIG. 13, the area, designated by X, situated on the left-hand side of a vertical straight broken line represents a time during which a vehicle is decelerated whereas the area, designated by Y, situated on the right-hand side of the vertical broken line represents a time during which the vehicle is accelerated. As will be seen from this figure, for a time period after the vehicle traveling conditions have changed from deceleration to acceleration, fluctuations in acceleration S 9  occurring in the fore-and-aft direction of the vehicle, in spark timing advance angle S 8 , in engine speed S 7  and in the basic fuel parameter T P  are greatly reduced, as shown in solid lines on the acceleration side, the broken line portions for S 7 , S 8 , S 9  and T P  indicating their respective characteristics without using the smoothing circuits. 
     It is clear that the calculation of the spark timing may be done using both a smoothed engine speed signal N&#39; and a smoothed basic fuel injection pulse duration signal T p  &#39;, or the spark timing may be calculated using either a smoothed basic fuel injection pulse duration signal T p  &#39; and an unsmoothed engine speed signal N, or an unsmoothed basic fuel injection pulse duration signal T p  and a smoothed engine speed signal N&#39; to reduce fluctuations such as mentioned above. In this particular embodiment, the smoothing time constant should be of a value such as to sufficiently smooth fluctuations having very short periods such as mentioned above and as to substantially follow required changes in the engine speed signal and the basic fuel injection pulse duration signal. In the present invention, smoothed values are used for calculation only when the throttle valve is open so that N and T p  do not show sudden changes except for during the time when the fluctuations occur, as mentioned above. 
     While the invention has been described with respect to preferred embodiments thereof, various changes and variations thereof could be made by those skilled in the art without departing from the scope and spirit of the invention as set forth in the attached claims.