[Freeswitch-users] How to use say_string

mayamatakeshi mayamatakeshi at gmail.com
Mon May 19 12:20:28 MSD 2014


OK. I understand now that application say and function say_string are not
exactly equivalents.

To use function say_string you need to properly set sound_prefix to
something like
sound_prefix=/usr/local/freeswitch/sounds/en/us/callie

This is not needed when you use application say because of configurations
like this:
./conf/lang/en/en.xml:  <language name="en" say-module="en"
sound-prefix="$${sounds_dir}/en/us/callie" tts-engine="cepstral"
tts-voice="callie">

So I just need to set the sound_prefix as appropriate.
Regards,
Takeshi

(obs: i will update wiki later as its DB is currently locked for
maintenance)


On Mon, May 19, 2014 at 3:29 PM, mayamatakeshi <mayamatakeshi at gmail.com>wrote:

> Further search makes it clear that say_string will generate relative paths.
> Then, FS will use some variables to resolve the absolute path:
>
> sound_prefix = "/usr/local/freeswitch/sounds"
> default_language = "en"
>
> But what else needs to be set so that
>   time/mon-4.wav
> becomes something like:
>   /usr/local/freeswitch/sounds/en/us/callie/time/8000/mon-4.wav
> ?
>
>
>
> On Mon, May 19, 2014 at 1:12 PM, mayamatakeshi <mayamatakeshi at gmail.com>wrote:
>
>> Hello,
>> before I open a Jira ticket, as I might be overlooking something.
>>
>> I am trying to use say_string. Documentation is lacking so all we have is
>> here:
>> http://wiki.freeswitch.org/wiki/Misc._Dialplan_Tools_say
>>
>> But when I try to use it in the CLI i get:
>>
>> freeswitch at 192.168.2.154@internal> eval ${say_string en.wav en
>> current_date_time pronounced ${strepoch()}}
>>
>> file_string://time/mon-4.wav!digits/19.wav!digits/2.wav!digits/thousand.wav!digits/14.wav!time/at.wav!digits/1.wav!time/oclock.wav!time/p-m.wav
>>
>> As we can see, say_string is not generating full path to the files so
>> when i try to use it with application playback for example I get "FILE NOT
>> FOUND" response from FS.
>>
>> The say application itself works, so I suspect this is a bug, but since
>> this behaviour happens with both latest head
>>
>> commit 34807208c672ce1afbd5d4f2984b5fddafe701c9
>> Author: Steve Underwood <steveu at coppice.org>
>> Date:   Sat May 17 14:28:58 2014 +0800
>>
>> and a very old commit that I have in another machine:
>>
>> commit 1aa910339adb6f39df190137af439e34774908bd
>> Author: Jeff Lenk <jeff at jefflenk.com>
>> Date:   Thu Mar 1 15:55:32 2012 -0600
>>
>> I am inclined to think I am missing some configuration for this to work.
>>
>> Regards,
>> Takeshi
>>
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20140519/88eedd29/attachment-0001.html 


Join us at ClueCon 2013 Aug 6-8, 2013
More information about the FreeSWITCH-users mailing list