Abstract:
A digital sample filtering device comprising storage device including ROM and RAM memory for storing in an interlaced manner, coefficients of at least two filters along with for each coefficient, data indicating to which of the filters the each coefficient belongs; a multiplier for multiplying at least one of the coefficients by a sample and an accumulator for adding the partial sums of the multiplication results for each of the filters.

Description:
FIELD OF THE INVENTION 
     The invention relates to a digital filtering device within a digital signal processing system. The invention can be used notably to implement a number of digital filters in series. 
     DESCRIPTION OF THE RELATED ART 
     The implementation of digital filters often implies the use of a number of identical circuit elements resulting in a very high chip surface requirement. 
     SUMMARY OF THE INVENTION 
     It is an object of the invention to provide a digital sample filtering device comprising a storage device for storing, in an interlaced manner, the coefficients of at least two filters along with for each coefficient, data indicating to which of the filters the coefficient belongs; a multiplier for multiplying of one of the coefficients by a sample; and an accumulator for adding the partial sums of the multiplication results for each of the filters. 
     Such a multiplexing scheme enables a single multiplier to be used. Furthermore, the manner in which the data is stored in a ROM storage device allows the order in which the calculations are carried out to be controlled and the time of output of the filtered samples from the device to be set. 
     In a particular embodiment, the said storage device is a ROM containing, in an interlaced manner, the coefficients of the filters in addition to data, for each coefficient, indicating the filter to which the coefficient belongs. 
     It is a further object to provide a storage device which includes buffer registers, and which contains coefficients of a first and second filter in series. Still further, the device contains two RAM memories (2,3) the first of which (2) registers the samples (X1), whereas the second (3) registers the samples filtered by the first of the filters (FA). 
     In a particular embodiment, at least one of the filters carries out an oversampling, and the coefficients of filters following the filter which carries out an oversampling, are stored in a repeated manner in the storage device. 
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS 
     The invention will be better understood and other advantages and characteristics will become clear on reading the following description of a particular embodiment, taken only as a non-limitative example, making reference to the appended figure, of which: 
     FIG. 1 represents symbolically the oversampling carried out by the filters in the present example; 
     FIG. 2 represents schematically a circuit according to the invention; 
     FIG. 3 is a block diagram illustrating the operation of the circuit shown in FIG. 2. 
    
    
     DETAILED DESCRIPTION OF THE INVENTION 
     In the present embodiment, samples at frequency F s  are successively fed to two filters, FA and FB. The first filter FA is a symmetrical half-band filter, of the 133rd order type, which carries out an oversampling of factor 2. As a result of its inherent characteristics, this filter can be implemented by means of 33 coefficients. The second filter FB is a filter of the 48th order type, represented by means of 46 coefficients and which carries out an additional oversampling of factor 4. Therefore, the two filters in series oversample at a factor of 8. The principles of oversampling used by the filter are themselves well known and will not be described here. 
     FIG. 1 illustrates the oversampling by showing two samples of the input signals and the samples during the output of the two filters FA and FB. During a period F s , 33 multiplications must be carried out for the implementation of filter FA, and 2*46=92 for Th the implementation of filter FB, making a total of 125 multiplications. The circuit can therefore be operated using a clock with a frequency of at least 125*F s . For obvious simplification reasons, we shall choose a clocking frequency of 128*F s . 
     It should be noted that if the circuit of the present embodiment is implemented in an audio processing circuit, the clock frequency will be doubled depending on the mono or stereo nature of the signals to be processed. 
     The ratio between the number of multiplications to be carried out for FA and those for FB is approximately 1/3. A multiplication is carried out for FA, followed by three for FB and so on until the 46 coefficients for the filter FB are depleted. The second series of 46 coefficients is processed in the same way. 
     The table below shows the configuration of the coefficients in the ROM. 
     
         __________________________________________________________________________□□Addr.   Filt. Coef.    Addr.       Filt.          Coef.             Addr.                Filt.                    Coef.                       Addr.                           Filt.                              Coef.__________________________________________________________________________ 0 A  A0 32 A  A5 64 B   B1  96 B  B25 1 B  B0 33 B  B24             65 B   B2  97 B  B26 2 B  B1 34 B  B25             66 A   A17                        98 A  A25 3 B  B2 35 B  B26             67 B   B3  99 B  B27 4 A  A1 36 A  A9 B8 B   B4 100 B  B28 5 B  B3 37 B  B27             69 B   B5 101 B  B29 6 B  B4 38 B  B28             70 A   A18                       102 A  A26 7 B  B5 39 B  B29             71 B   B6 103 B  B30 8 A  A2 40 A  A10             72 B   B7 104 B  B31 9 B  B5 41 B  B30             73 B   B8 105 B  B3210 B  B7 42 B  B31             74 A   A19                       106 A  A2711 B  B8 43 B  B32             75 B   B9 107 B  B3312 A  A3 44 A  A11             76 B   B10                       108 B  B3413 B  B9 45 B  B33             77 B   B11                       109 B  B3414 B  B10    46 B  B34             78 A   A20                       110 A  A2815 B  B11    47 B  B35             79 B   B12                       111 B  B3616 A  A4 48 A  A12             80 B   B13                       112 B  B3717 B  B12    49 B  B36             81 B   B14                       113 B  B3818 B  B13    50 B  B37             82 A   A21                       114 A  A2919 B  B14    51 B  B38             83 B   B15                       115 B  B3920 A  A5 52 A  A13             84 B   B16                       116 B  B4021 B  B15    53 B  B39             85 B   B17                       117 B  B4122 B  B16    54 B  B40             86 A   A22                       118 A  A3023 B  B17    55 B  B41             87 B   B18                       119 B  B4224 A  A6 56 A  A14             88 B   B19                       120 B  B4325 B  B18    57 B  B42             89 B   B20                       121 B  B4426 B  B29    58 B  B43             90 A   A23                       122 A  A3127 B  B20    59 B  B44             91 B   B21                       123 B  B4528 A  A7 60 A  A15             92 B   B22                       124 A  A3229 B  B21    61 B  B45             93 B   B2330 B  B22    62 A  A15             94 A   A2431 B  B23    63 B  B0 95 B   B24__________________________________________________________________________ (Addr. = address; Filt. = Filter; Coef. = Coefficient) 
    
     AI refers to the coefficients for the first filter whilst BI refers to the coefficients for the second filter. 
     We note that the table contains the FB filter coefficients in a repetitive manner, these coefficients being used at a frequency of 2*Fs, given that filter FA oversamples with a factor of 2*Fs, given that filter FA oversamples with a factor of 2. 
     FIG. 2 is a functional diagram of the circuit complying with the present ambodiment. The ROM 1 contains essentially the information in Table 1; each coefficient is coded on 17 bits. An additional bit is allocated for each coefficient in order to indicate the filter to which it belongs. The ROM 1, which therefore has a size of 125*18 bits, is read sequentially. The filter identification bit determines the different multiplexings carried out in the rest of the circuit. The contents of the ROM forms a sequencing program for the operations within the circuits. 
     The circuit in FIG. 2 also includes a RAM 2, which registers the samples input in the FA (XI samples). The samples are coded on 19 bits, RAM 2 registers 67 samples for filter FA whilst RAM 3 registers 12 for filter FB, given the oversamplings that are carried out. 
     Given the symmetrical nature of filter FA, a first sample read in memory 2 is memorized in buffer register 4; a second sample is read in order to be added to the first, by means of adder 5. This sum of coefficients is then multiplexed, by a multiplexer, with one of the samples read from RAM 3. The multiplexer is controlled by the status of the identification bit in the filter read from ROM 1. Multiplexer 6 output is memorized in buffer register 7, whilst the coefficient read from ROM 1 is memorized in buffer register 8. 
     The contents of buffers 7 and 8 are multiplied by a multiplier 9, the result is then stored in buffer register 10 to be added, by adder 11, to the partial sum already carried out for the filter to which it corresponds. 
     The partial sum corresponding to filter FA is stored in buffer register 14. For reasons explained later (as the null coefficients and the filter&#39;s central coefficient are not stored in ROM 1), the circuit shown in FIG. 2 only calculates one result in two for filter FA. For this reason, only one buffer register is used at this point. 
     Filter FB supplies four results per half-period of F s , in other words for 46 multiplications. These four results are stored in shift register 12, made up of four buffer registers in series. These four results correspond to the partial sums which are cumulated during the calculations carried out for the last four coefficients (42 to 45) for filter FA. 
     These results are moving in series once the calculation has been carried out for the last coefficient. 
     Shift register 12 also loops onto multiplexer 13. As for multiplexer 6, multiplexer 13 is controlled, during the multiplication phases, by the status of the filter&#39;s identification bit. The two buffers, 12 and 14, receive the output from adder 11. All final results from either of the filters are stored in buffer 15. When the result belongs to filter FA, it is stored in RAM 3 to be used later on by filter FB. The results output from filter FB are available as output from buffer 15. 
     FIG. 3 is a block diagram showing the operation of the circuit shown in FIG. 2. To simplify the explanation, the processing of the two filters has been artificially separated. Index I corresponds to the order index for the coefficients in ROM 1; @(I) is the address of coefficient I. 
     In the present embodiment, the circuit is controlled by a microprocessor which is not shown. 
     The first step (21) consists in reading ROM 1 at address @(I), Index I having already been initialized to the appropriate value. The identification bit, for the filter for coefficient I, is tested during step 22 (coefficient AI for filter FA and BI for filter FB). Steps 23 to 29 refer to the first filter, whilst steps 30 to 33 refer to the second filter. 
     Step 23 refers to the reading of two samples in RAM 2. These are the two &#34;symmetrical&#34; samples which correspond to coefficient AI, filter FA being a symmetrical filter. These two coefficients are then added during step 24, multiplied by AI, the result is then added to the artiad sum in progress. Step 26 tests to see whether the last coefficient of FA has been processed. 
     If this is the case, the result of the final cumulation is stored in RAM 3, shift register 12 is reset to zero, Index I is also reset (steps 27 to 29 respectively) and the reading of ROM 1 is restarted. If this is not the case, I is incremented (step 35) and the reading of ROM 1 continues. 
     Step 30 corresponds to the reading of a sample of RAM 3 for the calculation corresponding to filter FB. The sample is multiplied by BI and cumulated with the corresponding partial sum which has already been calculated. A test is then carried out (step 32) to ensure that BI corresponds to a last coefficient (45) of FB. If this is the case, the four results of the successive cumulations are transmitted to the circuit output and cumulation register 14 is reinitialized. If this is not the case, I is incremented and the reading of ROM 1 continues. 
     The dotted double arrow in the diagram of FIG. 3 shows that steps 25 and 31 are carried out by the same circuit element. 
     Filter FA is, in the present case, a filter whose central coefficient is not null. This is the only non-null coefficient. A result of the oversampling of a factor two on the input of filter FA is that every second result output from the filter results solely from the multiplication of this central coefficient by a sample, all the other multiplications having a null result. In fact, if the sequence of the samples is: 
     x 0 ,x 1 ,x 2  . . . , 
     then filter FA processes: 
     x 0 , 0, x 1 , 0, x 2 , 0 . . . , 
     However, the coefficients for the filter are of type: 
     C 0 , 0, C 2 , 0 . . . 0,  central-1 ,  central+1 , 0 . . . , C n   
     Initially, the following result is calculated: 
     C 0  x 0  +C 2  x 1  + . . . 
     During the second alternation, the following calculation must be carried out. 
     C 0  *0+0*x 1  +C 2  *0+ . . . + central  *x i  . . . 0*x n   
     Only  central  *x i  is not null. 
     As a result, only one alternation in two is calculated by using the interlacing indicated. The case of the central coefficient is dealt with separately during step 36 in order to avoid a large umber of useless calculations being carried out by multiplier 9. The microprocessor (or equivalent) carries out the calculation and registers the results in RAM 3. 
     Of course, the invention is not limited to the embodiment described above. It can also be applied to a greater number of filters and to cases where there is no oversampling. Furthermore, the filters are not necessarily in series but can be arranged in parallel. 
     In a particular embodiment, a single RAM is provided for the two filters, which enables the addressing to be simplified.