NAME
putsms - sends SMS using a GSM compatible modem
DESCRIPTION
putsms sends an SMS through a GSM 07.05 compatible modem. Usage:
-
putsms [options] destination "message"
OPTIONS
- -ax
-
set alarm handler to x (default none)
- -Ax
-
set alarm level to x (default 4)
- -bx
-
set baudrate to x (default 19200)
- -c
-
use character set conversion
- -dx
-
set modem device to x (default /dev/ttyS0)
- -ex
-
wait x seconds before retry (default 10)
- -fx
-
message file x (ascii)
- -Fx
-
message file x (binary, only in pdu mode old or new)
- -h
-
this help
- -H
-
disable hardware handshake RTS/CTS
- -ix
-
modem init string x
- -I
-
send as a flash SMS (class 0)
- -lx
-
use logfile x (filename or handle) (default syslog)
- -Lx
-
use loglevel x (default 9)
- -mx
-
set the PDU mode to x (default new) x can be old, new, ascii or digicom
- -nx
-
set modem name to x
- -px
-
set pin to x (default . Only needed if modem not initialized)
- -q
-
quick initialisation
- -r
-
request status report SMS (not in ascii mode)
- -Rx
-
report message ID in file x
- -sx
-
set SMSC Number to x
- -u
-
no user data header (UDH bit). Only used with -F.
- -V
-
print version info and copyright
All options may be omitted.
If you've specified a message file you may omitt the message argument. If the message file has a To: header you may omitt the destination argument.
The destination number and SMSC have to be the format like below. Example:
-
putsms -d/dev/ttyS0 491721234567 "Hello"
Return codes:
- 0
-
success
- 1
-
cannot open device or file
- 2
-
cannot verify PIN or modem not ready
- 3
-
modem not registered to the network or did not accept PDU mode.
- 4
-
SMS could not be sent
- 5
-
error in arguments
Format of the message file: To: xxxxxxxx<NL>other headers<NL><NL>message putsms ignores the other headers. The message begins after an empty line. You may specify a message file that contains only the message without header beginning at the first line.
Usage:
-
putsms [options] destination "message"
- -ax
-
set alarm handler to x (default none)
- -Ax
-
set alarm level to x (default 4)
- -bx
-
set baudrate to x (default 19200)
- -c
-
use character set conversion
- -dx
-
set modem device to x (default /dev/ttyS0)
- -ex
-
wait x seconds before retry (default 10)
- -fx
-
message file x (ascii)
- -Fx
-
message file x (binary, only in pdu mode old or new)
- -h
-
this help
- -H
-
disable hardware handshake RTS/CTS
- -ix
-
modem init string x
- -I
-
send as a flash SMS (class 0)
- -lx
-
use logfile x (filename or handle) (default syslog)
- -Lx
-
use loglevel x (default 9)
- -mx
-
set the PDU mode to x (default new) x can be old, new, ascii or digicom
- -nx
-
set modem name to x
- -px
-
set pin to x (default . Only needed if modem not initialized)
- -q
-
quick initialisation
- -r
-
request status report SMS (not in ascii mode)
- -Rx
-
report message ID in file x
- -sx
-
set SMSC Number to x
- -u
-
no user data header (UDH bit). Only used with -F.
- -V
-
print version info and copyright
All options may be omitted.
If you've specified a message file you may omitt the message argument. If the message file has a To: header you may omitt the destination argument.
The destination number and SMSC have to be the format like below. Example:
-
putsms -d/dev/ttyS0 491721234567 "Hello"
Return codes:
- 0
-
success
- 1
-
cannot open device or file
- 2
-
cannot verify PIN or modem not ready
- 3
-
modem not registered to the network or did not accept PDU mode.
- 4
-
SMS could not be sent
- 5
-
error in arguments
Format of the message file: To: xxxxxxxx<NL>other headers<NL><NL>message putsms ignores the other headers. The message begins after an empty line. You may specify a message file that contains only the message without header beginning at the first line.