Page 1 of 1

offer sangoma voice usb

PostPosted: Mon Feb 22, 2010 2:02 pm
by brett05
we buy the sangoma voice usb tools just for tunisia people if same one need it we have many of sangoma usb now just pm me
thanks

PostPosted: Mon Feb 22, 2010 2:36 pm
by gmcust3
Do you have any handy SH file to Install VoiceTime on asterisk 1.4 and VNow 1.3 under CentOS ?

thank

PostPosted: Mon Feb 22, 2010 4:10 pm
by brett05
yes it not hard to do a sh file
what os you have it?

PostPosted: Mon Feb 22, 2010 4:12 pm
by gmcust3
CentOS.

I wrote this , following http://wiki.sangoma.com/wanpipe-linux-asterisk-install:

cd /usr/src
wget http://downloads.asterisk.org/pub/telep ... 2.1.tar.gz
tar xvfz /usr/src/zaptel-1.4.12.1.tar.gz
ln -s zaptel-1.4.12.1 zaptel
cd zaptel-1.4.12.1
./configure
make
make install
make zaptel ZAPDIR=/usr/src/zaptel-1.4.12.1
make install

wget ftp://ftp.sangoma.com/linux/current_wan ... -3.4.4.tgz
cd /usr/src
tar xvfz wanpipe-3.4.4.tgz
cd wanpipe-3.4.4
/Setup zaptel


But ITS never smooth.

Some or other Errror always popup , even in virgin VNow 1.3

thank

PostPosted: Mon Feb 22, 2010 4:16 pm
by brett05
ok wait i will wrote you a script for this
and just say thanks :D

PostPosted: Mon Feb 22, 2010 4:19 pm
by gmcust3
Thanks in Advance.

I asked Sangoma regarding it and they say Ok.. We will plan a project for the same and implement it.

thank

PostPosted: Mon Feb 22, 2010 4:51 pm
by brett05
ok this file i have do it it will install again the zaptel and asterisk and libri and wanpipe so first you need ti stop asterisk your old asterisk installed .

1= asterisk -r
2= stop now

