7 Teleservice Application Framework
User Manual 232/374
7.3.8 SMS
Header file: "SMS_handler.h"
7.3.8.1 Introduction
The SMS functionality from the TAF library uses the ysms daemon to send and receive SMS messages
SMS can be sent or received either after standard time intervals or immediately. The standard time interval and
other parameters can be configured in the ysmsd configuration file (see SMS daemon (see "SMS daemon" on
page 97)).
For receiving SMS messages automatically in your application, use the TAF library function
dbus_initialize_request_callbacks (see "dbus_initialize_request_callbacks" on page 144).
7.3.8.2 ysmsd_send_sms
Function Description
sint32 ysmsd_send_sms (const T_DBUS_Util *const opt_DBusInstance, const charn * const
opcn_PhoneNumber , const charn *const opcn_Message)
The function sends a SMS to a subscriber with the number opcn_PhoneNumber. The SMS is sent after the
standard time interval that is set in the configuration file of the SMS daemon. The maximum message size is
160 characters
Information Flow
Input Information
holds all D-Bus information
maximal
MAX_SMS_NUMBER_LENGTH
pointer to the phone number buffer
Structure T_DBUS_Util
typedef struct
{
DBusConnection* pt_dbus_conn; // D-BUS connection instance
charn acn_myNameString[128]; // Name of the application, Don't use any
special
// characters, white spaces or new lines!
charn acn_myVersion[128]; // Additional value (for HELLO) signal (opt.)
charn acn_myStatus[128]; // Additional value (for HELLO) signal (opt.)
charn acn_myAddInfo[512]; // Additional value (for HELLO) signal (opt.)
sint32 s32_myTriginterval; // Time interval when the ysysd
// expects to be triggered
charn acn_myCMDOnWatchdog[2048]; // Bash cmd that must be executed
// by the ysysd in case no
// trigger signal occurred in time.
} T_DBUS_Util;