VOCP System - Install - Vgetty

Installing Vgetty and ensuring it works with your modem is easier than ever with VOCP 0.9

Vgetty may already be installed on your machine - mgetty+sendfax is pretty standard now with many Linux distributions and is also available through the FreeBSD ports system. It includes vgetty and the pvftools we'll be using. If it is installed, you need to make sure that it works with your modem.

The mgetty+sendfax source code (vgetty included) may be found at http://www.leo.org/~doering/mgetty/. It is also distributed in RPM format at sites like Redhat and Mandrake. Just look for a recent version (we are using the source for 1.1.30) of mgetty+sendfax.

Also, if you are unsure of your modem's compatibility, you really should get the source code and compile it - this will help a lot if your modem works with m/vgetty but is not correctly recognized.

The documentation included with mgetty is pretty straightforward - read it. You may compile and install the m/vgetty source manually but if you are unsure of your modem's compatibility, follow these instructions to automatically apply our patch and compile the programs.


Install

 
  1. Download the 1.1.30 source code from official mgetty site.
  2. Open a console and change into the VOCP distribution directory, into the prog/dependencies/mgetty-patch/
    $ cd /path/to/vocp-X.X.X/prog/dependencies/mgetty-patch
  3. Become the root user
    $ su
  4. Remove installed RPMs/DEBs
    If you have a stock RPM or DEB install of m/vgetty, remove it. For example, on a system that uses RPMs you would do:
    # rpm -qa | grep mgetty
    mgetty-1.1.26-6
    mgetty-voice-1.1.26-6
    mgetty-sendfax-1.1.26-6
    
    then remove the packages using
    # rpm -e mgetty-voice-1.1.26-6 mgetty-sendfax-1.1.26-6 mgetty-1.1.26-6
    
  5. Run the install_patched_vgetty.pl program. This program will unpack, patch, compile and install mgetty/vgetty:
    # ./install_patched_vgetty.pl
    

    The program will ask for the location of the mgetty source .tar.gz file, patch it to include our force_detect option, compile using the default policy values and install mgetty, sendfax and vgetty.


Configure

Edit the mgetty.config and voice.conf files. These will be found in /etc/mgetty+sendfax or /usr/local/etc/mgetty+sendfax or something similar.

For mgetty.config, the file is well documented and the defaults are usually ok - just ensure that the contents are sane for your setup.

Set up the voice.conf (copy it from the voice.conf-dist in the mgetty-X.X.X/voice source directory if you can't find it) as per the instructions. The most important thing is to

  1. set voice_devices to the correct ttyS (for instance, my modem uses ttyS1)
  2. set voice_shell to the location of your Perl executable (eg /usr/bin/perl)
  3. set the call_program to the VOCP executable (/etc/vocp/vocp.pl)

When vgetty is installed, you need to make sure there is a line in /etc/inittab that looks like

SX:345:respawn:/usr/sbin/vgetty ttySX
replacing the X's by the /dev/ttyS[0-3] on which your modem is installed. You now need to get init to re-read the config file, do so by running:
# init q
as root to for init to reread its config file.

Now, doing ps waux | grep [v]getty should display something like:

root 17250  0.0  0.3  1656  752 S Dec28 0:00 /usr/local/sbin/vgetty ttyS1
Does it? Good. Have a look at the /var/log/vgetty.ttySX file (again replacing X by the appropriate number). It should show vgetty initializing and testing the modem and contain a line like
12/28 19:18:08 yS1  US Robotics detected

If the modem isn't recognized or if it is recognized as some type but gives lots of error messages, you can try to run the ./vgetty-test.pl script. Change into the mgetty source directory produced when you ran install_patched_vgetty.pl - it should be at /path/to/vocp-X.X.X/prog/dependencies/mgetty-patch/mgetty-1.1.30/voice/contrib/Pat_Deegan

 

Still as root, run the test script. Vgetty-test.pl will ask a few questions and then try to play a sound file through the modem using every possible modem setting and compression level. You will be asked whether you wish to play the file through the handset or speaker - choose something appropriate.

The file will be played multiple times, each time using a different force_detect in the voice.conf file. If you hear nothing or just a garbled squeaking sound, answer 'n' and try the next modem/compression.

When you do find that you can hear the little voice, take note of the modem type and compression method - these will be needed later to configure VOCP. The values will be a modem name (e.g. US_Robotics) and a compression method (which is a numerical value, eg 1).

If all tests fail, your modem may not be supported. See the modems troubleshooting page. If that doesn't help either, join the mgetty mailing list and ask the experts directly, hack yourself some support or get a supported modem.

Now that the installation is done, you must test vgetty and configure it.

Go Back


© 2000-2003 Psychogenic inc. All rights reserved.