Telephone exchange apparatus

Abstract: When there is an incoming call to a digital line (1) and the digital line is to be connected to a digital terminal (18), a CPU (4) connects the line and the terminal directly. When the digital line is to be connected to an analog individual line telephone (17) or the like, the line and the terminal are connected via a level controller (14). The level controller shifts, to an appropriate level, the level of a voice signal represented by data received from the digital line, and the analog individual line telephone or the like connected to the extension receives the voice signal shifted to the appropriate level.

Description: BACKGROUND OF THE INVENTION 1. Field of the Invention: This invention relates a telephone exchange apparatus which accommodates a plurality of outside lines and a plurality of extension terminals and converts the levels of signals received from the outside lines. 2. Description of the Prior Art: In a case where an extension accommodates an individual telephone (an analog telephone) in a conventional telephone exchange apparatus, the level in the telephone exchange is adjusted so as to assure equal speech quality even if the individual telephone is connected to the extension or even if it is directly connected to a main wire. Further, in a case where a leased telephone of a telephone exchange apparatus is accommodated in an extension in the conventional telephone exchange apparatus, the arrangement is such that by adjusting the overall gain of the leased telephone and the telephone exchange apparatus, the optimum speech quality is obtained when the leased telephone carries on a telephone conversion by an analog line. Owing to the greater popularity of digital communication networks, situations in which the main wire of a telephone exchange apparatus accommodates a digital line are increasing. With regard to a telephone conversation via a digital line in the conventional telephone exchange apparatus, the gain within the apparatus is set at 0 dB in order to assure a speech quality equal to that which prevails when a digital telephone connected to an extension is connected to a digital network. In other words, the conventional telephone exchange apparatus is so adapted that data identical with the incoming data from an outside line is transmitted to the extension telephone. However, when a signal from a digital network is received in an individual telephone accommodated in the conventional telephone exchange apparatus, a problem which arises is that the sound volume of the received speech is too large. Furthermore, even in the case of a leased telephone accommodated in the conventional telephone exchange apparatus, the gain is adjusted so as to obtain the optimum speech quality if the telephone conversation is carried on by an analog line, as mentioned above. When a signal is received from a digital network, however, the sound volume of the received speech is too large. Document WO 80/00289 discloses a digital transmission system including one or more matrix switches in which data in digital form is stored in a send memory during one selected time slot of a recuring time frame and transferred to a receive memory during another time slot, in order to establish desire data paths through the switch. SUMMARY OF THE INVENTION Accordingly, an object of the present invention is to provide a telephone exchange apparatus which solves the aforementioned problems. Another object of the present invention is to provide a telephone exchange apparatus in which the signal level of a signal received from an outside line is converted in dependence upon the type of outline line to be connected and the type of extension terminal, whereby when a signal received from a digital network is received by an individual telephone and a leased telephone accomodated in an extension, the problem of excessive speech volume is ameliorated so that the optimum speech volume can be obtained irrespective of the type of terminal accomodated in the extension and the type of the outside line. According to the present invention, the foregoing objects are attained by providing a telephone exchange apparatus for connecting an external line with extension terminals of a plurality of types, comprising converting means for converting a voice signal level, characterized in that said converting means is adapted to convert the level of the voice signal which is to be inputted to the extension terminal via the external line, in dependence upon the type of the extension terminals. Further, according to the invention, the foregoing objects are attained by providing a method of converting a level of a voice signal which is inputted from an external line and is to be outputted to one of plural extension terminals, characterized in that it comprises : a step of determining a type of the one of plural extension terminals to which the voice signal is to be outputted; and a step of converting the level of the voice signal which is to be outputted to the one of plural extension terminals, in dependence upon the type determined in said determining step. In accordance with the above-described arrangement, the signal level of the signal received from the outside line is converted in dependence upon the type of outside line to be connected and the type of extension terminal. As a result, the telephone exchange apparatus according to the invention provides the optimum speech quality irrespective of the type of terminal connected to the extension and the type of outside line. Other features and advantages of the present invention will be apparent from the following description taken in conjunction with the accompanying drawings, in which like reference characters designate the same or similar parts throughout the figures thereof. BRIEF DESCRIPTION OF THE DRAWINGS Fig. 1 is a block diagram illustrating an example of the construction of an embodiment of a telephone exchange apparatus according to the present invention; Fig. 2 is a block diagram illustrating an example of the construction of a level controller according to the embodiment; Fig. 3 is a diagram showing an example of time-slot allocation of a level control highway according to the embodiment; Fig. 4 is a flowchart illustrating an example of a level-shift operation according to the embodiment; Fig. 5 is a flowchart for describing an example of operation when there is an incoming call from an ISDN according to the embodiment; Fig. 6 is a flowchart for describing an example of operation when an outgoing call is placed to an ISDN according to the embodiment; Fig. 7 is a flowchart for describing an example of operation when speech volume is set according to the embodiment; Fig. 8 is a block diagram illustrating an example of the construction of a level controller according to a second embodiment of the present invention; and Fig. 9 is a flowchart illustrating an example of decoding and level-shift operation according to a second embodiment of the present invention. DESCRIPTION OF THE PREFERRED EMBODIMENTS An embodiment of the present invention will now be described in detail with reference to the drawings. Fig. 1 is a block diagram illustrating an example of the construction of an embodiment of a telephone exchange apparatus according to the present invention. As shown in Fig. 1, a digital line 1 such as an ISDN and an analog line 2 are connected to a telephone exchange apparatus 3. The telephone exchange apparatus 3 includes a CPU 4, a ROM a 5 and a RAM 6 interconnected via a CPU bus 7 which contains an address bus and a data bus, an exchange switch (MTS) 8 controlled by the CPU 4 via the CPU bus 7, a digital-line interface 9, an analog-line interface 10, an extension analog individual telephone interface 11, an extension digital terminal interface 12, an extension leased-telephone interface 13, and a level controller 14. The digital-line interface 9 and the analog-line interface 10 are connected to the exchange switch 8 via an input highway (FHW a ) 15. The extension analog individual telephone interface 11, extension digital terminal interface 12 and extension leased-telephone interface 13 are connected to the exchange switch 8 via an output highway (BHW a ) 15. An analog individual telephone 17 is connected to the extension analog individual telephone interface 11, a digital terminal is connected to the extension digital terminal interface 12, and an individual telephone 19 is connected to the extension leased-telephone interface 13. In Fig. 1, only one digital line 1, one analog line 2, one analog individual line telephone 17, one digital terminal 18 and one leased telephone 19 are shown to be connected to the telephone exchange apparatus 3. In actuality, however, a plurality of each of these lines and telephones are connected to the telephone exchange apparatus 3. Though not shown in Fig. 1, the telephone exchange apparatus 3 has input highways leading to the exchange switch (MTS) 8 from the extension analog individual line telephone interface 11, extension digital terminal interface 12 and extension leased-telephone interface 13. Similarly, the telephone exchange apparatus 3 has input highways leading from the exchange switch (MTS) 8 to the digital-line interface 9 and analog-line interface 10. Programs executed by the CPU 4 are stored in the ROM a 5. Further, the ROM a 5 and the RAM 6 store the correlation between voice data from the digital-line interface 9 and analog-line interface 10 and time slots on the input highway FHW a 15, the correlation between time slots on the input highway FHW a and each extension interface, as well as the types of outside lines at the respective accommodating positions and the types of extension interfaces. The analog-line interface 10 includes a variable gain amplifier for amplifying the analog signal from the analog line 2, and a coder for coding the amplified analog signal. The extension analog individual line telephone interface 11 includes a decoder for decoding the code data from the output highway BHW a 16, and a variable gain attenuator for attenuating the decoded analog signal. Fig. 2 is a block diagram illustrating an example of the construction of the level controller 14 according to this embodiment. As shown in Fig. 2, the level controller 14 includes a counter 21 for counting the period of the time slots, a ROM b 22 which stores data corresponding to level gain (degree of attenuation or degree of amplification), a parallel-serial converter (P/S a ) 23, a serial-parallel converter (S/P a ) 24, a serial-parallel converter (S/P b ) 25 and a parallel-serial converter (P/S b ) 27, a ROM c 26 which stores a look-up table for level shift, a second input highway FHW b 28, a second output highway BHW b 29, a level-control input highway FHW c 30, and a level-control output highway BHW c . On each highway shown in Fig. 2, the data flows in time-shared, multiplexed fashion in a plurality of time slots. The level-shift operation of this embodiment will now be described in detail. By way of example, in a case where a level shift of data in a time slot on the input highway FHW a 15 is carried out, this time slot, which has entered the exchange switch MTS 8, is connected to the second output highway BHW b 29 by control executed by the CPU 4. The data on the second output highway BHW b 29 is converted into eight-bit parallel data by the serial-parallel converter S/P a 24, and the resulting parallel data is inputted to the ROM c 26 as the eight lower-order bits A 0 ∼ A 7 of address data having a length of 16 bits. The value of the count from the counter 21 enters the address terminals of the ROMb 22, and eight bits of parallel data are read out of the ROM b 22 at the period of one time slot. The parallel-serial converter P/S a 23 converts the parallel data inputted from the ROM b 22 into serial data, multiplexes the serial data in time-shared fashion and outputs the data to the level-control input highway FHW c 30. Fig. 3 is a diagram showing an example of time-slot allocation of the level control highway according to the embodiment. As shown in Fig. 3, level gains are allocated to time slots TS0, TS1, TS2, ···, and each time slot possesses corresponding eight-bit data. In other words, in conformity with the timing at which each level gain is outputted in time-shared fashion to the level-control input highway FHW c 30, the counter 21 changes over the address of the ROM b 22 and the parallel-serial converter P/S a 23 outputs the serial data to the level-control input highway FHW c 30. The level-control input highway FHW c 30 is connected to the level-control output highway BHW c 31 by control executed by the CPU 4. The serial data on the level-control output highway BHW c 31 is converted into eight-bit parallel data by the serial-parallel converter S/P b 25, and the resulting parallel data is inputted to the ROM c 26 as the eight higher-order bits A 8 ∼ A 15 of address data having a length of 16 bits. Control of the exchange switch MTS 8 and the principle of the level shift according to this embodiment will now be described with regard to an example in which the data (the data received from the digital line 1) in time slot TS0 on input highway FHW a 15 is attenuated 15 dB. The CPU 4 controls the exchange switch MTS 8 to connect the time slot TS2 (-15 dB) of the level-control input highway FHW c 30 and the time slot TS0 of the level-control output highway BHW c 31, as well as the time slot TS0 (digital line 1) of the input highway FHW a 15 and the time slot TS0 of the second output highway BHW b 29. That is, in the level controller 14 of the embodiment shown in Fig. 2, the data (02 = "00000010") of time slot TS2 on the level-control input highway FHW c 30 enters the address terminals A 8 ∼ A 15 of the ROM c 26 when the data of time slot TS0 on the second output highway BHW b 29 has entered the terminals A 0 ∼ A 7 of the ROM c 26. Since the degree of attenuation of the eight higher-order bits A 8 ∼ A 15 of the input address is -15 dB, the shift ratio k is 0.177828. Further, the eight lower-order bits A 0 ∼ A 7 (hereinafter referred to as "data y" of the input address are decoded in accordance with a voice decoding law (µ-law). Let x represent the data obtained by decoding the data y. Coded data z obtained by coding, in accordance with a voice coding law (µ-law), level shift data kx resulting from multiplying the shift ratio k by the decoded data x, has already been stored at the designated address of the ROM c 26 The ROM c 26 outputs the coded data z. More specifically, the level controller 14 of the embodiment shown in Fig. 2 in such that the data z corresponding to the data y inputted to the address terminals A 0 ∼ A 7 of the ROM c 26 is outputted from the data terminals D 0 ∼ D 7 of the ROM c 26. The data z is the coded data of the voice signal whose signal level, which is indicated by the data y, has been attenuated 15 dB. The coded data z outputted from the ROM c 26 in Fig. 2 is converted into serial data by the parallel-serial converter P/S b 27, and the serial data enters the exchange switch MTS 8 as the data of time slot TS0 on the second input highway FHW b 28. The CPU 4 connects the time slot TS0 of the second input highway FHW b 28 and the appropriate time slot on the output highway BHW a 16. More specifically, the data of time slot TS0 on the input highway FHW a 15 is level-shifted, and the resulting level-shifted data is connected to the time slot allocated to the terminal (e.g., the leased telephone 19 or the analog individual line telephone 17) from which an output is desired. In a case where data received from the digital line 1 is outputted to the digital terminal 18 connected to the extension, the CPU 4 controls the exchange switch MTS 8 in such a manner that the input highway FHW a 15 and the output highway BHW a 16 are directly connected, as a result of which this data will not pass through the level controller 14. Thus, in accordance with this embodiment, the level of the voice signal indicated by the data received from the digital line 1 can be shifted to an appropriate level. As a result, the problem of excessive sound volume of a received voice does not arise even if a signal received from the digital line 1 is received by the analog individual line telephone 17 or the leased telephone 19 connected to the extension. Fig. 4 is a flowchart illustrating an example of the level-shift operation according to another embodiment of the invention. The flow shown in Fig. 4 is for a case where the level shift is executed by an arithmetic operation using a microcomputer, rather than relying upon the ROM c 26. In Fig. 4, step S41 calls for the CPU 4 to control the exchange switch MTS 8 so as to connect the time slot TS2 (-15 dB) of the level-control input highway FHW c 30 and the time slot TS0 of the level-control output highway BHW c 31, thereby setting the data for the level shift. Further, the CPU 4 connects the time slot TS0 of the level-control input highway FHW a 15 and the time slot TS0 of the second output highway BHW b 29. That is, in the level controller 14 of the embodiment shown in Fig. 2, the data (02 = "00000010") of time slot TS2 on the level-control input highway FHW c 30 enters address terminals A 8 ∼ A 15 of the microcomputer (which in this embodiment is used instead of the ROM c 26) when the data of time slot TS0 on the second output highway BHW b 29 has entered address terminals A 0 ∼ A 7 of the microcomputer. Next, in this embodiment, the microcomputer reads the eight higher-order bits A 8 ∼ A 15 of the set data at step S42, and the microcomputer computes the shift ratio k at step S43. Specifically, since the set degree of attenuation is -15 dB, the shift ratio is calculated in accordance with the following equations: 20logk = -15 db k = 10 -15/20 = 0.177828 This is followed by step S44, at which the microcomputer reads the eight lower-order bits A 0 ∼ A 7 of the set data. Then, at step S45, the microcomputer decodes the data y in accordance with the voice decoding law (µ-law). That is, the microcomputer decodes the data y to obtain the data x on the basis of the following equation: x = sgn(y) (µ+1) |y| -1 µ The microcomputer then multiplies the shift ratio k by the decoded data x and performs a level shift at step S46. Next, at step S47, the microcomputer codes the level-shift data kx in accordance with the voice coding law (µ-law). That is, the microcomputer codes the level-shift data kx to obtain the data z on the basis of the following equation: z = sgn(kx) ln(1+µ |kx| ) ln(1+µ) This is followed by step S48, at which the microcomputer outputs the coded data z. From this point onward, the processing is the same as that for the case where the level shift was performed by table conversion carried out by the ROM c 26. It should be noted that voice data, which is obtained by shifting all voice data by respective amounts of shift in accordance with Eqs. (1) through (4), is stored in the ROM c 26 in advance. Next, operation of the embodiment in case of an incoming call from an ISDN (digital line 1) will be described. Fig. 5 is a flowchart for describing an example of operation when there is an incoming call from an ISDN according to the embodiment. In Fig. 5, the CPU 4 determines at step S50 whether there is an incoming call from an ISDN (digital line 1). The program proceeds to step S51 if there is an incoming call from the ISDN and to step S61 in the absence of a call from the ISDN. Steps S61 and S62 represent processing for a case where there is an incoming call from a pay station network PSTN (analog line 2). A detailed description of these steps is omitted. At step S51, the CPU 4 reads a bearer capability information element (see CCITT Recommendation I.451) contained in D-channel (control channel) data and proceeds to step S53 if the bearer capability information element is indicative of a voice or 3.1 KHz audio. If the bearer capability information element is indicative of unrestricted digital information, the program proceeds to step S52, at which the ISDN (digital line 1) and digital terminal 18 are connected, after which processing is terminated. The CPU 4 determines at step S53 whether an extension has been designated or not as by dialing. If an extension has been designated, then the program proceeds to step S54. If an extension has not been designated, the program proceeds to step S55. The program proceeds to step S57 if the CPU 4 determines at step S54 that the terminal connected to the designated extension is a non-digital terminal, and to step S52 if the CPU 4 determines at step S54 that the terminal connected to the designated extension is a digital terminal. The CPU 4 connects the digital line 1 to the designated digital terminal 18 at step S52 and then terminates processing. The CPU 4 rings all extension terminals once at step S55 then, by referring to the RAM 6, discriminates at step S56 the type of the extension terminal that has answered. If the terminal is a non-digital terminal, the program proceeds to step S57. If the terminal is a digital terminal, the program proceeds to step S52. The ISDN (digital line 1) and the digital terminal 18 are connected at step S52, after which processing is ended. In a case the digital line 1 and the analog individual line telephone 17 are connected, the CPU 4 controls the exchange switch MTS 8 to connect the received data from the digital line 1 to the level-control time slot at step S57, connect the the data indicating the amount of shift (e.g., -15 dB) to the corresponding level-control time slot at step S58, connect the level-shifted data outputted by the level controller 14 to the time slot of the terminal to be connected at step S59, and connect the ISDN (digital line 1) and analog telephone (the analog individual line telephone 17 or leased telephone 19) at step S60, after which the CPU 4 ends processing. In the foregoing description and Fig. 5, it is explained that the bearer capability information element is used in discriminating whether the received data from the digital line 1 represents a voice or not. However, this does not impose a limitation upon the invention. For example, it is possible to use a high layer compatibility information element (see CCITT Recommendation I.451) for identifying the communication medium. Thus, in accordance with this embodiment, when an incoming call is received from an ISDN (digital line 1) and the digital line 1 is to be connected to the digital terminal 18, the line and the terminal are connected directly. If the digital line 1 and the analog individual line telephone 17 are to be connected, the line and the terminal are connected via the level controller 14. Therefore, if an incoming call is received from an ISDN (digital line 1), the appropriate speech quality can be obtained irrespective of the type of extension terminal connected. Operation when an outgoing call is placed to an ISDN (digital line 1) according to this embodiment will now be described. Fig. 6 is a flowchart for describing an example of operation when an outgoing call is placed to an ISDN according to the embodiment. In Fig. 6, the CPU 4 determines at step S70 whether there is an outgoing call from an extension terminal to an ISDN (digital line 1. If there is an outgoing call to the ISDN, the program proceeds to step S71. If there is no outgoing call to the ISDN, the program proceeds to step S78. Steps S78 and S79 represent processing for a case where there is an outgoing call to a pay station network PSTN (analog line 2). A detailed description of these steps is omitted. The CPU 4 waits for an answer from the communicating party at step S71 and executes the processing of step S72 when the party answers. By referring to the RAM 6 at step S72, the CPU 4 discriminates the type of the call-originating extension terminal. If the extension terminal is a non-digital terminal, the program proceeds to step S74. If the extension terminal is the digital terminal 18, the program proceeds to step S73. The ISDN (digital line 1) and the originating digital terminal 18 are connected at step S73, after which processing is ended. From steps S74 to S76, the CPU 4 executes processing identical to that of steps S57 to S59 shown in Fig. 5. Then, at step S77, the CPU 4 connects the ISDN (digital line 1) and the originating analog telephone (the individual line telephone 17 or the leased telephone 19), after which processing is terminated. Thus, in accordance with this embodiment, the level controller 14 does not serve as an intermediary when there is an outgoing call from the digital terminal 18 to the ISDN (digital line 1). When there is an outgoing call from the analog individual line telephone 17 to the ISDN (digital line 1), the call is placed to the ISDN (digital line 1) through the level controller 14. In either case, the appropriate speech quality can be obtained without relation to the type of extension terminal from which the outgoing call originates. There are occasions where it is desired to adjust speech sound volume in accordance with the state of the line or the preference of the user when a call is received from digital line 1. A method of setting speech sound volume in accordance with the embodiment will now be described. In this embodiment, speech sound volume is decided depending upon which time slot of the level-control input highway FHW c 30 is connected to the time slot of the level-control output highway BHW c 31 shown in Fig. 2. More specifically, items of data corresponding to a variety of levels are allocated to the time slots of the level-control input highway FHW c 30, as illustrated in Fig. 3, and speech sound volume is decided by which data is inputted to the eight higher-order bits A 8 ∼ A 15 of the address terminals of the ROM c 26 shown in Fig. 2. Fig. 7 is a flowchart for describing an example of operation when speech volume is set according to the embodiment. In this embodiment, speech sound volume is capable of being set by manipulation of the leased telephone 19. In Fig. 7, the leased telephone 19 determines at step S80 whether a setting mode has been designated by the user. The program proceeds to step S81 if the setting mode has been designated. If the setting mode has not been designated, processing is terminated without any other action being taken. Next, at step S81, the leased telephone 19 reads in the mode number entered by the user and then, at step S82, determines whether the mode number is a number which corresponds to the level setting mode for for setting the level of voice sound volume. If the mode number is that indicative of the level setting mode, then the program proceeds to step S83. If the mode number is not that indicative of the level setting mode, then the program proceeds to step S84, at which a different setting operation is executed. The program then proceeds to step S85. At step S83, the leased telephone 19 waits for an input of level setting data. When the level setting data is entered, the program proceeds to step S85. At this step the leased telephone 19 transmits the entered level setting data to the interface 13 for the extension leased telephone. At step S86, the interface 13 informs the CPU 4 of the fact that the setting data has been received. This is followed by step S87, at which the CPU 4 stores the level setting data received by the interface 13, namely the entered outside-line number and the amount of shift, in the RAM 6. Thereafter, the CPU 4 refers to the RAM 6 to connect the time slot on the level-control input highway FHW c 30 corresponding to a level newly set by the user to the time slot on the level-control output highway BHW c 31. For example, in a case where a -9 dB level has been set anew, the CPU 4 connects the time slot TS4 on the level-control input highway FHW c 30 shown in Fig. 3 to the time slot TS0 on the level-control output highway BHW c 31, thereby making it possible to adjust, based upon the state of the line and the preference of the user, the speech sound volume when a call is received from the digital line 1. Processing according to the embodiment will now be described for a case where a telephone conversation takes place using the pay station network PSTN (analog line 2). In this embodiment, the variable gain amplifier of the analog-line interface 10 is adjusted in such a manner that an appropriate speech sound volume is obtained in a case where a voice signal from the analog line 2 is sent to the digital terminal 18 without the intermediary of the level controller 14. In this embodiment, the degree of attenuation of a variable attenuator in the extension analog individual line telephone interface 11 and the degree of attenuation of a variable attenuator incorporated in the leased telephone 19 are adjusted in such a manner that the appropriate speech sound volume will be obtained in a case where a voice signal from the analog line 2 has been transmitted to the analog individual line telephone 17 and the leased telephone 19, without the intermediary of the level controller 14, via the analog-line interface 10 whose gain has been adjusted in the manner described above. Fig. 8 is a block diagram illustrating an example of the construction of the level controller 14 according to a second embodiment of the present invention. The difference between the level controller 14 of the second embodiment shown in Fig. 8 and the level controller 14 of the first embodiment shown in Fig. 2 is that whereas the data terminals D 0 ∼ D 7 of the ROM c 26 are connected to the input terminals of the parallel-serial converter P/Sc 27 in the level controller 14 of the first embodiment, these data terminals are connected to the input terminals of a coding circuit 32 in the level controller 14 of the second embodiment. Other components are the same and are designated by like reference characters. These identical components need not be described in detail again. In the second embodiment, code data received from the digital line 1 is decoded by the ROM c 26 and is outputted as a digital signal shifted to the suitable level. The digital signal shifted to the suitable level is then coded by the coding circuit 32. Accordingly, the look-up table that has been stored in the ROM c 26 in the first embodiment also differs from that of the second embodiment. Fig. 9 is a flowchart illustrating an example of decoding and level-shift operation according to a second embodiment of the present invention. The flow shown in Fig. 9 is for a case where decoding and level shift are executed by an arithmetic operation using a microcomputer, rather than relying upon the ROM c 26. Furthermore, the level controller 14 of the second embodiment shown in Fig. 8 executes the decoding and level-shift operations using a look-up table stored in the ROM c 26. More specifically, the level controller 14 of the second embodiment shown in Fig. 8 stores the results of executing decoding and level shift by the microcomputer in accordance with the flowchart of Fig. 8 in the ROM c 26 in the form of a look-up table. At step S91 in Fig. 9, the CPU 4 controls the exchange switch MTS 8 to connect the time slot TS2 (-15 dB) of the level-control input highway FHW c 30 and the time slot TS0 of the level-control output highway BHW c 31, thereby setting the data for level shift. The CPU 4 then connects the time slot TS0 of the level-control input highway FHW a 15 and the time slot TS0 of the second output highway BHW b 29. That is, in the level controller 14 of the second embodiment shown in Fig. 8, the data (02 = "00000010") of time slot TS2 on the level-control input highway FHW c 30 enters the address terminals A 8 ∼ A 15 of the microcomputer when the data of time slot TS0 on the second output highway BHW b 29 has entered the address terminals A 0 ∼ A 7 of the microcomputer, which has been provided instead of the ROM c 26. Next, in accordance with the second embodiment, the microcomputer reads the eight higher-order bits A 8 ∼ A 15 of the set data at step S92, and the microcomputer computes the shift ratio k at step S93. Specifically, since the set degree of attenuation is -15 dB, the microcomputer calculates the shift ratio in accordance with the following equations: 20logk = -15 db k = 10 -15/20 = 0.177828 This is followed by step S94, at which the microcomputer reads the eight lower-order bits A 0 ∼ A 7 (hereinafter referred to as "data y") of the set data. Then, at step S55, the microcomputer decodes the data y in accordance with the voice decoding law (µ-law). That is, the microcomputer decodes the data y to obtain the data x on the basis of the following equation: x = sgn(y) (µ+1) |y| -1 µ The microcomputer then multiplies the shift ratio k by the decoded data x and performs a level shift at step S96. Next, at step S98, the microcomputer outputs voice signal data kx. That is, in the level controller 14 of the second embodiment shown in Fig. 8, the data kx corresponding to the data y inputted to the address terminals A 0 ∼ A 7 of the ROM c 26 is outputted from the data terminals D 0 ∼ D 7 of the ROM c 26. The data kx the level-shift data kx in accordance with the voice coding law (µ-law). That is, the microcomputer codes the level-shift data kx to obtain the data z on the basis of the following equation: z = sgn (kx) ln(1+µ |kx| ) ln(1+µ) This is followed by step S48, at which the microcomputer outputs the coded data z. From this point onward, the processing is the same as that for the case where the level shift was performed by table conversion carried out by the ROM c 26. It should be noted that voice data, which is obtained by shifting all voice data by respective amounts of shift in accordance with Eqs. (1) through (4), is stored in the ROM c 26 in advance. The data kx is voice signal data whose voice signal level, which is indicated by the data y, has been attenuated 15 dB. The voice signal data kx outputted by the ROM c 26 shown in Fig. 8 is coded by the coding circuit 32 and inputted to the exchange switch MTS 8 as the signal of time slot T0 on the second input highway FHW b 28. The CPU 4 connects the time slot T0 of the second input highway FHW b 28 and the appropriate time slot of the output highway BHW a 16. More specifically, in the second embodiment, the data of time slot T0 on the input highway FHW a 15 is decoded, level-shifted and then coded, and the code data obtained by the decoding, level shifting and coding is connected to the time slot allocated to the terminal (e.g., the leased telephone 19 or the analog individual line telephone 17) from which an output is desired. In a case where data received from the digital line 1 is outputted to the digital terminal 18 connected to the extension, the CPU 4 controls the exchange switch MTS 8 in such a manner that the input highway FHW a 15 and the output highway BHW a 16 are directly connected, as a result of which this data will not pass through the level controller 14. Thus, in accordance with this embodiment, the level of the voice signal indicated by the data received from the digital line 1 can be shifted to an appropriate level. As a result, the problem of excessive sound volume of a received voice does not arise even if a signal received from the digital line 1 is received by the analog individual line telephone 17 or the leased telephone 19 connected to the extension. In accordance with the present invention, as described above, the following advantages are obtained: (1) The level of the voice signal indicated by the data received from the digital line 1 can be shifted to an appropriate level by the level controller 14. As a result, the problem of excessive sound volume of a received voice does not arise even if a signal received from the digital line 1 is received by the analog individual line telephone 17 or the leased telephone 19 connected to the extension. (2) When an incoming call is received from an ISDN (digital line 1) and the digital line 1 is to be connected to the digital terminal 18, the line and the terminal are connected directly. If the digital line 1 and the analog individual line telephone 17 are to be connected, the line and the terminal are connected via the level controller 14. Therefore, if an incoming call is received from an ISDN (digital line 1), the appropriate speech quality can be obtained irrespective of the type of extension terminal connected. (3) The level controller 14 does not serve as an intermediary when there is an outgoing call from the digital terminal 18 to the ISDN (digital line 1). When there is an outgoing call from the analog individual line telephone 17 or the leased telephone 19 to the ISDN (digital line 1), the call is placed to the ISDN (digital line 1) through the level controller 14. In either case, the appropriate speech quality can be obtained without relation to the type of extension terminal from which the outgoing call originates. (4) When a telephone conversation takes place using the pay station network PSTN (analog line 2), the appropriate speech quality can be obtained irrespective of the type of extension terminal by adjusting the gain of the variable gain amplifier in the analog-line interface 10, the degree of attenuation in the variable attenuator of the extension analog individual line telephone interface 11 and the degree of attenuation in the variable attenuator incorporated in the leased telephone 19. Thus, in accordance with the present invention, there is provided a telephone exchange apparatus in which the signal level of a signal received from an outside line is converted in dependence upon the type of outside line and the type of extension terminal to be connected, whereby it is possible to obtain the optimum speech quality irrespective of the type of terminal and the type of outside line connected to an extension. As many apparently widely different embodiments of the present invention can be made without departing from the spirit and scope thereof, it is to be understood that the invention is not limited to the specific embodiments thereof except as defined in the appended claims.

Claims: A telephone exchange apparatus for connecting an external line (1, 2) with extension terminals (17 to 19) of a plurality of types, comprising converting means (4, 14) for converting a voice signal level, characterized in that said converting means is adapted to convert the level of the voice signal which is to be inputted to the extension terminal via the external line, in dependence upon the type of the extension terminals. The apparatus according to claim 1, further comprising exchanging means (8) for exchanging the external line with the extension terminals, wherein said exchanging means is adapted to apply the voice signal from the external line to said converting means, and to supply output from said converting means to one of the extension terminals. The apparatus according to claim 1, wherein said converting means is adapted to convert the level of the voice signal from the external line using a table registered in a memory (26) in advance. The apparatus according to claim 1, wherein the extension terminals include an analog type terminal (17) and a digital type terminal (18). The apparatus according to claim 1, wherein the external line includes a digital type line (1). A method of converting a level of a voice signal which is inputted from an external line (1, 2) and is to be outputted to one of plural extension terminals (17 to 19), characterized in that it comprises : a step of determining (S54, S56 and S72) a type of the one of plural extension terminals to which the voice signal is to be outputted; and a step of converting (S57, S58, S74 and S75) the level of the voice signal which is to be outputted to the one of plural extension terminals, in dependence upon the type determined in said determining step. The method according to claim 6, wherein the level of the voice signal is converted by controlling of an exchanging unit (8) such that the voice signal inputted from the external line is outputted to a level controller (14), and the voice signal whose level is converted by the level controller is outputted to the one of plural extension terminals. The method according to claim 6, wherein the level of the voice signal is converted in said converting step using a table registered in a memory (26). The method according to claim 6, wherein whether the one of plural extension terminals is an analog type terminal (17) or a digital type terminal (18) is determined in said determining step. The method according to claim 6, wherein the level of the voice signal inputted from the external line of a digital type (1), is converted in said converting step.

Inventors: IZUMI MICHIHIRO, IZUMI, MICHIHIRO, Izumi, Michihiro, c/o Canon Kabushiki Kaisha
Applicants: CANON KK, CANON KABUSHIKI KAISHA
Application year: 1992
Main classification: H04M3
IPC codes: H04M3, H04Q11, H04Q3