Rockbox.org home
Downloads
Release release
Dev builds dev builds
Extras extras
themes themes
Documentation
Manual manual
Wiki wiki
Device Status device status
Support
Forums forums
Mailing lists mailing lists
IRC IRC
Development
Bugs bugs
Patches patches
Dev Guide dev guide
Search



Donate

Rockbox Technical Forums


Login with username, password and session length
Home Help Search Staff List Login Register
News:

Thank You for your continued support and contributions!

+  Rockbox Technical Forums
|-+  Rockbox General
| |-+  Rockbox General Discussion
| | |-+  Voicing Playlists query.
« previous next »
  • Print
Pages: [1]

Author Topic: Voicing Playlists query.  (Read 3154 times)

Offline Bro.Tiag

  • Member
  • *
  • Posts: 5
Voicing Playlists query.
« on: September 14, 2009, 09:23:46 PM »
I have a SanDisk, e250 sansa v-1 with broken LCD, Rockbox has enabled me to continue to use this mp3 player as such. Especially nice are the Voice Menu's.

I am trying to get the voice menu to be able to announce the various & sundry playlists I've compiled in the "View Playlist Catalog" menu option. A search of these forums yielded a similer post, Voicing Playlists, but that poster seemed to give up early. I currently have the voice menu spelling out the playlist, but would prefer the actual playlists spoken.

I have followed the instructions in the manual under Section 8 General Settings, subsection 8.8  Voice;
Quote from: 8.8  Voice
Voice Menus.
    This option controls the voicing of menus/settings as they are selected by the cursor. In order for this to work, a voice file must be present in the /.rockbox/langs/ directory on the player. Voice files are large and are not shipped with Rockbox by default. The voice file is the name of the language for which it is made, followed by the extension .voice. So for English, the file name would be english.voice. This option is on by default, but will do nothing unless the appropriate voice file is installed in the correct place on the player. The Voice Menus have several limitations:

        * Setting the Sound Option Channels to Karaoke may disable voice menus.
        * Plugins and the wake up alarm do not support voice features.

Voice Directories.
    This option controls voicing of directory names. A voice file must be present for this to work. Several options are available.

    Spell.
        Speak the directory name by spelling it out letter by letter. Support is provided only for the most common letters, numbers and punctuation.
    Numbers.
        Each directory is assigned a number based upon its position in the file list. They are then announced as “Directory 1”, “Directory 2” etc.
    Off.
        No attempt will be made to speak directory names.

    You can use pre-generated .talk clips to have directory names spoken properly, but you must enable this explicitly (see below).
Use Directory .talk Clips.
    This option turns on the use of .talk clips for directories.

    On.
        Use special pre-recorded MP3 files (_dirname.talk) in each directory. These must be generated in advance, and are typically produced synthetically using a text-to-speech engine on a PC.
    Off.
        No checking is made for directory .talk clips; they are not used even if present. This can reduce disk activity.

    Use of a .talk clip takes precedence over other directory name voicing. Otherwise (e.g. if a .talk clip is not available), voicing uses the method set under Voice Directories above.
Voice Filenames.
    This option controls voicing of filenames. Again, a voice file must be present for this to work. The options provided are Spell, Numbers, and Off which function the same as for Voice Directories. You can use pre-generated .talk clips to have filenames spoken properly, but you must enable this explicitly (see below).
Use File .talk Clips.
    This option turns on the use of .talk clips for files.

    On.
        Use special pre-recorded MP3 files for each file. This functions the same as for directories except that the .talk clip file must have the same name as the described file with an extra .talk extension (e.g. Punkadiddle.mp3 would require a file called Punkadiddle.mp3.talk).
    Off.
        No checking is made for file .talk clips; they are not used even if present. This can reduce disk activity.

    Use of a .talk clip takes precedence over other filename voicing. Otherwise (e.g. if a .talk clip is not available), voicing uses the method set under Voice Filenames above.
Say File Type.
    This option turns on voicing of file types when Voice Filenames is set to Spell or Numbers. When Voice Directories is set to Spell, “Directory” will be voiced after each spelled out directory.
, as well as the expanded instructions in How to make your Rockbox-enabled player speak, Voiced names for directories and files
Quote from: Voiced names for directories and files
Rockbox doesn't have any internal text-to-speech capabilities, but you can have names spoken properly using pre-recorded mp3 clips renamed to have an extension of .talk.

In order to speak a directory name, Rockbox needs you to provide a file called

    _dirname.talk

