Solved

Can I some how Pause and Unpause the Asterisk Monitor command on Asterisk 1.2

Posted on 2007-11-21
1
1,644 Views
Last Modified: 2013-11-12
I'm attempting to be able to record a call and be able to Pause and UnPause the Monitor command. I'm able to successfully record the call on a feature command of *9, but after starting the recording I'm no longer able to control it






Extensions.conf
DYNAMIC_FEATURES=>automon#apps#precord#unprecord
 
[macro-apprecord]
exten => s,1,GotoIf($["${XAD}" = "0" | "${XAD}" = ""]?startrec:stoprec)
exten => s,n(startrec),Playback(startmonitor)
exten => s,n,Set(XAD=1)
exten => s,n,Set(FILENAME=${TIMESTAMP}-OUT${CALLERID(number)}-^-${UNIQUEID})
exten => s,n,Set(MONITOR_EXEC_ARGS=&& nice -n 19 lame -b 96 -t -F -m m --bitwidth 16 --quiet "/var/spool/asterisk/monitor/${FILENAME}.wav" /var/spool/asterisk/monitor/${FILENAME}.mp3" && rm -f "/var/spool/asterisk/monitor/${FILENAME}.wav" && mutt -s "Test Email" foo@foo.net -a  "/var/spool/asterisk/monitor/${FILENAME}.mp3")
exten => s,n,Monitor(wav,${FILENAME},m)
exten => s,n,MacroExit
exten => s,n(stoprec),StopMonitor
exten => s,n,Set(XAD=0)
exten => s,n,Playback(stopmonitor)
exten => s,n,MacroExit
 
# I also add this code here, but I think it only works in 1.4 is there a way to make it work on 1.2?
 
 
[macro-pauserecord]
exten => s,1,PauseMonitor()
exten => s,n,MacroExit
 
[macro-resumerecord]
exten => s,1,UnpauseMonitor()
exten => s,n,MacroExit
 
 
 
features.conf
 
[applicationmap]
apps => *9,caller,Macro,apprecord
precord => *8,caller,Macro,pauserecord
unprecord => *7,caller,Macro,resumerecord

Open in new window

0
Comment
Question by:richardsimnett
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 36

Accepted Solution

by:
grblades earned 500 total points
ID: 20330203
I believe the PauseMonitor() command was introduced in Asterisk 1.4 so your version would not have it.

The only thing you can do is stop the monitoring and then start it again later. You will have to track the state of the recording and all the files which have been created and then run a script to join them all together again afterwards.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Ever wanted to query Cisco Call Manager CDR records from MS SQL Server? Here's how! CUCM can be configured to upload a CDR file to a given FTP server every minute. This article will show you how to set this up, schedule the import of this data an…
The Zaptel people (www.zaptel.com) got kind of annoyed with the fact that they were getting bombarded with searches for the zaptel driver system for Asterisk (not to mention they own the trademark on zaptel). So, they kindly requested that Digium ch…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…
This video shows how to use Hyena, from SystemTools Software, to update 100 user accounts from an external text file. View in 1080p for best video quality.

710 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question