[Freeswitch-users] Phrases - Can't find macro

Michael Collins msc at freeswitch.org
Fri Feb 26 12:45:22 PST 2010


You might try this suggestion:
Create a new file for your custom macros:
/conf/lang/en/demo/custom-phrases.xml
<include>
  <macro name="confwelcome">
    <input pattern="(.*)">
      <action function="play-file" data="vm/vm-youhave.wav"/>
    </input>
  </macro>
</include>

Now you have a single place to put all of your custom macros. Be sure to
reloadxml!
-MC

On Fri, Feb 26, 2010 at 9:10 AM, Maciej Bylica <mbsip at gazeta.pl> wrote:

> Hello,
>
> I am playing around with Phrases to use them with conference application.
> But i've encountered rudimentary problem of how to use newly added macro.
>
> What I already did is (according to wiki Speech Phrase Management)
> http://wiki.freeswitch.org/wiki/Speech_Phrase_Management
> - confirmed that there is "mod_say_en" loaded (<load module="mod_say_en"/>)
> - confirmed that there are proper .wav files
> - modified onf/lang/en/en.xml file:
>  <section name="phrases" description="Speech Phrase Management">
>   <macros>
>     <language name="en" sound_path="$${sounds_dir}/en/us/callie"
> tts_engine="cepstral" tts_voice="callie">
>       <macro name="confwelcome">
>         <input pattern="(.*)">
>           <match>
>              <action function="play-file" data="vm-youhave.wav"/>
> <!-- just to test the phrase-->
>           </match>
>     </language>
>   </macros>
>  </section>
> - modified a part of dialplan:
>    <extension name="conference_48112223344">
>      <condition field="destination_number" expression="^(\d{11})$">
>         <action application="phrase" data="confwelcome"/>
>      </condition>
>     </extension>
>
> I have following outcome:
> 2010-02-26 19:57:09.487245 [DEBUG] switch_core_session.c:638 Send
> signal sofia/internal/1000 at 217.153.192.36 [BREAK]
> EXECUTE sofia/internal/1000 at 217.153.192.36 phrase(confwelcome)
> 2010-02-26 19:57:09.487245 [DEBUG] mod_dptools.c:1850 Execute confwelcome()
> lang
> 2010-02-26 19:57:09.487245 [DEBUG] switch_ivr_play_say.c:118 No
> language specified - Using [en]
> 2010-02-26 19:57:09.496322 [ERR] switch_ivr_play_say.c:202 Can't find
> macro confwelcome.
> 2010-02-26 19:57:09.496322 [WARNING] switch_ivr_play_say.c:368 Macro
> [confwelcome] did not match any patterns
>
>
>
> Strange is that if i use a wiki example, it works. To be more precise:
> - conf/lang/en/en.xml file was overwritten with an example macros
> (directly from aforementioned wiki).
> - dialplan was modified:
>    <extension name="conference_48112223344">
>      <condition field="destination_number" expression="^(\d{11})$">
>         <action application="phrase" data="msgcount"/>
>      </condition>
>     </extension>
>
>
> Am i doing something wrong?
>
> Thx,
> Maciej.
>
> _______________________________________________
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20100226/0143ba00/attachment-0002.html 


More information about the FreeSWITCH-users mailing list