Different device status

Hi
We are using asterisk 1.4. When we call from soft phone to hard phone and hard phone get busy the call we get device status as ‘BUSY’ but in case of soft phone we get device status is as ‘CONJECTION’. Logs of both states are given below

soft phone ----------> Hard phone
<------------->
— (10 headers 0 lines) —
– SIP/9004-000005d8 is ringing

<— SIP read from 10.111.11.54:2051 —>
SIP/2.0 486 Busy Here
Via: SIP/2.0/UDP 10.113.5.15:5060;branch=z9hG4bK338b0d96;rport=5060
From: “9099” sip:9099@10.113.5.15;tag=as1d9a0b92
To: sip:9004@10.111.11.54:2051;line=7hl5fvo6;tag=oy40ktipis
Call-ID: 1365c92b36e62e551968beb009189cec@10.113.5.15
CSeq: 102 INVITE
Contact: sip:9004@10.111.11.54:2051;line=7hl5fvo6;flow-id=1
Content-Length: 0

<------------->
— (8 headers 0 lines) —
– Got SIP response 486 “Busy Here” back from 10.111.11.54
Transmitting (no NAT) to 10.111.11.54:2051:
ACK sip:9004@10.111.11.54:2051;line=7hl5fvo6 SIP/2.0
Via: SIP/2.0/UDP 10.113.5.15:5060;branch=z9hG4bK338b0d96;rport
From: “9099” sip:9099@10.113.5.15;tag=as1d9a0b92
To: sip:9004@10.111.11.54:2051;line=7hl5fvo6;tag=oy40ktipis
Contact: sip:9099@10.113.5.15
Call-ID: 1365c92b36e62e551968beb009189cec@10.113.5.15
CSeq: 102 ACK
User-Agent: TRG-SIP
Max-Forwards: 70
Content-Length: 0

soft phone ----------> soft phone

— SIP read from 10.111.5.221:8070 —>
SIP/2.0 180 Ringing
To: sip:9098@10.111.5.221:8070;tag=a42f147a
From: "9099"sip:9099@10.113.5.15;tag=as566def64
Via: SIP/2.0/UDP 10.113.5.15:5060;branch=z9hG4bK6b111f26;rport=5060;received=10.113.5.15
Call-ID: 77a1ee095fef975a0ea39a123ed0c41a@10.113.5.15
CSeq: 102 INVITE
Contact: sip:9098@10.111.5.221:8070
Content-Length: 0

<------------->
— (8 headers 0 lines) —
– SIP/9098-000005d6 is ringing

<------------->
Really destroying SIP dialog ‘6e661fa033ed604a6b8ce9e66c79bf5a@10.113.5.15’ Method: OPTIONS

<— SIP read from 10.111.5.221:8070 —>
SIP/2.0 480 Temporarily Unavailable
To: sip:9098@10.111.5.221:8070;tag=a42f147a
From: "9099"sip:9099@10.113.5.15;tag=as566def64
Via: SIP/2.0/UDP 10.113.5.15:5060;branch=z9hG4bK6b111f26;rport=5060;received=10.113.5.15
Call-ID: 77a1ee095fef975a0ea39a123ed0c41a@10.113.5.15
CSeq: 102 INVITE
Content-Length: 0

— (7 headers 0 lines) —
– Got SIP response 480 “Temporarily Unavailable” back from 10.111.5.221
Transmitting (no NAT) to 10.111.5.221:8070:
ACK sip:9098@10.111.5.221:8070 SIP/2.0
Via: SIP/2.0/UDP 10.113.5.15:5060;branch=z9hG4bK6b111f26;rport
From: “9099” sip:9099@10.113.5.15;tag=as566def64
To: sip:9098@10.111.5.221:8070;tag=a42f147a
Contact: sip:9099@10.113.5.15
Call-ID: 77a1ee095fef975a0ea39a123ed0c41a@10.113.5.15
CSeq: 102 ACK
User-Agent: TRG-SIP
Max-Forwards: 70
Content-Length: 0

-- SIP/9098-000005d6 is circuit-busy

== Everyone is busy/congested at this time (1:0/1/0)
trgpbx_ib.php: status ---->CONGESTION
trgpbx_ib.php: hangupcause : 19
trgpbx_ib.php: CONGESTION : Inside–NoANSWER
– Playing ‘/data/PBXIVR/fwd_your_call’ (escape_digits=#) (sample_offset 0)
Really destroying SIP dialog ‘77a1ee095fef975a0ea39a123ed0c41a@10.113.5.15’ Method: INVITE

The first device returned:

SIP/2.0 486 Busy Here

which is clearly busy.

The second device returned:

SIP/2.0 480 Temporarily Unavailable

which means:

[quote]21.4.18 480 Temporarily Unavailable

The callee’s end system was contacted successfully but the callee is
currently unavailable (for example, is not logged in, logged in but
in a state that precludes communication with the callee, or has
activated the “do not disturb” feature). The response MAY indicate a
better time to call in the Retry-After header field. The user could
also be available elsewhere (unbeknownst to this server). The reason
phrase SHOULD indicate a more precise cause as to why the callee is
unavailable. This value SHOULD be settable by the UA. Status 486
(Busy Here) MAY be used to more precisely indicate a particular
reason for the call failure.[/quote]

which suggests that the subscriber wasn’t actually busy on the phone. As it is not clearly busy, Asterisk tends to use Congestion, as a catch all.

If you want more precise information ${HANGUPCAUSE} gives the nearest ISDN cause code to the SIP one. Current versions of Asterisk also allow you to access the SIP one.

Thanks david for reply.

But issue is why different STATUS while we are doing same scenario on soft phone as well as hard phone.

Phone A ---------(dials)-------------->Phone B
(ringing) -------->(we hangup call from Phone B)

In case of hard phone we get “status ---->BUSY”

and in case of soft phone we get “status ---->CONGESTION”

we also have used ${HANGUPCAUSE} but same result.

That is a function of the phones, not of Asterisk.