Keyboard Shortcuts
Likes
Search
Replacing Allison, was Re: [SHARI] Changing Callsign to Node Number and Vise Versa
¿ªÔÆÌåÓýHere is what I ultimately want to do. I want to host one or more voices somewhere, probably a github repository, then create a script that anyone can run direct from their shell via curl piped to bash, or by downloading it for those who don't trust that method. Fair enough if you don't. This script would do the following: 1. Detect if your system is running HamVoIP, ASL or neither. This can be done programmatically in a few ways. There are some differences between the HamVoIP and ASL sound packs. HamVoIP uses GSM files for everything, while ASL uses a mixture of both ulaw and GSM. Mostly ulaw. In the case of HamVoIP, there are a bunch of scripts that are hard-coded to look for .gsm files. I'll get to that later. 2. Detect if a third party voice has been previously installed already, and if so, which one. This can be written out in a number of ways when a voice has been installed on the system. 3. Display a menu of available voices, assuming more than one, with an option to play a demo file locally to your node, so you have an idea of how things will sound before installing. After all, what I like may not be what you like. I'd like to have at least one male and one female voice, with a couple of variations on speed. One normal, one faster. That kind of thing. 4. Back up your existing /var/lib/asterisk/sounds/ folder before installing a new voice. In the case of HamVoIP, there are also a few sound files outside of this directory that are called with some specific scripts, like saypublicip, sayreg and saydns, I believe. 5. Downloads .ulaw files to the appropriate place. I'm not a fan of the GSM format, and since we don't need the full asterisk sound pack for app.rpt (this can be cut down to a little over 400 samples), with a better edited, faster voice, the files will be of much higher quality, and take up less storage as well. 6. On HamVoIP, do a find/replace on every .sh and .pl file in /usr/local/sbin, replacing .gsm with .ulaw or .sln, which ever file format ends up being used. Ignore this step if using ASL. 6.1. Since HamVoIP likes to redownload all of these scripts for
most updates, a mechanism should exist to easily fix things after
an update without the need to download a sound pack again.
Alternatively, just use .GSM files and cry about the lower audio
quality, at least if you're me... I personally can't stand that
grainy, washed-out sound. Asterisk actually does better if you use
raw linear PCM or ulaw anyway, as it's one less layer of potential
transcoding, even for the stack connected to a radio channel
driver. 7. After the voice is installed, prompt the user if they would
like to run the write-node-callsigns.sh script from HamVoIP (after
checking if it exists on the system) with the new audio files. For
extra credit, if it doesn't exist, add an option to periodically
add new calls on a cronjob if desired.
On day two of having a fully working HamVoIP node back in
September of 2019, I made a new, extremely fast sound pack for
myself using the Apple Fred voice, because it was easy for me to
script. Basically, what I did was write a bash script on Mac OS
with a while loop that read a tab delimited text file with all the
prompts written out in the first column, then the path to write
each file in the second. Since Apple's say command only writes out
.aiff files, everything was then processed by SoX to filter,
normalize and trim each sample to make it extremely responsive.
Since I used .ulaw files, I wrote another script that uses sed
recursively to replace any occurrence of .gsm with .ulaw in all
.sh and .pl scripts in /usr/local/sbin. I am a screen reader user, so I listen to fast, synthetic speech every day. It is no exaggeration to say that my node says "N2DYI Disconnected" in only a little more time Allison would say "N2" on a normal setup. That being said, this voice is not one I would recommend for a wide area repeater, and it has some bugs that I never fixed, because it's for my own personal use, and I don't really care too much about the bits that are broken, but if anyone here wants it, no warranties, let me know. I have access to many high quality options that are licensed for non-commercial, commercial and broadcast/transmission use, so it's just a matter of painstakingly creating each sample, probably with a few variations each, multiple times for different voices, batch-processing the audio for high intelligibility at the low 8 kHz sampling rate, getting the timing just right, etc. I can do all that. It's part of my profession. But none of that does any good if it's not easy to install on a system. I would love to get something better out there especially for
repeater operators, but really just anyone who is as annoyed at
the stock Allison soundpack as I am. BTW, I was a long-time
Asterisk user before coming to the world of Allstarlink/HamVoIP,
having done managed a few commercial phone systems, so I had about
15 years of personal Allison annoyance behind me before I even
built a node.
73 N2DYI
On 6/15/2024 9:11 PM, Chris Smart via groups.io wrote:
|