Tag Archives | VoIP

Broadvoice – Fastest proxy switcher for asterisk.

#!/bin/bash curhip=(`cat /etc/hosts | grep sip.broadvoice.com | awk ‘{ print $1 }’`) echo “Current IP: $curhip” chkip=”(`ping -c 2 sip.broadvoice.com`)” curiplow=(`echo $chkip | grep PING | grep -Eo ‘\b[[:digit:]]{1,3}\.[[:digit:]]{1,3}\.[[:digit:]]{1,3}\.[[:digit:]]{1,3}\b’ | uniq`) curlow=(`echo $chkip | grep -o ‘time\s[0-9]\+[^ms]‘ | awk ‘{ print $2 }’`) function getnewlow { echo “Testing: $1″ chkip=”(`ping -c 2 $1`)” curip=(`echo $chkip […]

Continue Reading 0

chan_datacard

Chan_datacard is an Asterisk channel driver for Huawei UMTS / 3G datacards. Supported features: * Place voice calls and terminate voice calls * Send SMS and receive SMS * Send and receive USSD commands / messages Example dialplan: [datacard-incoming] exten => sms,1,Verbose(Incoming SMS from ${CALLERID(num)} ${SMS}) exten => sms,n,System(echo ‘${STRFTIME(${EPOCH},,%Y-%m-%d %H:%M:%S)} – ${DATACARD} – ${CALLERID(num)}: […]

Continue Reading 0

Text to Speech AGI

#!/usr/bin/perl #————————- #Text to Speech AGI #Mod by V #ver 0.03 #http://www.deepthought.ws #————————————————————————— #Standard Usage # Usage: exten => s,n,AGI(tts.pl,TEXT,VOICEENGINE,BACKGROUND,DELFILE) #Background Usage # exten => s,n,AGI(tts.pl,TEXT,VOICEENGINE,1,1) # exten => s,3,Background(${MY_VOICEFILE}) #-Optional: # exten => s,n,System(rm /var/lib/asterisk/sounds/tts/${MY_VOICEFILE}) #————————————————————————— use Asterisk::AGI; use File::Basename; use Digest::MD5 qw(md5_hex); $AGI = new Asterisk::AGI; my %input = $AGI->ReadParse(); my ($text)=$ARGV[0]; my […]

Continue Reading 0

Hack to emulate DISA

Crude hack to emulate DISA. It requires the user to hit the # key when they are finished dialing. [DISA_hack] exten => s,1,Answer exten => s,2,Wait(1) exten => s,3,Authenticate(${DISA_password}) exten => s,4,Playtones(dial) exten => s,5,Read(1stnumber,,1) exten => s,6,StopPlaytones exten => s,7,Read(restofnumber) exten => s,8,Goto(default,${1stnumber}${restofnumber},1)

Continue Reading 0

Powered by recycled bites and bytes.