~ubuntu-branches/debian/squeeze/nas/squeeze

« back to all changes in this revision

Viewing changes to server/dda/voxware/sound.sh

  • Committer: Bazaar Package Importer
  • Author(s): Steve McIntyre
  • Date: 2008-10-08 01:18:19 UTC
  • mfrom: (4.1.7 intrepid)
  • Revision ID: james.westby@ubuntu.com-20081008011819-wmr4h2w0298k8t7z
Tags: 1.9.1-5
* Fix pending l10n issues. Debconf translations:
* Swedish. Closes: #491766 (thanks to brother@bsnet.se)
* Arabic. Closes: #500437 (thanks to Ossama Khayat)
* Basque. Closes: #500533 (thanks to Piarres Beobide)
* Brazilian Portuguese. Closes: #500973 (thanks to Felipe
  Augusto van de Wiel)
* Many thanks again to Christian Perrier for his i18n efforts,
  co-ordinating the above.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# $NCDId: @(#)sound.sh,v 1.1 1994/04/27 23:48:56 greg Exp $
2
 
#
3
 
#
4
 
AUDIOSERVER=:0 export AUDIOSERVER
5
 
PIDFILE=/usr/local/lib/aupid
6
 
AU=/usr/local/bin/au
7
 
AUPLAY=/usr/local/bin/auplay
8
 
UPSOUND=/home/incoming/Sounds/tada.wav
9
 
DOWNSOUND=/home/incoming/Sounds/mind.wav
10
 
start ()
11
 
{
12
 
        echo "Starting sound server..."
13
 
        sleep 2
14
 
        $AU -aa &
15
 
        AUPID=$!
16
 
        echo $AUPID > $PIDFILE
17
 
        #
18
 
        #       Whip it into the Real Time class - doesn't hurt us & gives it
19
 
        #       CPU when it does need it.
20
 
        #
21
 
        if [ -x /usr/bin/priocntl ]
22
 
        then
23
 
                priocntl -c RT -s -i pid $AUPID
24
 
        fi
25
 
        sleep 2
26
 
        $AUPLAY $UPSOUND &
27
 
        sleep 1
28
 
}
29
 
 
30
 
stop()
31
 
{
32
 
        $AUPLAY $DOWNSOUND
33
 
        sleep 3
34
 
        kill -15 `cat $PIDFILE`
35
 
}
36
 
 
37
 
case $1 in
38
 
start)
39
 
        start;;
40
 
stop)
41
 
        stop;;
42
 
esac
43