CN104243281A - Voice communication method based on mobile Internet - Google Patents

Voice communication method based on mobile Internet Download PDF

Info

Publication number
CN104243281A
CN104243281A CN201410412680.8A CN201410412680A CN104243281A CN 104243281 A CN104243281 A CN 104243281A CN 201410412680 A CN201410412680 A CN 201410412680A CN 104243281 A CN104243281 A CN 104243281A
Authority
CN
China
Prior art keywords
client
server
media server
message
session
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201410412680.8A
Other languages
Chinese (zh)
Other versions
CN104243281B (en
Inventor
郑俊鑫
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangzhou Huaduo Network Technology Co Ltd
Original Assignee
Beijing Biling Online Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Biling Online Information Technology Co Ltd filed Critical Beijing Biling Online Information Technology Co Ltd
Priority to CN201410412680.8A priority Critical patent/CN104243281B/en
Publication of CN104243281A publication Critical patent/CN104243281A/en
Application granted granted Critical
Publication of CN104243281B publication Critical patent/CN104243281B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Telephonic Communication Services (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The invention discloses a voice communication method based on a mobile Internet. A client side and a signaling server are communicated through long connecting with a websocket communication protocol. The client side and the server can transmit data to each other actively. A TCP frequent establishing request and a destroying request can be avoided. Occupying of network bandwidth resources is lowered, and meanwhile server resources are saved. Meanwhile, client side and server communication information is packaged through an efficient serialization bank msgpack, and the magnitude of transmitted information is lowered. The client establishes a conversation with parties, the server directly establishes a conversation for each party which needs communication, conversation marks are sent to all client sides in the conversation, after the client sides receive the conversation marks, registering at the server is carried out, after registering is successful, communication through the server can be carried out, and protocol interaction during conversation connecting is lowered.

Description

Based on the voice communication method of mobile Internet
Technical field
The invention belongs to mobile Internet speech communication field, relate to a kind of voice communication method based on mobile Internet particularly.
Background technology
Along with the development of instant messaging technology, instant communicating system, except possessing basic instant communication function, also has other many additional functions, as voice call function.Use instant communicating system to carry out voice call and become one of popular tool of communications used of mass society, but existing voice call, in connection process, between client and server, interaction times is many, TCP connection establishment is many with destruction number of times, and the message uncompressed sent, cause the waste of network bandwidth resources and server resource.
Summary of the invention
The object of the present invention is to provide a kind of voice communication method based on mobile Internet.
According to the present invention, a kind of voice communication method based on mobile Internet is provided, comprise: client and signal server set up the first communication port, any one making in client and signal server initiatively transmits data to another in client and signal server; Client and media server set up second communication passage, make media server according to the data transfer requested of client.
Preferably, in described voice communication method, described first communication port sing on web Socket agreement.
Preferably, in described voice communication method, described second communication passage is based on udp protocol.
Preferably, in described voice communication method, setting up between the first communication port and second communication passage, also comprising: client is sending call request by the first communication port to signal server; Signal server is that client creates a session by the first communication port, and this session identification is sent to all clients in session.
Preferably, in described voice communication method, after setting up second communication passage, also comprise: client receives session identification, and send log-on message to media server, described log-on message comprises session identification and user ID; Media server receives registration message, and returns to client the mark that succeeds in registration; Client forwards speech message by media server, and described speech message comprises voice content, session identification and user ID.
Preferably, in described voice communication method, media server receives registration message, and returns to client the mark that succeeds in registration and comprise: media server receives registration message, sets up session list; Media server obtains the network address corresponding to client, and adds session list; Media server returns to client the mark that succeeds in registration.
Preferably, in described voice communication method, client forwards speech message by media server and comprises: client sends speech message to media server after receiving the mark that succeeds in registration; Speech message is sent to other clients in session list by media server; Client receives and plays the speech message of media server transmission.
Preferably, in described voice communication method, the message transmitted between described client and signal server adopts efficient serializing storehouse to pack.
According to the voice communication method based on mobile Internet of the present invention, client and signal server communication adopt the long of websocket communication protocol to be connected, client and server can initiatively transmit data to the other side, and avoid frequently creating TCP request and destroying request, reduce taking of network bandwidth resources, also save server resource simultaneously.Meanwhile, client and server communication message adopt efficient serializing storehouse msgpack to pack, and reduce the size of message transfer.Client is initiated to converse with whom, by server directly to needing each side of call to create a session, and this session mark is sent to all clients in session, each client receives session mark again at server registration, succeed in registration namely by server call, decrease the protocol interaction in talkthrough.
Accompanying drawing explanation
Fig. 1 is the flow chart of the voice communication method based on mobile Internet according to the embodiment of the present invention,
Fig. 2 is the Data Control schematic diagram of the voice communication method based on mobile Internet according to the embodiment of the present invention.
Embodiment
Following discloses are that the different characteristic implementing the application provides many different execution modes or example.The specific embodiment of parts or layout is described below to simplify the present invention.Certainly, these are only that example is not intended to limit the present invention.
In addition, in the specification and in the claims, term " first ", " second " etc. for distinguishing between analogous element, and may not describe time sequencing, spatial order, hierarchal order or any other mode order, be to be understood that, if these terms used are interchangeable under suitable environment, and embodiments of the invention described herein can to describe or other orders beyond illustrating operate herein.
It should be noted that the term used in detail in the claims " comprise " should not be construed as limited to listed hereinafter go out means, it does not get rid of other elements or step.Thus, it should be interpreted as specifying the existence as feature, numeral, step or parts as described in relating to, but does not get rid of existence or the interpolation of other features one or more, numeral, step or parts or its combination.Therefore, the scope that word " comprises the equipment of device A and B " should not be only limitted to the device be only made up of assembly A and B.This means for the present invention, the associated component of equipment is A and B.
In the whole text, quoting of " embodiment " or " embodiment " is meaned that special characteristic, structure or the characteristic described in conjunction with this embodiment comprises at least one embodiment of the present invention at this specification.Thus, differing to establish a capital at the phrase " in one embodiment " occurred everywhere of specification or " in an embodiment " refers to same embodiment, but may be so.In addition, openly it will be readily apparent to one skilled in the art that in one or more embodiments according to the present invention, special characteristic, structure or characteristic can combine in any suitable manner.
Below in conjunction with the accompanying drawing in the embodiment of the present invention, be clearly and completely described the technical scheme in the embodiment of the present invention, obviously, described embodiment is only the present invention's part embodiment, instead of whole embodiments.Based on the embodiment in the present invention, those of ordinary skill in the art, not making the every other embodiment obtained under creative work prerequisite, belong to the scope of protection of the invention.
In embodiment described below, description be session between two clients, but the present invention is not limited only to two clients, can be multiple client simultaneous sessions.The present embodiment describes the present invention using customer end A and customer end B in detail as client.Client-side smart mobile phone, panel computer, notebook and the desktop computer application on any one in this way.
Fig. 1 is the flow chart of the voice communication method based on mobile Internet according to the embodiment of the present invention, and described method comprises:
S1, client and signal server set up the first communication port, and any one making in client and signal server initiatively transmits data to another in client and signal server;
S2, client send call request by the first communication port to signal server;
S3, signal server are that client creates a session by the first communication port, and this session identification is sent to all clients in session.
S4, client and media server set up second communication passage, make media server according to the data transfer requested of client.
In the present embodiment, the first communication port sing on web Socket agreement by setting up between client and signal server.WebSocket agreement is the agreement (protocol) that HTML5 mono-kind is new.Sing on web Socket agreement, client and server only needs to do an action of shaking hands, and then, just defines an express passway between client and server, just directly can realize data between the two and transmit in real time mutually.WebSocket agreement can make client and server full-duplex communication, and namely client can initiatively transmit data to server, and server also can initiatively transmit data to client.The second communication passage that client and media server are set up is based on udp protocol.
Signal server is that client creates a session by the first communication port, particularly, customer end A and customer end B send call request to signal server, signal server receives call request, and set up a session for customer end A and customer end B, and this session identification callid is sent to customer end A and customer end B.Media server transmits data according to the request of client by second communication passage.
S5, client receive session identification, and send log-on message to media server, and described log-on message comprises session identification and user ID.
S6, media server receive registration message, and return to client the mark that succeeds in registration.
In the present embodiment, media server obtains session identification and user ID that in registration message, client is corresponding, sets up session list, then return to client the message that succeeds in registration according to this registration message after receiving client transmission registration message.Specifically comprise: media server receives registration message, sets up session list; Media server obtains the network address corresponding to client, and adds session list; Media server returns to client the mark that succeeds in registration.
Particularly, after customer end A and customer end B receive the session identification callid of signal server transmission, send registration message to media server, this registration message comprises session identification callid and user ID userid.Media server receives after registration message, sets up the session list of client, and obtains customer end A and the network address corresponding to customer end B, is recorded in the lump in session list, after succeeding in registration, returns to customer end A and customer end B the mark that succeeds in registration.
S7, client forward speech message by media server, and described speech message comprises voice content, session identification and user ID.
In the present embodiment, client sends speech message to media server after receiving the mark that succeeds in registration; Speech message is sent to other clients in session list by media server; Client receives and plays the speech message of media server transmission.
On the basis of above-described embodiment, described client and the message transmitted between signal server and media server adopt efficient serializing storehouse to pack.
Fig. 2 is the Data Control schematic diagram of the voice communication method based on mobile Internet according to the embodiment of the present invention, concrete, customer end A and customer end B send session request to signal server, signal server is that customer end A and customer end B set up a common session, this session has a session identification callid, this session identification is returned to customer end A and customer end B, session identification and the user ID userid of itself are packaged as registration message and send to media server to register by customer end A and customer end B, session identification in media server acquisition registration message and user ID, and the network address of customer end A and customer end B, by session identification, user ID, network address one_to_one corresponding sets up session list.Now succeed in registration, customer end A and customer end B can be conversed, and are forwarded the speech message of each terminal transmission by media server.This speech message comprises voice content, session identification and user ID.
According to the voice communication method based on mobile Internet of the present invention, client and signal server communication adopt the long of websocket communication protocol to be connected, client and server can initiatively transmit data to the other side, and avoid frequently creating TCP request and destroying request, reduce taking of network bandwidth resources, also save server resource simultaneously.Meanwhile, client and server communication message adopt efficient serializing storehouse msgpack to pack, and reduce the size of message transfer.Client is initiated to converse with whom, by server directly to needing each side of call to create a session, and this session mark is sent to all clients in session, each client receives session mark again at server registration, succeed in registration namely by server call, decrease the protocol interaction in talkthrough.
Above-described embodiment is citing of the present invention, although disclose embodiments of the invention and accompanying drawing for the purpose of illustration, but it will be appreciated by those skilled in the art that: without departing from the spirit and scope of the invention and the appended claims, various replacement, change and amendment are all possible.Therefore, the present invention should not be limited to the content disclosed in embodiment and accompanying drawing.

Claims (8)

1., based on a voice communication method for mobile Internet, comprising:
Client and signal server set up the first communication port, and any one making in client and signal server initiatively transmits data to another in client and signal server;
Client and media server set up second communication passage, make media server according to the data transfer requested of client.
2. voice communication method according to claim 1, wherein said first communication port sing on web Socket agreement.
3. voice communication method according to claim 1, wherein said second communication passage is based on udp protocol.
4. voice communication method according to claim 1, wherein, setting up between the first communication port and second communication passage, described method also comprises:
Client sends call request by the first communication port to signal server;
Signal server is that client creates a session by the first communication port, and this session identification is sent to all clients in session.
5. voice communication method according to claim 1, wherein, after setting up second communication passage, described method also comprises:
Client receives session identification, and sends log-on message to media server, and described log-on message comprises session identification and user ID;
Media server receives registration message, and returns to client the mark that succeeds in registration;
Client forwards speech message by media server, and described speech message comprises voice content, session identification and user ID.
6. voice communication method according to claim 5, wherein, media server receives registration message, and returns to client the mark that succeeds in registration and comprise:
Media server receives registration message, sets up session list;
Media server obtains the network address corresponding to client, and adds session list;
Media server returns to client the mark that succeeds in registration.
7. voice communication method according to claim 5, wherein, client forwards speech message by media server and comprises:
Client sends speech message to media server after receiving the mark that succeeds in registration;
Speech message is sent to other clients in session list by media server;
Client receives and plays the speech message of media server transmission.
8. voice communication method according to claim 1, wherein, the message transmitted between described client and signal server adopts efficient serializing storehouse to pack.
CN201410412680.8A 2014-08-20 2014-08-20 Voice communication method based on mobile internet Active CN104243281B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410412680.8A CN104243281B (en) 2014-08-20 2014-08-20 Voice communication method based on mobile internet

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410412680.8A CN104243281B (en) 2014-08-20 2014-08-20 Voice communication method based on mobile internet

Publications (2)

Publication Number Publication Date
CN104243281A true CN104243281A (en) 2014-12-24
CN104243281B CN104243281B (en) 2018-04-27

Family

ID=52230671

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410412680.8A Active CN104243281B (en) 2014-08-20 2014-08-20 Voice communication method based on mobile internet

Country Status (1)

Country Link
CN (1) CN104243281B (en)

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106297791A (en) * 2016-08-25 2017-01-04 Tcl集团股份有限公司 A kind of omnidistance voice realization method and system
CN106357697A (en) * 2016-11-14 2017-01-25 威创软件南京有限公司 Multi-terminal page synchronizing method based on WebSocket attribute synchronization
CN109462735A (en) * 2018-12-24 2019-03-12 苏州华兴源创科技股份有限公司 Terminal, video calling control system and method
CN110943910A (en) * 2019-12-10 2020-03-31 杭州当虹科技股份有限公司 WebSocket-based interphone implementation method
CN111385666A (en) * 2020-03-04 2020-07-07 北京字节跳动网络技术有限公司 Communication link establishing method, device, equipment and storage medium
CN112153224A (en) * 2020-09-22 2020-12-29 上海博泰悦臻电子设备制造有限公司 Vehicle data sending and acquiring method and related equipment
CN112583638A (en) * 2020-11-25 2021-03-30 新浪网技术(中国)有限公司 Websocket-based voice alarm method and system
WO2021068973A1 (en) * 2019-10-12 2021-04-15 华为技术有限公司 Data communication method and device employing application layer protocol
CN113542260A (en) * 2021-07-12 2021-10-22 宏图智能物流股份有限公司 Warehouse voice transmission method based on distribution mode
CN113747100A (en) * 2021-08-24 2021-12-03 深圳Tcl新技术有限公司 Audio and video call method and device, storage medium and electronic equipment

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102843784A (en) * 2012-08-13 2012-12-26 北京小米科技有限责任公司 Call access method, equipment and system
CN103546584A (en) * 2013-11-13 2014-01-29 深圳市中兴移动通信有限公司 Information pushing method and system
CN103874019A (en) * 2014-03-11 2014-06-18 腾讯科技(深圳)有限公司 Voice interaction method and device
CN103957135A (en) * 2014-04-24 2014-07-30 北京佳讯飞鸿电气股份有限公司 Method for no-break conversation in IP address switching process
CN103986695A (en) * 2014-04-23 2014-08-13 广州华多网络科技有限公司 Method and device for controlling speech session

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102843784A (en) * 2012-08-13 2012-12-26 北京小米科技有限责任公司 Call access method, equipment and system
CN103546584A (en) * 2013-11-13 2014-01-29 深圳市中兴移动通信有限公司 Information pushing method and system
CN103874019A (en) * 2014-03-11 2014-06-18 腾讯科技(深圳)有限公司 Voice interaction method and device
CN103986695A (en) * 2014-04-23 2014-08-13 广州华多网络科技有限公司 Method and device for controlling speech session
CN103957135A (en) * 2014-04-24 2014-07-30 北京佳讯飞鸿电气股份有限公司 Method for no-break conversation in IP address switching process

Cited By (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106297791A (en) * 2016-08-25 2017-01-04 Tcl集团股份有限公司 A kind of omnidistance voice realization method and system
CN106297791B (en) * 2016-08-25 2020-08-18 Tcl科技集团股份有限公司 Whole-process voice implementation method and system
CN106357697A (en) * 2016-11-14 2017-01-25 威创软件南京有限公司 Multi-terminal page synchronizing method based on WebSocket attribute synchronization
CN109462735A (en) * 2018-12-24 2019-03-12 苏州华兴源创科技股份有限公司 Terminal, video calling control system and method
WO2021068973A1 (en) * 2019-10-12 2021-04-15 华为技术有限公司 Data communication method and device employing application layer protocol
CN110943910A (en) * 2019-12-10 2020-03-31 杭州当虹科技股份有限公司 WebSocket-based interphone implementation method
CN111385666A (en) * 2020-03-04 2020-07-07 北京字节跳动网络技术有限公司 Communication link establishing method, device, equipment and storage medium
CN112153224A (en) * 2020-09-22 2020-12-29 上海博泰悦臻电子设备制造有限公司 Vehicle data sending and acquiring method and related equipment
CN112583638A (en) * 2020-11-25 2021-03-30 新浪网技术(中国)有限公司 Websocket-based voice alarm method and system
CN113542260A (en) * 2021-07-12 2021-10-22 宏图智能物流股份有限公司 Warehouse voice transmission method based on distribution mode
CN113747100A (en) * 2021-08-24 2021-12-03 深圳Tcl新技术有限公司 Audio and video call method and device, storage medium and electronic equipment
CN113747100B (en) * 2021-08-24 2024-01-23 深圳Tcl新技术有限公司 Audio and video call method and device, storage medium and electronic equipment

Also Published As

Publication number Publication date
CN104243281B (en) 2018-04-27

Similar Documents

Publication Publication Date Title
CN104243281A (en) Voice communication method based on mobile Internet
US10389787B2 (en) Method, apparatus and system for transmitting media stream
KR102110698B1 (en) Terminal interconnection method, device and storage medium
CN103188300B (en) The methods, devices and systems of VOIP phone are realized in cloud computing environment
CN102845123B (en) Virtual private cloud connection method and tunnel proxy server
CN105531979B (en) It is a kind of for exchanging the method and server of data between a client and a server
US20120297031A1 (en) Anonymous Signalling
CN104620611A (en) Messaging service active device
CN103108037B (en) A kind of communication means, Web server and Web communication system
CN104283760A (en) Method, related device and system for WebRTC communication
CN103929438B (en) Firewall traversal method, equipment and system based on web page browser communication
CN108712320A (en) Information push method and device
CN102752230A (en) Method and system for sharing subscriber relationship chain
CN104022947A (en) Quantum private communication HTTP (Hyper Text Transport Protocol) proxy gateway
CN102932470B (en) Handheld device controls the method and system of computer terminal
CN105306695A (en) Communication method of mobile terminal and mobile terminal
CN104780230A (en) Method of automatically acquiring cloud server IP address, system and cloud system
CN103167038A (en) Data transmission method of user terminal
CN105391702A (en) Audio/video communication method, terminal, server and platform
CN102282886B (en) Method, mobile terminal, device and system for implementing voice services
WO2010009642A1 (en) Method, system and device for implementing short message among enterprises
ATE428143T1 (en) ON-CHIP SYSTEM FOR CONNECTING EXTERNAL FUNCTIONAL UNITS WITH A SINGLE PARAMETERIZABLE COMMUNICATION PROTOCOL
CN102291402A (en) Method, device and system for passing through private network
CN103179229A (en) Data service communication method, equipment and system
CN104158884A (en) Voice communication method based on mobile Internet

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
TA01 Transfer of patent application right
TA01 Transfer of patent application right

Effective date of registration: 20180320

Address after: 511442 Guangzhou City, Guangdong Province, Panyu District, South Village, Huambo, No. 79, No. two road, Business District Wanda Commercial Plaza, North building, B-1 floor, floor

Applicant after: Guangzhou Huaduo Network Technology Co., Ltd.

Address before: 100020 7 layer 710, No. 39, Chaoyang District diazepam Road, Beijing

Applicant before: BEIJING BILING ONLINE INFORMATION TECHNOLOGY CO., LTD.

GR01 Patent grant
GR01 Patent grant
EE01 Entry into force of recordation of patent licensing contract
EE01 Entry into force of recordation of patent licensing contract

Application publication date: 20141224

Assignee: GUANGZHOU CUBESILI INFORMATION TECHNOLOGY Co.,Ltd.

Assignor: GUANGZHOU HUADUO NETWORK TECHNOLOGY Co.,Ltd.

Contract record no.: X2021980000101

Denomination of invention: Voice communication method based on mobile Internet

Granted publication date: 20180427

License type: Common License

Record date: 20210106