inside that directory. (That is literally "_dirname.talk", not matching the name of the directory!)

In order to speak a filename, e.g., "technoMix.mp3", Rockbox needs you to provide a file called

    technoMix.mp3.talk

in the same directory as the original technoMix.mp3 file. Remember the .talk filename must match the .mp3 filename exactly, dashes numbers spaces, everything, then tack on the ".talk" to your small clip of the song.

You must enable the "Use Directory .talk Clips" and "Use File .talk Clips" options which will then cause Rockbox to check for and "speak" the corresponding voice clip for the file or directory as you hover over it in the file browser. This can result in extra disk spin-ups, especially if you don't have dircache enabled.

The .talk files contain the spoken name of the directory or file in MP3 format. They are in regular MP3 format, if you have the software and patience you can put in a small spoken announcement and fade in a clip of the song, whatever you'd like.

If the .talk clip doesn't exist for a particular file or directory (or when browsing the database), Rockbox will fallback to using the numbered or spelled options, if configured.

Here is a copy of my config.cfg;
Quote from: config.cfg
# .cfg file created by rockbox r22632-090905 - http://www.rockbox.org



volume: -1

talk dir: spell

talk dir clip: on

talk file: spell

talk file clip: on

talk filetype: on

Announce Battery Level: on

As a recap, I have added a file named "_dirname.talk" to my /PLAYLIST directory, made an mp3 of the name of the Playlist to be announced, "01_veterans_memorial_coliseum-new_haven_ct-05-may-77.mp3" which corresponds to the name of the playlist "01_veterans_memorial_coliseum-new_haven_ct-05-may-77.m3u" and have added a file named "01_veterans_memorial_coliseum-new_haven_ct-05-may-77.mp3.talk", all in the /PLAYLIST directory. And have set my config file to the appropriate voice settings. Yet, I am unable to get the voice menu to announce the Playlist. What am I missing?

Regards
Teague
Logged

Offline pixelma

  • Rockbox Expert
  • Member
  • *
  • Posts: 645
Re: Voicing Playlists query.
« Reply #1 on: September 15, 2009, 02:07:40 AM »
The .talk files are not MP3 anymore for your e200 (only for the Archos ones) but speex.

If you can use speech synthesis, the easiest  way to create them is using the Rockbox Utility. If for some reason you want to make them "manually", you would have to use a tool called "rbspeexenc" (if I remember correctly) which is in the source and creates the files as the Rockbox voice system expects them.
Logged

Offline Bro.Tiag

  • Member
  • *
  • Posts: 5
Re: Voicing Playlists query.
« Reply #2 on: September 15, 2009, 08:26:05 AM »
Quote from: pixelma on September 15, 2009, 02:07:40 AM
The .talk files are not MP3 anymore for your e200 (only for the Archos ones) but speex.

If you can use speech synthesis, the easiest  way to create them is using the Rockbox Utility. If for some reason you want to make them "manually", you would have to use a tool called "rbspeexenc" (if I remember correctly) which is in the source and creates the files as the Rockbox voice system expects them.

AH, I see, speex file format instead of mp3 file format. I seemed to have miss that in all the documentation I read, especially the relevant bits I quoted in my OP. None the less, speex file format it is.

So I see the use of speex mentioned in; How to make your Rockbox-enabled player speak, Automated generation of .talk clips
Quote from: Automated generation of .talk clips
The simplest way to generate .talk clips is to use RockboxUtility.

Alternatively, a script to automatically create the .talk files using a computer voice for directory and/or file names is available here:

voiceBox+.zip New version which supports both mp3 (for the Archos line of mp3 players) and raw speex (for all newer devices). Both GUI mode and plain drag & drop are tested working. Drag & drop onto links is untested, but should work as well.

The .zip archive comes complete with all required files, including the free LAME mp3 encoder.

Unzip the file into a handy directory ('C:\Program Files' for instance). A 'voiceBox' directory will be created containg the required files. You are now ready to run the voiceBox.hta application. This will start an HTML application with simple tick boxes to allow you to choose whether to voice directories and/or filenames and whether to keep existing .talk files (to only create voice files for new music) or to delete all and re-create. Depending on how many files and directories you are voicing, and the speed of your computer, the application should give you a success message in a short time - a few seconds for a few files and directories, several minutes for a larger collection of names. Please read the included file "voiceBox_README.txt" for more detailed instructions on how to configure the script, e.g., voicing only directories or files, but not both.

