[ previous ] [ next ] [ threads ]
 To :  Marian Podgoreanu <marian@v...>
 From :  Milan Rukavina <rukavinamilan@g...>
 Subject :  Re: [yate] Sangoma USBfxo analog card
 Date :  Tue, 01 Jun 2010 18:29:20 +0200
Hi Marian,

When I set on answer-on-polarity I can make outgoing call - other party
rings, but when it picks up a call, yate doesn't make it answered, so
nothing happens. So as you explained seems like line polarity changes
are not supported.

I tried to tweak delaydial but without success. If it's grater than 0
calls becomes answered and I can hear dialtone, if it's 0 call is
answered as well but no dialtone. In any case seems like no actual
dialing is done. I tried to change this parameter in analog and in route
in regexroute but no dialing is done.

One more thing I noticed - on startup there's note:

 ZapCircuit driver=zaptel type=FXO channel=1 cic=1
dtmfdetect=true echotaps=0 echotrain=400 buflen=255 readonly=false
idlevalue=255 priority=normal [0x6ad150]
 ZapSpan('') driver=zaptel section=span1 type=FXO channels=1
circuits=1 [0x6ac670]
 ZapCircuit driver=zaptel type=FXO channel=2 cic=2
dtmfdetect=true echotaps=0 echotrain=400 buflen=255 readonly=false
idlevalue=255 priority=normal [0x6ad6a0]
 ZapSpan('') driver=zaptel section=span2 type=FXO channels=2
circuits=2 [0x6ad540]
* ZapCircuit(1). IOCTL(SetToneDetect) failed on channel 1
(param=3). 38: Function not implemented [0x6ac100]
 ZapCircuit(1). IOCTL(SetToneDetect) failed on channel 1
(param=3). 38: Function not implemented [0x6ac100]
 ZapCircuit(2). IOCTL(SetToneDetect) failed on channel 2
(param=3). 38: Function not implemented [0x6ac100]
 ZapCircuit(2). IOCTL(SetToneDetect) failed on channel 2
(param=3). 38: Function not implemented [0x6ac100]*

Does it have anything to do with this dialing problem?

