[Asterisk-Users] DTMF Error: Unable to handle DTMF tone 'f' for SIP

John Todd jtodd at loligo.com
Thu Jan 29 11:36:18 MST 2004


I think what he was talking about was the fact that Grandstream 
phones send "f" as a DTMF signal when one hits the "flash" button.

JT


At 11:23 AM -0600 1/29/04, Mark Spencer wrote:
>Latest CVS should not detect 'f' except in the case of a real fax.
>
>Mark
>
>On Thu, 29 Jan 2004, Brent Franks wrote:
>
>>  Christian,
>>
>>  You can change channel.c source code to be more forgiving of
>>  unrecognized DTMF tones.
>>
>>  Look for my addition near the bottom of this struct:
>>
>>	else if (digit == 'f');
>>
>>  Basically I altered channel.c to this:
>>
>>  static int do_senddigit(struct ast_channel *chan, char digit)
>>  {
>>          int res = -1;
>>
>>          if (chan->pvt->send_digit)
>>                  res = chan->pvt->send_digit(chan, digit);
>>          if (!chan->pvt->send_digit || res) {
>>                  /*
>>                   * Device does not support DTMF tones, lets fake
>>                   * it by doing our own generation. (PM2002)
>>                   */
>>                  static const char* dtmf_tones[] = {
>>                          "!941+1336/50,!0/50",   /* 0 */
>>                          "!697+1209/50,!0/50",   /* 1 */
>>                          "!697+1336/50,!0/50",   /* 2 */
>>                          "!697+1477/50,!0/50",   /* 3 */
>>                          "!770+1209/50,!0/50",   /* 4 */
>>                          "!770+1336/50,!0/50",   /* 5 */
>>                          "!770+1477/50,!0/50",   /* 6 */
>>                          "!852+1209/50,!0/50",   /* 7 */
>>                          "!852+1336/50,!0/50",   /* 8 */
>>                          "!852+1477/50,!0/50",   /* 9 */
>>                          "!697+1633/50,!0/50",   /* A */
>>                          "!770+1633/50,!0/50",   /* B */
>>                          "!852+1633/50,!0/50",   /* C */
>>                          "!941+1633/50,!0/50",   /* D */
>>                          "!941+1209/50,!0/50",   /* * */
>>                          "!941+1477/50,!0/50" }; /* # */
>>                  if (digit >= '0' && digit <='9')
>>
>>  ast_playtones_start(chan,0,dtmf_tones[digit-'0'], 0);
>>                  else if (digit >= 'A' && digit <= 'D')
>>
>>  ast_playtones_start(chan,0,dtmf_tones[digit-'A'+10], 0);
>>                  else if (digit == '*')
>>                          ast_playtones_start(chan,0,dtmf_tones[14], 0);
>>                  else if (digit == '#')
>>                          ast_playtones_start(chan,0,dtmf_tones[15], 0);
>>                  else if (digit == 'f');
>>                  else {
>>                          /* not handled */
>>                          ast_log(LOG_WARNING, "Unable to handle DTMF tone
>>  '%c' for '%s'\n", digit, chan->name);
>>                          return -1;
>>                  }
>>          }
>>          return 0;
>>  }
>>
>>  -----Original Message-----
>>  From: asterisk-users-admin at lists.digium.com
>>  [mailto:asterisk-users-admin at lists.digium.com] On Behalf Of Cristian
>>  Manoni
>>  Sent: Thursday, January 29, 2004 11:04 AM
>>  To: asterisk-users at lists.digium.com
>  > Subject: [Asterisk-Users] DTMF Error: Unable to handle DTMF tone 'f' for
>  > SIP
>  >
>  > Hi All
>  > i have continuos error:
>  > Unable to handle DTMF tone 'f' for 'SIP
>  > on the asterisk console.
>>  after this the call hang up.
>>
>>  I have a BGT 101 that make and receive call from the capi channel
>>
>>  Thanks
>>  _______________________________________________
>>  Asterisk-Users mailing list
>>  Asterisk-Users at 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 mailing list
>>  Asterisk-Users at 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 mailing list
>Asterisk-Users at 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




More information about the asterisk-users mailing list