wazo-hackathon-asterisk-stream-module icon indicating copy to clipboard operation
wazo-hackathon-asterisk-stream-module copied to clipboard

File Size is 0 after streaming channel

Open abdulgig opened this issue 3 years ago • 6 comments

Hi there @sboily @pc-m

I have tried this with Asterisk 17. The module is loaded ,

*CLI> module load res_ari_stream.so
Loaded res_ari_stream.so
  == WebSocket registered sub-protocol 'stream-channel'
 Loaded res_ari_stream.so => (Asterisk Websocket Channel Stream Module)

I pass the channel to the script and I see it starts to capture the audio,

python3 get.py 1626527094.40

WebSocket connection from '127.0.0.1:40548' for protocol 'stream-channel' accepted using version '13'
NOTICE[9548]: res_ari_stream.c:238 websocket_cb: channel 1626527094.40 : new call (interface id = 0x1)
----
----
[2021-07-17 13:06:23] NOTICE[9548]: res_ari_stream.c:247 websocket_cb: channel 1626527094.40 : end call
  == WebSocket connection from '127.0.0.1:40548' closed

However, I don't seem to get anything in the wav file. The size is 0.

fpbx:/usr/src/wazo-hackathon-asterisk-stream-module/contribs# du -hs *
4.0K    README.md
0       out.wav
4.0K    record-channel-id.py

What could be wrong ?

abdulgig avatar Jul 17 '21 13:07 abdulgig

Even with asterisk 18, same issue ! I thought version 17 was notorious for issues with streaming

abdulgig avatar Jul 17 '21 13:07 abdulgig

Hello, I'm using the plugin without issue. I'm not available for the two next weeks, but I'll check documentation if we forgot something. Is it your python script?

sboily avatar Jul 18 '21 03:07 sboily

Does the channel is answered?

sboily avatar Jul 18 '21 03:07 sboily

@sboily , thanks for following up. Yes, the channel is answered

It is the python script from this repo under the contrib directory, so not mine

Here is how I am using it,

I make the call, get the channel ID of the call and then run the script by passing the channelID. I can see the output on my asterisk CLI which I shared above also.

It could be,

  • It doesn't seem to pick media from the call
  • Can be an issue with script itself
  • Asterisk version, what version of Asterisk Re you using ?

Best Regards,

abdulgig avatar Jul 18 '21 06:07 abdulgig

By the way, I also verified if there was any rtp traffic between both the end points. It is there !

Do you have a working config? Ast Version / script

Got  RTP packet from    52.20.9.92:13984 (type 00, seq 016574, ts 104480, len 000160)                                                               [32/1827]Sent RTP packet to      195.200.221.18:49092 (type 00, seq 009057, ts 104480, len 000160)
Got  RTP packet from    52.20.9.92:13984 (type 00, seq 016575, ts 104640, len 000160)
Sent RTP packet to      195.200.221.18:49092 (type 00, seq 009058, ts 104640, len 000160)
Got  RTP packet from    195.200.221.18:49092 (type 00, seq 038476, ts 422870234, len 000160)
Got  RTP packet from    195.200.221.18:49092 (type 00, seq 038477, ts 422870394, len 000160)
Sent RTP packet to      52.20.9.92:13984 (type 00, seq 028356, ts 422870232, len 000160)
Sent RTP packet to      52.20.9.92:13984 (type 00, seq 028357, ts 422870392, len 000160)

abdulgig avatar Jul 18 '21 07:07 abdulgig

@sboily , let me know when you are around :-)

Looking forward !

abdulgig avatar Jul 26 '21 08:07 abdulgig