The method of taking on the telephone based on web browser, system and SoftSwitch server
Technical field
The present invention relates to a kind of method of taking on the telephone, system and SoftSwitch server based on web browser.
Background technology
The networking telephone is divided into the software-type networking telephone and hardware-type network phone, wherein, before the software-type networking telephone is used, user need to download and install third-party application software in advance, then buy networking telephone card, the installation of application software relates to the compatibility issue of computer operating system, some user likely due to this application software and its computer operating system incompatible, and application software is not installed, comparatively inconvenient.Third company is for expanding user group, and it often need to develop different application software for multiple computer operating system, and cost is high.Hardware-type network phone is generally connected to common telephone set by voice gateways and router, by this telephone set, by internet, send calling again, user's hardware requirement is had higher requirements, can only be fixed on a certain place and call out, can not realize calling whenever and wherever possible, comparatively inconvenience.
Summary of the invention
For the deficiencies in the prior art, object of the present invention is intended to provide a kind of method of taking on the telephone based on web browser, system and SoftSwitch server solving the problems of the technologies described above.
For achieving the above object, the present invention adopts following technical scheme:
The method of taking on the telephone based on web browser, it comprises the following steps:
Steps A: web browser establishes a communications link by WebSocket agreement and SoftSwitch server according to the call request from webpage;
Step B: SoftSwitch server is called out a Tandem Gateway according to this call request;
Step C: SoftSwitch server is set up calling virtual circuit according to the feedback signaling from Tandem Gateway and Tandem Gateway;
Step D: web browser obtains the simulated audio signal from microphone, and simulated audio signal is carried out to analog to digital conversion, coding and encapsulation, to generate IP bag;
Step e: SoftSwitch server is sent to Tandem Gateway by the IP bag from web browser;
Step F: SoftSwitch server receives the reply IP bag from Tandem Gateway, and this reply IP bag is transmitted to web browser; And
Step G: web browser is decoded the reply IP bag from SoftSwitch server and digital-to-analog conversion, to be reduced to simulated audio signal.
Further, this call request comprises the conversation number information for the treatment of.
Further, in step B, this SoftSwitch server is called out Tandem Gateway when the prefix standard until conversation number information of this call request of judgement.
Further, in step C, SoftSwitch server receives the feedback signaling from Tandem Gateway, judges whether feedback signaling comprises SUCCESS state value, if so, sets up and calls out virtual circuit with Tandem Gateway, if not, returns to information to the webpage of browser.
Further, in step D, web browser, according to bandwidth situation optionally from iSAC, is chosen a kind of coding in iLBC and G.711 coded format; The digital audio and video signals that web browser obtains analog to digital conversion by Real-time Transport Protocol or SRTP agreement is encapsulated as IP and wraps.
The present invention also comprises following technical scheme:
The system of taking on the telephone based on web browser, it comprises web browser and SoftSwitch server;
This web browser is for establishing a communications link by WebSocket agreement and SoftSwitch server according to the call request from the page;
This SoftSwitch server is used for calling out a Tandem Gateway according to this call request, and sets up calling virtual circuit according to the feedback signaling from Tandem Gateway and Tandem Gateway;
This web browser is also for the simulated audio signal from microphone is carried out to analog to digital conversion, coding and encapsulation, to generate IP bag;
This SoftSwitch server is also for being sent to Tandem Gateway by the IP bag from web browser;
This SoftSwitch server is also for receiving the reply IP bag from Tandem Gateway, and just this reply IP bag is transmitted to web browser;
This web browser is also for this reply IP bag is decoded and digital-to-analog conversion, to be reduced to simulated audio signal.
Further, this call request comprises the conversation number information for the treatment of.
Further, SoftSwitch server receives the feedback signaling from Tandem Gateway, judges whether feedback signaling comprises SUCCESS state value, if so, sets up and calls out virtual circuit with Tandem Gateway, if not, returns to information to the webpage of browser.
Further, web browser, is chosen in iLBC and G.711 coded format and a kind of above-mentioned digital audio and video signals is carried out to compressed encoding optionally from iSAC according to bandwidth situation; The digital audio and video signals that web browser obtains analog to digital conversion by Real-time Transport Protocol or SRTP agreement is encapsulated as IP and wraps, and this IP bag is RTP bag or SRTP bag.
The invention still further relates to following technical scheme:
A SoftSwitch server, it comprises that calling module, talk path set up module and IP pack receiving and transmitting module;
This calling module is for calling out a Tandem Gateway according to a call request, and this call request comprises the conversation number information for the treatment of;
This talk path is set up module for setting up calling virtual circuit according to the feedback signaling from Tandem Gateway and Tandem Gateway;
This IP pack receiving and transmitting module is used for the IP bag from Tandem Gateway to be sent to web browser, and the IP bag from web browser is sent to Tandem Gateway.
Beneficial effect of the present invention is as follows:
The present invention can realize based on web browser dial-in direct and by voice messaging and be sent to Telephone set or mobile phone, the page that user can log in browser at arbitrarily computer or mobile phone carries out number dialing telephone call, without third party software is installed, without considering compatibility issue, also can not take hard disk and the internal memory of computer or mobile phone, very convenient quick.
Accompanying drawing explanation
Fig. 1 is the process flow diagram of better embodiment that the present invention is based on the method for taking on the telephone of web browser.
Fig. 2 is the module diagram that the present invention is based on the system of taking on the telephone of web browser.
Fig. 3 is the module diagram of SoftSwitch server of the present invention.
Embodiment
Below in conjunction with accompanying drawing and embodiment, the present invention is described further:
Refer to Fig. 1, the present invention relates to a kind of method of taking on the telephone based on web browser, its better embodiment comprises the following steps:
Steps A: web browser establishes a communications link by WebSocket agreement and SoftSwitch server according to the call request from webpage;
In practical application, user can log in the page into operation web page according to its registered account on browser, fills in the telephone number that needs call, and triggers dialing icon, to generate this call request; Wherein, this call request comprises the conversation number information for the treatment of;
Step B: SoftSwitch server is called out a Tandem Gateway according to this call request;
Particularly, this SoftSwitch server is called out Tandem Gateway when the prefix standard until conversation number information of this call request of judgement; If it is lack of standardization to judge prefix, return to information to the webpage of browser, to point out user to cause because prefix is lack of standardization calling out, make mistakes;
Step C: SoftSwitch server is set up calling virtual circuit according to the feedback signaling from Tandem Gateway and Tandem Gateway.
Particularly, SoftSwitch server receives the feedback signaling from Tandem Gateway, judges whether feedback signaling comprises SUCCESS state value, if so, set up and call out virtual circuit with Tandem Gateway, if not, return to information to the webpage of browser, to point out user to call out, make mistakes.
Step D: web browser obtains the simulated audio signal from microphone, and simulated audio signal is carried out to analog to digital conversion, coding and encapsulation, to generate IP bag;
Particularly, web browser, is chosen in iLBC or G.711 coded format and a kind of digital audio and video signals after analog to digital conversion is carried out to compressed encoding optionally from iSAC according to bandwidth situation; Web browser is encapsulated as IP by Real-time Transport Protocol or SRTP agreement by digital audio and video signals and wraps.
Wherein, web browser also carries out echo inhibition and denoising Processing to obtained local simulated audio signal.
Step e: SoftSwitch server is sent to Tandem Gateway by the IP bag from web browser, so that Tandem Gateway carries out related voice conversion process to above-mentioned IP bag, carry out to call out and land, Tandem Gateway can be known by prior art the subsequent treatment of IP bag, not repeat them here.
Step F: SoftSwitch server receives the reply IP bag from Tandem Gateway, and reply IP bag is transmitted to web browser;
Step G: web browser is decoded the reply IP bag from SoftSwitch server and digital-to-analog conversion, to be reduced to simulated audio signal, so that user can hear by earphone or sound equipment the opposing party's reply;
This web browser also moves and delay process simulated audio signal debounce by NetEQ algorithm, to obtain better tonequality.
So, can realize directly and dial and voice messaging is sent to Telephone set or mobile phone at web browser, the page that can log in browser at arbitrarily computer or mobile phone carries out number dialing telephone call, without third party software is installed, without considering compatibility issue, also can not take hard disk and the internal memory of computer or mobile phone, very convenient.
Above-mentioned steps A to step C be call path establishment step, by carrying out call path establishment step, realize page end and communication terminal and set up and converse as mobile phone or Telephone set; Above-mentioned steps D and step e are page end voice forwarding steps, and it can be realized page end user's voice are forwarded to Tandem Gateway, to be sent to communication terminal; Above-mentioned steps F and G are page end phonetic incepting step, and it can realize the speech conversion from communication terminal is the sound signal that page end can be exported; Therefore, above-mentioned call path establishment step is prior to page end voice forwarding step and page end phonetic incepting step, and between page end voice forwarding step and page end phonetic incepting step, do not have sequential priority minute, page end voice forwarding step can be before page end phonetic incepting step, afterwards or simultaneously.
Refer to Fig. 2, the invention still further relates to a kind of system of taking on the telephone based on web browser, it comprises web browser and SoftSwitch server;
This web browser is for establishing a communications link by WebSocket agreement and SoftSwitch server according to the call request from the page;
This SoftSwitch server is used for calling out a Tandem Gateway according to this call request, and sets up calling virtual circuit according to the feedback signaling from Tandem Gateway and Tandem Gateway.
So, set up talk path, user can start to speak by microphone.
This web browser is also for the simulated audio signal from microphone is carried out to analog to digital conversion, coding and encapsulation, to generate IP bag;
This SoftSwitch server is also for being sent to Tandem Gateway by the IP bag from web browser.
So, user can be sent to the opposing party's Telephone set or mobile phone at the said voice messaging of page end.
This SoftSwitch server is also for receiving the reply IP bag from Tandem Gateway, and just this reply IP bag is transmitted to web browser;
This web browser is also for this reply IP bag is decoded and digital-to-analog conversion, to be reduced to simulated audio signal.
Refer to Fig. 3, the invention still further relates to a kind of SoftSwitch server, it comprises that calling module, talk path set up module and IP pack receiving and transmitting module;
This calling module is for calling out a Tandem Gateway according to a call request, and this call request comprises the conversation number information for the treatment of;
This talk path is set up module for setting up calling virtual circuit according to the feedback signaling from Tandem Gateway and Tandem Gateway;
This IP pack receiving and transmitting module is used for the IP bag from Tandem Gateway to be sent to web browser, and the IP bag from web browser is sent to Tandem Gateway.
For a person skilled in the art, can make other various corresponding changes and distortion according to technical scheme described above and design, and these all changes and distortion all should belong to the protection domain of the claims in the present invention within.