Playing ringtone until called party picks up (DAHDI)

hi guys,
i have a Digium TDM2400 card (with asterisk 1.8.10 / elastix) connected to my local PSTN provider. All inbound and outbound are working great .
when we dial out through the card , the DAHDI immediately picks up the call …and then goes completely silent until the called party starts ringing (i.e. there is no sound until the PSTN provider sends back a ringing tone) . often this takes about 12-15 seconds and the caller gets really frustrated and thinks the call is not working .

I was wondering if there is any way to keep playing ringing / music or any kind of sound to the caller until the called party answers ?

i have tried the following:

exten => _. , 1 , Answer() exten => _. , n , Ringing() exten => _. , n , Dial (DAHDI/1/${EXTEN)

but even in this case…this is what happens:

  1. Call is answered immediately
  2. User hears a single ring , before DAHDI answers the call
  3. DAHDI tries to make call through PSTN , during which time, the line is completely silent for 12-15 seconds
  4. finally when the PSTN provider manages to connect the call after 12-15 seconds, they send back and ringing tone which is played back to user.

Any solution ??

You should need neither Answer, nor Ringing.

This sounds like an answer supervision issue.

If that is the case, you need to meet two conditions. Firstly, your PSTN provider must provide an answer supervision signal. As you would always get this with ISDN, I presume you have analogue lines. For analogue lines, the most common way of doing the is to reverse the A and B wires (and therefore the voltage) when the caller answer. I have a feeling that this is the only form that Asterisk supports. Secondly, you must configure dahdi to recognise that form of answer supervision.

The default behaviour, which works even when there is no answer supervision, is to not look for it, but assume the call was answered immediately.

Whilst you are asking the provider about answer supervision, you may want to find out if they provide disconnect supervision.