<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META content="MSHTML 5.00.3700.6699" name=GENERATOR>
<STYLE>@font-face {
        font-family: Tahoma;
}
P.MsoNormal {
        FONT-FAMILY: "Times New Roman"; FONT-SIZE: 12pt; MARGIN: 0in 0in 0pt
}
LI.MsoNormal {
        FONT-FAMILY: "Times New Roman"; FONT-SIZE: 12pt; MARGIN: 0in 0in 0pt
}
DIV.MsoNormal {
        FONT-FAMILY: "Times New Roman"; FONT-SIZE: 12pt; MARGIN: 0in 0in 0pt
}
A:link {
        COLOR: blue; TEXT-DECORATION: underline
}
SPAN.MsoHyperlink {
        COLOR: blue; TEXT-DECORATION: underline
}
A:visited {
        COLOR: purple; TEXT-DECORATION: underline
}
SPAN.MsoHyperlinkFollowed {
        COLOR: purple; TEXT-DECORATION: underline
}
SPAN.emailstyle17 {
        COLOR: windowtext; FONT-FAMILY: Arial
}
SPAN.EmailStyle18 {
        COLOR: navy; FONT-FAMILY: Arial
}
DIV.Section1 {
        page: Section1
}
</STYLE>
</HEAD>
<BODY bgColor=white lang=EN-US link=blue vLink=purple>
<DIV align=left class=OutlookMessageHeader dir=ltr><FONT color=#0000ff
face=Arial size=2><SPAN class=159012217-06112003>Sorry that got accidentally
sent incompleted, here's the full post:</SPAN></FONT></DIV>
<DIV align=left class=OutlookMessageHeader dir=ltr><FONT color=#0000ff
face=Arial size=2><SPAN class=159012217-06112003></SPAN></FONT> </DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN class=508350617-06112003>OK,
here is the long drawn out description of how I am using Zap Barge and
Monitor:</SPAN></FONT></DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=508350617-06112003></SPAN></FONT> </DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=508350617-06112003></SPAN></FONT> </DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=508350617-06112003></SPAN></FONT> </DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=508350617-06112003>Zapbarge(listen in on live calls):</SPAN></FONT></DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=508350617-06112003></SPAN></FONT> </DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN class=508350617-06112003>Very
simple actually I just added this to my dial
plan(extensions.conf):</SPAN></FONT></DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=508350617-06112003></SPAN></FONT> </DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=508350617-06112003> ; barge monitoring
extension<BR> exten =>
8159,1,ZapBarge<BR> exten =>
8159,2,Hangup</SPAN></FONT></DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=508350617-06112003></SPAN></FONT> </DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN class=508350617-06112003>Then
when you dial 8159 on a phone you get asked which line you want to listen in on,
for Zap/1-1 you would press 1#, for Zap/25-1 you would press
25#</SPAN></FONT></DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=508350617-06112003></SPAN></FONT> </DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN class=508350617-06112003>and
that leads into the next phase, the recording of calls and also how people know
who is on which channel so they can record/Barge.</SPAN></FONT></DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=508350617-06112003></SPAN></FONT> </DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=508350617-06112003></SPAN></FONT> </DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=508350617-06112003></SPAN></FONT> </DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=508350617-06112003>Monitor(and other manager
functions)</SPAN></FONT></DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=508350617-06112003></SPAN></FONT> </DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN class=508350617-06112003>This
is much more complex than Barge, for this solution I decided to write <SPAN
class=159012217-06112003>a couple </SPAN>server programs and a perl/TK
client that can run on a Linux or Win32 desktop. </SPAN></FONT></DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=508350617-06112003></SPAN></FONT> </DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN class=508350617-06112003>First
the server side of things:</SPAN></FONT></DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN class=508350617-06112003>-
created a constantly run perl script that telnets into the Manager interface of
Asterisk and gets the "show channels" output every 333 milliseconds, it then
queries a database to see which "phone extension to Zap channel" are not in it
already and inserts them as well as deleting channels that are no longer active.
I chose to do it this way because it can scale easily without affecting the
Asterisk server at all.</SPAN></FONT></DIV>
<DIV><SPAN class=508350617-06112003><FONT color=#0000ff face=Arial size=2>-
created a cron job perl script that runs every 5 minutes to take the recording
files, merge them with soxmix and copy them to a universal storage location so
they can be easily retrieved<BR><SPAN
class=159012217-06112003> </SPAN></FONT></SPAN></DIV>
<DIV><SPAN class=508350617-06112003><FONT color=#0000ff face=Arial size=2><SPAN
class=159012217-06112003></SPAN></FONT></SPAN><SPAN
class=508350617-06112003><FONT color=#0000ff face=Arial size=2><SPAN
class=159012217-06112003>Now the Client side:</SPAN></FONT></SPAN></DIV>
<DIV><SPAN class=508350617-06112003><FONT color=#0000ff face=Arial size=2><SPAN
class=159012217-06112003>- created a perl/TK program that woudl pull the current
live calls information from the database every second using Net::MySQL and
displays them in listboxes(so you can see which person is on which Zap channel),
when the person whose phone you have selected is on a phone call, the recording
button is enabled and you can start recording. Recording is accomplished by the
program telnetting into the Asterisk Manager and sending the Monitor command for
the specific channel, and Stopping recording is done similarly with the
StopMonitor command. I also created the ability to Originate calls through this
interface. I eventually plan on adding a recently called Browsebox to initiate
calls and a few other Manager commands like transfers and moving calls into
meetme rooms. I chose Perl/TK because it is very fast and easy to develop in and
is cross platform because we have an equal number of Win32 machines and linux
machines in our office.</SPAN></FONT></SPAN></DIV>
<DIV><SPAN class=508350617-06112003><FONT color=#0000ff face=Arial size=2><SPAN
class=159012217-06112003></SPAN></FONT></SPAN> </DIV>
<DIV><SPAN class=508350617-06112003><FONT color=#0000ff face=Arial size=2><SPAN
class=159012217-06112003>If you have any other specific questions please let me
know.</SPAN></FONT></SPAN></DIV>
<DIV><SPAN class=508350617-06112003><FONT color=#0000ff face=Arial size=2><SPAN
class=159012217-06112003></SPAN></FONT></SPAN> </DIV>
<DIV><SPAN class=508350617-06112003><FONT color=#0000ff face=Arial size=2><SPAN
class=159012217-06112003>MATT---</SPAN></FONT></SPAN></DIV>
<DIV><SPAN class=508350617-06112003><FONT color=#0000ff face=Arial size=2><SPAN
class=159012217-06112003> </SPAN><BR></DIV></FONT></SPAN>
<BLOCKQUOTE style="MARGIN-RIGHT: 0px">
<DIV align=left class=OutlookMessageHeader dir=ltr><FONT face=Tahoma
size=2>-----Original Message-----<BR><B>From:</B> David Gomillion
[mailto:dgomillion@eyecarenow.com]<BR><B>Sent:</B> Thursday, November 06, 2003
10:56 AM<BR><B>To:</B> 'mattf'<BR><B>Subject:</B> RE: [Asterisk-Users]
recording calls<BR><BR></DIV></FONT>
<DIV class=Section1>
<P class=MsoNormal><FONT color=navy face=Arial size=2><SPAN
style="COLOR: navy; FONT-FAMILY: Arial; FONT-SIZE: 10pt">I think I am keenly
interested in this. Let me make sure I have this correct first,
though.</SPAN></FONT></P>
<P class=MsoNormal><FONT color=navy face=Arial size=2><SPAN
style="COLOR: navy; FONT-FAMILY: Arial; FONT-SIZE: 10pt"> </SPAN></FONT></P>
<P class=MsoNormal><FONT color=navy face=Arial size=2><SPAN
style="COLOR: navy; FONT-FAMILY: Arial; FONT-SIZE: 10pt">You are able to
monitor which lines are in use and record calls that are in progress (assuming
they come in via a Zap channel)? </SPAN></FONT></P>
<P class=MsoNormal><FONT color=navy face=Arial size=2><SPAN
style="COLOR: navy; FONT-FAMILY: Arial; FONT-SIZE: 10pt"> </SPAN></FONT></P>
<P class=MsoNormal><FONT color=navy face=Arial size=2><SPAN
style="COLOR: navy; FONT-FAMILY: Arial; FONT-SIZE: 10pt">If this is correct, I
would like to know how you did it. To be honest, I am not familiar with
the Manager interface. I have been looking at Asterisk for about a month
now, have a test system in place, and have mostly been
playing.</SPAN></FONT></P>
<P class=MsoNormal><FONT color=navy face=Arial size=2><SPAN
style="COLOR: navy; FONT-FAMILY: Arial; FONT-SIZE: 10pt"> </SPAN></FONT></P>
<P class=MsoNormal><FONT color=navy face=Arial size=2><SPAN
style="COLOR: navy; FONT-FAMILY: Arial; FONT-SIZE: 10pt">If you could help me
with this, I would be very interested!</SPAN></FONT></P>
<P class=MsoNormal><FONT color=navy face=Arial size=2><SPAN
style="COLOR: navy; FONT-FAMILY: Arial; FONT-SIZE: 10pt"> </SPAN></FONT></P>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face=Tahoma size=2><SPAN
style="FONT-FAMILY: Tahoma; FONT-SIZE: 10pt">-----Original
Message-----<BR><B><SPAN style="FONT-WEIGHT: bold">From:</SPAN></B>
asterisk-users-admin@lists.digium.com
[mailto:asterisk-users-admin@lists.digium.com] <B><SPAN
style="FONT-WEIGHT: bold">On Behalf Of </SPAN></B>mattf<BR><B><SPAN
style="FONT-WEIGHT: bold">Sent:</SPAN></B> </SPAN></FONT><FONT face=Tahoma
size=2><SPAN style="FONT-FAMILY: Tahoma; FONT-SIZE: 10pt">Wednesday, November
05, 2003</SPAN></FONT><FONT face=Tahoma size=2><SPAN
style="FONT-FAMILY: Tahoma; FONT-SIZE: 10pt"> </SPAN></FONT><FONT face=Tahoma
size=2><SPAN style="FONT-FAMILY: Tahoma; FONT-SIZE: 10pt">5:15
PM</SPAN></FONT><FONT face=Tahoma size=2><SPAN
style="FONT-FAMILY: Tahoma; FONT-SIZE: 10pt"><BR><B><SPAN
style="FONT-WEIGHT: bold">To:</SPAN></B>
'asterisk-users@lists.digium.com'<BR><B><SPAN
style="FONT-WEIGHT: bold">Subject:</SPAN></B> RE: [Asterisk-Users] recording
calls</SPAN></FONT></P>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN style="FONT-SIZE: 12pt"> </SPAN></FONT></P>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT color=blue face=Arial
size=2><SPAN
style="COLOR: blue; FONT-FAMILY: Arial; FONT-SIZE: 10pt">Hello,</SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN style="FONT-SIZE: 12pt"> </SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT color=blue face=Arial
size=2><SPAN style="COLOR: blue; FONT-FAMILY: Arial; FONT-SIZE: 10pt">You can
use ZapBarge as an extension in your dialplan to listen in on conversations
going on in Zap channels(Zaptel device channels)</SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN style="FONT-SIZE: 12pt"> </SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT color=blue face=Arial
size=2><SPAN style="COLOR: blue; FONT-FAMILY: Arial; FONT-SIZE: 10pt">As for
recording you can use the Manager interface command StartMonitor to start
recording of a Zap channel and StopMonitor to stop it.</SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN style="FONT-SIZE: 12pt"> </SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT color=blue face=Arial
size=2><SPAN style="COLOR: blue; FONT-FAMILY: Arial; FONT-SIZE: 10pt">Zap
channels are pretty much the only ones right now that you can directly monitor
and record through Asterisk. </SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN style="FONT-SIZE: 12pt"> </SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT color=blue face=Arial
size=2><SPAN style="COLOR: blue; FONT-FAMILY: Arial; FONT-SIZE: 10pt">If these
sound like they'll work for you, you can lookup the specifics online or ask me
and I'll try to do a brief overview of them. We are using the Asterisk
Manager functions together with a Perl/TK phone command program to show people
on our phone system who is on the phone and to record and originate phone
calls. It works rather well and uses the manager interface to
Asterisk.</SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN style="FONT-SIZE: 12pt"> </SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT color=blue face=Arial
size=2><SPAN
style="COLOR: blue; FONT-FAMILY: Arial; FONT-SIZE: 10pt">MATT---</SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN style="FONT-SIZE: 12pt"> </SPAN></FONT></P></DIV>
<BLOCKQUOTE style="MARGIN-BOTTOM: 5pt; MARGIN-RIGHT: 0in; MARGIN-TOP: 5pt">
<P class=MsoNormal
style="MARGIN-BOTTOM: 12pt; MARGIN-LEFT: 0.5in; MARGIN-RIGHT: 0in"><FONT
face=Tahoma size=2><SPAN
style="FONT-FAMILY: Tahoma; FONT-SIZE: 10pt">-----Original
Message-----<BR><B><SPAN style="FONT-WEIGHT: bold">From:</SPAN></B> Todd
Wallace [mailto:twallace_list@touchstonetel.com]<BR><B><SPAN
style="FONT-WEIGHT: bold">Sent:</SPAN></B> </SPAN></FONT><FONT face=Tahoma
size=2><SPAN style="FONT-FAMILY: Tahoma; FONT-SIZE: 10pt">Wednesday,
November 05, 2003</SPAN></FONT><FONT face=Tahoma size=2><SPAN
style="FONT-FAMILY: Tahoma; FONT-SIZE: 10pt"> </SPAN></FONT><FONT
face=Tahoma size=2><SPAN style="FONT-FAMILY: Tahoma; FONT-SIZE: 10pt">4:58
PM</SPAN></FONT><FONT face=Tahoma size=2><SPAN
style="FONT-FAMILY: Tahoma; FONT-SIZE: 10pt"><BR><B><SPAN
style="FONT-WEIGHT: bold">To:</SPAN></B>
asterisk-users@lists.digium.com<BR><B><SPAN
style="FONT-WEIGHT: bold">Subject:</SPAN></B> [Asterisk-Users] recording
calls</SPAN></FONT></P>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face=Arial size=2><SPAN
style="FONT-FAMILY: Arial; FONT-SIZE: 10pt">Is there a way or an "Open
Source" product that allows you to record and/or monitor calls in
progress?</SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN style="FONT-SIZE: 12pt"> </SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN style="FONT-SIZE: 12pt"> </SPAN></FONT></P></DIV>
<DIV>
<P class=MsoNormal style="MARGIN-LEFT: 0.5in"><FONT face="Times New Roman"
size=3><SPAN style="FONT-SIZE: 12pt">Todd
Wallace</SPAN></FONT></P></DIV></BLOCKQUOTE></DIV></BLOCKQUOTE></BODY></HTML>