Abstract:
A device interconnects within the phone line coming from a first phone and routes telephone calls along a least cost route originating from the first telephone to a second telephone via the network. A housing forms an enclosure and has a first jack for interconnection to the phone side of the phone line and a second jack for interconnection to the network side of the phone line. The housing forms an enclosure which includes a switch for disconnecting the first phone from the network. The device generates a source of current through the switch to the first phone corresponding to the amount of current provided by the phone network. A database stores billing rate parameters for determining various communication paths of different carriers based on parameters such as the time and date of the call. Phone calls from the first phone are detected and stored. The database is addressed and a plurality of communication switch paths are identified as well as the cost rate of each path. The cost rates for each identified path are compared to determine a least cost route for the call. The device generates a number sequence corresponding to a desired carrier so that the dialed call is routed through the second jack and phone line to the selected communication path and carrier so as to establish a switched connection between the first and second phones.

Description:
FIELD OF THE INVENTION 
     This invention relates to a device which can be connected directly into the phone line for routing phone calls made from a first phone along the least cost path of the telephone network to a second phone. 
     BACKGROUND OF THE INVENTION 
     The advent of numerous local and long distance telephone carriers has resulted in a wide selection of different carriers which have different telephone cost rates depending on the time of day, the number of phone calls, the location of a calling party and other factors. Typically, a consumer chooses one carrier, and maintains that carrier account for all long distance calling needs, and in some instances for local calls also. With increased competition among interstate, intrastate, interlata and intralata phone carriers, a caller could save money if different carriers are chosen for each particular phone call to a particular destination. 
     It has been known to design complex phones that route calls along selected switching points via selected tie lines to establish a least cost route. For example, U.S. Pat. No. 4,122,308 to Weinberger et al. discloses such a device. It has been found, however, that many consumers are unwilling to purchase a complex telephone device in substitution for the phone already used in the home. Typically, consumers buy a phone for aesthetic or economic reasons. Consumers have been found unwilling to purchase complex phone equipment in lieu of phones already purchased which are more simple, smaller and aesthetically pleasing to the eye. 
     SUMMARY OF THE INVENTION 
     One of the features of the present invention is a device that may be connected within the phone line separate and apart from the telephone and which routes telephone calls along a least cost route originating from a first telephone through the telephone network to a second telephone. 
     Another feature of the present invention is a device that can be connected directly within the telephone line originating from a first telephone and can be hidden from view such as behind a furniture piece. 
     Another feature of the invention is a device for routing telephone calls along a least cost route that can be quickly attached and detached from the telephone line such as by telephone jacks. 
     In accordance with the present invention, the device routes telephone calls along a least cost route originating from the first telephone through the telephone network to a second telephone. As is conventional, the network has a plurality of alternate communication switch paths corresponding to different carriers which can be chosen to route the call. 
     A housing forms an enclosure and has jacks mounted on the housing for interconnection to the phone line. A first jack interconnects to the phone side of the phone line and a second jack interconnects to the network side of the phone line. The device components are contained in the enclosure and includes a switch which operatively connects to the first jack for disconnecting the first phone from the network. A current source is generated through the switch to the first phone and corresponds to the current provided by the phone network at the central office. A database stores billing rate parameters for determining a least cost communication path based on the least cost routing parameters, which could include such parameters as the time and date of the call. 
     Means is operatively connected to the switch for detecting and storing a dialed phone number originating from the first phone. The database is addressed for identifying a plurality of communication switch paths to the dialed number as well as the cost rate of each path. The cost rate of each path is compared to determine a least cost route for the call. A tone generator is connected to the switch means and the second jack and generates a number sequence corresponding to the desired carrier so that the dialed call is routed through the second jack and phone line to the selected communication carrier so as to establish a switched connection between the first and second phones. 
     When a call is incoming, the switch connects the first phone to the network. An internal power supply provides power to the current generating means. In one aspect of the invention, the means generating the number sequence is a dual tone multifrequency generator that generates the necessary tones to the central office for establishing the least cost route. The detecting means includes, but is not limited to a dual tone multifrequency detector for detecting tones sent by the first phone. 
     The housing may be a number of different configurations. In one embodiment it is substantially cylindrical with opposing ends. The first jack is positioned on one end and the second jack is positioned on the other end. 
     In another aspect of the invention, the database is updated with a current billing rate schedule. In one aspect of the invention the update means includes a circuit board mounted within the enclosure, and the database is contained on a removable chip positioned on the circuit board. The housing may include a removable cover for accessing the chip on the circuit board to replace it with an updated chip. In still another aspect of the invention, the device includes a modem for receiving signals through the telephone line and downloading updated information to the database. 
     In still another aspect of the invention, a display is mounted on the housing and visibly displays the time and date. The time and date display receives a predetermined dial sequence from the first phone corresponding to a predetermined date and time to be displayed. After receiving the predetermined dial sequence, the display time and date is changed based on the received signals. In some designs, the date and time display can also be changed manually. 
    
    
     DESCRIPTION OF THE DRAWINGS 
     The foregoing advantages and features of the present invention will be appreciated more fully from the following description, with reference to the accompanying drawings in which: 
     FIG. 1 is an environmental view showing the device in accordance with the present invention positioned behind a sofa in a household. 
     FIG. 2 is a block diagram of the overall circuit used in the device of the present invention. 
     FIG. 3 is a flow chart depicting the initializing of the device and flow of an incoming call to the phone. 
     FIG. 4 is a flow chart depicting the routine for changing the display and dialing the codes for least cost routing in accordance with the present invention. 
     FIG. 4A is a flow chart illustrating the routine for obtaining digits for a least cost route. 
     FIG. 5 is a flow chart of a subroutine in the flow chart of FIG. 4 showing a database look-up routine. 
     FIG. 6 is a block diagram of the device with a modem. 
     FIG. 7 is a isometric view of one design of the device showing a cover that has been removed for accessing the chip to update the database. 
    
    
     DETAILED DESCRIPTION OF THE INVENTION 
     Referring now to FIG. 1, the device 10 of the present invention is shown connected or &#34;plugged&#34; into the phone line 12 of a first telephone 14 in the environment of a household 15 and positioned out of sight behind a sofa 16. As evident, the device of the present invention is advantageous because it can be readily connected within the phone line 12 and hidden from view without purchasing a new phone. Many consumers select phones based on aesthetic and economic reasons, and some consumers are unwilling to spend large sums for complex and unwieldy phones. 
     As shown in FIGS. 1 and 7, the device 10 includes a housing 20 which forms an enclosure 22. In the illustrated embodiment, the housing 20 is cylindrically configured with two opposing ends 20a, 20b. Although the cylindrical configuration is illustrated, any configuration can be used depending on the designer&#39;s choice and purchaser&#39;s desire. It is even possible to design the device 10 to be an ornament that can rest on a table or other readily visible place. A cylindrical configuration for the housing 20 has been found easy to mold and relatively inexpensive. AS shown in the drawings, the housing includes a first jack 24 for connecting &#34;plugging&#34; to the phone side of the phone line 12 and a second jack 25 for connection or &#34;plugging&#34; to the network side of the phone line. 
     The electronic components forming the device 10 are mounted within the enclosure, typically on a circuit board as shown in FIG. 7. The housing can be designed with a removable cover 26 (FIG. 7) to access the components, or a removable end where the circuit board can be slid outward to access any components. 
     Referring now to FIG. 2, the basic components used in the device of the present invention are shown in the block diagram. As noted before, the second phone jack 25 has one line 32 connecting to the first phone jack 24 positioned on the other end of the cylindrically configured housing. The phone jack 25 connects to a switch 36, referred to as a 2 Form C switch, which switches the phone off the network to the other components contained in the device. The switch 36 connects to a &#34;local CO (central office)&#34; current source 38 which generates a current corresponding to the current supplied by the central office of the network. The switch 36 connects and disconnects the phone from the network into the current source 38, which in turn supplies a current to the phone equivalent to the current supplied by the central office of the network. The switch 36 also connects to a line current detector 40 (off-hook detector) which detects an off-hook or on-hook state of the phone. A combination polarity guard 42 and Direct Access Arrangement 44 (DAA) interfaces and allows communication to the network. The line current detector can be formed from numerous types and brands of device. One available device is a teltone M949 device. 
     The controller for the device 10 includes the standard components of a microprocessor including a microprocessing unit 50 (MPU) such as a Toshiba TMPZ 84C011 and a RAM chip 52 such as a generic chip sold by Hyundai under the designation HY6116. A bank selected Eprom 54 for storing the database is also included and can be a generic Eprom chip such as a Toshiba TC574000 chip with more Eprom than the microprocessor can directly address. A real time clock 56 maintains the proper time and provides signals for controlling the device. An example of a clock chip which can be used for the device is an Epsom RTC62421B chip. The microprocessing unit 50 includes the conventional address, control, and data buses 60, 62, 64 and an input output bus 66. 
     A serial bus 68 connects from the MPU 50 to a display controller 70 which controls a 31/2 digit display 72. The 31/2 digit display 72 displays the time and date and is positioned on the outside of the housing where it can be readily read. A ring detect circuit 74 is interconnected to the input-output bus and the incoming line jack 30 and detects the ringing of the phone. A power supply 76 is also included and provides the current for the local CO current generator 38. In the present invention, power can be generated from the phone company when the first phone is &#34;off-hook&#34;, or generated from the battery when the first phone is &#34;on-hook&#34;. 
     Once a minute the device will update the date and time on the display 72 and then revert to a passive state also known as the &#34;sleep&#34; state. It is not possible to draw power for the device 10 from the phone company in an &#34;on-hook&#34; condition. Therefore, the power supply 76 provides power once a minute to change the display 72 to a new setting. A DTMF (dual tone multifrequency) tone generator 80 includes a crystal oscillator 82 which together generate the tone frequencies necessary to generate the tones for the dialing sequences. An analog switch 84 allows switching to either the-phone or the network. The dial tone detect circuit 86 connects to the line coming from the polarity guard 42 and connects to the line detector 40. The DTMF tone detector 88 detects the tones generated from the first phone. The reset circuit 89 allows for resetting the entire circuit from a begin point. 
     Referring now to FIGS. 3-5, there are illustrated flow charts depicting the operation of the device in accordance with the present invention. The steps are enumerated beginning with the numeral 100 and follow through with sequential even numbers in most cases. 
     Initially, as shown in FIG. 3, in step 100 the device detects an &#34;off-hook&#34; condition for the first phone, such as when the handle is raised from the cradle of a phone. The device is initialized in step 102 and the clock reset is disabled. The initializing step 102 can also occur when the reset occurs such as a startup in step 104. Thus, it is evident that a reset occurs in two conditions: 1) when the phone goes &#34;off hook&#34; or 2) when the real time clock emits a pulse (such as once a second) for setting the clock. 
     In step 106 the ring detect circuit 74 detects if there is a ring. If a ring is detected, the word &#34;USE&#34; in step 108 is displayed on the 31/2 digit display 72 corresponding to the device 10 being in use. The phone remains connected by the switch 36 to the central office network and the DTMF tone oscillator and generator 80, 82 operation are terminated. The power is shut down in step 12 of the device to allow communication between the first phone and the second phone, who was the calling party in this instance. The device 10 has gone into a passive mode also referred to as a &#34;sleep mode&#34; in step 14. 
     If during initialization in step 106 the ring detector did not detect a ring, the device 10 then checks for an off-hook condition in step 16. If there is no off-hook condition, then the device is restarting such as from a clock pulse. The clock count is incremented in step 118. If the clock count is greater than 60 seconds in step 120, then the display controller 70 displays a new date and time on the 31/2 digit display 72 in step 122. If the count is not greater than 60 seconds then the phone remains connected to the central office (phone network) in step 110 and the phone has gone into a passive mode in step 112. 
     If the off-hook condition is sensed in step 106, the phone is prepared in step 130, i.e., the device is prepared to receive DTMF tone signals from the first phone (FIG. 4). In this step the device 60 connects to the central office (phone network) in step 132 and the DTMF tone generator 80, 82 is set to the &#34;on&#34; position. The first phone is connected via the switch 36 to the local central office, i.e., the local current source 38, to generate a current through the switch to the jack 34 and to the first phone. Additionally, in step 132, the device is initialized to begin the lookup routines in the database. 
     The caller at the first phone then dials a number and the device 10 enters a subroutine known as &#34;get digit&#34; in step 134 (FIG. 4A). The DTMF tone detector 88 detects each digit as it is called. If the digit is a &#34;pound sign&#34; (&#34;#&#34;) in step 136, then the device is initialized to prepare the date and time on the display 72. Although the &#34;pound sign&#34; is illustrated as the initial sequence code for settling the time and date, it is readily apparent that any sequence of codes can be used as long as the code is not the beginning of a telephone number. 
     If the digit is a &#34;pound sign&#34;, the &#34;get digit&#34; subroutine is followed once again in step 138. The &#34;get digit&#34; subroutine is shown in greater detail on the left side of FIG. 4. A DTMF digit is detected in step 140 and the routine then returns in step 142 to the mainflow chart. If the digit is not detected, a test is made to see whether the first phone current is on hook in step 144. If the first phone is not on hook the subroutine continues to detect digits. If the first phone is on hook, then the device goes into &#34;sleep&#34; or passive mode. 
     If the numeral 3 is detected in step 150, corresponding to the letter D, then the DTMF tones following are input as the date, such as the month, day and year, as well as the time, such as the hour, minute and seconds in that order in step 152, and displayed on the 31/2 digit display in step 154. The device then routes into the passive &#34;sleep&#34; mode. If the numeral &#34;3&#34; was not detected in step 150 the device then routes into the sleep mode, or could implement other special functions indicated by the digit, e.g. (test modes). For example, if the number &#34;7&#34; is detected (step 150A) for the phone, corresponding to the letter &#34;P&#34;, the telephone number for the device is obtained (step 150B), and saved (step 150C). Typically, this routine can be started by the caller pressing the pound (#) key, and the number being stored as NPA NXX XXXX. 
     If the pound sign was not detected in step 136, the detected digit is saved in step 160 and the detected digits are then analyzed in step 12 to determine if the area code and exchange (the NPA NXX) are known in step 12. If they are not known, the get &#34;digit routine&#34; is repeated in step 14 until the NPA NXX code is known. The call is then routed in step 16 in a route call routine, which is set forth in FIG. 5. The device distinguishes from the dialed digit if an area code (NPA) has been dialed. If the NPA has not been dialed, this device uses the NPA from the data specified for the device location. 
     As shown in FIG. 5, the device 10 initially determines whether the area code and exchange digits known are in a special category in step 168 such as 911, 411, 800, or 900 numbers. If the dial routine is a special number, the telephone signal is flagged in step 170 and returned to the main routine where further digits such as the last four digits of the phone number are obtained and received in step 174. The digits are saved in step 176 and the dialing is completed in step 178. The number is then dialed in step 180 and the device routes into the passive or sleep mode and the call completed. If the dialing is not complete, then the get digit routine is repeated until all digits from the telephone number are obtained. 
     If the number in step 168 is not a special number (FIG. 5), the call type is determined in step 182, e.g. if the call is local, interlata, intralata, interstate, intrastate or a combination thereof. In step 284 the first carrier is set and the cost is looked up in the database in step 186. The next carrier is then set in step 188. If there are more couriers in step 190, the look up cost is repeated until all carriers are exhausted. In step 192 the best carrier is picked and the dialing pattern set in step 194. The sequence is then returned in step 196 to the route call routine of step 166. 
     Because the rates among different carrier may change monthly, or even daily and weekly depending on circumstances, the database may be updated. In one embodiment, the database can be downloaded through a modem 200 (FIG. 6) to a storage unit 202. However, this method will require additional components such as a modem. 
     In another embodiment, the Eprom chip containing the database is removed, such as by accessing the chip through an opening 210. Once the chip is removed,another updated chip is substituted and the housing cover 26 replaced on the device 10. In an alternative embodiment, an end can be removed, and the entire circuit board 220 holding the components slid outwardly to expose the chips to be replaced. Once any chips are replaced, the circuit board can be slid back into the housing. 
     The device 10 of the present invention is advantageous over prior art call metering devices that are incorporated within the phone itself. The device of the present invention can be connected into the phone line coming from a phone and easily hidden from view or placed in an inconspicuous location, and a consumer does not have to purchase anew phone. Basic microprocessor and other circuits are used and can be contained in an attractive housing, and the date and time can be easily set by the keypad of a standard telephone. Additionally, in some instances, the determined cost of a phone call may be given a bias for preference to a given carrier. For example, if a first carrier is no greater than 5% additional cost than a second carrier, that first carrier may be given a preference. 
     It is to be understood that the above description is only one embodiment of the invention. Numerous other arrangements may be devised by one skilled in the art without departing from the spirit and scope of the invention.