View previous topic :: View next topic |
Author |
Message |
frank at impactfax.com Guest
|
Posted: Sun Dec 28, 2008 2:07 pm Post subject: [Freeswitch-users] session_record post-processing |
|
|
Quote: | Maybe I am going about this all wrong. All I am trying to do is process a recording file of a session after either one of the legs hangs up and the call is over. I am just trying to convert the wav to mp3 and email it off. So I have a bash script to do this. The dialplan is simple enought <action application="set" data="RECORD_ANSWER_REQ=true"/> <action application="set" data="RECORD_STEREO=true"/> <action application="record_session" data="$${base_dir}/recordings/3329000_1.wav"/> <action application="bridge" data="${enum_auto_route}"/> <action application="hangup"/> |
using FS svn 10960
But nothing I have tried seems to get it done. I have tried to use api_hangup_hook to call a lua script. But the wav file is not yet closed for some reason yet and I cannot seem to close it in the lua script. Basically I get the same problem if I use ‘system’ with the api_hangup_hook to call the bash script to process the recording.
I have tried to use the transfer application with the api_hangup_hook to allow me to stop_record_session and then a system call from another extension, but the transfer never happens on hangup.
Am I missing a simple way to do this? Is there something similar to the ‘h’ extension in asterisk maybe? |
|
Back to top |
|
|
msc at freeswitch.org Guest
|
Posted: Mon Dec 29, 2008 10:55 am Post subject: [Freeswitch-users] session_record post-processing |
|
|
I wonder if putting a sleep statement in your shell script might help. If it's a timing issue then possibly the shell script is trying to access the file before FS and/or the OS are done with it. You would need to tinker with how long to sleep in order to find a value that works in all cases.
-MC
Sent from my iPhone
On Dec 28, 2008, at 11:06 AM, "Frank @ Impact" <frank@impactfax.com (frank@impactfax.com)> wrote:
Quote: | Quote: | Maybe I am going about this all wrong. All I am trying to do is process a recording file of a session after either one of the legs hangs up and the call is over. I am just trying to convert the wav to mp3 and email it off. So I have a bash script to do this. The dialplan is simple enought <action application="set" data="RECORD_ANSWER_REQ=true"/> <action application="set" data="RECORD_STEREO=true"/> <action application="record_session" data="$${base_dir}/recordings/3329000_1.wav"/> <action application="bridge" data="${enum_auto_route}"/> <action application="hangup"/> |
using FS svn 10960
But nothing I have tried seems to get it done. I have tried to use api_hangup_hook to call a lua script. But the wav file is not yet closed for some reason yet and I cannot seem to close it in the lua script. Basically I get the same problem if I use ‘system’ with the api_hangup_hook to call the bash script to process the recording.
I have tried to use the transfer application with the api_hangup_hook to allow me to stop_record_session and then a system call from another extension, but the transfer never happens on hangup.
Am I missing a simple way to do this? Is there something similar to the ‘h’ extension in asterisk maybe?
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
|
|
Back to top |
|
|
frank at impactfax.com Guest
|
Posted: Mon Dec 29, 2008 12:39 pm Post subject: [Freeswitch-users] session_record post-processing |
|
|
Yes. I had tried that. Put a sleep 15 in the shell script before I looked at the file. Same results however. FS just does not appear to be closing that record file on hangup.
-----Original Message-----
From: freeswitch-users-bounces@lists.freeswitch.org [mailto:freeswitch-users-bounces@lists.freeswitch.org] On Behalf Of Michael S Collins
Sent: Monday, December 29, 2008 10:51 AM
To: freeswitch-users@lists.freeswitch.org
Subject: Re: [Freeswitch-users] session_record post-processing
I wonder if putting a sleep statement in your shell script might help. If it's a timing issue then possibly the shell script is trying to access the file before FS and/or the OS are done with it. You would need to tinker with how long to sleep in order to find a value that works in all cases.
-MC |
|
Back to top |
|
|
msc at freeswitch.org Guest
|
Posted: Mon Dec 29, 2008 3:00 pm Post subject: [Freeswitch-users] session_record post-processing |
|
|
Curious: what are your endpoints? Also, what codec(s), etc. are you using? I'm using PCMU with openzap endpoints and I don't get anything like this at all. I'd like to try and emulate what you've got more closely to see if I can reproduce the symptoms.
Thanks,
MC
On Mon, Dec 29, 2008 at 9:39 AM, Frank @ Impact <frank@impactfax.com (frank@impactfax.com)> wrote:
|
|
Back to top |
|
|
frank at impactfax.com Guest
|
Posted: Tue Dec 30, 2008 10:12 am Post subject: [Freeswitch-users] session_record post-processing |
|
|
The two endpoints are sip (asterisk) and ulaw.
Thanks.
-----Original Message-----
From: freeswitch-users-bounces@lists.freeswitch.org [mailto:freeswitch-users-bounces@lists.freeswitch.org] On Behalf Of Michael Collins
Sent: Monday, December 29, 2008 2:56 PM
To: freeswitch-users@lists.freeswitch.org
Subject: Re: [Freeswitch-users] session_record post-processing
Curious: what are your endpoints? Also, what codec(s), etc. are you using? I'm using PCMU with openzap endpoints and I don't get anything like this at all. I'd like to try and emulate what you've got more closely to see if I can reproduce the symptoms.
Thanks,
MC |
|
Back to top |
|
|
mike at jerris.com Guest
|
Posted: Tue Dec 30, 2008 10:50 am Post subject: [Freeswitch-users] session_record post-processing |
|
|
Try svn revision 11002 or later, it should now remove the media bugs earlier on hangup state before the api_hangup_hook is run.
Mike
On Dec 30, 2008, at 10:12 AM, Frank @ Impact wrote:
|
|
Back to top |
|
|
|