PickUp Issues (trough Sip trunk)

Hi all!

This features is not working for me. Any help will be appreciated.

   Tel
     |

Sip Trunk
/
5808 5807

When the call in trough sip trunk and the extension 5808 rings, I want to pickup from 5807.

This is what I see in the cmd:

-- SIP/5808-08b33ee8 is ringing
    -- Executing [**5808@from-internos:1] NoOp("SIP/5803-b6b0ee90", "Attempt to Pickup 5808 by 5803") in new stack
    -- Executing [**5808@from-internos:2] Pickup("SIP/5803-b6b0ee90", "5808@from-internos") in new stack
[Sep  8 12:39:35] NOTICE[16031]: app_directed_pickup.c:159 pickup_exec: No target channel found for 5808.
    -- Executing [**5808@from-internos:3] Hangup("SIP/5803-b6b0ee90", "") in new stack
  == Spawn extension (from-internos, **5808, 3) exited non-zero on 'SIP/5803-b6b0ee90'

sip.conf

[Astest]
host=192.168.2.1
username=Astest
secret=@st3rv01p
type=peer
insecure=very
disallow=all
allow=ulaw
allow=alaw
auth=md5
context=from-mitel

features.conf

[general]
parkext => 700
parkpos => 701-720
context => parkedcalls
;xfersound = beep
;xferfailsound = beeperr
;pickupexten = *8

[featuremap]
automon => *1
atxfer => *2

extensions.conf

[general]

;; ----------------------
[from-internos]
include => from-mitel
include => pickup-from-internos

[from-mitel]
include => meetme-all
include => mitel-disa
exten => _58xx,1,Macro(mitel-internos,${EXTEN})

[pickup-from-internos]                 
exten => _**.,1,Noop(Attempt to Pickup ${EXTEN:2} by ${CALLERID(num)})
exten => _**.,n,Pickup(${EXTEN:2}@from-internos)
exten => _**.,n,Hangup

[macro-mitel-internos]
exten => s,1,Dial(SIP/${ARG1},20,TtrwW)
exten => s,n,Macro(vmail,${ARG1}@from-internos)

Thanks in advance!.

Hi what are the contexts of the phones ?

Ian

hi Ian,

the context is: from-internos

[5807]             
type=friend  
secret=t3st.3xt
qualify=yes
port=5060 
nat=yes
mailbox=5807@device
host=dynamic
dtmfmode=rfc2833 
dial=SIP/5807
context=from-internos
canreinvite=no      
callerid=Test07 <5807>
call-limit=50   

[5808]     
type=friend
secret=t3st.3xt
qualify=yes
port=5060
nat=yes
mailbox=5808@device
host=dynamic
dtmfmode=rfc2833
dial=SIP/5808
context=from-internos
canreinvite=no
callerid=Test08 <5808>
call-limit=50

I have read about PICKUPMARKā€¦ but I cant make it work.

extensions.conf

[from-internos]
include => pickup-from-internos
include => discado-interno

[discado-interno]
exten => _58xx,1,Macro(mitel-internos,${EXTEN})

[macro-mitel-internos]   
exten => s,1,Set(__PICKUPMARK=${ARG1})
exten => s,n,Dial(SIP/${ARG1},20,TtrwW)
exten => s,n,Macro(vmail,${ARG1}@from-internos)

[macro-vmail]
exten => s,1,Goto(s-${DIALSTATUS},1)
exten => s-NOANSWER,1,Voicemail(u${ARG1})
exten => s-BUSY,1,Voicemail(b${ARG1})
exten => _s-.,1,Goto(s-NOANSWER,1)
exten => a,1,VoicemailMain(${ARG1})

[from-mitel]
include => discado-interno

[pickup-from-internos]
exten => _**.,1,Noop(Attempt to Pickup ${EXTEN:2} by ${CALLERID(num)})
exten => _**.,n,Pickup(${EXTEN:2}@from-internos)
exten => _**.,n,Hangup

Is this wrong?

I dial **5808 and nothing happensā€¦