ZOIP
ZoIP - The Great Asterisk Underground Empire
Originally from http://uc.org/read/ZoIP
Zoip is a new way of playing Zork - It uses Text-to-Speech and
Speech Recognition to play the classic infocom game, Zork. It appears
as a destination. If you wish to play this without needing to go through an IVR,
the easy way is to create a Ring Group with an invalid extension in it, and a destination of Zoip.
Also, if your FreePBX machine is on a slow connection, BE WARNED. This is a 7 Megabyte
download. That's a lot through a slow connection. You don't need to use
the 'online modules' link to donwload this, you can download it
manually - see the bottom of this page, with the title of 'Downloading
it Manually'. I can't download it through a 1.5mbit connection in under
the default 30 second max execution time. If you don't want to download
it manually, and the screen just goes white and stops after 30 seconds,
this is because your 'max_execution_time' in /etc/php.ini is too short.
Set it to 600 (10 minutes), restart apache (/etc/init.d/httpd restart as root) and it should work fine.
As it does some new, non-standard things, there are some packages
that need to be installed. Without these, the module will not work
properly.
CenOS/RHEL/FC3/4/5 Instructions
From the shell:
[root@asterisk1 ~]
rpm -i http://mirror.freepbx.org/sphinx2-0.6-0.i386.rpm
(This could take a couple of minutes to finish downloading, as it's a big file)
[root@asterisk1 ~]#
wget http://mirror.freepbx.org/Speech-Recognizer-SPX-0.0801.tar.gz
--09:08:27--
http://mirror.freepbx.org/Speech-Recognizer-SPX-0.0801.tar.gz
=> `Speech-Recognizer-SPX-0.0801.tar.gz'
... A few lines of text ...
09:08:30 (117.55 KB/s) - `Speech-Recognizer-SPX-0.0801.tar.gz' saved [91123/91123]
[root@asterisk1 ~]#
tar -xzf Speech-Recognizer-SPX-0.0801.tar.gz
... A lot of text scrolls past ...
[root@asterisk1 ~]#
cd Speech-Recognizer-SPX-0.0801
[root@asterisk1 Speech-Recognizer-SPX-0.0801]#
perl Makefile.PL --sphinx-prefix=/usr
Found Sphinx-II in /usr and /usr/share/sphinx2
Checking if your kit is complete...
Looks good
Writing Makefile for Audio::MFCC
Writing Makefile for Audio::SPX
Writing Makefile for Speech::Recognizer::SPX
[root@asterisk1 Speech-Recognizer-SPX-0.0801]#
make install
cp SPX.pm blib/lib/Speech/Recognizer/SPX.pm
cp SPX/Config.pm blib/lib/Speech/Recognizer/SPX/Config.pm
... about 20 lines ...
Installing /usr/share/man/man3/Speech::Recognizer::SPX.3pm
Writing /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi/auto/Speech/Recognizer/SPX/.packlist
Appending installation info to /usr/lib/perl5/5.8.5/i386-linux-thread-multi/perllocal.pod
[root@asterisk1 Speech-Recognizer-SPX-0.0801]#
cd ..
[root@asterisk1 ~]#
wget http://mirror.freepbx.org/Proc-Daemon-0.03.tar.gz
... file downloads ...
[root@asterisk1 ~]#
tar zxvf Proc-Daemon-0.03.tar.gz
... 9 files ...
[root@asterisk1 ~]#
cd Proc-Daemon-0.03
[root@asterisk1 Proc-Daemon-0.03]#
perl Makefile.PL
Checking if your kit is complete...
Looks good
Writing Makefile for Proc::Daemon
[root@asterisk1 Proc-Daemon-0.03]#
make install
... 6 lines of installation ...
[root@asterisk1 Proc-Daemon-0.03]#
cd ..
[root@asterisk1 ~]#
wget http://mirror.freepbx.org/Config-Tiny-2.08.tar.gz
... file downloads ...
[root@asterisk1 ~]#
tar zxvf Config-Tiny-2.08.tar.gz
... 26 files ...
[root@asterisk1 ~]# cd Config-Tiny-2.08
[root@asterisk1 Config-Tiny-2.08]# perl Makefile.PL
Checking if your kit is complete...
Looks good
Writing Makefile for Config::Tiny
[root@asterisk1 Config-Tiny-2.08]# make install
... a few lines...
[root@asterisk1 Config-Tiny-2.08]# cd ..
[root@asterisk1 ~]# yum install festival
Setting up Install Process
Setting up repositories
... etc ...
[root@asterisk1 ~]#
That's it - you can now download the module and it'll work happily!
Debian, Ubuntu, apt-style distros
This is taken from the Zoip installer, and may not be accurate. I don't have a Debian machine here, so I can't test this.
- Install Sphinx2, and Festival
- Install the Sphinx2 binaries and developer kit
apt-get install sphinx2-bin libsphinx2-dev
-
- Install the Sphinx2 Perl bindings
-
- Install Festival, and the 'kallpc8k' voice, sitable for telephone quality
apt-get install festival festvox-kallpc8k
- Add some additional perl modules used by ZoIP from the apt repository
apt-get install libproc-daemon-perl liblog-log4perl-perl libconfig-tiny-perl
Installing ZoIP Manually
Beacuse this is abig file, it may be neccesary to download the module manually. This is simply done by:
[root@asterisk1 ~]# cd /var/www/html/admin/modules
[root@asterisk1 ~]# wget http://mirror.freepbx.org/modules/release/2.2/zoip-0.2.0.tgz
... file is downloaded ...
[root@asterisk1 ~]# tar zxvf zoip-0.2.0.tgz
... files are extracted ...
From here, you can go back to your Module Administration page, and
the Zoip module will appear as a 'Disabled Module' ready to be
installed, without requiring going to the online module repository.