[asterisk-users] Problem with PSTN calls (Asterisk as SIP client on embedded device)

2011-05-27 Thread helge.reike...@gmail.com
Hi

I've spent two days trying to solve this issue but to no prevail and I'm
hoping to get some help.

I've configured Asterisk as a SIP client, running on OpenWRT on an embedded
device with onboard FXS and ATA. Asterisk is connecting to an external SIP
provider on the Internet who in turn provides a PSTN gateway. I'm able to
make calls to other SIP accounts registered on the same server who are
outside my LAN. However, I can not make calls to any PSTN numbers. When
trying to make PSTN calls it sounds like the person at the other end is
immediately rejecting the call although I know this is not the case.

Firstly, I'm absolutely sure that the PSTN gateway is working because I can
make outbound PSTN calls with the same SIP account using other SIP clients
(Empathy-SIP, SIPDroid) from the same LAN. However, when registering the
same SIP account using Asterisk from OpenWRT all PSTN calls fail. Inbound
calls from PSTN numbers also fail while calls from other SIP clients on the
same server work fine. Thus, I'm fairly confident the problem is with my
Asterisk configuration.

The SIP accounts shows as registered in Asterisk. I've attached detailed
error logs. The log files 'messages-pstn.log' shows the failed (PSTN) call
and 'messages-voip.log' shows the successful (VOIP) call. Note that I have
replaced actual phone numbers and domain names with *** for anonymity.

I suspect perhaps a codec issue, but I haven't been able to identify the
actual problem. Any ideas that will help me towards solving this problem is
greatly appreciated.

