Hello,
Today I made my test about Early media using sip device.
Indeed, after inserting the “Progress()” before “Dial()” into the dialplan, “180 Ring” became “183 Session Progress”, and RTP stream is sent to the device.
However this seems to be not enough, because that RTP stream does not contains the early media took from the ISDN channels.
Instead it contains a ringback tone,which has to be produced locally by the asterisk.
I hope I won’t abuse your kindness, but I included in this post some informations to describe better my scenario.
From PRI Debug I see that ISDN switch send a Progress Indicator = 8, asterisk receive it and produce the an event for the SIP subsystem.
From the SIP point of view, progress is received from the DAHDI channel and passed to SIP.
Sip telephone, now with the “Progress()”, receive the “183 Session Progress” with the RTP stream.
Why this rtp stream does not contains the ISDN sent early media?
[i]
--------------------------------------- console output ---------------------------------------
weboffice*CLI>
== Using SIP RTP CoS mark 5
– Executing [3398xxxxxx@from-nwo:1] Progress(“SIP/weboffice-0000002e”, “”) in new stack
– Executing [3398xxxxx8@from-nwo:2] Dial(“SIP/weboffice-0000002e”, “dahdi/13/3398xxxxxx,40,rTt”) in new stack
– Requested transfer capability: 0x00 - SPEECH
– Called dahdi/13/3398xxxxxx
– DAHDI/i5/3398xxxxxx-10 is making progress passing it to SIP/weboffice-0000002e
– DAHDI/i5/3398xxxxxx-10 is proceeding passing it to SIP/weboffice-0000002e
--------------------------------------- PRI debug ---------------------------------------
PRI Span: 5 – Making new call for cref 32771
PRI Span: 5
PRI Span: 5 > DL-DATA request
PRI Span: 5 > Protocol Discriminator: Q.931 (8) len=60
PRI Span: 5 > TEI=0 Call Ref: len= 1 (reference 3/0x3) (Sent from originator)
PRI Span: 5 > Message Type: SETUP (5)
PRI Span: 5 TEI=0 Transmitting N(S)=6, window is open V(A)=6 K=1
PRI Span: 5
PRI Span: 5 > Protocol Discriminator: Q.931 (8) len=60
PRI Span: 5 > TEI=0 Call Ref: len= 1 (reference 3/0x3) (Sent from originator)
PRI Span: 5 > Message Type: SETUP (5)
PRI Span: 5 > [04 03 80 90 a3]
PRI Span: 5 > Bearer Capability (len= 5) [ Ext: 1 Coding-Std: 0 Info transfer capability: Speech (0)
PRI Span: 5 > Ext: 1 Trans mode/rate: 64kbps, circuit-mode (16)
PRI Span: 5 > User information layer 1: A-Law (35)
PRI Span: 5 > [18 01 81]
PRI Span: 5 > Channel ID (len= 3) [ Ext: 1 IntID: Implicit BRI Spare: 0 Preferred Dchan: 0
PRI Span: 5 > ChanSel: B1 channel
PRI Span: 5 > ]
PRI Span: 5 > [1e 02 80 83]
PRI Span: 5 > Progress Indicator (len= 4) [ Ext: 1 Coding: CCITT (ITU) standard (0) 0: 0 Location: User (0)
PRI Span: 5 > Ext: 1 Progress Description: Calling equipment is non-ISDN. (3) ]
PRI Span: 5 > [28 15 b1 41 6c 65 73 73 61 6e 64 72 6f 20 43 61 72 6d 69 6e 61 74 69]
PRI Span: 5 > Display (len=21) Charset: 31 [ Alessandro ]
PRI Span: 5 > [6c 05 21 80 35 31 33]
PRI Span: 5 > Calling Number (len= 7) [ Ext: 0 TON: National Number (2) NPI: ISDN/Telephony Numbering Plan (E.164/E.163) (1)
PRI Span: 5 > Presentation: Presentation permitted, user number not screened (0) ‘513’ ]
PRI Span: 5 > [70 0c 80 31 39 39 31 39 39 33 34 35 32 31]
PRI Span: 5 > Called Number (len=14) [ Ext: 1 TON: Unknown Number Type (0) NPI: Unknown Number Plan (0) ‘3398xxxxxx’ ]
PRI Span: 5 q931.c:6037 q931_setup: Call 32771 enters state 1 (Call Initiated). Hold state: Idle
– Called dahdi/13/3398xxxxxx
PRI Span: 5
PRI Span: 5 < Protocol Discriminator: Q.931 (8) len=7
PRI Span: 5 < TEI=0 Call Ref: len= 1 (reference 3/0x3) (Sent to originator)
PRI Span: 5 < Message Type: SETUP ACKNOWLEDGE (13)
PRI Span: 5 < [18 01 89]
PRI Span: 5 < Channel ID (len= 3) [ Ext: 1 IntID: Implicit BRI Spare: 0 Exclusive Dchan: 0
PRI Span: 5 < ChanSel: B1 channel
PRI Span: 5 < ]
PRI Span: 5 Received message for call 0x93a2a90 on link 0x92f88bc TEI/SAPI 0/0
PRI Span: 5 – Processing IE 24 (cs0, Channel Identification)
PRI Span: 5 q931.c:8810 post_handle_q931_message: Call 32771 enters state 2 (Overlap Sending). Hold state: Idle
Span 5: Processing event PRI_EVENT_SETUP_ACK
– DAHDI/i5/3398xxxxxx-3 is making progress passing it to SIP/weboffice-00000002
PRI Span: 5
PRI Span: 5 < Protocol Discriminator: Q.931 (8) len=8
PRI Span: 5 < TEI=0 Call Ref: len= 1 (reference 3/0x3) (Sent to originator)
PRI Span: 5 < Message Type: CALL PROCEEDING (2)
PRI Span: 5 < [1e 02 82 88]
PRI Span: 5 < Progress Indicator (len= 4) [ Ext: 1 Coding: CCITT (ITU) standard (0) 0: 0 Location: Public network serving the local user (2)
PRI Span: 5 < Ext: 1 Progress Description: Inband information or appropriate pattern now available. (8) ]
PRI Span: 5 Received message for call 0x93a2a90 on link 0x92f88bc TEI/SAPI 0/0
PRI Span: 5 – Processing IE 30 (cs0, Progress Indicator)
PRI Span: 5 q931.c:8455 post_handle_q931_message: Call 32771 enters state 3 (Outgoing Call Proceeding). Hold state: Idle
Span 5: Processing event PRI_EVENT_PROCEEDING
– DAHDI/i5/3398xxxxxx-3 is proceeding passing it to SIP/weboffice-00000002
PRI Span: 5
PRI Span: 5 < Protocol Discriminator: Q.931 (8) len=8
PRI Span: 5 < TEI=0 Call Ref: len= 1 (reference 3/0x3) (Sent to originator)
PRI Span: 5 < Message Type: PROGRESS (3)
PRI Span: 5 < [1e 02 82 88]
PRI Span: 5 < Progress Indicator (len= 4) [ Ext: 1 Coding: CCITT (ITU) standard (0) 0: 0 Location: Public network serving the local user (2)
PRI Span: 5 < Ext: 1 Progress Description: Inband information or appropriate pattern now available. (8) ]
PRI Span: 5 Received message for call 0x93a2a90 on link 0x92f88bc TEI/SAPI 0/0
PRI Span: 5 – Processing IE 30 (cs0, Progress Indicator)
Span 5: Processing event PRI_EVENT_PROGRESS
– DAHDI/i5/3398xxxxxx-3 is making progress passing it to SIP/weboffice-00000002
--------------------------------------- phone received traffic ---------------------------------------
0.000000 192.168.1.34 -> 192.168.1.116 SIP/SDP Request: INVITE sip:3398xxxxxx@weboffice.nextel.it;user=phone, with session description
0.000893 192.168.1.116 -> 192.168.1.34 SIP Status: 100 Trying
0.002102 192.168.1.116 -> 192.168.1.34 SIP Status: 407 Proxy Authentication Required
0.033751 192.168.1.34 -> 192.168.1.116 SIP Request: ACK sip:3398xxxxxx@weboffice.nextel.it;user=phone
0.039169 192.168.1.34 -> 192.168.1.116 SIP/SDP Request: INVITE sip:3398xxxxxx@weboffice.nextel.it;user=phone, with session description
0.039908 192.168.1.116 -> 192.168.1.34 SIP Status: 100 Trying
0.401398 192.168.1.116 -> 192.168.1.34 SIP/SDP Status: 183 Session Progress, with session description
0.421900 192.168.1.116 -> 192.168.1.34 RTP PT=ITU-T G.711 PCMU, SSRC=0x6CE7990C, Seq=5161, Time=160
0.441880 192.168.1.116 -> 192.168.1.34 RTP PT=ITU-T G.711 PCMU, SSRC=0x6CE7990C, Seq=5162, Time=320
0.461880 192.168.1.116 -> 192.168.1.34 RTP PT=ITU-T G.711 PCMU, SSRC=0x6CE7990C, Seq=5163, Time=480
0.481875 192.168.1.116 -> 192.168.1.34 RTP PT=ITU-T G.711 PCMU, SSRC=0x6CE7990C, Seq=5164, Time=640
0.490876 192.168.1.34 -> 192.168.1.116 RTP PT=ITU-T G.711 PCMU, SSRC=0x7C15383F, Seq=40853, Time=3107480083, Mark
0.501875 192.168.1.116 -> 192.168.1.34 RTP PT=ITU-T G.711 PCMU, SSRC=0x6CE7990C, Seq=5165, Time=800
0.521881 192.168.1.116 -> 192.168.1.34 RTP PT=ITU-T G.711 PCMU, SSRC=0x6CE7990C, Seq=5166, Time=960
0.530702 192.168.1.34 -> 192.168.1.116 RTP PT=ITU-T G.711 PCMU, SSRC=0x7C15383F, Seq=40854, Time=3107480483, Mark
0.541878 192.168.1.116 -> 192.168.1.34 RTP PT=ITU-T G.711 PCMU, SSRC=0x6CE7990C, Seq=5167, Time=1120
0.550726 192.168.1.34 -> 192.168.1.116 RTP PT=ITU-T G.711 PCMU, SSRC=0x7C15383F, Seq=40855, Time=3107480643
0.561873 192.168.1.116 -> 192.168.1.34 RTP PT=ITU-T G.711 PCMU, SSRC=0x6CE7990C, Seq=5168, Time=1280
0.580714 192.168.1.34 -> 192.168.1.116 RTP PT=ITU-T G.711 PCMU, SSRC=0x7C15383F, Seq=40856, Time=3107480803
0.581872 192.168.1.116 -> 192.168.1.34 RTP PT=ITU-T G.711 PCMU, SSRC=0x6CE7990C, Seq=5169, Time=1440
0.600728 192.168.1.34 -> 192.168.1.116 RTP PT=ITU-T G.711 PCMU, SSRC=0x7C15383F, Seq=40857, Time=3107480963
0.601867 192.168.1.116 -> 192.168.1.34 RTP PT=ITU-T G.711 PCMU, SSRC=0x6CE7990C, Seq=5170, Time=1600
--------------------------------------- sip.conf ---------------------------------------
[general]
maxexpirey = 300
defaultexpirey = 300
context=default
allowoverlap=no
udpbindaddr=0.0.0.0:25060
tcpenable=no
tcpbindaddr=0.0.0.0
srvlookup=yes
domain=asterisk
domain=192.168.1.116
domain=192.168.1.116:25060
allowexternaldomains=yes
progressinband=yes
prematuremedia=yes
[weboffice] ; the proxy which mantains sip device registrations
type=peer
host=weboffice.nextel.it
port=5060
fromdomain=weboffice.nextel.it
canreinvite=yes
qualify=yes
context=from-nwo
progressinband=yes
prematuremedia=yes
--------------------------------------- chan_dahdi.conf ---------------------------------------
[trunkgroups]
[channels]
context=default
usecallerid=yes
hidecallerid=no
callwaiting=yes
usecallingpres=yes
callwaitingcallerid=yes
threewaycalling=yes
transfer=yes
canpark=yes
callcounter = yes
cancallforward=yes
callreturn=yes
echocancel=yes
echotraining=no
echocancelwhenbridged=yes
relaxdtmf=yes
rxgain=0.0
txgain=0.0
group=1
callgroup=1
pickupgroup=1
immediate=no
overlapdial=yes
callprogress=yes
;Sangoma AFT-B500 port 5 [slot:0 bus:10 span:5]
context=from-pstn_channel_1
group=2
callgroup=1
echocancel=yes
signalling=bri_cpe
channel =>13
[/i]