unrecognized in-band DTMF

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, May 15, 2009 at 4:31 PM, fcch2k <fcch2000 at gmail.com> wrote:
> Hi,
>
> I used PJSIP 1.0.1 in windows XP to send in-band dtmf. The sip sever
> (iptel)? is able to decode the 1,4,7,2,5,8 in-band dtmp, but it cannot
> recognize the 3, 6, 9 dtmf.? I have try to change the on/off time and
> volume, but the sever still unable to receive? 3,6,9 digits.
>
> The eyebeam can send 3, 6, 9 in-band dtmf and receive properly in the sip
> server (iptel).
>
> Have anyone seen this problem recently?
>
> I am also try to send both in-band and rfc2833 dtmf for each digit, and
> sometime the server will miss the digit. The server will not miss any digits
> if send rfc2833 only.

Hello,
I had this problem recently. I'm not sure but maybe pjsip is not using
DTMF definitions by default in tonegen (maybe it is using MFR1).
So to solve this, I set the frequency map using this:

pj_status_t set_dtmf_map(pj_pool_t *pool, pjmedia_port *tonegen) {
    /* From http://en.wikipedia.org/wiki/DTMF */
    pjmedia_tone_digit_map *map;
    map = (pjmedia_tone_digit_map*)pj_pool_alloc(pool,
sizeof(pjmedia_tone_digit_map));

    map->count = 16;

    map->digits[0].digit = '0';
    map->digits[0].freq1 = 941;
    map->digits[0].freq2 = 1336;

    map->digits[1].digit = '1';
    map->digits[1].freq1 = 697;
    map->digits[1].freq2 = 1209;

    map->digits[2].digit = '2';
    map->digits[2].freq1 = 697;
    map->digits[2].freq2 = 1336;

    map->digits[3].digit = '3';
    map->digits[3].freq1 = 697;
    map->digits[3].freq2 = 1477;

    map->digits[4].digit = '4';
    map->digits[4].freq1 = 770;
    map->digits[4].freq2 = 1209;

    map->digits[5].digit = '5';
    map->digits[5].freq1 = 770;
    map->digits[5].freq2 = 1336;

    map->digits[6].digit = '6';
    map->digits[6].freq1 = 770;
    map->digits[6].freq2 = 1477;

    map->digits[7].digit = '7';
    map->digits[7].freq1 = 852;
    map->digits[7].freq2 = 1209;

    map->digits[8].digit = '8';
    map->digits[8].freq1 = 852;
    map->digits[8].freq2 = 1336;

    map->digits[9].digit = '9';
    map->digits[9].freq1 = 852;
    map->digits[9].freq2 = 1477;

    map->digits[10].digit = 'a';
    map->digits[10].freq1 = 697;
    map->digits[10].freq2= 1633;

    map->digits[11].digit = 'b';
    map->digits[11].freq1 = 770;
    map->digits[11].freq2 = 1633;

    map->digits[12].digit = 'c';
    map->digits[12].freq1 = 852;
    map->digits[12].freq2 = 1633;

    map->digits[13].digit = 'd';
    map->digits[13].freq1 = 941;
    map->digits[13].freq2 = 1633;

    map->digits[14].digit = '*';
    map->digits[14].freq1 = 941;
    map->digits[14].freq2 = 1209;

    map->digits[15].digit = '#';
    map->digits[15].freq1 = 941;
    map->digits[15].freq2 = 1477;

    return pjmedia_tonegen_set_digit_map(tonegen,map);
}

After that, detection of DTMF by the other end became perfect.

regards,
takeshi



[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux