Decoding G711 encoded rtp payloads and generating an audio file [closed]

I've wrote a code in python to capture network traffic, identify when a voip call starts based on an implemented logic for the softphone im using, then extract the rtp payload of each rtp packet, decode it, save it in a data list, then it gets passed to a function to generate an audio file of the audio captured from the rtp packets.

now the code works but the audio is not perfect..

now my question is, where is the issue exactly ? is it in the decoding part ? or the way im handling the packets ? I can't pinpoint the issue and would appreciate any help you can give.

Kindly check this video https://streamable.com/s8c0t9 to help understand the issue more. the generated audio is played in second 15 which shows that the audio is not as it should be.

Ideally the generated audio file should contain the voip call audio exactlyt as it is.

Current code can be found here : https://github.com/OsaidAlHasan/Osaid-Al-Hasan/blob/master/G711%20Code



Comments

Popular posts from this blog

Today Walkin 14th-Sept

Spring Elasticsearch Operations

Hibernate Search - Elasticsearch with JSON manipulation