1. DTMF Mode Mismatch
The most common cause. If Asterisk is set to rfc2833 but the phone sends SIP INFO, the digits will be lost. Check both sides and make them match.
2. Inband DTMF with Compressed Codecs
Inband DTMF sends actual audio tones. Compressed codecs like G.729 distort these tones, making them unrecognizable by the DSP. Never use inband DTMF with G.729. Switch to RFC 2833 or use G.711.
3. RFC 2833 Payload Type Mismatch
RFC 2833 uses a dynamic RTP payload type (usually 101). If the remote side uses a different payload type number and Asterisk does not negotiate correctly, DTMF events are lost. Check the SDP negotiation.
; Look in SDP for telephone-event:
; m=audio 10000 RTP/AVP 0 101
; a=rtpmap:101 telephone-event/8000
; ^^^^
; Both sides must agree on this payload type
4. DTMF During Early Media (Before Answer)
Some IVR systems require DTMF before the call is officially answered (during 183 Session Progress). Asterisk may not process RFC 2833 events during early media. Fix by answering the call first:
; In extensions.conf - always Answer() before reading DTMF:
exten => s,1,Answer()
same => n,Wait(1)
same => n,Read(DIGITS,please-enter-number,4)
same => n,Verbose(1,Caller entered: ${DIGITS})5. Feature Codes Eating DTMF
If Dial() is called with the T or t options (transfer), Asterisk listens for feature codes (* or #) and may consume DTMF digits intended for the remote IVR.
; Problem: 't' and 'T' flags enable transfer features
; which intercept * and # DTMF
exten => _X.,1,Dial(PJSIP/${EXTEN},,tT)
; Fix: Remove t/T if you don't need transfer features
exten => _X.,1,Dial(PJSIP/${EXTEN},30)
; Or set specific feature codes that don't conflict:
; In features.conf:
; blindxfer = *1
; atxfer = *2