Jump to content
PortSIP PBX for Unified Communications
FenilS14

Not able to play an audio file

Recommended Posts

On 5/27/2020 at 11:16 AM, Joe Lepple said:

When you start PortSIP_playAudioFileToRemote?

Please start playAudioFileToRemote after onInviteAnswered or onInviteConnected

Hi Joe,

I tried calling the PortSIP_playAudioFileToRemote method inside onInviteAnswered or onInviteConnected events, but both these events gets executed quite a while before the user picks up.

Can you suggest any other event which I might be missing out or any other workaround....?

Thanks,

Fenil  

Share this post


Link to post
Share on other sites

Hi Fenil,

   These two events happen after the user answers.

   Is there an intermediate server like IVR / CallQueue between you and the end user responsible for connecting the call, playing music, and finally transferring the call?

Best regards,

Share this post


Link to post
Share on other sites
On 5/31/2020 at 9:18 PM, Joe Lepple said:

Hi Fenil,

   These two events happen after the user answers.

   Is there an intermediate server like IVR / CallQueue between you and the end user responsible for connecting the call, playing music, and finally transferring the call?

Best regards,

Hi Joe, 

Apologies for the late reply.

As I'm using the modem, the modem server is between the two calling parties which acts as a kind of intermediate server .

Please if you could suggest any workaround.

 

Thanks & Best Regards,

Fenil

Share this post


Link to post
Share on other sites

Hi Fenil

  I don't know your usage. Only after the call is established, the audio can be played normally.

 

Best regards,

Share this post


Link to post
Share on other sites
19 hours ago, Joe Lepple said:

Hi Fenil

  I don't know your usage. Only after the call is established, the audio can be played normally.

 

Best regards,

Hi Joe,

Let me give you the whole requirement which might help you here.

I want to build an application, which takes up the user details and the path of the audio file configured for that user from the Database.

For each record in the database, the application will pickup the record --> call the user --> plays the audiofile --> Ends the call.

Now here, we're using the modem to place the call using the SIP server we've created. using the SIP server, the application will call the user through the modem then as the user pickup the call ,I want to play the associated audio file.

Now the issue that I'm facing is that , I'm not able to receive any event from the modem which hints me that the user has picked up the call.So I need to handle this from SIP side.

As you suggest to make use of  the events, OnInviteAnswered & onInviteConnected , I tried. But, the issue is both these events get fired quite a while before the user actually picks the call and hence the audio file starts playing. Hence, when the user actually pick up the call, he'll be hearing from the middle of the audio file and thus, he needs to wait till the next loop of audio file.

I want that the audio file should start playing only after the user actually picks up the call.

I hope this helps.

Thanks & Best Regards,

Fenil Shah 

Share this post


Link to post
Share on other sites

The problem is that the server replies to the caller that the call has been answered before the user answers. Cause the caller to think that the call has been established and start playing the file prematurely.

Only the server knows the user's answer call time.

You can capture the packet on SIP server to track this issue.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...