Asynchronously detects a tone
The TONE_DETECT function detects a single-frequency tone and keeps track of how many times the tone has been detected.
When reading this function (instead of writing), supply
tx to get the number of times a tone has been detected in the TX direction and
rx to get the number of times a tone has been detected in the RX direction.
freq- Frequency of the tone to detect.
duration_ms- Minimum duration of tone, in ms. Default is 500ms. Using a minimum duration under 50ms is unlikely to produce accurate results.
d- Custom decibel threshold to use. Default is 16.
g- Go to the specified context,exten,priority if tone is received on this channel. Detection will not end automatically.
h- Go to the specified context,exten,priority if tone is transmitted on this channel. Detection will not end automatically.
n- Number of times the tone should be detected (subject to the provided timeout) before going to the destination provided in the
hoption. Default is 1.
r- Apply to received frames only. Default is both directions.
s- Squelch tone.
t- Apply to transmitted frames only. Default is both directions.
x- Destroy the detector (stop detection).
This documentation was imported from Asterisk Version GIT-16-249fe0f