<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
    <title></title>
  </head>
  <body bgcolor="#ffffff" text="#000000">
    Will do, thanks very much.<br>
    <br>
    Adam<br>
    <br>
    On 3:59 PM, Anthony Minessale wrote:
    <blockquote
cite="mid:%3CCAKbxfG8VqY+B=-38ZW6JJ1NA0Vorm3G8uXTCmZv0LEtFd9hoUA@mail.gmail.com%3E"
      type="cite">
      <pre wrap="">It was a bug. next time file it in JIRA, its only by chance that I
caught this email floating in a sea of 1000 other ones.

commit 5fe3a22d83867d07f30ef7974329b2fa966747ea
Author: Anthony Minessale <a class="moz-txt-link-rfc2396E" href="mailto:anthm@freeswitch.org">&lt;anthm@freeswitch.org&gt;</a>
Date:   Wed Sep 21 11:05:33 2011 -0500

    fix inaccurate sample count in file handle, buffered samples were
being double tallied



On Wed, Sep 21, 2011 at 10:08 AM, Adam Kelloway
<a class="moz-txt-link-rfc2396E" href="mailto:adam.kelloway@newpace.ca">&lt;adam.kelloway@newpace.ca&gt;</a> wrote:
</pre>
      <blockquote type="cite">
        <pre wrap="">Hi there,

I've noticed that the variable_record_ms and variable_record_seconds values
are often inaccurate. Is there any explanation for this?

The example below shows that while the RECORD_START and RECORD_STOP events
were about 4 seconds apart, the variables claim that the file is 7 seconds
long. See the soxi output at the end, which shows that the length of the
file is 00:00:03.50, thus more in line with what the event timestamps
suggest.

RECV EVENT
Event-Name: RECORD_START
Core-UUID: 235bab4c-36c6-48af-87d7-0f30a1140d52
Event-Date-GMT: Wed, 21 Sep 2011 14:52:24 GMT
Event-Date-Timestamp: 1316616744483384
Event-Calling-File: switch_ivr_play_say.c
Event-Calling-Function: switch_ivr_record_file
Event-Calling-Line-Number: 615
Unique-ID: fa39d249-c9da-4072-aebe-4b606e661e5f
Caller-Profile-Created-Time: 1316616744483384
Caller-Channel-Created-Time: 1316616740683382
Caller-Channel-Answered-Time: 1316616740683382
variable_current_application_data:
/tmp/fa39d249-c9da-4072-aebe-4b606e661e5f.wav 120 200 2
variable_current_application: record
Record-File-Path: /tmp/fa39d249-c9da-4072-aebe-4b606e661e5f.wav

RECV EVENT
Event-Name: RECORD_STOP
Core-UUID: 235bab4c-36c6-48af-87d7-0f30a1140d52
Event-Date-GMT: Wed, 21 Sep 2011 14:52:28 GMT
Event-Date-Timestamp: 1316616748083413
Event-Calling-File: switch_ivr_play_say.c
Event-Calling-Function: switch_ivr_record_file
Event-Calling-Line-Number: 790
Unique-ID: fa39d249-c9da-4072-aebe-4b606e661e5f
Caller-Profile-Created-Time: 1316616744483384
Caller-Channel-Created-Time: 1316616740683382
Caller-Channel-Answered-Time: 1316616740683382
variable_current_application_data:
/tmp/fa39d249-c9da-4072-aebe-4b606e661e5f.wav 120 200 2
variable_current_application: record
variable_record_seconds: 7
variable_record_ms: 7000
variable_record_samples: 56000
Record-File-Path: /tmp/fa39d249-c9da-4072-aebe-4b606e661e5f.wav

root@dev:/usr/local/freeswitch# soxi
/tmp/fa39d249-c9da-4072-aebe-4b606e661e5f.wav

Input File&nbsp;&nbsp;&nbsp;&nbsp; : '/tmp/fa39d249-c9da-4072-aebe-4b606e661e5f.wav'
Channels&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : 1
Sample Rate&nbsp;&nbsp;&nbsp; : 8000
Precision&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : 16-bit
Duration&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : 00:00:03.50 =8000 samples ~ 262.5 CDDA sectors
File Size&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : 56.0k
Bit Rate&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; : 128k
Sample Encoding: 16-bit Signed Integer PCM

FreeSWITCH-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a>
<a class="moz-txt-link-freetext" href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a>
UNSUBSCRIBE:<a class="moz-txt-link-freetext" href="http://lists.freeswitch.org/mailman/options/freeswitch-users">http://lists.freeswitch.org/mailman/options/freeswitch-users</a>
<a class="moz-txt-link-freetext" href="http://www.freeswitch.org">http://www.freeswitch.org</a>


</pre>
      </blockquote>
      <pre wrap="">


</pre>
    </blockquote>
    <br>
    <div class="moz-signature">-- <br>
      Adam<br clear="all">
      -- <br clear="all">
      <table id="signature" style="font-size: 85%; color: rgb(61, 35,
        22);" border="0" cellpadding="1" cellspacing="0">
        <tbody>
          <tr>
            <td rowspan="2" align="center" valign="middle"><img
                moz-do-not-send="false"
                src="cid:part1.03000001.06070204@newpace.ca"
                alt="NewPace Logo" height="50" width="50"></td>
            <td rowspan="6" width="6px"><br>
            </td>
            <td><br>
            </td>
            <td rowspan="6" width="6px"><br>
            </td>
            <td><font style="font-weight: bold; font-size: 110%;">Adam
                Kelloway</font></td>
          </tr>
          <tr>
            <td rowspan="6" style="font-weight: bold; font-size: 100%;"
              bgcolor="#a8cf38" width="1px"><br>
            </td>
            <td>Software Engineer, NewPace</td>
          </tr>
          <tr>
            <td align="right">phone</td>
            <td>+1&nbsp;(902)&nbsp;406&#8211;8375&nbsp;&nbsp;x1031</td>
          </tr>
          <tr>
            <td align="right">email</td>
            <td><a href="mailto:Adam.Kelloway@newpace.com"
                style="text-decoration: none; color: rgb(61, 35, 22);">Adam.Kelloway@NewPace.com</a></td>
          </tr>
          <tr>
            <td align="right"><a
                href="aim:GoIm?screenname=Adam.Kelloway@newpace.com"
                style="text-decoration: none; color: rgb(61, 35, 22);">aim</a>/<a
                href="msnim:chat?contact=Adam.Kelloway@newpace.com"
                style="text-decoration: none; color: rgb(61, 35, 22);">msn</a></td>
            <td><a href="aim:GoIm?screenname=Adam.Kelloway@newpace.ca"
                style="text-decoration: none; color: rgb(61, 35, 22);">Adam.Kelloway</a>@NewPace.ca</td>
          </tr>
        </tbody>
      </table>
    </div>
  </body>
</html>