Thanks,
Milan
> Hi,
>
> Try to set
> delaydial=0
> in the line's group in analog.conf.
> This will send the called number just after the off hook notification.
>
> You should also test if your provider and device support line polarity
> changes.
> Set
> answer-on-polarity=yes
> hangup-on-polarity=yes
> in the line's group in analog.conf.
> If line polarity changes are not supported by your provider or device
> there is no way to detect when an outgoing call is answered so it will
> be declared answered as soon as the number is sent.
>
> Marian
>
> Milan Rukavina wrote:
>> Hi,
>>
>> I'm still not able to make outbound call. Soon after I try to call - it
>> says "connected" and I hear dialtone from analog line but no actual
>> dialing is made. Any help or hint would be helpful. Here is console
>> output. I'm calling 995 - rewritten by regex to 95 - but just hear
>> dialtone. You can notice line where analog returned status 'answered'
>> where the call is not really answered. Disregard 'asterisk' word it's
>> just realm property:
>>
>>  Received 650 bytes SIP message from 192.168.1.2:5061
>> ------
>> INVITE sip:995@asterisk SIP/2.0
>> Via: SIP/2.0/UDP
>> 192.168.1.2:5061;rport;branch=z9hG4bK57F15274F410AB8CBFBAAB810E6EE6BA
>> From: 1001 ;tag=162244127
>> To: 
>> Contact: 
>> Call-ID: 0ADFB37B-86DF-983E-B4E9-EEE0D43A044D@1...
>> CSeq: 38311 INVITE
>> Max-Forwards: 70
>> Content-Type: application/sdp
>> User-Agent: X-Lite release 1105d
>> Content-Length: 231
>>
>> v=0
>> o=1001 3844635156 3844635208 IN IP4 192.168.1.2
>> s=X-Lite
>> c=IN IP4 192.168.1.2
>> t=0 0
>> m=audio 8000 RTP/AVP 0 8 101
>> a=rtpmap:0 pcmu/8000
>> a=rtpmap:8 pcma/8000
>> a=rtpmap:101 telephone-event/8000
>> a=fmtp:101 0-15
>> a=sendrecv
>> ------
>>  Sending code 100 0x6d0c20 to 192.168.1.2:5061
>> ------
>> SIP/2.0 100 Trying
>> Via: SIP/2.0/UDP
>> 192.168.1.2:5061;rport=5061;branch=z9hG4bK57F15274F410AB8CBFBAAB810E6EE6BA;received=192.168.1.2
>>
>> From: 1001 ;tag=162244127
>> To: 
>> Call-ID: 0ADFB37B-86DF-983E-B4E9-EEE0D43A044D@1...
>> CSeq: 38311 INVITE
>> Server: YATE/2.2.0
>> Content-Length: 0
>>
>> ------
>>  Could not classify call from '1001', wasted 15563 usec
>>  Routing call to '995' in context 'default' via 'analog/house' in
>> 2379 usec
>>  Executing call. caller=1001 called=95 line=house/1
>>  Outgoing call on line house/1 caller=1001 called=95
>> [0x6e6200]
>>  status=answered [0x6e6200]
>>  Guessed local IP '192.168.1.2' for remote '192.168.1.2'
>>  Session 'yrtp/2118801173' 0x6eba60 bound to
>> 192.168.1.2:27750 +RTCP [0x6eaf10]
>>  DataTranslator::attachChain [0x697080] '(null)' -> [0x6a8c80]
>> 'mulaw' not possible
>>  DataTranslator::attachChain [0x6d14f0] 'mulaw' -> [0x6971b0]
>> '(null)' not possible
>>  Sending code 200 0x6a3c10 to 192.168.1.2:5061
>> ------
>> SIP/2.0 200 OK
>> Via: SIP/2.0/UDP
>> 192.168.1.2:5061;rport=5061;branch=z9hG4bK57F15274F410AB8CBFBAAB810E6EE6BA;received=192.168.1.2
>>
>> From: 1001 ;tag=162244127
>> To: ;tag=610486506
>> Call-ID: 0ADFB37B-86DF-983E-B4E9-EEE0D43A044D@1...
>> CSeq: 38311 INVITE
>> Server: YATE/2.2.0
>> Contact: 
>> Allow: ACK, INVITE, BYE, CANCEL, REGISTER, REFER, OPTIONS, INFO
>> Content-Type: application/sdp
>> Content-Length: 205
>>
>> v=0
>> o=yate 1275154956 1275154956 IN IP4 192.168.1.2
>> s=SIP Call
>> c=IN IP4 192.168.1.2
>> t=0 0
>> m=audio 27750 RTP/AVP 0 8 101
>> a=rtpmap:0 PCMU/8000
>> a=rtpmap:8 PCMA/8000
>> a=rtpmap:101 telephone-event/8000
>> ------
>>  Received 368 bytes SIP message from 192.168.1.2:5061
>> ------
>> ACK sip:995@1...:5060 SIP/2.0
>> Via: SIP/2.0/UDP
>> 192.168.1.2:5061;rport;branch=z9hG4bK101D604D5CAD0E8D0C67398D76A77330
>> From: 1001 ;tag=162244127
>> To: ;tag=610486506
>> Contact: 
>> Call-ID: 0ADFB37B-86DF-983E-B4E9-EEE0D43A044D@1...
>> CSeq: 38311 ACK
>> Max-Forwards: 70
>> Content-Length: 0
>>
>> ------
>>  RTP starting format 'mulaw' payload 0 [0x6eaf10]
>>  Choosing started 'audio' format 'mulaw' [0x6e8490]
>>  ZapCircuit(1). Buffer overrun old=640 channel=1 (11:
>> Resource temporarily unavailable) [0x6ace20]
>>  ZapCircuit(1). Buffer overrun old=640 channel=1 (11:
>> Resource temporarily unavailable) [0x6ace20]
>>  ZapCircuit(1). Buffer overrun old=640 channel=1 (11:
>> Resource temporarily unavailable) [0x6ace20]
>>  Received 402 bytes SIP message from 192.168.1.2:5061
>> ------
>> BYE sip:995@1...:5060 SIP/2.0
>> Via: SIP/2.0/UDP
>> 192.168.1.2:5061;rport;branch=z9hG4bK12D4A5734F21B3C36B3D464960A4DE45
>> From: 1001 ;tag=162244127
>> To: ;tag=610486506
>> Contact: 
>> Call-ID: 0ADFB37B-86DF-983E-B4E9-EEE0D43A044D@1...
>> CSeq: 38312 BYE
>> Max-Forwards: 70
>> User-Agent: X-Lite release 1105d
>> Content-Length: 0
>>
>> ------
>>  Sending code 100 0x6d0c20 to 192.168.1.2:5061
>> ------
>> SIP/2.0 100 Trying
>> Via: SIP/2.0/UDP
>> 192.168.1.2:5061;rport=5061;branch=z9hG4bK12D4A5734F21B3C36B3D464960A4DE45;received=192.168.1.2
>>
>> From: 1001 ;tag=162244127
>> To: ;tag=610486506
>> Call-ID: 0ADFB37B-86DF-983E-B4E9-EEE0D43A044D@1...
>> CSeq: 38312 BYE
>> Server: YATE/2.2.0
>> Content-Length: 0
>>
>> ------
>>  YRTPWrapper::terminate() [0x6eaf10]
>>  status=disconnected reason=normal [0x6e6200]
>>  status=hangup reason=normal [0x6e6200]
>>  Sending code 200 0x6a3c10 to 192.168.1.2:5061
>> ------
>> SIP/2.0 200 OK
>> Via: SIP/2.0/UDP
>> 192.168.1.2:5061;rport=5061;branch=z9hG4bK12D4A5734F21B3C36B3D464960A4DE45;received=192.168.1.2
>>
>> From: 1001 ;tag=162244127
>> To: ;tag=610486506
>> Call-ID: 0ADFB37B-86DF-983E-B4E9-EEE0D43A044D@1...
>> CSeq: 38312 BYE
>> P-RTP-Stat: PS=1116,OS=178560,PR=1116,OR=178560,PL=0
>> Server: YATE/2.2.0
>> Allow: ACK, INVITE, BYE, CANCEL, REGISTER, REFER, OPTIONS, INFO
>> Content-Length: 0
>>
>> ------
>>  ZapCircuit(1). Consumer errors: 3. Lost: 1920/178560
>> [0x6ace20]
>>  status=destroyed reason=normal [0x6e6200]
>>
>>> Hi
>>>
>>> This is an FXO card so in zapcard.conf type must be FXO not FXS.
>>>
>>> Marian
>>>
>>> Milan Rukavina wrote:
>>>> Hi All,
>>>>
>>>> I bought recently Sangoma USBfxo device
>>>> http://wiki.sangoma.com/sangoma-wanpipe-usbfxo.I succeeded to install
>>>> drivers /zaptel and run USBfxo with Asterisk, but my target
>>>> platform is
>>>> Yate with zapcard/analog modules. The only thing I made to work for
>>>> now
>>>> is to make my SIP phone ring on incoming calls, but when I pick up a
>>>> call nothing happens. Also, when caller hangs up - sip still rings.
>>>> Caller ID is not present, but it works with Asterisk.
>>>>
>>>> Also, I'm not able to make outgoing call - it's routed well to analog
>>>> module but it freezes in status trying.
>>>>
>>>> Is there anything particular I should look at and change in
>>>> configuration files:
>>>>
>>>> *zapcard.conf:*
>>>> [span1]
>>>> type=FXS
>>>> offset=0
>>>> voicechans=1
>>>>
>>>> [span2]
>>>> type=FXS
>>>> offset=1
>>>> voicechans=1
>>>>
>>>> *analog.conf:*
>>>> [house-fxs]
>>>> type=FXS
>>>> spans=span1,span2
>>>>
>>>> *regexroute.conf:*
>>>> ;outbound calls
>>>> ^9\(.*\)$=analog/house-fxs;called=
>>>> ;inbound calls
>>>> ${address}^house-fxs/\(.*\)$=;called=1001
>>>>
>>>> Thanks,
>>>> Milan
>>
>




