[asterisk-users] Play sound on hangup

2007-10-17 Thread Atis Lezdins
Hi,

Does anybody have some ideas - how to play a sound file on channel, after that 
bridged channel got hanged up?

Regards,
Atis

-- 
Atis Lezdins
VoIP Developer,
IQ Labs Inc.
[EMAIL PROTECTED]
Skype: atis.lezdins
Cell Phone: +371 28806004
Work phone: +1 800 7502835

___
--Bandwidth and Colocation Provided by http://www.api-digital.com--

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Play sound on hangup

2007-10-17 Thread Dovid B

- Original Message - 
From: Atis Lezdins [EMAIL PROTECTED]
To: asterisk-users@lists.digium.com
Sent: Wednesday, October 17, 2007 5:18 PM
Subject: [asterisk-users] Play sound on hangup


 Hi,

 Does anybody have some ideas - how to play a sound file on channel, after 
 that
 bridged channel got hanged up?

 Regards,
 Atis


How about the g option ? 
http://www.voip-info.org/wiki/view/Asterisk+cmd+Dial 



___
--Bandwidth and Colocation Provided by http://www.api-digital.com--

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Play sound on hangup

2007-10-17 Thread Philipp Kempgen
Atis Lezdins wrote:

 Does anybody have some ideas - how to play a sound file on channel, after 
 that 
 bridged channel got hanged up?

---cut---
g- Proceed with dialplan execution at the current extension if the
   destination channel hangs up.
---cut---

Maybe something like this would do it:

Dial(tech/123,,g);
if (${DIALSTATUS} = ANSWER) {
Playback(somefile);
}


Regards,
  Philipp Kempgen

-- 
amooma GmbH - Bachstr. 126 - 56566 Neuwied - http://www.amooma.de
Let's use IT to solve problems and not to create new ones.
  Asterisk? - http://www.das-asterisk-buch.de

Geschäftsführer: Stefan Wintermeyer
Handelsregister: Neuwied B 14998

___
--Bandwidth and Colocation Provided by http://www.api-digital.com--

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Play sound on hangup

2007-10-17 Thread Tony Mountifield
In article [EMAIL PROTECTED],
Atis Lezdins [EMAIL PROTECTED] wrote:
 Hi,
 
 Does anybody have some ideas - how to play a sound file on channel, after 
 that 
 bridged channel got hanged up?

So A calls B, who answers; A talks to B and B then hangs up - you want a sound
file played to A?

Assuming A is executing in the dialplan, and calls Dial() to call B, you might
be able to do it by giving the 'g' option to Dial(), so that the calling
channel continues after Dial has returned. You then follow the Dial with a
Playback() command.

However, in the above scenario, if it is A who hangs up, I don't think you
can play a message to B, since B is not executing in the dialplan.

Cheers
Tony
-- 
Tony Mountifield
Work: [EMAIL PROTECTED] - http://www.softins.co.uk
Play: [EMAIL PROTECTED] - http://tony.mountifield.org

___
--Bandwidth and Colocation Provided by http://www.api-digital.com--

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Play sound on hangup

2007-10-17 Thread Atis Lezdins
On Wednesday 17 October 2007 19:03:55 Tony Mountifield wrote:
  Does anybody have some ideas - how to play a sound file on channel, after
  that bridged channel got hanged up?

 So A calls B, who answers; A talks to B and B then hangs up - you want a
 sound file played to A?

 Assuming A is executing in the dialplan, and calls Dial() to call B, you
 might be able to do it by giving the 'g' option to Dial(), so that the
 calling channel continues after Dial has returned. You then follow the Dial
 with a Playback() command.

 However, in the above scenario, if it is A who hangs up, I don't think you
 can play a message to B, since B is not executing in the dialplan.

Ok, i thing - this better explains my needs - i need to play sound to B, 
whenever A hangs up.

Actually it's executing dialplan part with h extension - but i haven't been 
successful in playing sound there. 

Regards,
Atis



-- 
Atis Lezdins
VoIP Developer,
IQ Labs Inc.
[EMAIL PROTECTED]
Skype: atis.lezdins
Cell Phone: +371 28806004
Work phone: +1 800 7502835

___
--Bandwidth and Colocation Provided by http://www.api-digital.com--

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Play sound on hangup

2007-10-17 Thread Atis Lezdins
On Wednesday 17 October 2007 18:54:58 Philipp Kempgen wrote:
 Atis Lezdins wrote:
  Does anybody have some ideas - how to play a sound file on channel, after
  that bridged channel got hanged up?

 ---cut---
 g- Proceed with dialplan execution at the current extension if the
destination channel hangs up.
 ---cut---

 Maybe something like this would do it:

 Dial(tech/123,,g);
 if (${DIALSTATUS} = ANSWER) {
   Playback(somefile);
 }

Well, as i have tried - i never get ANSWER status there - i just got thrown to 
h extension.

Plus - i want to do it on other half of channel - i have incoming calls routed 
trough queue (and Agent/ channels), then Dial()'ed to local SIP. In case when 
caller hangs up - i would like to play the sound.

Regards,
Atis

-- 
Atis Lezdins
VoIP Developer,
IQ Labs Inc.
[EMAIL PROTECTED]
Skype: atis.lezdins
Cell Phone: +371 28806004
Work phone: +1 800 7502835

___
--Bandwidth and Colocation Provided by http://www.api-digital.com--

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users