[Freeswitch-users] Call recording
Sven Uszpelkat
USZPELSV at comunycarse.com
Thu Jun 15 07:49:24 UTC 2017
Hello,
We are using FreeSWITCH as a third-party recording application, i.e. we are receiving SIP calls with the complete audio of conversations taking place on another switch and we are saving this audio to a file. To achieve this we are using a simple script similar to this:
session:answer()
while(session:ready() == true) do
test = session:recordFile("/usr/local/freeswitch/recordings/test.wav", 18000, 0, 300)
session:setAutoHangup(false)
session:hangup()
end
This script will be invoked by the following dialplan:
<extension name="Recording">
<condition field="destination_number" expression=".*">
<action application="lua" data="record.lua"/>
</condition>
</extension>
Basically it seems to work quite well, but sometimes there are missing audio at the end of the recorded file. Usually it's only a few seconds, but sometimes it seems to be more. (It's like the recording sometimes goes behind the real call and when the hangup event is received the remaining audio is discarded.)
What could be the reason for this behavior? Is there something wrong with the script or is there a better way to achieve our goal?
Many thanks in advance.
Best regards,
Sven Uszpelkat
Departamento I+D
Comunycarse Network Consultants, S.L.
[Descripción: Descripción: http://www.comunycarse.com/email_images/facebook_16.jpg]<http://www.facebook.com/pages/Comunycarse/227218309114> [Descripción: Descripción: http://www.comunycarse.com/email_images/linkedin_16.jpg] <http://www.linkedin.com/company/comunycarse-s.l.> [Descripción: Descripción: http://www.comunycarse.com/email_images/twitter_16.jpg] <https://twitter.com/#!/comunycarse> [Descripción: Descripción: http://www.comunycarse.com/email_images/wordpress_16.jpg] <http://www.blog.comunycarse.com/>
Joaquín Turina, 2
28224 Pozuelo de Alarcón MADRID
Tlf. +34 917 498 700
Fax +34 917 498 720
Sabino Arana, 18
08028 BARCELONA
Tlf. +34 934 098 480
Fax +34 934 098 490
http://www.comunycarse.com<http://www.comunycarse.com/>
AVISO LEGAL
La presente comunicación y sus anexos tiene como destinatario la persona a la que va dirigida, por lo que si usted lo recibe por error debe notificarlo al remitente y eliminarlo de su sistema, no pudiendo utilizarlo, total o parcialmente, para ningún fin. Su contenido puede tener información confidencial o protegida legalmente y únicamente expresa la opinión del remitente. El uso del correo electrónico vía internet no permite asegurar ni la confidencialidad de los mensajes ni su correcta recepción. En el caso de que el destinatario no consintiera la utilización del correo electrónico deberá ponerlo en nuestro conocimiento inmediatamente.
DISCLAIMER
This message and its attachments are intended exclusively for the named addressee. If you receive this message by mistake, please delete it immediately from your system and notify the sender. You may not use this message or any part of it for any purpose. The message may contain information that is confidential or protected by law, and any opinions expressed are those of the individual sender. Internet email guarantees neither the confidentiality nor the proper receipt of the message sent. If the addressee of this message does not consent to the use of internet e-mail, please inform us immediately.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20170615/8b417d63/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.jpg
Type: image/jpeg
Size: 1630 bytes
Desc: image001.jpg
URL: <http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20170615/8b417d63/attachment-0004.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image002.jpg
Type: image/jpeg
Size: 1694 bytes
Desc: image002.jpg
URL: <http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20170615/8b417d63/attachment-0005.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image003.jpg
Type: image/jpeg
Size: 1628 bytes
Desc: image003.jpg
URL: <http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20170615/8b417d63/attachment-0006.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image004.jpg
Type: image/jpeg
Size: 1402 bytes
Desc: image004.jpg
URL: <http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20170615/8b417d63/attachment-0007.jpg>
More information about the FreeSWITCH-users
mailing list