From XastirWiki
Jump to: navigation, search

Getting Festival Working with Xastir

It's been reported that Festival "just works" with BSD and with Ubuntu-16.04 by installing the festival package and running "festival --server" from a command line.

FreeBSD

As root:

  cd /usr/ports/audio/festival
  make install clean

You will also need to install one of the festival voice packages as stated by the final message emitted by the install command above. For example:

  cd /usr/ports/audio/festvox-ked16
  make install clean

Reconfigure and rebuild Xastir, and you have festival support.

You can then run "festival --server" as your own user ID from the command line, and festival options should be available and work (try the "Test" button in the File->Configure->Speech dialog).

Ubuntu 16.04

You must install the festival and festival-dev packages. It is also recommended to install festvox-kallpc16k.

  sudo apt-get install festival-dev festival festvox-kallpc16k

Configure and build Xastir. Start festival with "festival --server" from a command line. Xastir speech should work.


OpenSuSE 42.3 / 15.x

OpenSuSE runs festival_server as the "festival" user using systemd. The setup is not configured to send the Festival output to the user's Pulseaudio.

Add these lines near the end of /usr/share/festival/festival.scm, just prior to the "(provide 'festival')" line:

 (Parameter.set 'Audio_Required_Format 'aiff)
 (Parameter.set 'Audio_Method 'Audio_Command)
 (Parameter.set 'Audio_Command "paplay $FILE --client-name=Festival --stream-name=Speech")

The above should get Festival talking through PulseAudio.

Start festival_server, running as the "festival" user:

 sudo systemctl start festival_server

As a first test try this:

 festival
 (SayText "Hello")

You should hear Festival talking through PulseAudio. Check your Pulseaudio volume control if not and try again.

Hit Control-D to exit the festival client.

Next test, which goes through the port Xastir will use instead of calling Festival on the command-line:

 telenet localhost 1314
 (SayText "Hello")

This didn't work for me. In this case Festival server was started by systemctl as the "festival" user, which doesn't have access to my user's PulseAudio.

Next try this:

 sudo systemctl stop festival_server
 /usr/bin/festival --libdir /usr/share/festival --server --batch &

Then (perhaps in another window):

 telnet localhost 1314
 (SayText "Hello")

At this point festival_server is running as your user so should have access to your PulseAudio.

We're working on a better / more final solution that allows festival_server started by systemd to still talk to a user's Pulseaudio.