[Home]

Summary:ASTERISK-05483: when exiting a conference room, DTMF tones are not properly translated back into the dialplan
Reporter:Niles Ingalls (atheos)Labels:
Date Opened:2005-11-06 19:55:41.000-0600Date Closed:2005-11-20 06:29:49.000-0600
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Applications/app_meetme
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:
Description:I'm using the X flag within the Meetme application to exit the conference room and perform various functions based on the number being pressed.  After upgrading from 1.2 Beta1 to 1.2 Beta2, the DTMF tones are mixed up. Example, 5 translates to 4, 9 translates to 2 and so on.
I copied over the Beta1 meetme.c file with my Beta2 source to get this functionality back.
Comments:By: Kevin P. Fleming (kpfleming) 2005-11-07 19:33:38.000-0600

Please post a complete console trace showing the DTMF being detected and then the conference being exited... I can't see how the digits could be misinterpreted.

By: Russell Bryant (russell) 2005-11-10 22:04:33.000-0600

Also, please try with RC1.

By: BJ Weschke (bweschke) 2005-11-11 07:52:03.000-0600

atheos: we need some feedback from you to further troubleshoot/diagnose this bug. otherwise it will be closed for lack of informaiton.

By: Niles Ingalls (atheos) 2005-11-11 21:36:31.000-0600

I'll paste what I can get out of the console, but from what I can tell, the digits pressed within the meetme application are not echo'd on the console, but are rather interpreted somewhere in the meetme application.
I'm using the meetme X flag to allow exiting the conference room by any single digit, and so on.
Here's my console using: asterisk -vvvgc after entering conference room.  I then dial 1, then 2, then 3, then 4 with no response. (1,2,3,4 are all valid in the dialplan) dialing 5 does what 4 is configured to do.

   -- Executing SetGlobalVar("IAX2/niles-41", "CONF=1701") in new stack
 == Setting global variable 'CONF' to '1701'
   -- Executing Playback("IAX2/niles-41", "script12") in new stack
   -- Playing 'script12' (language 'en')
   -- Executing SayDigits("IAX2/niles-41", "1701") in new stack
   -- Playing 'digits/1' (language 'en')
   -- Playing 'digits/7' (language 'en')
   -- Playing 'digits/0' (language 'en')
   -- Playing 'digits/1' (language 'en')
   -- Executing Goto("IAX2/niles-41", "conf|conf|1") in new stack
   -- Goto (conf,conf,1)
   -- Executing Answer("IAX2/niles-41", "") in new stack
   -- Executing SetMusicOnHold("IAX2/niles-41", "britten") in new stack
   -- Executing Macro("IAX2/niles-41", "isadmin") in new stack
   -- Executing MYSQL("IAX2/niles-41", "Connect connid localhost asterisk asterisk asterisk") in new stack
   -- Executing MYSQL("IAX2/niles-41", "Query resultid 1 SELECT mailbox FROM voicemail WHERE voicemail.mailbox='18' || voicemail.phone_work='18' || voicemail.phone_home='18' || voicemail.phone_other='18' && mailbox < '9999' LIMIT 1") in new stack
   -- Executing MYSQL("IAX2/niles-41", "Fetch fetchid 2 null") in new stack
Nov 11 22:05:10 WARNING[14759]: app_addon_sql_mysql.c:318 aMYSQL_fetch: ast_MYSQL_fetch: numFields=1
   -- Executing MYSQL("IAX2/niles-41", "Clear 2") in new stack
   -- Executing MYSQL("IAX2/niles-41", "Disconnect 1") in new stack
   -- Executing GotoIf("IAX2/niles-41", "1?7") in new stack
   -- Goto (macro-isadmin,s,7)
   -- Executing SetGlobalVar("IAX2/niles-41", "CONFADMIN=1") in new stack
 == Setting global variable 'CONFADMIN' to '1'
   -- Executing GotoIf("IAX2/niles-41", "1?5:7") in new stack
   -- Goto (conf,conf,5)
   -- Executing MeetMe("IAX2/niles-41", "1701|aMX") in new stack
 == Parsing '/etc/asterisk/meetme.conf': Found
   -- Created MeetMe conference 1023 for conference '1701'
   -- Playing 'conf-onlyperson' (language 'en')
   -- Started music on hold, class 'britten', on channel 'IAX2/niles-41'

