eric weaver
2009-Oct-31 06:57 UTC
[asterisk-users] Local channel that runs a custom app... why immediate hangup?
I have an app which handles a Mitel's command port to change the MWI lights. It detects dial tone, plays some DTMF digits, listens for dialtone-or-busy, does a manager event on what it finds, and returns. Since the Mitel command port does not give answer supervision (looks like it's ringing), and since I run this app via a AMI "originate" command, I set up an extension in extensions.conf thus: exten => MWISend,1,Answer(1000) ; does more-or-less the same thing without the delay exten => MWISend,2,MWISend(${MWISEND_DIGITS}) ; the variable set in the AMI call - this is tested & works. The Originate goes like: Channel: Local/MWISend at default Extension: 650nnnnnnn Context: direct_out ; a context that dials SIP/${EXTEN}@metaswitch which is known to work Priority: 1 What happens is the local channel goes immediately into Hangup with many odd-looking messages about searching for the extension, when it has clearly already been found and goes into a hangup(see trace below). Anybody have a hint what's happening here and how to make the application see the voice frames from the dial-out? Thanks. [Oct 30 23:44:45] DEBUG[16246] manager.c: Manager received command 'originate' [Oct 30 23:44:45] DEBUG[16247] pbx.c: Launching 'Answer' [Oct 30 23:44:45] DEBUG[16247] devicestate.c: Notification of state change to be queued on device/channel Local/MWISend at default [Oct 30 23:44:45] DEBUG[16150] devicestate.c: No provider found, checking channel drivers for Local - MWISend at default [Oct 30 23:44:45] DEBUG[16246] devicestate.c: Notification of state change to be queued on device/channel Local/MWISend at default [Oct 30 23:44:45] DEBUG[16150] chan_local.c: Checking if extension MWISend at default exists (devicestate) [Oct 30 23:44:45] DEBUG[16150] devicestate.c: Changing state for Local/MWISend at default - state 2 (In use) [Oct 30 23:44:45] DEBUG[16176] app_queue.c: Device 'Local/MWISend at default' changed to state '2' (In use) but we don't care because they're not a member of any queue. [Oct 30 23:44:45] DEBUG[16150] devicestate.c: No provider found, checking channel drivers for Local - MWISend at default [Oct 30 23:44:45] DEBUG[16150] chan_local.c: Checking if extension MWISend at default exists (devicestate) [Oct 30 23:44:45] DEBUG[16150] devicestate.c: Changing state for Local/MWISend at default - state 2 (In use) [Oct 30 23:44:45] DEBUG[16176] app_queue.c: Device 'Local/MWISend at default' changed to state '2' (In use) but we don't care because they're not a member of any queue. [Oct 30 23:44:45] DEBUG[16248] channel.c: Soft-Hanging up channel 'Local/MWISend at default-1b18,1' [Oct 30 23:44:45] DEBUG[16248] channel.c: Hanging up channel 'Local/MWISend at default-1b18,1' [Oct 30 23:44:45] DEBUG[16247] pbx.c: Spawn extension (default,MWISend,1) exited non-zero on 'Local/MWISend at default-1b18,2' [Oct 30 23:44:45] DEBUG[16247] channel.c: Soft-Hanging up channel 'Local/MWISend at default-1b18,2' [Oct 30 23:44:45] DEBUG[16247] channel.c: Hanging up channel 'Local/MWISend at default-1b18,2' [Oct 30 23:44:45] DEBUG[16247] devicestate.c: Notification of state change to be queued on device/channel Local/MWISend at default [Oct 30 23:44:45] DEBUG[16150] devicestate.c: No provider found, checking channel drivers for Local - MWISend at default [Oct 30 23:44:45] DEBUG[16150] chan_local.c: Checking if extension MWISend at default exists (devicestate) [Oct 30 23:44:45] DEBUG[16150] devicestate.c: Changing state for Local/MWISend at default - state 2 (In use) [Oct 30 23:44:45] DEBUG[16176] app_queue.c: Device 'Local/MWISend at default' changed to state '2' (In use) but we don't care because they're not a member of any queue. [Oct 30 23:44:45] DEBUG[16248] devicestate.c: Notification of state change to be queued on device/channel Local/MWISend at default [Oct 30 23:44:45] DEBUG[16150] devicestate.c: No provider found, checking channel drivers for Local - MWISend at default [Oct 30 23:44:45] DEBUG[16150] chan_local.c: Checking if extension MWISend at default exists (devicestate) [Oct 30 23:44:45] DEBUG[16150] devicestate.c: Changing state for Local/MWISend at default - state 1 (Not in use) [Oct 30 23:44:45] DEBUG[16176] app_queue.c: Device 'Local/MWISend at default' changed to state '1' (Not in use) but we don't care because they're not a member of any queue. --- at this point the AMI application sees the hangup event and terminates --- -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20091030/c4efddef/attachment.htm