Hello to all!
I can not help but share the experience of implementing such a necessary feature as call paging on Cisco CallManager. This should work like this:
- the subscriber picks up the phone, presses the function access key and starts broadcasting;
- Predefined phones receive and reproduce sound through their hands-free speakers.
Unfortunately, despite the fact that paging is a standard feature of any traditional PBX, CCM does not know how. However, thanks to the XML browser built into the 7900 series phones, paging (and not only) can be implemented as a service.
Theory
Here is a good guide about this. From it, you can learn that communication with the phone consists in the transfer to it of certain XML objects that cause it to take some action. There are few actions: display text, menu or image, make a call, play a sound and, what interests us most, transfer sound from a microphone to RTP at a given address or receive RTP and play sound to a speaker (using g.711u).
I used only two objects (the syntax is described in the same guide):
- CiscoIPPhoneExecute - execute a command or open a URL. To control the transmission of an audio stream, use the RTPRx and RTPTx commands;
- CiscoIPPhoneText - display text on the phone display. In addition to the actual text and title, this object can contain SoftKeyItem elements - programmable keys. You can assign actions to them (separately for pressing and releasing), similar to the CiscoIPPhoneExecute object.
Implementation
The most primitive implementation might look something like this:
- let's say phones play RTP from a given port:
<CiscoIPPhoneExecute>
<ExecuteItem Priority = "0" URL = "RTPMRx: 239.0.0.45: 20480: 90" />
</ CiscoIPPhoneExecute>
Pay attention to the RTPMRx command - after a series of experiments, I decided to send out the sound by multicast. The address is chosen arbitrarily, the port number must be even and in the range of 20480-32768; - on the phone from which paging is performed, we will create a minimal interface: a text label and two buttons, “start” and “exit”:
<CiscoIPPhoneText>
<Title> Alert </ Title>
<Prompt> Click Start </ Prompt>
<Text> Alert </ Text>
<SoftKeyItem>
<Name> Start </ Name>
<URL> RTPTx: Stop </ URL>
<URLDown> RTPMTx: 239.0.0.45: 20480 </ URLDown>
<Position> 1 </ Position>
</ SoftKeyItem>
<SoftKeyItem>
<Name> Log Out </ Name>
<URL> SoftKey: Exit </ URL>
<URLDown> http://10.1.1.65/page_stop.php </ URLDown>
<Position> 4 </ Position>
</ SoftKeyItem>
</ CiscoIPPhoneText>
By pressing the “Start” button, the phone receives a command from the URLDown element, RTPMTx: 239.0.0.45: 20480, and starts sending an audio stream to the specified address. When the subscriber releases the button, the phone executes the RTPTx: Stop command from the URL element; - Unfortunately, I did not find a way to execute two commands for one user action, so after releasing the “Start” button, the receiving phones continue to play RTP (which is already gone). Therefore, when you press the “Exit” button, one more object is called for each phone that listens to the phone:
<CiscoIPPhoneExecute>
<ExecuteItem Priority = "0" URL = "RTPMRx: Stop" />
</ CiscoIPPhoneExecute>
I implemented it all on php + mysql (for storing phone addresses. I was already too lazy to figure out how to get them from the CCM database), but I warn you right away - I’m not even a close programmer, so all that you see
here and
here is real govnokod. Proceed with caution.
What else can be done from this
And a lot of things: weather forecast / currency rates / news, text messaging, reminders / alarm clocks, even heard about the broadcast images from surveillance cameras. And yes, for the most curious, it is noticed that when the microphone is turned on remotely, the phone signals this only with an unremarkable icon on the display ...