(Here is the point where I'm pressing 1, 2, 3, then 4 without any response. pressing 5 gets me to a function set to digit 4)

   -- Hungup 'Zap/pseudo-914799046'
   -- Executing Set("IAX2/niles-41", "CONF=1701") in new stack
   -- Executing GotoIf("IAX2/niles-41", "1?3:4") in new stack
   -- Goto (conf,4,3)
   -- Executing Goto("IAX2/niles-41", "confquickcustom|custom|1") in new stack
   -- Goto (confquickcustom,custom,1)
   -- Executing Set("IAX2/niles-41", "tmpcustom=page1131764726") in new stack
   -- Executing Record("IAX2/niles-41", "page1131764726:wav") in new stack
   -- Stopped music on hold on IAX2/niles-41
   -- Playing 'beep' (language 'en')
 == Spawn extension (confquickcustom, custom, 2) exited non-zero on 'IAX2/niles-41'
   -- Executing Hangup("IAX2/niles-41", "") in new stack
 == Spawn extension (confquickcustom, h, 1) exited non-zero on 'IAX2/niles-41'
   -- Hungup 'IAX2/niles-41'



The following is the same console output after downgrading back to beta1. well, it's actually beta2 with the beta1 app_meetme.c file.  when I press 1, and get the valid response, and all other keys are interpreted correctly.

 -- Executing SetGlobalVar("IAX2/niles-38", "CONF=1701") in new stack
 == Setting global variable 'CONF' to '1701'
   -- Executing Playback("IAX2/niles-38", "script12") in new stack
   -- Playing 'script12' (language 'en')
   -- Executing SayDigits("IAX2/niles-38", "1701") in new stack
   -- Playing 'digits/1' (language 'en')
   -- Playing 'digits/7' (language 'en')
   -- Playing 'digits/0' (language 'en')
   -- Playing 'digits/1' (language 'en')
   -- Executing Goto("IAX2/niles-38", "conf|conf|1") in new stack
   -- Goto (conf,conf,1)
   -- Executing Answer("IAX2/niles-38", "") in new stack
   -- Executing SetMusicOnHold("IAX2/niles-38", "britten") in new stack
   -- Executing Macro("IAX2/niles-38", "isadmin") in new stack
   -- Executing MYSQL("IAX2/niles-38", "Connect connid localhost asterisk asterisk asterisk") in new stack
   -- Executing MYSQL("IAX2/niles-38", "Query resultid 1 SELECT mailbox FROM voicemail WHERE voicemail.mailbox='18' || voicemail.phone_work='18' || voicemail.phone_home='18' || voicemail.phone_other='18' && mailbox < '9999' LIMIT 1") in new stack
   -- Executing MYSQL("IAX2/niles-38", "Fetch fetchid 2 null") in new stack
Nov 11 22:18:37 WARNING[25083]: app_addon_sql_mysql.c:318 aMYSQL_fetch: ast_MYSQL_fetch: numFields=1
   -- Executing MYSQL("IAX2/niles-38", "Clear 2") in new stack
   -- Executing MYSQL("IAX2/niles-38", "Disconnect 1") in new stack
   -- Executing GotoIf("IAX2/niles-38", "1?7") in new stack
   -- Goto (macro-isadmin,s,7)
   -- Executing SetGlobalVar("IAX2/niles-38", "CONFADMIN=1") in new stack
 == Setting global variable 'CONFADMIN' to '1'
   -- Executing GotoIf("IAX2/niles-38", "1?5:7") in new stack
   -- Goto (conf,conf,5)
   -- Executing MeetMe("IAX2/niles-38", "1701|aMX") in new stack
 == Parsing '/etc/asterisk/meetme.conf': Found
   -- Created MeetMe conference 1023 for conference '1701'
   -- Playing 'conf-onlyperson' (language 'en')
   -- Started music on hold, class 'britten', on channel 'IAX2/niles-38'

(Here is where I press 1, which simply says what room I'm in.)

   -- Hungup 'Zap/pseudo-1561763011'
   -- Executing Set("IAX2/niles-38", "CONF=1701") in new stack
   -- Executing BackGround("IAX2/niles-38", "script12") in new stack
   -- Stopped music on hold on IAX2/niles-38
   -- Playing 'script12' (language 'en')
   -- Executing SayDigits("IAX2/niles-38", "1701") in new stack
   -- Playing 'digits/1' (language 'en')
   -- Playing 'digits/7' (language 'en')
   -- Playing 'digits/0' (language 'en')
   -- Playing 'digits/1' (language 'en')
   -- Executing GotoIf("IAX2/niles-38", "?5:6") in new stack
   -- Goto (conf,1,6)
   -- Executing Goto("IAX2/niles-38", "conf|5") in new stack
   -- Goto (conf,conf,5)
   -- Executing MeetMe("IAX2/niles-38", "1701|aMX") in new stack
 == Parsing '/etc/asterisk/meetme.conf': Found
   -- Created MeetMe conference 1023 for conference '1701'
   -- Playing 'conf-onlyperson' (language 'en')
   -- Started music on hold, class 'britten', on channel 'IAX2/niles-38'



Here is the portion of my dialplan in question:

[conf]

exten => conf,1,Answer
exten => conf,2,SetMusicOnHold(britten)
exten => conf,3,Macro(isadmin)
exten => conf,4,GotoIf(${CONFADMIN}?5:7)
exten => conf,5,MeetMe(${CONF},aMX)
exten => conf,6,Hangup
exten => conf,7,MeetMe(${CONF},AMX)
exten => conf,8,Hangup

exten => dynamic,1,Set(DYNAMIC=1)
exten => dynamic,2,SetMusicOnHold(britten)
exten => dynamic,3,Macro(isadmin)
exten => dynamic,4,GotoIf(${CONFADMIN}?5:10)
exten => dynamic,5,GotoIf(${MEETMECHANNEL}?6:8)
exten => dynamic,6,MeetMe(${MEETMECHANNEL},eMAX)
exten => dynamic,7,Hangup
exten => dynamic,8,MeetMe(,aeX)
exten => dynamic,9,Hangup
exten => dynamic,10,MeetMe(,AeX)
exten => dynamic,11,Hangup

; 1 broadcast conference. 2 paging groups  3 custom paging group

exten => 1,1,Set(CONF=${MEETMECHANNEL})
exten => 1,2,Background(script12);Conference Room
exten => 1,3,SayDigits(${MEETMECHANNEL})
exten => 1,4,GotoIf(${DYNAMIC}?5:6)
exten => 1,5,Goto(dynamic,5)
exten => 1,6,Goto(conf,5)

exten => 2,1,Set(CONF=${MEETMECHANNEL})
exten => 2,2,GotoIf(${CONFADMIN}?3:4)
exten => 2,3,Goto(confescape,escape,1)
exten => 2,4,Background(script13b); function not defined
exten => 2,5,Goto(conf,7)
exten => 3,1,Set(CONF=${MEETMECHANNEL})
exten => 3,2,GotoIf(${CONFADMIN}?3:4)
exten => 3,3,Goto(confcustom,custom,1)
exten => 3,4,Background(script13b); function not defined
exten => 3,5,Goto(conf,7)
exten => 4,1,Set(CONF=${MEETMECHANNEL})
exten => 4,2,GotoIf(${CONFADMIN}?3:4)
exten => 4,3,Goto(confquickcustom,custom,1)
exten => 4,4,Background(script13b)
exten => 4,5,Goto(conf,7)
exten => *,1,GotoIf(${DYNAMIC}?2:3)
exten => *,2,Goto(dynamic,5)
exten => *,3,Goto(conf,5)

I've upgraded, downgraded 3 times with persistent results.
Also, sorry for the delay in my responses. This phone system is live.

By: BJ Weschke (bweschke) 2005-11-15 20:15:53.000-0600

are you using inband DTMF? This is easily reproducible with inband DTMF for us, but not rfc2833 or the like. You're not going to be able to use inband DTMF with this because the reverb from the music on hold is going to cause problems with digit recognition if they get recognized at all.

By: Niles Ingalls (atheos) 2005-11-15 20:21:17.000-0600

using rfc2833 for the sip phones, and it's not in the iax.conf file for the iax phones.  
I don't see how that could explain how this problem only occurs for me when I upgrade to beta1 or above.  below beta 1, I don't have this issue at all.

By: BJ Weschke (bweschke) 2005-11-15 20:28:46.000-0600

you're right. sorry about that. What IAX phone are you using as a client? please add the "dtmf" logger channel to logger.conf and also make sure that "verbose" and "debug" is in there as well and then reproduce the symptoms. Please then attach the output of the log to this bug and we'll have a look again.

By: Niles Ingalls (atheos) 2005-11-15 20:36:57.000-0600

bweschke
11-15-05 20:28

you're right. sorry about that. What IAX phone are you using as a client? please add the "dtmf" logger channel to logger.conf and also make sure that "verbose" and "debug" is in there as well and then reproduce the symptoms. Please then attach the output of the log to this bug and we'll have a look again.

I'm using the newer style IAXy S101I adapter with a basic phone, and I have the same issue with a cisco 7940 using SIP.  I won't be able to take the phone down until Saturday afternoon to do further testing.
Thanks

By: Chih-Wei Huang (cwhuang) 2005-11-16 23:40:00.000-0600

See ASTERISK-5624

By: BJ Weschke (bweschke) 2005-11-17 00:37:41.000-0600

cwhuang: I could be wrong, but I don't believe that bug has anything to do with this one.

By: Chih-Wei Huang (cwhuang) 2005-11-17 01:26:42.000-0600

Well, there is a simple logical error in app_meetme that prevents X option from working. That is, if you press a DTMF defined in context ${MEETME_EXIT_CONTEXT} (or the current context if that variable is not defined), you will NOT exit the conference. But if you press a DTMF NOT defined in ${MEETME_EXIT_CONTEXT}, you will be kicked out the conference. My patch fixed the bug.

I am not sure if my patch fix this problem. But I'm sure you should apply my patch before doing any further testing of X option.

By: Chih-Wei Huang (cwhuang) 2005-11-17 01:52:41.000-0600

OK, the original poster said:
"Here is the point where I'm pressing 1, 2, 3, then 4 without any response. pressing 5 gets me to a function set to digit 4..."

This is eaxct the symptom that I found. So I believe my patch in ASTERISK-5624 fix THIS problem. Please give a try.

By: BJ Weschke (bweschke) 2005-11-17 09:01:56.000-0600

I believe that I was looking at this wrong originally (lack of sleep probably <g>). cwhuang's patch for 5773 is likely correct for this situation and 5631. It looks like the changes committed from 5138 is what broke this originally and the timing on that is 9/7. Beta1 was 8/27, so it looks like the timing is in sync.
Kudos to cwhuang for being persistent on what the solution really was when I was just being ignorant. Thanks! cwhuang - we just need to get that disclaimer situation cleared up and we can then commit your patch.

By: twisted (twisted) 2005-11-20 01:16:01.000-0600

I have commited the fix in 5773, so I assume this one should be closed as well?

By: BJ Weschke (bweschke) 2005-11-20 06:29:36.000-0600

fixed with the patch committed yesterday.