A listening interaction system and method
By encoding and encapsulating voice data and dynamically adjusting the data block size based on network conditions, the problems of real-time performance, integrity, and reliability of voice transmission in horizontal shunting operations have been solved. This has enabled efficient voice transmission in complex network environments, ensuring operational safety and efficiency.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- BEIJING CENTURY DONGFANG COMMUNICATION EQUIPMENT CO LTD
- Filing Date
- 2026-01-27
- Publication Date
- 2026-06-02
AI Technical Summary
In the monitoring and interaction scenarios of shunting operations on railways and in stations, the network environment is complex and ever-changing, making it difficult to guarantee the real-time performance, integrity and reliability of voice transmission. Distortion and disconnection are prone to occur, affecting the safety and efficiency of operations.
Voice data is encoded and encapsulated to generate voice data packets. The data block size is dynamically adjusted according to the network status. The data is transmitted in conjunction with the TCP protocol. A double-boundary identifier design for the data header and data trailer is adopted. The data block size is dynamically adjusted, unacknowledged data packets are buffered and resent when the network recovers. Voice data packets are processed first, and the MTU size is limited to achieve a balance between transmission efficiency and quality.
It effectively solves the problems of voice lag and disconnection in weak network scenarios, improves the real-time performance, integrity and reliability of voice transmission, and significantly improves operational safety and overall operating efficiency.
Smart Images