Hi Marian,

When I set on answer-on-polarity I can make outgoing call - other party rings, but when it picks up a call, yate doesn't make it answered, so nothing happens. So as you explained seems like line polarity changes are not supported.

I tried to tweak delaydial but without success. If it's grater than 0 calls becomes answered and I can hear dialtone, if it's 0 call is answered as well but no dialtone. In any case seems like no actual dialing is done. I tried to change this parameter in analog and in route in regexroute but no dialing is done.

One more thing I noticed - on startup there's note:

<house:ALL> ZapCircuit driver=zaptel type=FXO channel=1 cic=1 dtmfdetect=true echotaps=0 echotrain=400 buflen=255 readonly=false idlevalue=255 priority=normal [0x6ad150]
<house:INFO> ZapSpan('') driver=zaptel section=span1 type=FXO channels=1 circuits=1 [0x6ac670]
<house:ALL> ZapCircuit driver=zaptel type=FXO channel=2 cic=2 dtmfdetect=true echotaps=0 echotrain=400 buflen=255 readonly=false idlevalue=255 priority=normal [0x6ad6a0]
<house:INFO> ZapSpan('') driver=zaptel section=span2 type=FXO channels=2 circuits=2 [0x6ad540]
<house:NOTE> ZapCircuit(1). IOCTL(SetToneDetect) failed on channel 1 (param=3). 38: Function not implemented [0x6ac100]
<house:NOTE> ZapCircuit(1). IOCTL(SetToneDetect) failed on channel 1 (param=3). 38: Function not implemented [0x6ac100]
<house:NOTE> ZapCircuit(2). IOCTL(SetToneDetect) failed on channel 2 (param=3). 38: Function not implemented [0x6ac100]
<house:NOTE> ZapCircuit(2). IOCTL(SetToneDetect) failed on channel 2 (param=3). 38: Function not implemented [0x6ac100]


