Author |
|
ftgman Intermediate
Joined: February 27 2005 Location: United Kingdom Posts: 9
|
Posted: March 10 2005 at 6:25am | IP Logged
|
|
|
Hi,
Can you tell me what im missing when I try to get the single line phone example to use a SipProxy.
In the PhoneBase.cpp/StartUpCallBack I have modified the end to read:
// as the final initialization step, enable the engine.
SipTelephonyEnable(pCPhoneBase->hSipEngine);
status=EnableSipDomain(pCPhoneBase-
>hSipEngine,"ftgate.com");
status=EnableSipProxyServer(pCPhoneBase->hSipEngine,"127. 0.0.1",5061);
Each status returned is SipSuccess, but when I place a call it never goes via the proxy, it goes right to the address. I tested this by sutting down the proxy and it still connected !
What am I doing wrong?
Thanks for you help.
|
Back to Top |
|
|
support Administrator
Joined: January 26 2005 Location: United States Posts: 1666
|
Posted: March 10 2005 at 10:57am | IP Logged
|
|
|
Hello Richard,
This is a good question. Adding domain, registrar and proxy support to any of the example software applications is pretty simple. It’s explained in the API docs but we know that a software example is what developers are really interested in. :)
So…
This morning we made changes to the PhoneBase.cpp module that is used by all of the LanScape VOIP Media Engine software examples. You can find the updated C++ module at the following link:
http://www.lanscapecorp.com/support/VoipMediaEngine/PhoneBas e.cpp
Replace your existing PhoneBase.cpp module with the one at the link above. In the new C++ module, look for the macro ENABLE_SIP_REGISTRAR_AND_PROXY_SUPPORT to see what has changed.
Rebuild your example VOIP applications. From now on, let’s assume you are using the single line phone app.
After you rebuild your single line phone, put an image of each on different machines where the VOIP Media Engine has been installed. Make sure each soft phone has a unique “phone name” or phone number that will be registered at the registrar/sip proxy. Start up each soft phone on each of the hosts.
We do not know what SIP proxy/registrar you are using but you should be able to inspect your registrar to see that your soft phones have registered. Lets assume one of your phones has a name/extension of 111 and the other has a name/extension of 222.
Making phone calls using a SIP proxy:
Step 1: Add a new phone book entry.
The example apps use a simple ASCII phone book. Press the Call button on your 111 soft phone. The address book will open. Add a new entry by going to the “person’s Name” field and enter 222. For the remote address, specify your domain name ftgate.com. If you do not specify your domain for the remote address, the VOIP Media Engine will make the call outside of the proxy (direct to the address or host you specify).
After you enter in 222 and ftgate.com, press the Add, Save and Close buttons in that order (I know…).
Step 2: Make a call from phone 111 to phone 222.
Press the Call button on the faceplate of the 111 soft phone.
When the address book pops up, double click on the 222 entry at the bottom of the address list.
You should now be calling phone 222 using your proxy.
Final Comments:
All of the above actions are documented in the compiled HTML online Software developer’s reference. Please become as familiar with this document as possible. If the developer documentation is somehow inadequate, we ask that you email us feedback so that we may improve the product. There is an email link at the bottom of most help file pages that will allow you to send statements about comments, errors and omissions to “feedback ‘at’ lanscapecorp.com. If you cannot figure out what to do using the software developer’s reference, then please feel free to post to this forum. Also, when things do not go as expected, please make sure your VOIP Media Engine generates a SIP message log file. Please see the LogSipMessages and pSipLogFileName members of the START_SIP_TELEPHONY_PARAMS structure used by the StartSipTelephony API procedure. We do not expect every customer to understand all of the SIP message content but you will at least be able to see where SIP protocol messages are being sent and where they are coming from. For example, here is a log from my soft phone when I call extension 3460 that is in our office. You can see exactly where the SIP protocol traffic is going:
>>>> TxTxTxTxTxTxTxTxTxTxTxTxTxTxTxTxTxTxTx (0 Ms, To: 192.168.1.80:7000) >>>>
REGISTER sip:lanscapecorp.dnsalias.com:7000 SIP/2.0
Via: SIP/2.0/UDP 192.168.1.2:10000
From: <sip:3487@lanscapecorp.dnsalias.com:10000>;tag=433651c
To: <sip:3487@lanscapecorp.dnsalias.com:10000>
Call-Id: d63031f5-dfbf-4350-99ba-2f26c1114afc@192.168.1.2
CSeq: 70477453 REGISTER
Expires: 3600
Max-Forwards: 70
Contact: <sip:3487@192.168.1.2:10000>;user=phone
User-Agent: LanScape VOIP Media Engine/5.10.0102 (www.LanScapeCorp.com)
Content-Length: 0
<<<< RxRxRxRxRxRxRxRxRxRxRxRxRxRxRxRxRxRx (0 Ms, From: 192.168.1.80:7000) <<<<
SIP/2.0 200 OK
Via: SIP/2.0/UDP 192.168.1.2:10000;received=192.168.1.2:10000
From: <sip:3487@lanscapecorp.dnsalias.com:10000>;tag=433651c
To: <sip:3487@lanscapecorp.dnsalias.com:10000>;tag=18467
Call-ID: d63031f5-dfbf-4350-99ba-2f26c1114afc@192.168.1.2
CSeq: 70477453 REGISTER
Contact: <sip:3487@192.168.1.2:10000>;user=phone;expires=3600
User-Agent: LanScape Centrex Proxy/3.40 (www.LanScapeCorp.com)
Content-Length: 0
>>>> TxTxTxTxTxTxTxTxTxTxTxTxTxTxTxTxTxTxTx (7371 Ms, To: 192.168.1.80:7000) >>>>
INVITE sip:3460@lanscapecorp.dnsalias.com SIP/2.0
Via: SIP/2.0/UDP 192.168.1.2:10000
From: "LanScape Customer Support" <sip:3487@lanscapecorp.dnsalias.com:7000>;tag=43345cf
To: <sip:3460@lanscapecorp.dnsalias.com>
Contact: <sip:3487@lanscapecorp.dnsalias.com:7000>;x-inst=VGVzd CBDYWxsIERhdGEgZnJvbSB0aGUgVlBob25lIGFwcC4=
Call-Id: 8e8586ae-c25b-48a5-81e1-2791595a6579@192.168.1.2
CSeq: 70488495 INVITE
Max-Forwards: 70
Organization: 63A637CE-AB53-47DC-86B4-10FC1CCBF7F8
Content-Length: 197
User-Agent: LanScape VOIP Media Engine/5.10.0102 (www.LanScapeCorp.com)
Allow: INVITE, ACK, OPTIONS, BYE, CANCEL, SUBSCRIBE, NOTIFY
Content-Type: application/sdp
v=0
o=3487 70455930 70455930 IN IP4 192.168.1.2
s=LanScape
c=IN IP4 192.168.1.2
t=0 0
m=audio 9002 RTP/AVP 0 101
a=rtpmap:0 PCMU/8000/1
a=rtpmap:101 telephone-event/8000/1
a=fmtp:101 0-15
<<<< RxRxRxRxRxRxRxRxRxRxRxRxRxRxRxRxRxRx (7361 Ms, From: 192.168.1.80:7000) <<<<
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 192.168.1.2:10000;received=192.168.1.2:10000
From: "LanScape Customer Support" <sip:3487@lanscapecorp.dnsalias.com:7000>;tag=43345cf
To: <sip:3460@lanscapecorp.dnsalias.com>
Call-ID: 8e8586ae-c25b-48a5-81e1-2791595a6579@192.168.1.2
CSeq: 70488495 INVITE
User-Agent: LanScape Centrex Proxy/3.40 (www.LanScapeCorp.com)
Content-Length: 0
<<<< RxRxRxRxRxRxRxRxRxRxRxRxRxRxRxRxRxRx (10 Ms, From: 192.168.1.80:7000) <<<<
SIP/2.0 180 Ringing
Via: SIP/2.0/UDP 192.168.1.2:10000;received=192.168.1.2:10000
From: "LanScape Customer Support" <sip:3487@lanscapecorp.dnsalias.com:7000>;tag=43345cf
To: <sip:3460@lanscapecorp.dnsalias.com>;tag=6ae965
Call-ID: 8e8586ae-c25b-48a5-81e1-2791595a6579@192.168.1.2
CSeq: 70488495 INVITE
user-agent: LanScape VOIP Media Engine/5.10.0102 (www.LanScapeCorp.com)
Content-Length: 0
<<<< RxRxRxRxRxRxRxRxRxRxRxRxRxRxRxRxRxRx (1031 Ms, From: 192.168.1.80:7000) <<<<
SIP/2.0 200 OK
Via: SIP/2.0/UDP 192.168.1.2:10000;received=192.168.1.2:10000
Record-Route: <sip:192.168.1.80:7000>
From: "LanScape Customer Support" <sip:3487@lanscapecorp.dnsalias.com:7000>;tag=43345cf
To: <sip:3460@lanscapecorp.dnsalias.com>;tag=6ae965
Call-ID: 8e8586ae-c25b-48a5-81e1-2791595a6579@192.168.1.2
CSeq: 70488495 INVITE
Contact: <sip:3460@192.168.1.3:13333>
user-agent: LanScape VOIP Media Engine/5.10.0102 (www.LanScapeCorp.com)
Allow: INVITE, ACK, OPTIONS, BYE, CANCEL, SUBSCRIBE, NOTIFY
Content-Type: application/sdp
Content-Length: 158
v=0
o=LanScape 3319505631 3319505631 IN IP4 192.168.1.3
s=LanScape
c=IN IP4 192.168.1.3
t=0 0
m=audio 14076 RTP/AVP 0
a=rtpmap:0 PCMU/8000
a=ptime:20
>>>> TxTxTxTxTxTxTxTxTxTxTxTxTxTxTxTxTxTxTx (1061 Ms, To: 192.168.1.80:7000) >>>>
ACK sip:3460@lanscapecorp.dnsalias.com SIP/2.0
Via: SIP/2.0/UDP 192.168.1.2:10000;received=192.168.1.2:10000
From: "LanScape Customer Support" <sip:3487@lanscapecorp.dnsalias.com:7000>;tag=43345cf
To: <sip:3460@lanscapecorp.dnsalias.com>;tag=6ae965
Call-Id: 8e8586ae-c25b-48a5-81e1-2791595a6579@192.168.1.2
CSeq: 70488495 ACK
Max-Forwards: 70
Route: <sip:192.168.1.80:7000>,<sip:3460@192.168.1.3:13333 >
User-Agent: LanScape VOIP Media Engine/5.10.0102 (www.LanScapeCorp.com)
Content-Length: 0
>>>> TxTxTxTxTxTxTxTxTxTxTxTxTxTxTxTxTxTxTx (2334 Ms, To: 192.168.1.80:7000) >>>>
BYE sip:3460@lanscapecorp.dnsalias.com SIP/2.0
Via: SIP/2.0/UDP 192.168.1.2:10000
From: "LanScape Customer Support" <sip:3487@lanscapecorp.dnsalias.com:7000>;tag=43345cf
To: <sip:3460@lanscapecorp.dnsalias.com>;tag=6ae965
Call-Id: 8e8586ae-c25b-48a5-81e1-2791595a6579@192.168.1.2
CSeq: 70468910 BYE
Max-Forwards: 70
User-Agent: LanScape VOIP Media Engine/5.10.0102 (www.LanScapeCorp.com)
Content-Length: 0
<<<< RxRxRxRxRxRxRxRxRxRxRxRxRxRxRxRxRxRx (3385 Ms, From: 192.168.1.80:7000) <<<<
SIP/2.0 200 OK
Via: SIP/2.0/UDP 192.168.1.2:10000;received=192.168.1.2:10000
From: "LanScape Customer Support" <sip:3487@lanscapecorp.dnsalias.com:7000>;tag=43345cf
To: <sip:3460@lanscapecorp.dnsalias.com>;tag=6ae965
Call-ID: 8e8586ae-c25b-48a5-81e1-2791595a6579@192.168.1.2
CSeq: 70468910 BYE
user-agent: LanScape VOIP Media Engine/5.10.0102 (www.LanScapeCorp.com)
Content-Length: 0
This post intended to get your questions answered accurately. If you have further technical questions, please do not hesitate to post back to this forum.
Best regards,
LanScape Support
|
Back to Top |
|
|
ftgman Intermediate
Joined: February 27 2005 Location: United Kingdom Posts: 9
|
Posted: March 10 2005 at 12:43pm | IP Logged
|
|
|
A1 support. Thanks.
|
Back to Top |
|
|
|
|