<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE section PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" 
   "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">

<section id="voicemail" xmlns:xi="http://www.w3.org/2001/XInclude">
    <sectioninfo>
	<revhistory>
	    <revision>
		<revnumber>$Revision$</revnumber>
		<date>$Date$</date>
	    </revision>
	</revhistory>
    </sectioninfo>
    
    <section>
	<title>Introduction</title>
	<para>
	    The voicemail system provides <application>ser</application> with
	    voice announcement and recording capabilities. Voice messages may
	    then be mailed to the called user. The system relies on
	    <application>ser</application> for implementing the
	    <acronym>SIP</acronym> stack and communicate with it through
	    <acronym>FIFO</acronym>. It implements the dialog and media
	    handling as described in RFC 3264 (An Offer/Answer Model with the
	    Session Description Protocol) and RFC 1889 (Real time transport
	    protocol) to realize its goal.
	</para>
    </section>
    <section>
	<title>Advantages</title>
	<para>
	    <itemizedlist>
		<listitem>
		    <para>
			Anyone deploying <application>ser</application> and
			<acronym>VoIP</acronym> should profit from this 'ready-to-run'
			application. It plugs into <application>ser</application> as
			easy as configuring the database location, announce file path
			and SMTP server address. 
		    </para>
	        </listitem>
	        <listitem>
		    <para>
			Further, <application>voicemail</application>
			integrates the most popular free codecs (G.711ulaw,
			G.711alaw and GSM 06.10) and its own SMTP client, which
			means that you don't need to install anything else as
			<application>ser</application> and
			<application>voicemail</application>.
		    </para>
	        </listitem>
	        <listitem>
		    <para>
			If you want your voicemail system to support other
			codecs, a simple plugin system with SDK allows you to
			integrate them fast and simply (see the basis plugins
			for examples).
		    </para>
	        </listitem>
	    </itemizedlist>
	</para>
    </section>

    <section>
	<title>Technical limitations</title>
	<para>
	    <itemizedlist>
		<listitem>
		    <para>
			The sound conversion engine doesn't support yet
			re-sampling. It means that input and output files have
			to be compatible with the sampling rate of the
			codec. All codecs included with the distribution work
			at 8kHz, which means that all the input and output
			files MUST be sampled at the rate of 8kHz.
		    </para>
		</listitem>
		<listitem>
		    <para>
			At the moment, voicemail only support the Microsoft Wav
			file format with PCM 16 bit, Mu-law and A-law 8 bit
			encoding.
		    </para>
		</listitem>
	    </itemizedlist>
	</para>
    </section>

    <section>
	<title>Compilation and installation</title>
	<para>
	    <itemizedlist>
		<listitem>
		    <para>
			First, you need to compile Ser with voicemail
			support. Therefore, you must edit Ser's Makefile.defs
			file and uncomment the line with '-DVOICE_MAIL' and
			'-D_TOTAG'.
		    </para>
		</listitem>
		<listitem>
		    <para>
			Then do 'make all' in Ser's root directory.
		    </para>
		</listitem>
		<listitem>
		    <para>
			Configure Ser to fit your needs. You can report to
			voicemail example config file to know what your
			configuration file should include. Note that voicemail
			only needs to know the user database location in order
			to work. Report to the README file in the vm module
			directory for description of the functions and variable
			that are used by voicemail and how they work.
		    </para>
		</listitem>
		<listitem>
		    <para>
			Finally, compile the voicemail application:
			
			<programlisting>
[~/voicemail]$ cd ortp-0.5.0
[~/voicemail/ortp-0.5.0]$ ./configure
[~/voicemail/ortp-0.5.0]$ make all
[~/voicemail/ortp-0.5.0]$ cd ..
[~/voicemail]$ cd plug-in/gsm/gsm-????
[~/voicemail/plug-in/gsm/gsm-????]$ make all
[~/voicemail/plug-in/gsm/gsm-????]$ cd ../..
[~/voicemail]$ make all
			</programlisting>

			You can then start voicemail with following
			command <command>ans_machine</command> and
			look if the default fit your needs. If not,
			type <command>ans_machine -h</command> to see
			how to change the default parameters.

			  <!--<note>-->
			  If <application>ans_machine</application> is
			  not started or can't be joined while
			  <application>ser</application> tries to
			  communicate with it, the caller will become
			  a '500 internal server error' with a comment
			  saying what the trouble is.
			  <!--</note>-->
		    </para>
		</listitem>
	    </itemizedlist>
	</para>
    </section>
    <section>
	<title>Availability, report bugs, contact the author</title>
	<para>
	    Ser's Voicemail's home page is hosted at
	    http://sems.berlios.de. A snapshot may be downloaded directly
	    from the CVS tree. A pre-configured version of 
	    <application>ser</application> including
	    <application>voicemail</application> will be soon available
	    (from version 0.8.11). Bugs can be reported at the voicemail's
	    home page. If you want to contact the author, use the contact
	    email at the home page.
	</para>
    </section>
</section>