Does it have anything to do with this dialing problem?

Thanks,
Milan
Hi,

Try to set
delaydial=0
in the line's group in analog.conf.
This will send the called number just after the off hook notification.

You should also test if your provider and device support line polarity changes.
Set
answer-on-polarity=yes
hangup-on-polarity=yes
in the line's group in analog.conf.
If line polarity changes are not supported by your provider or device there is no way to detect when an outgoing call is answered so it will be declared answered as soon as the number is sent.

Marian

Milan Rukavina wrote:
Hi,

I'm still not able to make outbound call. Soon after I try to call - it
says "connected" and I hear dialtone from analog line but no actual
dialing is made. Any help or hint would be helpful. Here is console
output. I'm calling 995 - rewritten by regex to 95 - but just hear
dialtone. You can notice line where analog returned status 'answered' where the call is not really answered. Disregard 'asterisk' word it's
just realm property:

<sip:INFO> Received 650 bytes SIP message from 192.168.1.2:5061
------
INVITE sip:995@asterisk SIP/2.0
Via: SIP/2.0/UDP
192.168.1.2:5061;rport;branch=z9hG4bK57F15274F410AB8CBFBAAB810E6EE6BA
From: 1001 <sip:1001@asterisk:5061>;tag=162244127
To: <sip:995@asterisk>
Contact: <sip:1001@1...:5061>
Call-ID: 0ADFB37B-86DF-983E-B4E9-EEE0D43A044D@1...
CSeq: 38311 INVITE
Max-Forwards: 70
Content-Type: application/sdp
User-Agent: X-Lite release 1105d
Content-Length: 231

