Abstract:
A decoder for decoding a delta-modulated code represented with binary digit &#34;1&#34; or &#34;0&#34; to convert it into an analog signal, wherein when the delta-modulated code takes the first value (&#34;1&#34; or &#34;0&#34;), a positive pulse signal is applied to an integrator to increase its accumulated value by a constant value and when the delta-modulated code takes the second value (&#34;0&#34; or &#34;1&#34;), a negative pulse signal is appied to the integrator to decrease its accumulated value by the constant value, and this accumulated value of the integrator is outputted as an analog signal which corresponds to a code train of the delta-modulated code. The decoder is characterized in that it has a pulse width modulater which limits an effective pulse width of the pulse signal by performing pulse width modulation of the positive or negative pulse signal in response to a control signal.

Description:
This application is a continuation of application Ser. No. 222,769 filed on July 22, 1988, now abandoned. 
    
    
     BACKGROUND OF THE INVENTION 
     This invention relates to a decoder for a delta-modulated code and, more particularly, to the same which decodes the delta-modulated code obtained from delta modulation of an analog signal to convert it into an original analog signal. 
     The delta modulation coding system is a coding system which utilizes very simple hardware that does not require an A/D converter and is useful for digitization of, for example, audio signals. 
     FIG. 13 is a circuit configuration showing a conventional delta modulation system. An analog signal is inputted to an input terminal 101 and is passed through a low pass filter 102 designed to cut high frequency components and thus limit the pass bandwidth. An analog signal with limited bandwidth is passed through a coupling capacitor 103 in order to supply its alternating components to a plus input terminal of a comparator 107. A resistance 105 and a variable resistor 106 are included and determine a direct current voltage level of an input signal line 104 and this voltage level is set generally at 1/2 of the power supply voltage Vcc. An output signal from a flip-flop 108 is integrated by a resistance 110 and a capacitor 111 and the integrated signal is supplied to a minus input terminal of the comparator 107 through a signal input line 112. The comparator 107 compares magnitudes of the two inputted signals and outputs a high voltage (high level) at its output terminal when the signal at the plus terminal is larger, or outputs a low voltage (low level) when the signal at the minus terminal is larger respectively. The output of the comparator 107 is supplied to an input of the flip-flop 108. The flip-flop 108 receives the output signal of the comparator 107 in synchronization with a clock signal applied to a clock terminal 109 and outputs nearly the same high level as the input (voltage approximately equal to Vcc) or the same low level (the grounded voltage, usually 0 volt) and holds the condition as it is until arrival of the next clock. The output voltage of the flip-flop 108 and the relatively high resistance 110 configure a dummy constant current source, and thereby the capacitor 111 is charged up. 
     Now, signal waveforms on two signal lines 104 and 112 of the comparator 107 are shown in FIG. 14. When a signal 200 is applied to the input signal line 104, a signal waveform on the input signal line 112 becomes as shown with numeral 201. At this time, a delta-modulated code train 202 is outputted at the output terminal of the flip-flop 108. This signal is processed in a digital signal processing portion 113. 
     An output signal of the delta-modulated code of the digital signal processing portion 113 is supplied to a flip-flop 114 to be received in synchronization with a clock signal applied at a clock terminal 115. An output of the flip-flop 114 is integrated by a relatively high resistance 116 and a capacitor 117 to convert it into an analog signal. When the output of the flip-flop 114 is a code train 202, a signal waveform 201 is obtained as shown in FIG. 14. This signal is formed in stairs and is smoothed by an analog low pass filter 119 and then an analog signal is outputted at an output terminal 120. 
     Now, in the digital signal processing portion 113, the signal is passed through a digital low pass filter and then is decimated (processing of lowering a sampling frequency) and is converted into a normal PCM (Pulse Code Modulation) code and thereafter is subjected to a variety of processing. However, when an inputted signal waveform is outputted as it is in such a case as digital delay, conversion of the signal into PCM code is not necessary. 
     The delta modulated code obtained in the above delta modulation coding system is a code train of &#34;1&#34; and &#34;0&#34;. In order to perform the normal digital signal processing of &#34;1&#34; and &#34;0&#34;, the decimation with the digital low pass filter and the conversion of the signal into the usual PCM signal is required. Therefore, there is a problem in which the required circuit configuration becomes complicated and expensive. 
     SUMMARY OF THE INVENTION 
     The present invention has been made to solve the above problem, and therefore it is an object of the present invention to provide a decoder for delta-modulated code which can perform, for example, product and sum operations which are the basis of digital signal processing in the decoding stage without converting the delta-modulated code into a PCM signal, by using very simple hardware. 
     The decoder for a delta-modulated code according to the invention is for decoding the delta-modulated code that is represented with the binary digit &#34;1&#34; or &#34;0&#34; into an analog signal. When the deltamodulated code is the first value (&#34;1&#34; or &#34;0&#34;), a positive pulse signal is given to an integrator to increase its accumulated value by a constant value and when the delta-modulated code is the second value (&#34;0&#34; or &#34;1&#34;), a negative pulse signal is given to the integrator to decrease its accumulated value by the constant value, and this accumulated value of the integrator is outputted as an analog signal which corresponds to a delta-modulated code train. In this decoder, a positive or negative pulse signal is pulse-width-modulated in response to a control signal to supply it to the integrator to perform product and sum operations with simple hardware. 
     In the present invention, the pulse width modulation means limits an effective pulse width of the positive or negative pulse signal in response to the control signal, thereby varying an increase or decrease value in increasing or decreasing an integrator accumulated value in response to a logical value of the delta-modulated code, and thus an amplitude of an analog output signal corresponding to the delta-modulated code train is varied. As a result of this processing, the amplitude of the above analog output signal becomes an inputted delta-modulated code multiplied by a predetermined value corresponding to the above control signal. 
     As mentioned above, according to the present invention, the product and sum operations which constitute the basis of the digital signal processing are performed by a very simple circuit configuration in decoding of the delta-modulated code. Among other things, the multiplier in the product and sum operations can be varied in response to the control signal given to the pulse width modulation means, therefore, this enables dynamic processing of the signal. Accordingly, this technology can be applied to a digital attenuator, mixing of a plurality of signals, or fade-in fade-out of two signals. 
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS 
     The present invention will become more fully understood from the detailed description given hereinbelow and the accompanying drawings which are given by way of illustration only, and thus are not limitative of the present invention and wherein: 
     FIG. 1 is a circuit diagram showing a first embodiment of the present invention; 
     FIG. 2 shows signal waveforms at each part of the circuit of FIG. 1; 
     FIG. 3 shows one example of the waveforms subjected to attenuation by pulse width modulation; 
     FIG. 4 shows one example of a circuit diagram for generating the control signal to perform the pulse width modulation in the circuit of FIG. 1; 
     FIG. 5 shows waveforms illustrating an input signal and an output signal of the circuit shown in FIG. 4; 
     FIG. 6 is a circuit diagram showing a second embodiment of the present invention; 
     FIG. 7 shows signal waveforms at each part of the circuit of FIG. 6; 
     FIG. 8 is a circuit diagram showing a third embodiment of the present invention; 
     FIGS. 9 and 10 show signal waveforms at each part of the circuit of FIG. 8; 
     FIG. 11 shows one example of the control signal generating circuits used for the circuit of FIG. 8; 
     FIG. 12 shows signal waveforms at each part of the circuit of FIG. 11; 
     FIG. 13 shows one example of a circuit configuration of a conventional delta modulation coding system; and 
     FIG. 14 shows signal waveforms for explaining an operation of the circuit of FIG. 13. 
    
    
     DESCRIPTION OF THE PREFERRED EMBODIMENT 
     In the conventional device shown in FIG. 13, the output signal pulse from a flip-flop 114 on the decoding side is integrated by a resistance 116 and a capacitance 117 to convert it into an analog signal. By pulse width modulation of the output signal pulse from this flip-flop 114, the effective pulse width of the output pulse is controlled, thereby, a charge quantity to be integrated is controlled by charging time. Narrowing the effective pulse width less than the original pulse width is equivalent to multiplication of an amplitude of the output waveform by a numerical value less than one. For example, by narrowing the pulse width to 1/2, the amplitude of the output waveform can be reduced to 1/2. Addition in the product and sum operations is implemented by constituting constant current sources by passing each output signal of a plurality of the flip-flops through each relatively high resistance and connecting these to the same terminal. Further, for control of the pulse width of the flip-flop 114, a tri-state output buffer gate is used, thereby greatly simplifying the circuit configuration. 
     FIG. 1 is a circuit diagram showing a first embodiment of the present invention. This embodiment is configured for the decoding portion (114-120) of the conventional device of FIG. 13 by adding a pulse width modulation circuit that is the feature of this embodiment, which decoding portion converts the delta-modulated code into the analog signal. 
     Now, the circuit added between the flip-flop 114 and the resistance 116 is the tri-state buffer gate 304. This tri-state buffer gate 304 outputs the input signal as it is when a signal GA at a control input 305 is &#34;H&#34; (high level). The output terminal assumes a high impedance (&#34;Z&#34;) level regardless of the input signal when the signal GA is &#34;L&#34; (low level). 
     Now, assuming that the output signal A of the flip-flop 114 which is supplied to the input of the buffer gate 304 and the control signal GA which is supplied to the control input of the buffer gate 304 have each signal waveform as shown in FIG. 2, an output signal A&#39; waveform of the buffer gate 304 becomes A&#39; in FIG. 2. Further, the output of the buffer gate 304 becomes &#34;Z&#34; (high impedance) when the control signal GA is &#34;L&#34;. The output of the buffer gate 304 forms a constant current source with the resistance 116 when the signal A&#39; is &#34;H&#34; or &#34;L&#34; and it charges or discharges the capacitor 117, but a current does not flow when the buffer gate 304 is &#34;Z&#34; and so a voltage of the capacitor 117 does not change. Therefore, an amount of charge which is charged or discharged to or from the capacitor 117 becomes small and thus an amplitude of the analog output signal becomes small. For example, when the signal A on the signal input line 303 of the buffer gate 304 is equal to the code train 202 of FIG. 14 and the control signal GA for the buffer gate 304 has &#34;L&#34; level during 1/4 clock period as shown in FIG. 2, a waveform 500 shown in FIG. 3 is obtained on the signal input line 118 of the low pass filter 119. The amplitude of this waveform is reduced to 3/4 of the original amplitude of FIG. 14. When higher frequency components of this waveform are cut by the low pass filter 119 of FIG. 1, a signal having a waveform 501 of FIG. 3 is obtained at the output terminal 120. That is, this waveform is obtained by multiplying the original waveform by a ratio TH/T in which T is a pulse width of the delta modulation in FIG. 2 and TH is a time duration in high level of the control signal GA. Therefore, the circuit of FIG. 1 configures a digital attenuator. 
     One example of a control signal GA generating circuit is shown in FIG. 4. This circuit is configured with a counter 603, a latch 606 and a comparator 608. The counter 603 receives an output clock CP DM  for the delta modulation and a clock pulse CP PW  which is more minute than the output clock CP DM  (here, 1/16 clock). At first, a specified value (here 12) is set at the latch 606 via a signal input terminal 605. The counter 603 is reset by the clock pulse CP DM  for the delta modulation and is counted up by the clock pulse CP PW  for pulse width modulation. An amplitude of an output signal 604 from the counter 603 and an amplitude of an output signal 607 from the latch 606 are compared by using the comparator 608, and when the former is smaller than the latter, an output 609 of the comparator 608 becomes high level. On the contrary, when the amplitude of the signal 604 becomes larger than the amplitude held at the latch 606, the output 609 of the comparator 608 goes low level. Therefore, the control signal GA having a waveform shown in FIG. 5 can be generated. An amplitude of an analog signal obtained from decoding (or demodulating) the delta-modulated code can be controlled by the value set at the latch 606 of FIG. 4, and thus the digital attenuator can be realized. 
     FIG. 6 is a circuit diagram showing a second embodiment of the present invention. At the time of decoding, the circuit of this second embodiment performs mixing of a plurality of code signals coded by the delta modulation system. The circuit configuration of FIG. 6 is for mixing two signals and combines two basic circuits of FIG. 1. That is, each two units of flip-flop 114, buffer gate 304 and resistance 116 of FIG. 1 are provided (114a, 304a and 116a; 114b, 304b and 116b). In this circuit configuration, combining outputs of the buffer gates 304a, 304b with relatively high resistances 116a, 116b respectively constitutes a current addition circuit, and connecting this configuration with a capacitor 117 forms an integrator. Signals A&#39;, B&#39;, which were pulse-width-modulated by the control signal GA, GB, are added and integrated by these circuits. The mixing ratio of the signals A and B is determined by the control signal GA, GB. FIG. 7 shows waveforms which results in mixing of the signal A with the ratio 0.25 and the signal B with the ratio 0.5. The control signals GA, GB can be generated by the circuit of FIG. 4, and the mixing ratio is determined with a value set at the latch 606. By using the circuit of FIG. 6, digital mixing of two signals can be performed. Needless to say, for mixing of three or more signals, provision of the number of the basic circuits corresponding to the number of the signals will suffice to implement the mixing. 
     FIG. 8 is a circuit diagram showing a third embodiment of the present invention. The circuit of this embodiment is for performing connection of waveforms by fade-in fade-out of two code signals. The distinctive feature between the circuit of FIG. 6 and the circuit of FIG. 8 resides in that the buffer gate 304a and 304b are complementarily supplied with the same control signal GAB. That is, the buffer gate 304a is supplied with the control signal GAB as it is, while the buffer gate 304b is supplied with an inverted signal derived from inversion of the control signal GAB using an inverter 915. Thus, as a buffer gate output, the output from either the gate 304a or gate 304b is selected and the circuit combines the two outputs into one output signal 916 (signal designation AB). This signal is connected to a capacitor 117 through a resistance 116. As shown in the signal waveforms of FIG. 9, designating a period of the control signal GAB as T, and its duration in the high level as TH, then the two signals A and B are mixed with the ratios of TH/H and 1-(TH/T). In FIG. 9, waveforms for mixing of the signal A with the ratio 3/4 and the signal B with the ratio 1/4 are shown, and a mixed analog signal can be obtained by integrating the signal AB and passing the integrated signal through the low pass filter 119. Now, in the embodiment of FIG. 8, the control signal for buffer gates 304a, 304b are complementarily supplied, therefore, this portion may be replaced by logical AND OR gates. 
     Further, as shown in FIG. 10, a gain HA of the signal A can be gradually decreased and a gain HB of the signal B can be gradually increased by gradually reducing the TH of the control signal GAB. The control signal GAB used in this operation is generated by the circuit shown in FIG. 11. This circuit is basically the same as that of FIG. 4, but uses an up-down counter 1208 of FIG. 11 in place of the latch 606 of FIG. 4. The up-down counter 1208 has more bits than the counter 603, and a high-order bit signal 607 of the up-down counter 1208 is supplied to the comparator 608. Now, as shown in FIG. 12, when a larger value than the value that the counter 603 can take is set in the up-down counter 1208, the comparator 608 always outputs a high level GAB. Then, when the control signal 1206 for down count is raised to a high level, the up-down counter 1208 is counted down by the clock pulse CPDM for the delta modulation to decrease gradually a count value. As shown in FIG. 12, the value CA of the counter 603 is counted up by the clock pulse for the pulse width modulation and reset by the clock pulse for the delta modulation, and therefore, is formed in a stepped triangle. On the other hand, when the output value CB of the up-down counter 1208 is gradually decreased, a time duration in which value CA exceeds value CB is gradually increased, and as this state goes on, a time duration in which value GAB is in a low level is increased and value GAB reaches the perfect low level when value CB becomes D and switching of fade-in fade-out from signal A to signal B is finished. On the contrary, switching from signal B to signal A is implemented by counting up the up-down counter 1208. While only certain embodiments of the present invention have been described, it will be apparent to those skilled in the art that various changes and modifications may be made therein without departing from the spirit and scope of the present invention as claimed.