Send SMS messages from ICX-AlphaCom
From Zenitel Wiki
This article describes how information can be sent from the ICX-AlphaCom (or AlphaCom XE) to a mobile phone as a SMS message. This could for example be Call Requests in low traffic systems, error messages (station error, AlphaNet error etc.) or Silent Alarm when a remote control input (RCI) is activated.
The GSM Gateway MV-370 (item 2200003000) has a built-in GSM modem with which one can generate SMS messages by AT commands over the Telnet protocol. ICX-AlphaCom can be configured to communicate with the GSM gateway on the Telnet port (port 23), and use the EDO command to generate the required AT commands.
GSM Gateway configuration
The MV-370 unit is configured via a web interface. The default IP address is 192.168.0.100, mask 255.255.255.0. The default IP address can be set by pressing the reset button (located next to the SIM card) for 3 seconds. Other settings will be kept. Before accessing the web page, confirm that the IP address of the configuration PC is on the same subnet, e.g. 192.168.0.x.
- Username: voip
- Password: 1234
Network settings
Change the network settings according to the network environment. Select Network > WAN Settings:
- IP Type = Enable Fixed IP
- IP = IP address of the Mobile VoIP unit
- Mask = Network mask
- Gateway = IP address of the network gateway
Mobile settings
- Mobile > Settings > SIP from: Select User/Tel (Not Reg)
- Mobile > Settings > Mobile PIN Code: If the mobile needs to be unlocked by a pin code you must enable ON, and enter the pin code, and confirm the pin code
- Mobile > Status: Shows that the SIM card in in place, and that the Mobil VoIP unit is registered on the GSM network.
ICX-AlphaCom Configuration
Configuring the communication port
Configure the communication parameters of the ICX-AlphaCom.
In AlphaPro, Exchange & System -> Serial ports, select EDIO port 1 and set the following parameters:
- Port type: TCP/IP Client
- IP Address: Enter the IP Address of the MV-370 GSM gateway
- Port: 23 (This is the Telnet port)
- Keep Alive: Enable
License requirements
No licenses are required to send SMS messages via the MV-370 GSM gateway.
However, if voice communication is required between ICX-AlphaCom and the mobile phone, then a SIP Trunk license is required, and the gateway and the ICX-AlphaCom must be configured for SIP Trunking, see Configuration guide for Mobile VoIP.
Application examples
Forward Call Requests as SMS message
The Call Request must be forwarded to a dummy station, which will queue the call and via the event handler send the SMS message. If there are several simultaneous call requests, a SMS message will be generated every 10 seconds until the call queue is empty.
The dummy number can be any station directory number in the exchange which is not in use. Here directory number 5152 on physical 552 is used as an example.
- Forwarding to SMS On: On the Control Room station dial 7870 + Dummy Number (e.g. dial 7870 + 5152, or press a DAK key with the programming: I 7870 I 5152).
- Forwarding to SMS Off: On the Control Room station dial 70
When the dummy receives the call request, the event "New current mail" is triggered on the dummy. This event causes the SMS message to be sent, and a 10 second timer is started. When the timer expires, the current mail is deleted ($CANM). If there are more calls in the queue, the event "New current mail" will be re-triggered, causing a new SMS to be sent. This will go in loop until there are no more calls in the queue.
In AlphaPro, Exchange & System -> Events, press Insert to add new event.
Event 1:
When a call request is made, a SMS message "Call from: xxx" is sent to telephone number 12345678. Then a 10 second timer is started to check for more call requests:
Action commands:
EDO 1 "voip\r\n" Log in with username "voip". This is the same username as for the Web interface. EDO 1 "1234\r\n" Log in with password "1234". This is the same password as for the Web interface. EDO 1 "module1\r\n" Start software "module 1" in the GSM modem. pause A 400 ms delay is required before the next action. pause pause pause EDO 1 "at+cmgf=1\r\n" AT-command which sets the GSM modem to Text Mode pause A 400 ms delay is required before the next action. pause pause pause EDO 1 "at+cmgs=\"12345678\"\r\n" AT-command to set the GSM number of the receiver pause A 400 ms delay is required before the next action. pause pause pause EDO 1 "Call from: %2.dir\x1A\r\n" The text to transmit, terminated by <Ctrl+Z> (hex 1A) EDO 1 "logout\r\n" Log out from Telnet $ST L%1.dir W100 L%2.dir Start a 10 sec timer
The telephone number and the SMS text must be adapted to the actual requirement.
Event 2:
When the timer started in the above event expires, the current call request is deleted from the mail queue using the CANM command. This will result in a new current mail event being triggered if there are still calls in queue:
Action commands:
$CANM L%2.dir L%1.dir Cancel the call request
Send Station Errors as SMS message
The station error message must be forwarded as a "Call Request" to a dummy station. In this way errors messages are put in a queue at the dummy. Via the event handler SMS messages are generated every 10 seconds until the queue is empty.
The dummy number can be any station directory number in the exchange that is not in use. Here directory number 5151 on physical 551 is used as an example.
When the dummy receives the call request, the event "New current mail" is triggered on the dummy. This event causes the SMS message to be sent, and a 10 second timer is started. When the timer expires, the current mail is deleted ($CANM). If there are more calls in the queue, the event "New current mail" will be re-triggered, causing a new SMS to be sent. This will go in loop until there are no more elements in the queue.
In AlphaPro, Exchange & System -> Events, press Insert to add new event.
Event 1: Send station errors as Call Request to dummy station 551:
Event Owner: UDP 8 (all stations) Event type: 13 - Faulty Station Line Subevent: 0 When change to: ON
Action commands:
$SM L%1.dir L5151 U100 NM18 GV U0
Event 2:
Send the SMS message "Station error: xxx" to telephone number 12345678, and start a 10 second timer to check for more error messages:
Event Owner: The Dummy Station (e.g. 551) Event type: 23 - New Current Mail in station queue Subevent: 0 When change to: ON When related to: All
Action commands:
EDO 1 "voip\r\n" Log in with username "voip". This is the same username as for the Web interface. EDO 1 "1234\r\n" Log in with password "1234". This is the same password as for the Web interface. EDO 1 "module1\r\n" Start software "module 1" in the GSM modem. pause A 400 ms delay is required before the next action. pause pause pause EDO 1 "at+cmgf=1\r\n" AT-command which sets the GSM modem to Text Mode pause A 400 ms delay is required before the next action. pause pause pause EDO 1 "at+cmgs=\"12345678\"\r\n" AT-command to set the GSM number of the receiver pause A 400 ms delay is required before the next action. pause pause pause EDO 1 "Station error: %2.dir\x1A\r\n" The text to transmit, terminated by <Ctrl+Z> (hex 1A) EDO 1 "logout\r\n" Log out from Telnet $ST L%1.dir W100 L%2.dir Start a 10 sec timer
The telephone number and the SMS text must be adapted to the actual requirement.
Event 3:
When the timer started in the above event expires, the current call request is deleted. This will result in a new current mail event being triggered if there are still calls in queue:
Action commands:
$CANM L%2.dir L%1.dir Cancel the call request
Trigger SMS message from DAK key or from Remote Control Input RCI
A SMS message can be triggered by dialing a code (event trigger) on a keypad or by pressing a DAK key, or from a Remote Control Input (RCI). This can be used for instance as a Silent Alarm function.
By dialing an Event Trigger
In the following example, when dialing event trigger code 9534, the SMS message "Alarm from front desk" is transmitted to telephone number 12345678.
In AlphaPro, Exchange & System -> Events, press Insert to add new event with the following properties:
Action commands:
EDO 1 "voip\r\n" Log in with username "voip". This is the same username as for the Web interface. EDO 1 "1234\r\n" Log in with password "1234". This is the same password as for the Web interface. EDO 1 "module1\r\n" Start software "module 1" in the GSM modem. pause A 400 ms delay is required before the next action. pause pause pause EDO 1 "at+cmgf=1\r\n" AT-command which sets the GSM modem to Text Mode pause A 400 ms delay is required before the next action. pause pause pause EDO 1 "at+cmgs=\"12345678\"\r\n" AT-command to set the GSM number of the receiver pause A 400 ms delay is required before the next action. pause pause pause EDO 1 "Alarm from front desk\x1A\r\n" The text to transmit, terminated by <Ctrl+Z> (hex 1A) EDO 1 "logout\r\n" Log out from Telnet
The telephone number and the SMS text must be adapted to the actual requirement.
From Remote Control Input
In the following example, when RCI 2 is triggered, the SMS message "Temperature ALARM" is transmitted to telephone number 12345678.
RCI configuration:
ON Action:
$ER U15 U0 U1 U1 L101 U3 L9000
|
Explanation: Triggers the event type 15, subevent 0, When Change To = ON, Owner = station 101, Related To = directory number 9000
Event handler configuration:
In AlphaPro, Exchange & System -> Events, press Insert to add new event with the following properties:
Action commands:
EDO 1 "voip\r\n" Log in with username "voip". This is the same username as for the Web interface. EDO 1 "1234\r\n" Log in with password "1234". This is the same password as for the Web interface. EDO 1 "module1\r\n" Start software "module 1" in the GSM modem. pause A 400 ms delay is required before the next action. pause pause pause EDO 1 "at+cmgf=1\r\n" AT-command which sets the GSM modem to Text Mode pause A 400 ms delay is required before the next action. pause pause pause EDO 1 "at+cmgs=\"12345678\"\r\n" AT-command to set the GSM number of the receiver pause A 400 ms delay is required before the next action. pause pause pause EDO 1 "Temperature ALARM\x1A\r\n" The text to transmit, terminated by <Ctrl+Z> (hex 1A) EDO 1 "logout\r\n" Log out from Telnet
The telephone number and the SMS text must be adapted to the actual requirement.