v=0
o=1001 3844635156 3844635208 IN IP4 192.168.1.2
s=X-Lite
c=IN IP4 192.168.1.2
t=0 0
m=audio 8000 RTP/AVP 0 8 101
a=rtpmap:0 pcmu/8000
a=rtpmap:8 pcma/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-15
a=sendrecv
------
<sip:INFO> Sending code 100 0x6d0c20 to 192.168.1.2:5061
------
SIP/2.0 100 Trying
Via: SIP/2.0/UDP
192.168.1.2:5061;rport=5061;branch=z9hG4bK57F15274F410AB8CBFBAAB810E6EE6BA;received=192.168.1.2
From: 1001 <sip:1001@asterisk:5061>;tag=162244127
To: <sip:995@asterisk>
Call-ID: 0ADFB37B-86DF-983E-B4E9-EEE0D43A044D@1...
CSeq: 38311 INVITE
Server: YATE/2.2.0
Content-Length: 0

------
<INFO> Could not classify call from '1001', wasted 15563 usec
<INFO> Routing call to '995' in context 'default' via 'analog/house' in
2379 usec
<analog:ALL> Executing call. caller=1001 called=95 line=house/1
<analog/4:CALL> Outgoing call on line house/1 caller=1001 called=95
[0x6e6200]
<analog/4:CALL> status=answered [0x6e6200]
<yrtp:INFO> Guessed local IP '192.168.1.2' for remote '192.168.1.2'
<yrtp:INFO> Session 'yrtp/2118801173' 0x6eba60 bound to
192.168.1.2:27750 +RTCP [0x6eaf10]
<INFO> DataTranslator::attachChain [0x697080] '(null)' -> [0x6a8c80]
'mulaw' not possible
<INFO> DataTranslator::attachChain [0x6d14f0] 'mulaw' -> [0x6971b0]
'(null)' not possible
<sip:INFO> Sending code 200 0x6a3c10 to 192.168.1.2:5061
------
SIP/2.0 200 OK
Via: SIP/2.0/UDP
192.168.1.2:5061;rport=5061;branch=z9hG4bK57F15274F410AB8CBFBAAB810E6EE6BA;received=192.168.1.2
From: 1001 <sip:1001@asterisk:5061>;tag=162244127
To: <sip:995@asterisk>;tag=610486506
Call-ID: 0ADFB37B-86DF-983E-B4E9-EEE0D43A044D@1...
CSeq: 38311 INVITE
Server: YATE/2.2.0
Contact: <sip:995@1...:5060>
Allow: ACK, INVITE, BYE, CANCEL, REGISTER, REFER, OPTIONS, INFO
Content-Type: application/sdp
Content-Length: 205

v=0
o=yate 1275154956 1275154956 IN IP4 192.168.1.2
s=SIP Call
c=IN IP4 192.168.1.2
t=0 0
m=audio 27750 RTP/AVP 0 8 101
a=rtpmap:0 PCMU/8000
a=rtpmap:8 PCMA/8000
a=rtpmap:101 telephone-event/8000
------
<sip:INFO> Received 368 bytes SIP message from 192.168.1.2:5061
------
ACK sip:995@1...:5060 SIP/2.0
Via: SIP/2.0/UDP
192.168.1.2:5061;rport;branch=z9hG4bK101D604D5CAD0E8D0C67398D76A77330
From: 1001 <sip:1001@asterisk:5061>;tag=162244127
To: <sip:995@asterisk>;tag=610486506
Contact: <sip:1001@1...:5061>
Call-ID: 0ADFB37B-86DF-983E-B4E9-EEE0D43A044D@1...
CSeq: 38311 ACK
Max-Forwards: 70
Content-Length: 0

