How to set Asterisk to send RTP all the time

I’m looking solution to Asterisk to send RTP all the time, eg. during IVR, when asterisk waiting for push some button asterisk don’t send RTP, in this case when asterisk doesn’t send RTP in 5 sec, my sip provider will send “bye”, but if I set moh in background, operator doesn’t drop connection.

exten => s,n,WaitExten(4,m(silence)

In above example I set the “silence” but even so the music is heard during WaitExten.

Below example my dialplan


exten => s,1,Answer()
exten => s,n,Wait(1)
exten => s,n,Set(TIMEOUT(digit)=5) ; Set Digit Timeout to 5 seconds
exten => s,n,Set(TIMEOUT(response)=10) ; Set Response Timeout to 10 seconds
exten => s,n(poczatek),Background(welcome)
exten => s,n,Background(dolaczenie)
exten => s,n,Background(digits/1)
exten => s,n,Background(rezerwacja)
exten => s,n,Background(digits/2)
exten => s,n,WaitExten(4,m(silence)

Maybe someone know solution to Asterisk send RTP all the time ?

Asterisk should still send RTCP, which should reset the timeout.

You have a missing “)”, although, in that, place, it is probably harmless.

What is in your silence music class?

You are right, I forget “)”, now I hear silence and RTP is send from and to platform. It’s some solution but everytime I need to use: exten => s,n,WaitExten(4,m(silence)) in my dialplan which is quite well developed