提交 4bb6f969 authored 作者: Anthony Minessale's avatar Anthony Minessale

Adding mod_sofia to the tree so we can work on it easier....

I am not adding it to the examples or to the modules.conf because it's not really ready for that yet.
This is only 1.5 days old from scratch at this point but the brave hearted who want to play with it can do the following:

Add this to modules.conf:
-----------------------------------------------------------------------------
endpoints/mod_sofia
-----------------------------------------------------------------------------

Add this to freeswitch.xml in the configuration/modules.conf area
-----------------------------------------------------------------------------
<load module="mod_sofia"/>
-----------------------------------------------------------------------------

Add this to freeswitch.xml in the configuration section

-----------------------------------------------------------------------------
    <configuration name="sofia.conf" description="sofia Endpoint">
      <!-- You may have multiple profiles -->
      <profile name="test">
        <param name="rfc2833-pt" value="101"/>
        <param name="sip-port" value="5060"/>
        <param name="dialplan" value="XML"/>
        <param name="dtmf-duration" value="100"/>
        <param name="codec-prefs" value="PCMU"/>
        <param name="use-rtp-timer" value="true"/>
        <param name="rtp-ip" value="127.0.0.1"/>
        <param name="sip-ip" value="127.0.0.1"/>
        <!-- optional ; -->
        <!-- <param name="ext-rtp-ip" value="stun:stun.server.com"/>-->
        <!-- <param name="ext-rtp-ip" value="100.101.102.103"/> -->

        <!-- VAD choose one (out is a good choice); -->
        <!-- <param name="vad" value="in"/> -->
        <!-- <param name="vad" value="out"/> -->
        <!-- <param name="vad" value="both"/> -->
	<!--<param name="alias" value="sip:208.64.200.40:5555"/>-->
      </profile>
    </configuration>
-----------------------------------------------------------------------------

The call string to use profile test would be:

sofia/test/1000@1.2.3.4

as in:

<action application="bridge" data="sofia/test/1000@1.2.3.4"/>



git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@2398 d0543943-73ff-0310-b7d9-9358b9ac24b2
上级 b8974012
VERSION = sofia-sip-1.12
TARBALL = sofia-sip-1.12.1.tar.gz
CFLAGS += -I. -I$(PREFIX)/include/$(VERSION)
LDFLAGS += -lsofia-sip-ua
LINKER=$(CC)
all: depends $(MODNAME).$(DYNAMIC_LIB_EXTEN)
depends:
MAKE=$(MAKE) $(BASE)/build/buildlib.sh $(BASE) install $(TARBALL) --prefix=$(PREFIX) --with-pic
%.o: %.c
$(CC) -fPIC $(CFLAGS) -c -o $@ $<
$(MODNAME).$(DYNAMIC_LIB_EXTEN): $(MODNAME).c
$(CC) $(CFLAGS) -fPIC -c $(MODNAME).c -o $(MODNAME).o
$(LINKER) $(SOLINK) -o $(MODNAME).$(DYNAMIC_LIB_EXTEN) $(MODNAME).o $(LDFLAGS)
clean:
rm -fr *.$(DYNAMIC_LIB_EXTEN) *.o *~
install:
cp -f $(MODNAME).$(DYNAMIC_LIB_EXTEN) $(PREFIX)/mod
差异被折叠。
......@@ -1501,9 +1501,12 @@ SWITCH_DECLARE(switch_status_t) switch_ivr_originate(switch_core_session_t *sess
endfor1:
if (session) {
switch_codec_t *read_codec = switch_core_session_get_read_codec(session);
switch_codec_t *read_codec = NULL;
switch_channel_pre_answer(caller_channel);
read_codec = switch_core_session_get_read_codec(session);
assert(read_codec != NULL);
if (switch_core_codec_init(&write_codec,
"L16",
read_codec->implementation->samples_per_second,
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论