then we need to delete all asterisk file :
rm -R /usr/lib/asterisk/modules/*.*
rm -R /etc/asterisk/*.*
rm -R /var/lib/asterisk/quiet-mp3/*.*
rm -R /var/lib/asterisk/mohmp3/*.*
rm -R /var/lib/asterisk/sounds/*.*

then create a file for exemple in /usr/src/myfile.sh
then past all this :


#!/bin/bash

function choice {
CHOICE=''
local prompt="$*"
local answer

read -p "$prompt" answer
case "$answer" in
[yY1] ) CHOICE='y';;
[nN0] ) CHOICe='n';;
* ) CHOICE="$answer";;
esac
}

echo "Asterisk v.1.4 with wanpipe voice"
echo
choice "Continue? (N/y) : "

if [ "$CHOICE" == "y" ]; then

echo
choice "Do you use centos OS? (N/y) : "
SCENTOS="$CHOICE"

echo
choice "Do you have a Sangoma T1 card installed? (N/y) : "
SANGOMA="$CHOICE"

echo
choice "Do you have a Sangoma VoiceTime USB timer installed? (N/y) : "
SANGOMAVT="$CHOICE"

choice "Do you want to put recording in RAM? (N/y) : "
SFSTAB="$CHOICE"

if [ "$SCENTOS" == "y" ]; then
yum -y install kernel-devel-$(uname -r) libtool install gcc patch perl bison gcc-c++ ncurses ncurses-devel flex libtermcap-devel lksctp-tools-devel
rpm -qa | grep zaptel
fi

echo "We will download all file :"
cd /usr/src/tars
wget http://downloads.digium.com/pub/asteris ... 1.2.tar.gz
wget http://downloads.digium.com/pub/libpri/ ... 4.9.tar.gz
wget http://downloads.digium.com/pub/zaptel/ ... 2.1.tar.gz
wget http://downloads.digium.com/pub/telepho ... ent.tar.gz
wget http://downloads.digium.com/pub/telepho ... ent.tar.gz
wget http://downloads.digium.com/pub/telepho ... ent.tar.gz
wget http://downloads.digium.com/pub/telepho ... ent.tar.gz
wget http://downloads.digium.com/pub/telepho ... ent.tar.gz
wget http://downloads.digium.com/pub/telepho ... ent.tar.gz
wget http://downloads.digium.com/pub/telepho ... gsm.tar.gz
wget http://downloads.digium.com/pub/telepho ... law.tar.gz
wget http://downloads.digium.com/pub/telepho ... wav.tar.gz
wget ftp://ftp.sangoma.com/linux/current_wan ... .2.7.1.tgz
wget ftp://ftp.sangoma.com/linux/wanpipe_voi ... -1.0.9.tgz

echo "We will patch asterisk 1.4 :"
mkdir -p /usr/src/astguiclient/patches-1.4
cd /usr/src/astguiclient/patches-1.4
wget http://public.vicidial.com/conf/patches/enter.h
wget http://public.vicidial.com/conf/patches/leave.h
wget http://public.vicidial.com/conf/patches ... -1.4.patch
wget http://public.vicidial.com/conf/patches ... -asm.patch

echo "We will Uncompress files for install :"
cd /usr/src
tar -xzf /usr/src/tars/asterisk-1.4.21.2.tar.gz
tar -xzf /usr/src/tars/libpri-1.4.9.tar.gz
tar -xzf /usr/src/tars/zaptel-1.4.12.1.tar.gz
tar -xzf /usr/src/tars/wanpipe-3.2.7.1.tgz
tar -xzf /usr/src/tars/wanpipe-voicetime-1.0.9.tgz
echo "Finished!"

echo -n "Moving add-on files to Asterisk Source Tree... "
cp /usr/src/astguiclient/patches-1.4/enter.h /usr/src/asterisk-1.4.21.2/apps/enter.h
cp /usr/src/astguiclient/patches-1.4/leave.h /usr/src/asterisk-1.4.21.2/apps/leave.h
echo "Done!"

echo "Patching Asterisk"
cd /usr/src/asterisk-1.4.21.2/codecs/gsm
patch -p1 Makefile /usr/src/astguiclient/patches-1.4/asterisk-gsm-1.4.patch
cd inc
patch -p1 private.h /usr/src/astguiclient/patches-1.4/asterisk-gsm-asm.patch
echo "Patching Done!"

echo "Now starting source compile"

cd /usr/src/libpri-1.4.9
make clean
make
make install


cd /usr/src/zaptel-1.4.12.1
make clean
./configure
make
make install
make zttool
rm /etc/init.d/zaptel
rm /etc/rc.d/init.d/zaptel

if [ "$SANGOMA" == "y" ]; then
cd /usr/src/wanpipe-3.2.7.1
./Setup install --silent --protocol=TDM
fi

if [ "$SANGOMAVT" == "y" ]; then
cd /usr/src/wanpipe-voicetime-1.0.9
make ZAPDIR=/usr/src/zaptel-1.4.12.1/kernel
make install
fi

cd /usr/src/asterisk-1.4.21.2
make clean
./configure
make
make install
make samples

echo "Finished Compiling"
echo -n "Doing Sound installation for WAV ULAW GSM formats... "

if [ "$SFSTAB" == "y" ]; then
echo "tmpfs /var/spool/asterisk/monitor tmpfs rw 0 0" >> /etc/fstab
fi

cd /var/lib/asterisk/sounds
tar -xzf /usr/src/tars/asterisk-core-sounds-en-gsm-current.tar.gz
tar -xzf /usr/src/tars/asterisk-core-sounds-en-ulaw-current.tar.gz
tar -xzf /usr/src/tars/asterisk-core-sounds-en-wav-current.tar.gz
tar -xzf /usr/src/tars/asterisk-extra-sounds-en-gsm-current.tar.gz
tar -xzf /usr/src/tars/asterisk-extra-sounds-en-ulaw-current.tar.gz
tar -xzf /usr/src/tars/asterisk-extra-sounds-en-wav-current.tar.gz
wget http://public.vicidial.com/conf/conf.gsm
echo "Done!"

echo -n "Converting sounds to support ULAW, WAV, and GSM formats... "
sox conf.gsm conf.wav
sox conf.gsm -t ul conf.ulaw
cp conf.gsm park.gsm
cp conf.ulaw park.ulaw
cp conf.wav park.wav
echo -n "25% "
cd /var/lib/asterisk
ln -s moh mohmp3
mkdir mohmp3
cd mohmp3
tar -xzf /usr/src/tars/asterisk-moh-freeplay-gsm.tar.gz
tar -xzf /usr/src/tars/asterisk-moh-freeplay-ulaw.tar.gz
tar -xzf /usr/src/tars/asterisk-moh-freeplay-wav.tar.gz
rm CHANGES*
rm LICENSE*
rm .asterisk*
mkdir /var/lib/asterisk/quiet-mp3
echo -n "50% "
cd /var/lib/asterisk/quiet-mp3
sox ../mohmp3/macroform-cold_day.wav macroform-cold_day.wav vol 0.25
sox ../mohmp3/macroform-cold_day.gsm macroform-cold_day.gsm vol 0.25
sox -t ul -r 8000 -c 1 ../mohmp3/macroform-cold_day.ulaw -t ul macroform-cold_day.ulaw vol 0.25
sox ../mohmp3/macroform-robot_dity.wav macroform-robot_dity.wav vol 0.25
sox ../mohmp3/macroform-robot_dity.gsm macroform-robot_dity.gsm vol 0.25
sox -t ul -r 8000 -c 1 ../mohmp3/macroform-robot_dity.ulaw -t ul macroform-robot_dity.ulaw vol 0.25
sox ../mohmp3/macroform-the_simplicity.wav macroform-the_simplicity.wav vol 0.25
sox ../mohmp3/macroform-the_simplicity.gsm macroform-the_simplicity.gsm vol 0.25
sox -t ul -r 8000 -c 1 ../mohmp3/macroform-the_simplicity.ulaw -t ul macroform-the_simplicity.ulaw vol 0.25
sox ../mohmp3/reno_project-system.wav reno_project-system.wav vol 0.25
sox ../mohmp3/reno_project-system.gsm reno_project-system.gsm vol 0.25
echo -n "75% "
sox -t ul -r 8000 -c 1 ../mohmp3/reno_project-system.ulaw -t ul reno_project-system.ulaw vol 0.25
sox ../mohmp3/manolo_camp-morning_coffee.wav manolo_camp-morning_coffee.wav vol 0.25
sox ../mohmp3/manolo_camp-morning_coffee.gsm manolo_camp-morning_coffee.gsm vol 0.25
sox -t ul -r 8000 -c 1 ../mohmp3/manolo_camp-morning_coffee.ulaw -t ul manolo_camp-morning_coffee.ulaw vol 0.25
echo "Finished!"
echo
echo "Now asterisk is done thank --By Brett05!"

fi

after chmod this file :
chmod 777 -R /usr/src/myfile.sh
and run it :
./usr/src/myfile.sh
and follow the question as you will see them.
finally you need to change the mode boot of asterisk with zaptel .
so do this:
pico /etc/init.d/vicidial
then change this line :
# Zaptel module name, please replace with driver name for hardware card
# If using a wanpipe_voicetime modules, please change to wanpipe_voicetime
ZAP_MOD=ztdummy

to
# Zaptel module name, please replace with driver name for hardware card
# If using a wanpipe_voicetime modules, please change to wanpipe_voicetime
ZAP_MOD=wanpipe_voicetime

save you file .
then reboot your server.
finnaly you need to verify is all is good
so do this :
cat /proc/zaptel/1" you need to see same thing as this :
Span 1: WANVTIME/1 "WANVTIME/1 (source: wanpipe_voicetime) 1" (MASTER)
then go to asterisk by asterisk -r and verify the status of zaptel:
zap show status you need see this :
Description Alarms IRQ bpviol CRC4
WANVTIME/1 (source: wanpipe_voicetime) UNCONFIGUR 0 0 0

all this work with zaptel and we can also do it with dahdi
thanks :wink:

PostPosted: Mon Feb 22, 2010 5:04 pm
by gmcust3
rm: cannot remove `/usr/lib/asterisk/modules/*.*': No such file or directory
rm: cannot remove `/etc/asterisk/*.*': No such file or directory
rm: cannot remove `/var/lib/asterisk/quiet-mp3/*.*': No such file or directory
rm: cannot remove `/var/lib/asterisk/mohmp3/*.*': No such file or directory
rm: cannot remove `/var/lib/asterisk/sounds/*.*': No such file or directory

PostPosted: Mon Feb 22, 2010 7:01 pm
by gmcust3
[root@vici ~]# ./voicevime.sh
Asterisk v.1.4 with wanpipe voice

Continue? (N/y) : y
./voicevime.sh: line 178: syntax error: unexpected end of file
[root@vici ~]#

sagoma device

PostPosted: Mon Feb 22, 2010 7:03 pm
by brett05
pm me with you ssh access
because here i don't see and error strange

PostPosted: Mon Feb 22, 2010 7:34 pm
by gmcust3
/etc/init.d/vicidial

I don't seee any file by name vicidial ?

thank

PostPosted: Mon Feb 22, 2010 7:38 pm
by brett05
hmmmm in centos it will be in other folder i think
try whereis vicidial

PostPosted: Mon Feb 22, 2010 7:56 pm
by gmcust3
Now asterisk is done thank --By Brett05!
You have new mail in /var/spool/mail/root
[root@vici ~]#
[root@vici ~]#
[root@vici ~]#
[root@vici ~]# whereis vicidail
vicidail:
[root@vici ~]# whereis vicidial
vicidial:
[root@vici ~]# whereis vicidial
vicidial:
[root@vici ~]#


I don't find the file.

PostPosted: Tue Feb 23, 2010 6:34 pm
by gmcust3
In which file do I need to change > ZAP_MOD ?

PostPosted: Wed Feb 24, 2010 5:57 pm
by gmcust3
Gardo , can you guide me ?

I use VNow 1.3