SMS Gateway/Use case
Description of the components
Third Party Application
This behavior will be changed in the future.
In the first version of the SMS Gateway the third party application is the controlling instance that will use the SMS Gateway as webservice. The third party application has to take care about the mobile number range because it has to choose which gateway to use in an multiple SMS Gateway setup.
The communication protocol between the third party application and the SMS Gateway software is a http request that could be secured by using an Apache http deamon as SSL terminator.
The SMS Gateway itself is implemented as pure JAVA web application driven by the Apache Tomcat servlet engine.
At this point of the implementation the SMS Gateway does filter the incoming text messages like with “instring” or something similar. Also the SMS Gateways does not check if the mobile number is “correct” or if this SMS Gateway is the right SMS Gateway for sending the current text message (number circle).
The SMS Gateway communicates with the connected mobile phones through telnet and it takes care about that always one text message is computed at one time. The telnet connection could be made over Ethernet or to direct attached devices (serial port or USB).
The SMS Gateway operates parallel on the text message queue (the database) so it scales up with the connected modem devices.
The SMS Gateway will also delegate the text message queue to another configured SMS Gateway in case of all configured local modems gets unresponsively. In this case the incoming connection will be shut down or as an answer of the request of the third party software the SMS Gateway will send ERROR.
It lies in the scope of the third party software to react and to send the next messages to the remaining SMS Gateway.
List of supported devices:
- Multitech Multimodem Modell: MTCBA-G-EN-F4-EU 3 http://www.multitech.com/en_US/products/families/multimodemgprs/
- Don't forget to disable PPP when using this modem: http://www.multitech.com/en_US/SUPPORT/help/resolutions/res3932.aspx
- Serial (including USB) Modem (will follow) some facts on Linux
Find your modem (e.g. wavecom WM0D2 on serial port)
dmesg | grep tty -> ttyS0 at I/O 0x3f8 (irq = 4) is a NS16550A (ln -sf /dev/ttyS0 /dev/modemgsm1 ... if you want to set a nice name) apt-get install setserial setserial /dev/ttyS0 irq 4 port 0x3f8 uart 16550
apt-get install wvdial wvdialconf output: wvdialconf Editing `/etc/wvdial.conf'. Scanning your serial ports for a modem. ttyS0<*1>: ATQ0 V1 E1 -- ��� ttyS0<*1>: failed with 2400 baud, next try: 9600 baud ttyS0<*1>: ATQ0 V1 E1 -- OK ttyS0<*1>: ATQ0 V1 E1 Z -- OK ttyS0<*1>: ATQ0 V1 E1 S0=0 -- OK ttyS0<*1>: ATQ0 V1 E1 S0=0 &C1 -- OK ttyS0<*1>: ATQ0 V1 E1 S0=0 &C1 &D2 -- OK ttyS0<*1>: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0 -- OK ttyS0<*1>: Modem Identifier: ATI -- WAVECOM MODEM'#' ttyS0<*1>: Speed 19200: AT -- �� ttyS0<*1>: Speed 19200: AT -- x� ttyS0<*1>: Speed 19200: AT -- ttyS0<*1>: Max speed is 9600; that should be safe. ttyS0<*1>: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0 -- OK Modem Port Scan<*1>: S2 S3
Found a modem on /dev/ttyS0. Modem configuration written to /etc/wvdial.conf. ttyS0<Info>: Speed 9600; init "ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0"
test the modem with minocom
minicom -s Serial Port Setup A: /dev/ttyS0 (device from above) E: 9600 (speed from above) save setup as wm0d2 Exit
Output: Port /dev/ttyS0
Press CTRL-A Z for help on special keys
AT S7=45 S0=0 L1 V1 X4 &c1 E1 Q0 OK
exit minicom: Strg+A Z,X restart minicom: minocom wm0d2
=> and be happy!!!