scmxx(1)

NAME
scmxx - exchange data with your Siemens mobile phone

SYNOPSIS
scmxx [--device device] [--baud baudrate] [--quiet] [--verbose] [--reset] {--info | --set-time | --mem-info | --lock-info | --lock lock {--enable | --disable} | --set-smsc --number {number | name} }

scmxx [--device device] [--baud baudrate] [--quiet] [--verbose] [--reset] [--out file] [--pipe pipe] {--remove | --send | --get} [--binary] [--mem memory] [--slot slot] [file...]

scmxx [--device device] [--baud baudrate] [--quiet] [--verbose] [--reset] [--out file] [--pipe pipe] [--pin PIN] {--remove | --send | --get} [--pbook] [--mem memory] [--slot slot] [--text text] [ --number {number | name} ] [file...]

scmxx [--device device] [--baud baudrate] [--quiet] [--verbose] [--reset] [--out file] [--pipe pipe] {--remove | --send | --get} [--sms] [--mem memory] [--slot slot] [--text text] [ --number {number | name} ] [--direct] [--flash] [--srr] [--unicode] [file...]

scmxx [--help] [--version]

DESCRIPTION
SCMxx can copy files to and from a Siemens mobile phone and also delete stored files. Files can read from a given file or through stdin and stored to a given file or stdout. SMS can also be directly sent or received without storing in the mobile phone. SCMxx was tested with several mobile phones manufactured by Siemens (only S25 and later).

OPTIONS

--device (-d)
    specify another than the compiled in device. This overwrites the SCMXX_TTY environment variable and the compiled-in value. For linux systems, this may be e.g. /dev/ttyS0 for serial connections, /dev/ircomm0 for infrared connections and /dev/rfcomm0 for bluetooth connections.

--baud (-b)
    specify the device's speed. Valid values are dependent on the system but may be 9600, 19200, 38400, 57600 or 115200. The default value is 19200. The S25 and *35i only work at the 19200, all later phones also work at full serial speed. Infrared connections may be an exception to these rules (dependent on the infrared donle). This overwrites the SCMXX_BAUD environment variable and the compiled-in value.

--out (-o)
    specify a file to use. When getting binary files with "all", the slot number, a dot and the filetype are appended. When sending or deleting, this parameter has no use but the last parameters that should be valid files. Stdout must be explicitly selected with the dash ("-"), by default nothing is written to stdout. There is nothing appended to "-" when getting multiple files.

--pipe (-p)
    specify a pipe to another program. When getting with "all", every file is piped to this programs on its own (only for --binary and --sms).

--quiet (-q)
    decreases verbosity by 1

--pin
    use this option if a PIN code is required for access

--verbose (-v)
    increases verbosity by 1

--reset
    try to reset the phone, so it gets accessible again. It may happen that the phone does not answer on the serial interface anymore, especially with a previous user-interrupted file transfer. This simply blindly sends some special characters.

--help (-h)
    print the help message

--version
    print the version number

--remove (-r)
    removes an entry from the phone. When specified with --sms and --get, this will get'n'delete. When specified with --sms and --send, this will send'n'delete.

--get (-g)
    get an entry and save it to a file. When specified with --sms and --remove, this will get'n'delete. When specified with --sms and --send, this will get'n'send.

--send (-s)
    sends a file to the phone. When sending sms, you might want to take a look at the option --direct, too. When specified with --sms and --remove, this will send'n'delete. When specified with --sms and --get, this will get'n'send.

--info (-i)
    collect information from the phone, --mem-info can be used as a trigger to display a more complex listing of the available memories

--mem-info
    display information about available memories and their slots and other information. It uses the same format as --mem=? (see below) and can also be use as a trigger for --info to replace the short memory listing.

--lock-info
    display status of locks. It can also be use as a trigger for --info to replace the lock name listing.

--lock
    specify a lock that you can enable or disable. For some locks, a password is needed (see --pin)

--enable
    enable e.g. a lock

--disable
    disable e.g. a lock

--dial
    dial a number (requires --number). The program returns either after 10 seconds or when the call reached the other side.

--hangup
    hangup all currently active calls

--set-time
    synchronize time to phone. The use of tools like ntpdate is recommended before using this.

--set-smsc
    set the SMSC number (requires --number)

--binary (-N)
    select binary file transfer mode

--pbook (-P)
    select phonebook transfer mode

--sms (-S)
    select short message service mode

--mem
    select a memory to access. Slot numbers may vary depending on the selected memory. See the output of --info for the supported memory types. Not using this option triggers the default behaviour (if a default behaviour was defined). There is a special string "?" that outputs in the same format as --mem-info but only for the selected mode.

--slot
    select a slot to access. See the output of --mem-info or --mem=?. Not using this option triggers the default behaviour (if a default behaviour was defined). The special string "all" defines the whole range of available slots for the selected memory and mode and, except with --sms, cannot be used with --send. For SMS, there are four additional special strings: "read", "unread", "sent" and "unsent". The latter two can be used with --send. For phonebook access, there is the additional special string "last". When this option is omitted with --send, scmxx tries to find an empty slot (that may or may not take long). Finding an empty slot is not supported for phonebooks, yet. When a slot was specified and also multiple files to upload, the specified slot is the starting point to search for empty slots. Overwriting multiple, non-empty slots is not supported, yet, except for the special case "all".

--text (-t)
    specify content text of short message or text of the phonebook entry. For phonebook entries, the length limit may depend on the selected phonebook (see output of --mem-info or --mem=?).