Alternatively, you can either drag files or directories onto the script (voiceBox.wsf). If no files are dropped on the script or specified on the command line, you will be asked to enter the name of a file or directory. You should enter the full pathname to the file or directory if you are using the command line or entering names at the script prompt.

If you get an error message from the script, or nothing seems to be happening at all, check if perhaps your virus scanner is blocking any scripting activity. If it is, you should temporarily disable this feature - do not forget to re-enable it after you have generated your .talk files! You might also want to look at the contents of the file "VoiceBox_logfile.txt", which contains a list of the files and directories processed and the commands that the script attempted to execute.

You will also need to have a text-to-speech engine installed on your Windows PC. I believe this comes as standard with Windows XP and above. If the voiceBox application indicates that 'Microsoft Speech' is not installed, then you will have to download and install it from the microsft.com website.

Once the clip generation process is completed, disconnect the jukebox and reboot it as usual.

The thing is, the RockboxUtility fails because I do not have a tts engine installed and the alternative voiceBox+.zip seems to be for windows users (which I'm not).

So, since I've created a wav file the old fashioned way, with a recorder. Converted said wav file to a spx file via speexenc. Is there a way manually to get Rockbox to recognize the spx file and speak it? If so, how?

Cheers
Teague 
Logged

Offline AlexP

  • Global Moderator
  • Member
  • *
  • Posts: 3688
  • ex-BigBambi
Re: Voicing Playlists query.
« Reply #3 on: September 15, 2009, 08:37:15 AM »
The trouble is that as it mentions in the section you quoted (although it isn't terribly well emphasised), the speex files are "raw speex", i.e. not in a container.  The files produced by standard speex encoders won't work.  It may be possible to extract them from their containers and have them work, I don't know.

What you should use is:

Quote from: pixelma on September 15, 2009, 02:07:40 AM
If for some reason you want to make them "manually", you would have to use a tool called "rbspeexenc" (if I remember correctly) which is in the source and creates the files as the Rockbox voice system expects them.
Logged
H140, F60, S120, e260, c240, Clip, Fuze v2, Connect, MP170, Meizu M3, Nano 1G, Android

Offline Bro.Tiag

  • Member
  • *
  • Posts: 5
Re: Voicing Playlists query.
« Reply #4 on: September 15, 2009, 09:32:03 AM »
Quote from: AlexP on September 15, 2009, 08:37:15 AM
The trouble is that as it mentions in the section you quoted (although it isn't terribly well emphasised), the speex files are "raw speex", i.e. not in a container.  The files produced by standard speex encoders won't work.  It may be possible to extract them from their containers and have them work, I don't know.

What you should use is:

Quote from: pixelma on September 15, 2009, 02:07:40 AM
If for some reason you want to make them "manually", you would have to use a tool called "rbspeexenc" (if I remember correctly) which is in the source and creates the files as the Rockbox voice system expects them.

Thanks for the reply, I assumed (I know) that "rbspeexenc" was just "speexenc" renamed for Rockbox along the *buntu renaming lines, sorry for that.

Anyhow, some more digging on the mail-list seems to imply that speexenc/dec could be used to make the raw speex file and a read through the speexenc man page supports that.

I'll try the rbspeexenc from the source archive first. Looks like all one needs to do is run makefile.

Cheers
Logged

Offline Bro.Tiag

  • Member
  • *
  • Posts: 5
Re: Voicing Playlists query.
« Reply #5 on: September 17, 2009, 08:52:50 PM »
Quote from: Bro.Tiag on September 15, 2009, 09:32:03 AM
Thanks for the reply, I assumed (I know) that "rbspeexenc" was just "speexenc" renamed for Rockbox along the *buntu renaming lines, sorry for that.

Anyhow, some more digging on the mail-list seems to imply that speexenc/dec could be used to make the raw speex file and a read through the speexenc man page supports that.

I'll try the rbspeexenc from the source archive first. Looks like all one needs to do is run makefile.

Cheers
Aye, what a pain in the arse getting rbspeexenc was. One would think that you should not have to download and install most (if not all) of rockbox just to get a wee ancillary application tool.

I don't suppose their is a man page for rbspeexenc/rbspeexdec, what 'bout some documentation on how they work? I've spoke with several developers (mind you their linux developers) and non have ever heard of a "raw speex" file other then what speexenc produces. Any chance that there is some more information on how this rbspeexenc produces this magical "raw speex" format that only the rockbox voice menu can use? How 'bout some more info on this "raw speex" format.

It would be really convenient to offer others the ability to make custom voice menus with more readily available gpl-tools. I do have to admit, the custom menus are way nicer then those computer generated ones.

Cheers
Teague
Logged

Offline GodEater

  • Member
  • *
  • Posts: 2829
Re: Voicing Playlists query.
« Reply #6 on: September 18, 2009, 03:01:08 AM »
Quote from: Bro.Tiag on September 17, 2009, 08:52:50 PM
Aye, what a pain in the arse getting rbspeexenc was. One would think that you should not have to download and install most (if not all) of rockbox just to get a wee ancillary application tool.

We can certainly look into making a precompiled binary available I suppose.

Quote
I don't suppose their is a man page for rbspeexenc/rbspeexdec, what 'bout some documentation on how they work?

From the source code :
Code: [Select]
Usage: rbspeexenc [options] infile outfile
Options:
  -q x   Quality, floating point number in the range [0-10], default 8.0
  -c x   Complexity, increases quality for a given bitrate, but encodes
         slower, range [0-10], default 3
  -n     Enable narrowband mode, will resample input to 8 kHz
  -v x   Volume, amplitude multiplier, default 1.0

rbspeexenc expects a mono 16 bit WAV file as input. Files will be resampled
to either 16 kHz by default, or 8 kHz if narrowband mode is enabled.
WARNING: This tool will create files that are only usable by Rockbox!


Usage: rbspeexdec infile outfile

rbspeexdec outputs mono 16 bit 16 kHz WAV files.
WARNING: This tool will only decode files made with rbspeexenc!

Quote
I've spoke with several developers (mind you their linux developers) and non have ever heard of a "raw speex" file other then what speexenc produces. Any chance that there is some more information on how this rbspeexenc produces this magical "raw speex" format that only the rockbox voice menu can use? How 'bout some more info on this "raw speex" format.

The speexenc/speexdec programmes that most people are familiar with produce speex encoded audio, and save it into an OGG container. rbspeexenc/rbspeexdec don't bother with the container, they just save the speex encoded audio. There is nothing magical about this.

Quote
It would be really convenient to offer others the ability to make custom voice menus with more readily available gpl-tools.

rbspeexenc and rbspeexdec are both gpl and readily available, though as I said, we'll see if can arrange to get them made available as precompiled binaries.

Logged

Read The Manual Please

Offline Bro.Tiag

  • Member
  • *
  • Posts: 5
Re: Voicing Playlists query.
« Reply #7 on: September 20, 2009, 04:33:41 PM »
Quote from: GodEater on September 18, 2009, 03:01:08 AM
Quote
I've spoke with several developers (mind you their linux developers) and non have ever heard of a "raw speex" file other then what speexenc produces. Any chance that there is some more information on how this rbspeexenc produces this magical "raw speex" format that only the rockbox voice menu can use? How 'bout some more info on this "raw speex" format.

The speexenc/speexdec programmes that most people are familiar with produce speex encoded audio, and save it into an OGG container. rbspeexenc/rbspeexdec don't bother with the container, they just save the speex encoded audio. There is nothing magical about this.

Well still can't quit rap my mind round this, but if you say so.

Anyhow, I put together a wee deb (it's just a metapackage with rbspeexenc & rbspeexdec) and have tested it on a few i386 and it seems to work. It works on Debian GNU/Linux, stable, testing & unstable without a hitch. Only the stable was a brand new default install. It failed on my powerPC deb install. I've yet to try it on my 64 bit debian install. So what I'm driving at is I've no idea what it depends on, conflicts with or may break. But it's a start.

So if someone else is interested, wants to test it, or offer me some more suggestion to maintain the package, it can be found here, rbspeex_1.0.1_i386.deb .

Cheers
Teague
Logged

Offline GodEater

  • Member
  • *
  • Posts: 2829
Re: Voicing Playlists query.
« Reply #8 on: September 21, 2009, 03:15:25 AM »
This is very useful - but doesn't belong on the forums - it should go in the wiki. Could you please move it there ?
Logged

Read The Manual Please

  • Print
Pages: [1]
« previous next »
+  Rockbox Technical Forums
|-+  Rockbox General
| |-+  Rockbox General Discussion
| | |-+  Voicing Playlists query.
 

  • SMF 2.0.17 | SMF © 2019, Simple Machines
  • Rockbox Privacy Policy
  • XHTML
  • RSS
  • WAP2

Page created in 0.094 seconds with 15 queries.