Regards,
Helge
[Feb 10 16:40:56] VERBOSE[5769] logger.c: -- event_offhook
[Feb 10 16:40:56] VERBOSE[5769] logger.c: --   AST_STATE_DOWN: 
[Feb 10 16:40:56] VERBOSE[5769] logger.c: -- start mp_new
[Feb 10 16:40:59] VERBOSE[5769] logger.c: -- event_dtmf #
[Feb 10 16:40:59] DEBUG[5769] devicestate.c: Notification of state change to be queued on device/channel MP/1
[Feb 10 16:40:59] DEBUG[5767] devicestate.c: Changing state for MP/1 - state 0 (Unknown)
[Feb 10 16:40:59] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:40:59] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:00] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:00] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:00] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:00] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:00] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:01] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:01] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:01] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:04] VERBOSE[5769] logger.c: -- event_digit_timer
[Feb 10 16:41:04] VERBOSE[5769] logger.c: --   extension exists, starting PBX #**
[Feb 10 16:41:04] DEBUG[5769] devicestate.c: Notification of state change to be queued on device/channel MP/1
[Feb 10 16:41:04] DEBUG[5767] devicestate.c: Changing state for MP/1 - state 0 (Unknown)
[Feb 10 16:41:04] DEBUG[5901] pbx.c: Launching 'Dial'
[Feb 10 16:41:04] VERBOSE[5901] logger.c: -- Executing [#**@default:1] Dial(MP/1, SIP/**@sipaccount|120|r) in new stack
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: Asked to create a SIP channel with formats: 0x4 (ulaw)
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: Allocating new SIP dialog for (No Call-ID) - INVITE (With RTP)
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: Setting NAT on RTP to On
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: *** Our native formats are 0x2 (gsm) 
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: *** Joint capabilities are 0x0 (nothing) 
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: *** Our capabilities are 0xe (gsm|ulaw|alaw) 
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: *** AST_CODEC_CHOOSE formats are 0x2 (gsm) 
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: *** Our preferred formats from the incoming channel are 0x4 (ulaw) 
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: This channel will not be able to handle video.
[Feb 10 16:41:04] DEBUG[5901] rtp.c: Channel 'MP/1' has no RTP, not doing anything
[Feb 10 16:41:04] DEBUG[5901] channel.c: Not copying variable STACK-default-#**-1.
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: Outgoing Call for **
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: Updating call counter for outgoing call
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: Our T38 capability (0), joint T38 capability (0)
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: ** Our capability: 0x6 (gsm|ulaw) Video flag: False
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: ** Our prefcodec: 0x4 (ulaw) 
[Feb 10 16:41:04] VERBOSE[5901] logger.c: Audio is at 10.130.1.21 port 17800
[Feb 10 16:41:04] VERBOSE[5901] logger.c: Adding codec 0x4 (ulaw) to SDP
[Feb 10 16:41:04] VERBOSE[5901] logger.c: Adding codec 0x2 (gsm) to SDP
[Feb 10 16:41:04] VERBOSE[5901] logger.c: Adding non-codec 0x1 (telephone-event) to SDP
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: -- Done with adding codecs to SDP
[Feb 10 16:41:04] 

[asterisk-users] Problem with PSTN calls (Asterisk as SIP client on embedded device)

2011-05-12 Thread helge.reike...@gmail.com
Hi

I've spent two days trying to solve this issue but to no prevail and I'm
hoping to get some help.

I've configured Asterisk as a SIP client, running on OpenWRT on an embedded
device with onboard FXS and ATA. Asterisk is connecting to an external SIP
provider on the Internet who in turn provides a PSTN gateway. I'm able to
make calls to other SIP accounts registered on the same server who are
outside my LAN. However, I can not make calls to any PSTN numbers. When
trying to make PSTN calls it sounds like the person at the other end is
immediately rejecting the call although I know this is not the case.

Firstly, I'm absolutely sure that the PSTN gateway is working because I can
make outbound PSTN calls with the same SIP account using other SIP clients
(Empathy-SIP, SIPDroid) from the same LAN. However, when registering the
same SIP account using Asterisk from OpenWRT all PSTN calls fail. Inbound
calls from PSTN numbers also fail while calls from other SIP clients on the
same server work fine. Thus, I'm fairly confident the problem is with my
Asterisk configuration.

The SIP accounts shows as registered in Asterisk. I've attached detailed
error logs. The log files 'messages-pstn.log' shows the failed (PSTN) call
and 'messages-voip.log' shows the successful (VOIP) call. Note that I have
replaced actual phone numbers and domain names with *** for anonymity.

I suspect perhaps a codec issue, but I haven't been able to identify the
actual problem. Any ideas that will help me towards solving this problem is
greatly appreciated.

Regards,
Helge
[Feb 10 16:40:56] VERBOSE[5769] logger.c: -- event_offhook
[Feb 10 16:40:56] VERBOSE[5769] logger.c: --   AST_STATE_DOWN: 
[Feb 10 16:40:56] VERBOSE[5769] logger.c: -- start mp_new
[Feb 10 16:40:59] VERBOSE[5769] logger.c: -- event_dtmf #
[Feb 10 16:40:59] DEBUG[5769] devicestate.c: Notification of state change to be queued on device/channel MP/1
[Feb 10 16:40:59] DEBUG[5767] devicestate.c: Changing state for MP/1 - state 0 (Unknown)
[Feb 10 16:40:59] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:40:59] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:00] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:00] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:00] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:00] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:00] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:01] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:01] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:01] VERBOSE[5769] logger.c: -- event_dtmf *
[Feb 10 16:41:04] VERBOSE[5769] logger.c: -- event_digit_timer
[Feb 10 16:41:04] VERBOSE[5769] logger.c: --   extension exists, starting PBX #**
[Feb 10 16:41:04] DEBUG[5769] devicestate.c: Notification of state change to be queued on device/channel MP/1
[Feb 10 16:41:04] DEBUG[5767] devicestate.c: Changing state for MP/1 - state 0 (Unknown)
[Feb 10 16:41:04] DEBUG[5901] pbx.c: Launching 'Dial'
[Feb 10 16:41:04] VERBOSE[5901] logger.c: -- Executing [#**@default:1] Dial(MP/1, SIP/**@sipaccount|120|r) in new stack
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: Asked to create a SIP channel with formats: 0x4 (ulaw)
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: Allocating new SIP dialog for (No Call-ID) - INVITE (With RTP)
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: Setting NAT on RTP to On
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: *** Our native formats are 0x2 (gsm) 
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: *** Joint capabilities are 0x0 (nothing) 
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: *** Our capabilities are 0xe (gsm|ulaw|alaw) 
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: *** AST_CODEC_CHOOSE formats are 0x2 (gsm) 
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: *** Our preferred formats from the incoming channel are 0x4 (ulaw) 
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: This channel will not be able to handle video.
[Feb 10 16:41:04] DEBUG[5901] rtp.c: Channel 'MP/1' has no RTP, not doing anything
[Feb 10 16:41:04] DEBUG[5901] channel.c: Not copying variable STACK-default-#**-1.
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: Outgoing Call for **
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: Updating call counter for outgoing call
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: Our T38 capability (0), joint T38 capability (0)
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: ** Our capability: 0x6 (gsm|ulaw) Video flag: False
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: ** Our prefcodec: 0x4 (ulaw) 
[Feb 10 16:41:04] VERBOSE[5901] logger.c: Audio is at 10.130.1.21 port 17800
[Feb 10 16:41:04] VERBOSE[5901] logger.c: Adding codec 0x4 (ulaw) to SDP
[Feb 10 16:41:04] VERBOSE[5901] logger.c: Adding codec 0x2 (gsm) to SDP
[Feb 10 16:41:04] VERBOSE[5901] logger.c: Adding non-codec 0x1 (telephone-event) to SDP
[Feb 10 16:41:04] DEBUG[5901] chan_sip.c: -- Done with adding codecs to SDP
[Feb 10 16:41:04] 

Re: [Asterisk-Users] Problem with PSTN

2005-05-01 Thread Wilson Pickett
 I want to use this to call on to a Telecom line(PSTN) and vice versa. I read
 somewhere that we need to use some provider for it like FWD or iconnect, do
 we need to use them to make outgoing and incoming calls to PSTN lines or we
 can do it without them.

Try reading these articles:
http://www.onlamp.com/pub/a/onlamp/2003/07/03/asterisk.html
http://www.onlamp.com/pub/a/onlamp/2004/01/22/asterisk2.html

I don't know what should I put in the .conf files so
 that it enables these calls.

Download and print the available PDFand read it a few times
http://www.asteriskdocs.org

All the answers to your current questions (and more) are there.
___
Asterisk-Users mailing list
Asterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[Asterisk-Users] Problem with PSTN

2005-04-30 Thread Salina Jain
Hi,
I am a new user of Linux and Asterisk. I bought Digium TDM400P card and now 
want to setup my dial plan. With some help from the suggestions given online 
I have been able to configure the two SIP phones to interact with each 
other.

I want to use this to call on to a Telecom line(PSTN) and vice versa. I read 
somewhere that we need to use some provider for it like FWD or iconnect, do 
we need to use them to make outgoing and incoming calls to PSTN lines or we 
can do it without them. I can post my .conf files if anybody needs them to 
help me out with this. I don't know what should I put in the .conf files so 
that it enables these calls.

Any amount of help or suggestions would really be appreciated.
Thanx,
Salina
_
News, views and gossip. http://www.msn.co.in/Cinema/ Get it all at MSN 
Cinema!

___
Asterisk-Users mailing list
Asterisk-Users@lists.digium.com
http://lists.digium.com/mailman/listinfo/asterisk-users
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users