--number (-n)
    specify number to send the short message to or the number for the phonebook entry. Note that the number may have a leading '+' for international numbers. It is normally limited to 20 digits (without the '+') which is certainly enough.

--direct
    send/get short messages without storing in the phone. This is not default because you will certainly be charged for it when sending. With direct getting, SMS that are not of type DELIVER are still stored on the phone (scmxx cannot decode those messages, yet).

--unicode
    send the short message and use UCS-2 (16bit unicode) as character set. You do not need to specify this parameter to enable unicode sms decoding.

--flash
    set the class0 in the data coding scheme field that is normally interpreted as "immediate display". Not all receiving entities support this. Note that a second sms of this type normally overwrites a previous one without asking! Its use is not recommended.

--srr
    this sets the StatusReportRequest bit in the pdutype field of the sms pdu. It depends on the SMSC if this is honored. With some providers, this produces additional costs!

--sort
    sort the messages on printing to chosen output. Possible sorting methods are "type", "slot" and "type,slot". "type" sorts for the type of the short message with an internal order of unsupported types first, then SMS-SUBMIT, SMS-STATUS-REPORT and SMS-DELIVER. "slot" sorts for the slot of the short message. "type,slot" does sorting like "type" first and sorts each type like "slot". Default is to not sort at all (order depends on phone).

--pin
    enable pin usage. Use this only if there was an error message that asks for a PIN or PUK. For a PIN, this is the corresponding "<PIN>", for a PUK, it is "<PUK>,<new PIN>". The value is only used once. Consider using the pin file (see below) instead of this option.

--system-charset
    define the system character set instead of using the return value from nl_langinfo(CODESET). This is to work around systems that do not support unicode locales like UTF-8 or when data from a different system with a different locale is used as input. Usually, you do not need this option.

EXAMPLES

Send an bitmap file to the phone as bitmap (logo):
    scmxx --send --binary --mem="bmp" --slot=0 myfile.bmp

Get a Bitmap from the phone and save it into a new file:
    scmxx --get --binary --mem="bmp" --slot=0 --out=myfile.bmp

Get all unread (default on get) short messages and output to stdout:
    scmxx --get --sms --slot=unread --out=- scmxx -gS -o-

Send a short message directly (not stored in the phone):
    scmxx --send --sms --direct --number=123 --text="test"

Get a phonebook and store it to a file:
    scmxx --get --pbook --mem=SM --out=SM.pb

Modify a specific slot (33) in phonebook memory SM:
    scmxx -sP --mem=SM --slot=33 --number=123 --text="test"

NOTES
The output of text (phonebook and sms) depends on the character set of your current locale. Input is the same. This has the advantage of localization but may have the drawback that all other characters must be entered by a sequence \XXXX where X is a hex character (e.g. \20ac for EuroSign). This is a 16bit representative of the unicode value. The \XXXX is only used for output with the intention to read it again at a later time. For normal output, characters that cannot be displayed in the current local are replaced by a '?'. Using an UTF-8 based locale will make sure that all character can be converted. The newline character can be entered using the common \n and '\' must be masked with itself. In bash, this might even result in a needed input like "\\\\".

CONNECTION PROBLEMS
There are additional parameters --ignore-serial-bits (default) and --keep-serial-bits. Use it only when you get no response from the phone at all. Which setting is needed depends on the cable and serial port and cannot be determined automatically.

If you experience timeouts on the first command, try the --start-delay=<seconds> parameter.

Another parameter --device-timeout=<seconds> is provided for the case that your phone ever needs more than default value of 10 seconds to answer. Actually, this should be more than enough but one never knows. The minimum value is 1, values higher than 25 mean "forever".

SECURITY
The --pin option should be used with care. The option and its argument are visible in the process list.

ENVIRONMENT

SCMXX_TTY
    see --device for decription

SCMXX_BAUD
    see --baud for description

FILES

~/.scmxx/cache.pb
    this file serves as lookup file during short message output (for recipient/sender address) and for number aliasing for --number on sending a short message. The format is the same as a phonebook file (slot numbers don't matter but must be present).

~/.scmxx/config
    this file can contain long options (without the --), the arguments is seperated from the option name by an '='. Any amount of spaces at beginning of line, before and after the seperator are allowed. A '#' at beginning of line marks this line as comment. Examples:
              #choose a device to access
              device  =  /dev/ttyS0
              #always send SMS using UCS-2
              unicode

~/.scmxx/pin
    This file is used as an alternativ to the --pin command line option. The file MUST NOT be group readable/writeable or world readable/writeable! It also MUST be a regular file, not a symlink. SCMxx refuses to use the file if this is not the case. If a PUK value is requested by the phone, the corresponding PIN must also be defined. The only necessary format elements are '{', '=', ';' and '}'. Spaces and newlines are ignored. The file has the following format:
              sim 262031234567890 {
                pin = 1234
                puk = 12345678;
                pin2 = 4321;
                puk2 = 87654321;
              }
              device 350123456789012 {
                type SIM {
                  pin = 0000;
                  puk = 0000;
                }
              }

    "sim" sections use the IMSI as identifier, "device" sections use the IMEI as identifier (see output of --info). Since the IMSI is needed, you canNOT switch the phone on with this! The "type" sub section in the device section has the following idenfifiers:

    SIM device code (theft protection)

    FSIM
        very first inserted SIM

    NET network personalization

    NETSUB
        network subset personalization

    SP  service provider personalization

    CORP
        corporate personalization

AUTHOR
Hendrik Sattler post@hendrik-sattler.de