Figure CN122137796A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of network communication technology, and in particular to a monitoring and interaction system and method. Background Technology
[0002] In the scenario of monitoring and interacting with shunting operations on railways and at stations, efficient communication between shunting personnel and the dispatch center and on-site personnel is crucial to ensuring operational safety.
[0003] In related technologies, shunting operations often take place in open outdoor environments with complex and variable network conditions, which are prone to distortion and disconnection. Therefore, how to effectively meet the requirements of real-time, complete, and reliable voice transmission for monitoring and interaction in shunting operations has become a technical problem that urgently needs to be solved by those skilled in the art. Summary of the Invention
[0004] This invention provides a monitoring and interaction system and method. By encoding and encapsulating voice data and dynamically adjusting the data block size in the voice data packet according to the network status, it can effectively adapt to the complex outdoor environment of shunting operations, achieve a dynamic balance between transmission efficiency and transmission quality, effectively solve the problems of voice stuttering and disconnection in weak network scenarios, provide multiple guarantees for the real-time performance, integrity and reliability of voice transmission, and significantly improve the safety of operations and overall operating efficiency.
[0005] This invention provides a listening and interaction system, comprising: Wireless control station, shunting equipment, server, and client; The wireless zone station is used to send voice data to the shunting equipment; The shunting device is used to encode and encapsulate the voice data, generate voice data packets, and send the voice data packets to the server based on the TCP protocol; The server is used to dynamically adjust the data block size in the voice data packet according to the network status, and send the adjusted voice data packet to the client. The client is used to parse the voice data packets and play them in real time.
[0006] According to a monitoring and interaction system provided by the present invention, the step of encoding and encapsulating the voice data to generate a voice data packet includes: The voice data is PCM encoded and encapsulated by adding a data header 0x1002 and a data tail 0x1003 to obtain the voice data packet; the voice data packet is 650 bytes in size and the data block size in the voice data packet is 640 bytes.
[0007] According to a monitoring and interaction system provided by the present invention, the step of dynamically adjusting the data block size in the voice data packet based on the network status includes: When the packet loss rate is between 10% and 20%, the data block size in the voice data packet is adjusted to 320 bytes; When the packet loss rate is greater than 20%, the data block size in the voice data packet is adjusted to 160 bytes.
[0008] According to a monitoring and interaction system provided by the present invention, the shunting device is further configured to cache voice data packets that the server has not acknowledged receiving, and resend the cached voice data packets after detecting that the network has returned to normal.
[0009] According to a monitoring and interaction system provided by the present invention, the server is further configured to send a NACK command to the shunting device when a voice data packet loss is detected, requesting the shunting device to retransmit the lost voice data packet.
[0010] According to a monitoring and interaction system provided by the present invention, the server is further configured to receive signaling sent by the shunting device, set the received voice data packets to high priority, set the received signaling to low priority, and send the voice data packets and the signaling to the client in sequence based on the priority order.
[0011] According to the monitoring and interaction system provided by the present invention, the client is also used to query historical voice data and historical signaling based on time and / or shunting device identification and play them online.
[0012] According to a monitoring and interaction system provided by the present invention, the shunting device is also used to limit the MTU size to 800 bytes.
[0013] According to a monitoring and interaction system provided by the present invention, the shunting device is also used to synchronize the time of the shunting device and the wireless zone chief station.
[0014] The present invention also provides a method for monitoring interaction, comprising: Send voice data to the shunting equipment; The voice data is encoded and encapsulated to generate a voice data packet, and the voice data packet is sent to the server based on the TCP protocol; The size of the data blocks in the voice data packets is dynamically adjusted according to the network status, and the adjusted voice data packets are sent to the client. The audio data packets are parsed and played in real time.
[0015] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the above-described listening and interaction method.
[0016] The present invention also provides a computer program product, including a computer program that, when executed by a processor, implements the above-described listening and interaction method.
[0017] The present invention provides a monitoring and interaction system and method that, by encoding and encapsulating voice data and dynamically adjusting the size of data blocks in the voice data packets according to the network status, can effectively adapt to the complex outdoor environment of shunting operations, achieve a dynamic balance between transmission efficiency and transmission quality, effectively solve the problems of voice stuttering and disconnection in weak network scenarios, provide multiple guarantees for the real-time performance, integrity and reliability of voice transmission, and significantly improve operational safety and overall operating efficiency. Attached Figure Description
[0018] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.
[0019] Figure 1 This is one of the structural schematic diagrams of the monitoring and interaction system provided by the present invention.
[0020] Figure 2 This is the second structural schematic diagram of the monitoring and interaction system provided by the present invention.
[0021] Figure 3 This is a flowchart illustrating the monitoring and interaction method provided by the present invention. Detailed Implementation
[0022] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.
[0023] The following is combined with Figures 1-3 This invention describes a monitoring and interaction system and method.
[0024] To facilitate a clearer understanding of the technical solutions of the various embodiments of this application, some technical content related to the various embodiments of this application will be introduced first.
[0025] In related technologies, methods and systems for transmitting voice based on TCP have the following drawbacks: 1. The data boundary identification method is singular and has poor adaptability.
[0026] In related technologies, using only the 0x00 byte as a unique boundary identifier has obvious limitations: If the data does not contain the 0x00 byte, the entire data must be transmitted as a single data block, which may result in excessively large TCP packets and increased transmission latency. This is especially problematic for voice data that requires real-time processing; large data packets are prone to triggering the TCP retransmission mechanism, further exacerbating latency.
[0027] If the 0x00 byte appears frequently in the data, it will be split into multiple small data blocks, increasing the TCP header overhead and the complexity of the receiving end reassembling the complete packet, thus reducing transmission efficiency.
[0028] 2. TCP transmission logic was not optimized for the characteristics of voice data. The TCP protocol itself is designed for reliable transmission, but voice data has the characteristics of prioritizing real-time performance and allowing for partial packet loss. Existing technologies only segment data into static blocks and do not dynamically adjust transmission strategies based on the continuous and bursty characteristics of the voice stream. In addition, the encoding / decoding process of middleware units is not optimized for the encoding and decoding format of voice data, which may lead to voice distortion or processing delays.
[0029] 3. Lack of adaptability to complex network environments Existing technologies do not consider complex network scenarios such as weak networks and high packet loss rates. Fixed boundary markers are prone to data block segmentation errors during network fluctuations, such as the loss or misjudgment of 0x00 bytes, leading to data reassembly failure at the receiving end. Moreover, related technologies do not include dynamic retransmission or fault tolerance mechanisms. When TCP retransmission timeouts occur, voice streams are prone to stuttering or disconnection.
[0030] Figure 1 This is a schematic diagram of the monitoring and interaction system provided by the present invention, including: Wireless control station, shunting equipment, server, and client; The wireless section chief station is used to send voice data to the shunting equipment; The shunting equipment is used to encode and encapsulate voice data, generate voice data packets, and send the voice data packets to the server based on the TCP protocol; The server is used to dynamically adjust the size of data blocks in voice data packets according to network conditions, and then send the adjusted voice data packets to the client. The client is used to parse voice data packets and play them in real time.
[0031] Specifically, in this embodiment, the wireless zone manager's station collects voice information from shunting personnel and on-site workers during the monitoring interaction of shunting operations and transmits it to the shunting equipment. Optionally, after receiving the voice data sent by the wireless zone manager's station, the shunting equipment encodes and encapsulates the voice data to generate standardized voice data packets, and sends the encapsulated voice data packets to the server based on the reliable transmission characteristics of the TCP protocol. Optionally, encoding and encapsulating the voice data can ensure the real-time performance, integrity, and reliability of voice data transmission, thereby effectively adapting to the complex outdoor environment of shunting operations and ensuring operational safety and efficiency.
[0032] Optionally, after receiving the voice data packets sent by the shunting equipment, the server can dynamically adjust the data block size in the voice data packets based on real-time network packet loss rate and other status parameters between the shunting equipment and the client, and send the adjusted voice data packets to the client, effectively avoiding voice data distortion. Optionally, when the network condition is good, large data block transmission can be maintained to improve efficiency; when the network condition is poor, the data block size can be reduced to avoid voice interruptions and disconnections caused by network fluctuations, ensuring the continuity of voice transmission. Optionally, after receiving the adjusted voice data packets forwarded by the server, the client can parse the voice data packets and play them in real time, enabling operators to clearly obtain dispatch information and ensuring operational safety.
[0033] The method described in the above embodiments, by encoding and encapsulating voice data and dynamically adjusting the size of data blocks in the voice data packets according to the network status, can effectively adapt to the complex outdoor environment of shunting operations, achieve a dynamic balance between transmission efficiency and transmission quality, effectively solve the problems of voice stuttering and disconnection in weak network scenarios, provide multiple guarantees for the real-time performance, integrity and reliability of voice transmission, and significantly improve operational safety and overall operating efficiency.
[0034] In some embodiments, voice data is encoded and encapsulated to generate voice data packets, including: The voice data is PCM encoded and encapsulated by adding a data header 0x1002 and a data tail 0x1003 to obtain a voice data packet; the voice data packet size is 650 bytes, and the data block size in the voice data packet is 640 bytes.
[0035] Specifically, in this embodiment of the application, after receiving the voice data transmitted by the wireless zone chief station, the shunting device encodes it using pulse code modulation (PCM) to restore the original information of the analog voice to the greatest extent, avoid voice distortion during the encoding process, and ensure clear transmission of voice information.
[0036] Optionally, after PCM encoding the voice data, a data header (0x1002) and a data trailer (0x1003) can be added for encapsulation to form a fixed-size voice data packet. Optionally, the overall size of the encoded and encapsulated data packet is 650 bytes, of which the effective voice data block size is 640 bytes, and the data header and data trailer occupy a total of 10 bytes. It should be noted that this application, through a double-boundary identifier design of a 0x1002 data header and a 0x1003 data trailer, replaces the single-byte boundary identifier in related technologies, completely solving the problems of missegmentation and packet cross-referencing that are prone to occur with single boundaries. This enables the server and client to quickly and accurately identify the start and end positions of each voice data packet, improving parsing efficiency.
[0037] The method described in the above embodiments, by performing PCM encoding on the voice data, can preserve the original analog voice information to the greatest extent, effectively avoid encoding distortion, and ensure clear transmission of voice information. When encapsulating the voice data, a double-boundary design with a data header and data tail is adopted to replace the traditional single-byte boundary scheme, which completely solves problems such as missegmentation and packet crosstalk. This enables the server and client to quickly and accurately identify the start and end positions of the data packets, significantly improves data parsing efficiency, and effectively enhances the clarity, integrity, and parsing efficiency of voice transmission in shunting operation monitoring and interaction.
[0038] In some embodiments, dynamically adjusting the data block size in voice data packets according to network conditions includes: When the packet loss rate is between 10% and 20%, adjust the data block size in the voice data packets to 320 bytes; When the packet loss rate is greater than 20%, the data block size in the voice data packet will be adjusted to 160 bytes.
[0039] Specifically, in this embodiment, the server acquires the network transmission status between the shunting device and the client in real time. When the network packet loss rate is detected to be between 10% and 20%, the server adjusts the effective data block size in the voice data packet from the initial 640 bytes to 320 bytes. That is, when the network condition deteriorates, by appropriately reducing the data block size, the transmission risk of a single data packet is reduced, the probability of packet loss due to excessively large data packets is reduced, the continuity of voice transmission is ensured, and significant stuttering is avoided. Optionally, when the packet loss rate is greater than 20%, the data block size in the voice data packet is adjusted to 160 bytes. That is, for weak network scenarios with high packet loss, the data block size is further reduced to maximize the success rate of data packet transmission. Even under poor network conditions, the effective transmission of voice information can be ensured through the rapid transmission and retransmission of small data packets.
[0040] The method described in the above embodiments dynamically adjusts the size of voice data packets according to the network transmission status between the shunting equipment and the client, which significantly improves the system's adaptability to harsh network environments such as weak networks and high packet loss, balances transmission efficiency and transmission quality, and ensures the real-time performance and integrity of interactive voice transmission for shunting operations.
[0041] In some embodiments, the shunting device is also used to cache voice data packets that the server has not acknowledged, and to resend the cached voice data packets after the network is detected to have returned to normal.
[0042] Specifically, in this embodiment, after the shunting device sends a voice data packet to the server based on the TCP protocol, it does not immediately discard the data packet, but continuously monitors the server's reception confirmation feedback. If no reception confirmation information is received from the server within a preset time, the voice data packet is stored in the local cache space, and the cached voice data packet is resent after the network is detected to be restored to normal, until the server's reception confirmation is received or the preset number of retransmissions is reached. This effectively avoids the loss of voice data packets, ensures the integrity of voice data, and by caching unsuccessfully transmitted data packets locally, there is no need to re-encode and encapsulate them, reducing the resource consumption of repeated processing and improving the efficiency of data retransmission.
[0043] The method described in the above embodiments, by caching voice data packets that the server has not acknowledged as received, and retransmitting the cached voice data packets after detecting that the network has returned to normal, not only avoids the loss of voice data packets that have not been successfully transmitted in abnormal scenarios such as weak networks, thus ensuring the integrity of voice data transmission; but also eliminates the need for re-encoding and encapsulation of cached data packets, significantly reducing the resource consumption caused by repeated processing, significantly improving retransmission efficiency, shortening data transmission interruption time, and effectively ensuring the reliability and continuity of interactive voice transmission for shunting operations.
[0044] In some embodiments, the server is also configured to send a NACK command to the shunting equipment when a voice data packet loss is detected, requesting the shunting equipment to retransmit the lost voice data packet.
[0045] Specifically, in this embodiment, during the process of the server receiving voice data packets sent by the shunting device, the server identifies in real time whether any voice data packets are lost by verifying the sequence number of the data packets. When the server confirms that a voice data packet has been lost, it generates a NACK instruction, which identifies key information such as the sequence number and source IP of the lost data packet. This instruction is sent to the corresponding shunting device via the TCP protocol, indicating which data packet needs to be retransmitted. This ensures that the voice data packets forwarded by the server to the client are complete and intact, guaranteeing the continuity and integrity of voice transmission.
[0046] The method described in the above embodiment sends a NACK command to the shunting equipment when a voice data packet is detected to request the shunting equipment to retransmit the lost voice data packet. This ensures that the voice data forwarded by the server to the client is complete and intact, significantly improving the continuity and integrity of voice transmission. This ensures that key information such as dispatching instructions is fully conveyed during shunting operations, guaranteeing the continuity and integrity of voice transmission.
[0047] In some embodiments, the server is further configured to receive signaling sent by the shunting equipment, set the received voice data packets to high priority and the received signaling to low priority, and send the voice data packets and signaling to the client in sequence based on the priority order.
[0048] Specifically, in this embodiment, the wireless zone chief station can send not only voice data but also signaling. After receiving the voice data and signaling, the server can prioritize the received voice data packets and signaling based on the needs of monitoring and interacting with shunting operations. Voice data packets are set to high priority, and signaling is set to low priority. High-priority voice data packets are forwarded to the client first, and low-priority signaling is forwarded only after the voice data packet transmission is complete. This ensures that voice transmission is not interfered with by signaling transmission, achieving voice-first transmission. This effectively solves the bandwidth and resource contention problem during voice and signaling transmission, prevents voice stuttering and delays caused by excessive resource consumption during signaling transmission, and guarantees the real-time and continuous nature of voice communication.
[0049] The method described in the above embodiments sets voice data packets to high priority and signaling to low priority, thereby avoiding bandwidth and resource contention during voice and signaling transmission, preventing voice stuttering and delays caused by excessive signaling resource consumption, and ensuring the real-time and continuous nature of voice communication during shunting operations.
[0050] In some embodiments, the client is also used to query historical voice data and historical signaling based on time and / or shunting equipment identification and play them online.
[0051] Specifically, in this embodiment, the client can also query and play back historical voice data and signaling online based on time and / or shunting device identifiers. This effectively enables the tracing and playback of historical voice data and signaling, improving the traceability of shunting operations and the efficiency of problem investigation. Optionally, the client can support queries at precise time points or within a specific time interval. Optionally, the client can support users inputting one or more shunting device IDs to query historical data.
[0052] In some embodiments, the shunting equipment is also used to limit the MTU size to 800 bytes.
[0053] Specifically, in this embodiment, the shunting device can actively limit the maximum transmission unit (MTU) size to 800 bytes, thereby effectively adapting to the complex outdoor network environment of horizontal shunting operation monitoring and interaction, avoiding packet loss and delay caused by data packets exceeding the network link carrying capacity, and ensuring the reliability of voice data packets and signaling transmission under the TCP protocol.
[0054] In some embodiments, the shunting equipment is also used to synchronize the timing of the shunting equipment and the radio control station.
[0055] Specifically, in this embodiment of the application, the shunting device also needs to keep its time consistent with that of the wireless zone chief station, so as to effectively solve the problem of timing disorder of voice data and signaling data in shunting operations.
[0056] For example, such as Figure 2 As shown in the figure, this application provides a listening and interaction system, including: (1) Shunting equipment.
[0057] The shunting unit is used to connect to the wireless zone control station, store data locally, forward data to the server, and receive server commands. For example, the functions of each module in the shunting unit are as follows: Wireless zone manager interface: Receives hexadecimal signaling via serial port and analog voice via audio port to connect to the wireless zone manager.
[0058] Audio encoding module: performs PCM encoding on analog speech.
[0059] Voice boundary encapsulation module: Adds a 0x1002 data header and a 0x1003 data tail to PCM voice, encapsulating it into a 650-byte standard packet, of which 640 bytes are data bits, thereby effectively solving the problem of voice data boundary recognition.
[0060] Serial port protocol conversion module: Converts the hexadecimal signaling of the wireless zone chief station into JSON format, thereby effectively adapting to the text signaling interaction between the server and the client.
[0061] Local database: Stores historical voice and signaling data in WAV format, and supports remote retrieval.
[0062] Network communication module: Limits the MTU size to 800 bytes to accommodate large packet transmission restrictions imposed by network security policies and avoids packet loss during routing.
[0063] Unacknowledged data packets are cached during periods of weak network connectivity and resent once the network is restored.
[0064] NTP time synchronization module: Receives NTP commands from the server and synchronizes its own time with the wireless zone chief station to ensure data timing consistency.
[0065] (2) Server side.
[0066] The server is used for data reception / forwarding, weak network optimization, historical storage, and command scheduling.
[0067] For example, the specific functions of each module on the server side are as follows: Equipment access module: Receives voice / signaling data from the shunting equipment based on the TCP protocol.
[0068] Voice boundary resolution module: Identifies the 0x1002 header and 0x1003 tail sent by the shunting equipment, extracts valid PCM voice, and thus solves the problem of ambiguous voice data boundaries.
[0069] Weak network processing module: Dynamically adjust data block size: The voice data block size is dynamically adjusted according to the network status of the shunting equipment / client, such as packet loss rate and latency. For example: 640 bytes are used when the packet loss rate is <5%; 320 bytes are used when the packet loss rate is 10%-20%; and 160 bytes are used when the packet loss rate is >20%, thereby effectively balancing transmission efficiency and packet loss resistance.
[0070] NACK retransmission mechanism: When the server detects packet loss, it sends a message to the shunting equipment requesting the retransmission of the lost data packets, thereby effectively avoiding blind retransmission and wasting bandwidth.
[0071] Priority queue: Voice data is set to high priority and signaling is set to secondary priority to ensure the real-time performance of voice during shunting operations.
[0072] Data forwarding module: Based on the client's monitoring range, such as shunting yard No. 1 and shunting units No. 3-5, forward the real-time voice / signaling of the corresponding shunting unit.
[0073] Data storage module: Stores historical voice and signaling data, and supports retrieval by time and shunting unit ID; NTP service module: issues NTP time synchronization commands to shunting equipment to ensure time synchronization across the entire system.
[0074] Retrieval Service Module: Responds to historical data query requests from clients and returns the URL of the audio file and the JSON signaling.
[0075] (3) Client.
[0076] The client is used for real-time monitoring, command sending, and historical data management.
[0077] For example, the functions of each module in the client are as follows: Real-time monitoring module: Receives PCM voice and JSON signaling forwarded by the server and displays them visually.
[0078] Command sending module: Send microphone on / off signals to the shunting equipment to effectively control the microphone of the wireless zone chief station; Send client-side voice messages to the shunting equipment.
[0079] Historical data management module: Search: Query historical voice / signaling data by time and shunting equipment; Playback: Play WAV audio files online; Download: Supports individual downloads and packaged downloads; Export: Signaling data can be exported to Excel with one click, including information such as time, shunting device ID, signaling content, and inspection marks; Network communication module: Maintains a long connection with the server based on the TCP protocol, effectively ensuring the real-time performance of commands / data.
[0080] For example, such as Figure 3 As shown, this application also provides a method for listening to interactions, as detailed below: (1) The analog voice of the wireless section chief station is transmitted to the shunting equipment through the audio port.
[0081] (2) The shunting device converts the analog voice into PCM format, adds a 0x1002 data header and a 0x1003 data tail to the PCM voice, and encapsulates it into a 650-byte standard packet, of which 640 bytes are data bits, thereby effectively solving the problem of voice data boundary recognition.
[0082] (3) The shunting equipment sends data packets to the server via TCP. Optionally, the MTU can be limited to 800 bytes to avoid route dropping.
[0083] (4) The server identifies the 0x1002 header / 0x1003 tail and extracts the PCM voice; if the client's network packet loss rate is >10%, the server reduces the data block from 640 bytes to 320 bytes and forwards it to the client.
[0084] (5) The client decodes the PCM voice and plays it to the user in real time.
[0085] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.
[0086] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A monitoring and interaction system, characterized in that, include: Wireless control station, shunting equipment, server, and client; The wireless zone station is used to send voice data to the shunting equipment; The shunting device is used to encode and encapsulate the voice data, generate voice data packets, and send the voice data packets to the server based on the TCP protocol; The server is used to dynamically adjust the data block size in the voice data packet according to the network status, and send the adjusted voice data packet to the client. The client is used to parse the voice data packets and play them in real time.
2. The monitoring and interaction system according to claim 1, characterized in that, The process of encoding and encapsulating the voice data to generate a voice data packet includes: The voice data is PCM encoded and encapsulated by adding a data header 0x1002 and a data tail 0x1003 to obtain the voice data packet; the voice data packet is 650 bytes in size and the data block size in the voice data packet is 640 bytes.
3. The monitoring and interaction system according to claim 1, characterized in that, The step of dynamically adjusting the data block size in the voice data packet according to the network status includes: When the packet loss rate is between 10% and 20%, the data block size in the voice data packet is adjusted to 320 bytes; When the packet loss rate is greater than 20%, the data block size in the voice data packet is adjusted to 160 bytes.
4. The monitoring and interaction system according to any one of claims 1-3, characterized in that, The shunting device is also used to cache voice data packets that the server has not acknowledged receiving, and to resend the cached voice data packets after the network is detected to have returned to normal.
5. The monitoring and interaction system according to any one of claims 1-3, characterized in that, The server is also used to send a NACK command to the shunting equipment when a voice data packet loss is detected, requesting the shunting equipment to retransmit the lost voice data packet.
6. The monitoring and interaction system according to any one of claims 1-3, characterized in that, The server is also used to receive signaling sent by the shunting device, set the received voice data packets to high priority, set the received signaling to low priority, and send the voice data packets and signaling to the client in sequence based on the priority order.
7. The monitoring and interaction system according to any one of claims 1-3, characterized in that, The client is also used to query historical voice data and historical signaling based on time and / or shunting equipment identification, and play them online.
8. The monitoring and interaction system according to any one of claims 1-3, characterized in that, The shunting device is also used to limit the MTU size to 800 bytes.
9. The monitoring and interaction system according to any one of claims 1-3, characterized in that, The shunting device is also used to synchronize the time of the shunting device and the wireless zone chief station.
10. A method for monitoring interaction, characterized in that, Applied to the monitoring and interaction system as described in any one of claims 1-9, comprising: Send voice data to the shunting equipment; The voice data is encoded and encapsulated to generate a voice data packet, and the voice data packet is sent to the server based on the TCP protocol; The size of the data blocks in the voice data packets is dynamically adjusted according to the network status, and the adjusted voice data packets are sent to the client. The audio data packets are parsed and played in real time.