On Wednesday 18 August 2021 at 09:36:02, Antory Stone wrote:
On Wednesday 18 August 2021 at 00:20:20, Raúl Alexis
Betancor Santana wrote:
On Tuesday 17 August 2021 at 21:22:37, Antony
Stone wrote:
On Tuesday 17 August 2021 at 21:55:15, Fred
Posner wrote:
On 8/17/21 2:20 PM, Antony Stone wrote:
> If not, can anyone suggest something else which could sit in between
> a very basic SIP client and a PBX server, in order to inject these
> sorts of commands into the path and thereby give me these sorts of
> extra call capabilities?
This really sounds like a better use case for Asterisk, FreeSWITCH,
SEMS, or PJSIP.
I know Asterisk pretty well.
When you use it as a SIP client to register to another PBX, it is
extremely basic - it can place a call and it can receive a call, but it
has no concept of presence, it cannot send a REINVITE to put a call on
hold, it cannot send a REFER to transfer a call...
I don't understand how placing this in between my simple client and the
PBX
which is handling the call can possibly inject the commands I need.
Sorry for telling you this, but if you think that, you don't know Asterisk
at all.
No problem - I'm very prepared to learn from experts.
You don't need to send a REINVITE to put a
call on hold, just change how
you handle the RTP of the call if you SIP endpoint doesn't support
REINVITES/UPDATES.
So, for such a simple thing, how could I get Asterisk to change the handling
of the RTP of the call, so that the remote PBX server starts playing its music
on hold to the other party?
Just tells Asterisk to put the call on hold.
If you can just show me the basics of what dialplan
commands I should be
looking at, I can work out the rest (or ask the Asterisk people).
On your scenario of controlling the call from outside the SIP channel,
Custom Dynamic Features
(
https://wiki.asterisk.org/wiki/display/AST/Custom+Dynamic+Features)
and AMI PlayDTMF
(
https://wiki.asterisk.org/wiki/display/AST/Asterisk+13+ManagerAction_PlayDT…)
could do the trick
Asterisk knows about presence, it doesn't have
full implementation,
Asterisk certainly knows about presence *when it is
the server* telling
clients *about* the presence of other clients / extensions.
It knows zero about presence when *it* is a client *asking* for the state of
other extensions on another PBX (at least, that's according to Joshua Colp,
Asterisk developer, when I asked on the Asterisk mailing list).
That's not true, you could use res_pjsip and RLS, It will need some dialplan and
script coding
but could be done. Either way I don't undestand why you whant Presence handling if
your are using a
soo dumb SIP Client.
> The thing you need it's a B2BUA, and
Asterisk, FreeSwitch, YATE, SEMS,
> either a simple python script using pjsua2 or any of the dozens SIP
> frameworks out there, will allow you to acomplish your goals
>
> If you go the Asterisk road, any of the AMI/ARI documentation will explain
> to you how to handle ongoing calls.
There is no AMI command to put a call on hold. There
are AMI notifications to
tell you that a call has been put on hold (or resumed) but there is no command
to cause this to happen. To quote from Joshua Colp: "I know of no way from
AMI to control putting a call on and off hold."
I've told you how to doit: CDF + AMI PlayDTMF
However, my understanding of a B2BUA is that *it*
would then start handling
the state of the calls itself - whether they're on hold, routing the
transfers, etc.
Partially true.
I need something which can *tell the existing PBX* to
do these things, in the
same way that a competent hardware SIP telephone would tell it.
NO, what you first need is to undestand how SIP protocol works, then which role could
play any of the available tools, next design how your are going to get you problem
solved and which tools with which roles you need to use to acomplish your goals,
and finaly build and test your solution.
There is no pre-build tool to solve your problem and no magic wand to move and get it
solved.
If there are multiple ways of achieving what I'm
trying to do (even if
Kamailio isn't one of them), please just point me at something specific which
shows me *how* - telling me "it's simple" or "there are lots of ways
of doing
it" doesn't help me to find out *how* I can do it, and the suggestions
regarding Asterisk are simply in conflict with the advice I've had from people
on the Asterisk list, who say it can't be done.
I have pointed you to how to solve it, it's up to you to read the docs and undestand
how to get to the final solution.
I'm not going to argue agains what people from the Asterisk lists says, there are too
many things done wrong inside Asterisk since it was first launched, and lot of
things that it's supposed it could not do, it does, if you know how to deal with it.
I hope someone can point me at just one example of how
this requirement can be
achieved - I've tried to keep it as simple as possible, by focusing on call
hold - once I've got that, I can build up the more complex stuff.
To reiterate, a SIP client places a call to a SIP
server; I then need a way to
tell that SIP server to put the call on hold, given that the client itself
cannot do it.
So read the docs of that SIP Server and how it allows you to put a call on hold,
Asterisk, for example, allows your to do so, playing DTMF codes on the on-going
call, no matter that the SIP endpoint does not have a "hold button". If your
SIP
endpoint it's soo dumb that it could not play DTMF, your could simulate the
"hold"
button throught CDF+AMI PlayDMTF, I've told you so.
Just rethink what you need and what are you doing. Seems to me, like your are trying
to build the Piramids and neither you know how a hammer works.
Saludos
--
Raúl Alexis Betancor Santana
Serlink Telecom S.R.L.U.