------
<yrtp:INFO> RTP starting format 'mulaw' payload 0 [0x6eaf10]
<NOTE> Choosing started 'audio' format 'mulaw' [0x6e8490]
<house:ALL> ZapCircuit(1). Buffer overrun old=640 channel=1 (11:
Resource temporarily unavailable) [0x6ace20]
<house:ALL> ZapCircuit(1). Buffer overrun old=640 channel=1 (11:
Resource temporarily unavailable) [0x6ace20]
<house:ALL> ZapCircuit(1). Buffer overrun old=640 channel=1 (11:
Resource temporarily unavailable) [0x6ace20]
<sip:INFO> Received 402 bytes SIP message from 192.168.1.2:5061
------
BYE sip:995@1...:5060 SIP/2.0
Via: SIP/2.0/UDP
192.168.1.2:5061;rport;branch=z9hG4bK12D4A5734F21B3C36B3D464960A4DE45
From: 1001 <sip:1001@asterisk:5061>;tag=162244127
To: <sip:995@asterisk>;tag=610486506
Contact: <sip:1001@1...:5061>
Call-ID: 0ADFB37B-86DF-983E-B4E9-EEE0D43A044D@1...
CSeq: 38312 BYE
Max-Forwards: 70
User-Agent: X-Lite release 1105d
Content-Length: 0

------
<sip:INFO> Sending code 100 0x6d0c20 to 192.168.1.2:5061
------
SIP/2.0 100 Trying
Via: SIP/2.0/UDP
192.168.1.2:5061;rport=5061;branch=z9hG4bK12D4A5734F21B3C36B3D464960A4DE45;received=192.168.1.2
From: 1001 <sip:1001@asterisk:5061>;tag=162244127
To: <sip:995@asterisk>;tag=610486506
Call-ID: 0ADFB37B-86DF-983E-B4E9-EEE0D43A044D@1...
CSeq: 38312 BYE
Server: YATE/2.2.0
Content-Length: 0

------
<yrtp:INFO> YRTPWrapper::terminate() [0x6eaf10]
<analog/4:CALL> status=disconnected reason=normal [0x6e6200]
<analog/4:CALL> status=hangup reason=normal [0x6e6200]
<sip:INFO> Sending code 200 0x6a3c10 to 192.168.1.2:5061
------
SIP/2.0 200 OK
Via: SIP/2.0/UDP
192.168.1.2:5061;rport=5061;branch=z9hG4bK12D4A5734F21B3C36B3D464960A4DE45;received=192.168.1.2
From: 1001 <sip:1001@asterisk:5061>;tag=162244127
To: <sip:995@asterisk>;tag=610486506
Call-ID: 0ADFB37B-86DF-983E-B4E9-EEE0D43A044D@1...
CSeq: 38312 BYE
P-RTP-Stat: PS=1116,OS=178560,PR=1116,OR=178560,PL=0
Server: YATE/2.2.0
Allow: ACK, INVITE, BYE, CANCEL, REGISTER, REFER, OPTIONS, INFO
Content-Length: 0

------
<house:NOTE> ZapCircuit(1). Consumer errors: 3. Lost: 1920/178560 [0x6ace20]
<analog/4:CALL> status=destroyed reason=normal [0x6e6200]

Hi

This is an FXO card so in zapcard.conf type must be FXO not FXS.

Marian

Milan Rukavina wrote:
Hi All,

I bought recently Sangoma USBfxo device
http://wiki.sangoma.com/sangoma-wanpipe-usbfxo.I succeeded to install
drivers /zaptel and run USBfxo with Asterisk, but my target platform is
Yate with zapcard/analog modules. The only thing I made to work for now
is to make my SIP phone ring on incoming calls, but when I pick up a
call nothing happens. Also, when caller hangs up - sip still rings.
Caller ID is not present, but it works with Asterisk.

Also, I'm not able to make outgoing call - it's routed well to analog
module but it freezes in status trying.

Is there anything particular I should look at and change in
configuration files:

*zapcard.conf:*
[span1]
type=FXS
offset=0
voicechans=1

[span2]
type=FXS
offset=1
voicechans=1

*analog.conf:*
[house-fxs]
type=FXS
spans=span1,span2

*regexroute.conf:*
;outbound calls
^9\(.*\)$=analog/house-fxs;called=
;inbound calls
${address}^house-fxs/\(.*\)$=;called=1001

Thanks,
Milan