On Thu, Jan 30, 2020 at 5:19 PM Kevin Harwell <[email protected]> wrote:
> On Thu, Jan 30, 2020 at 2:58 PM [email protected] < > [email protected]> wrote: > >> in my country when I dial to a mobile and I not answer the call, the call >> going to the voicemail, but the audio is executed before the 200OK, on 183 >> early media. >> >> so, I need to execute the AMD when I receive the 183, not the 200 OK. >> > > Unfortunately I am unaware of any easy solution. > > Something to be aware of if you are not. From what I understand app_dial > is reading the frames from the channel. Any solution that attempts to also > read frames from the same channel at the same time is going to run into > problems. So for instance, you can't execute app_dial and app_amd at the > same time. > > If you wish to inject some kind of audio listening, and detection > algorithms while dialing you'll have to do that within the confines of the > dial application. Basically, while app_dial is waiting for the other side > to answer it's processing frames. When an audio frame is received then that > is where you'll want to do your detection. Also once answered you'll need > to continue processing incoming audio frames. Maybe you are already doing > all of this? > > If that's the case then if a hangup occurs app_dial will automatically > handle what you need since it will detect the hangup and stop reading > frames, which in turn means audio will not get passed down into your > detection checks anymore. There is no loop to break out of since the dial > application is handing that for you (reading of frames, etc.). > Frame hooks or audio hooks might help here. Off hand, I don't know if they are active at this time but they might make it easier to implement in another module. Richard
-- _____________________________________________________________________ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev
