Base library for cellular modem implementations

Dependencies:   Socket lwip-sys lwip

Dependents:   CellularUSBModem CellularUSBModem

Embed: (wiki syntax)

« Back to documentation index

ISMSInterface Class Reference

ISMSInterface Class Reference

Component to use the Short Messages Service (SMS) More...

#include <SMSInterface.h>

Inherited by CDMASMSInterface, and GSMSMSInterface.

Public Member Functions

virtual int init ()=0
 Initialize interface Configure SMS commands & register for SMS-related unsolicited result codes.
virtual int send (const char *number, const char *message)=0
 Send a SM.
virtual int get (char *number, char *message, size_t maxLength)=0
 Receive a SM.
virtual int getCount (size_t *pCount)=0
 Get the number of SMs in the incoming box.

Detailed Description

Component to use the Short Messages Service (SMS)

Definition at line 34 of file SMSInterface.h.


Member Function Documentation

virtual int get ( char *  number,
char *  message,
size_t  maxLength 
) [pure virtual]

Receive a SM.

Parameters:
numberPointer to a buffer to store the sender's phone number (must be at least 17 characters-long, including the space for the null-terminating char)
messagePointer to a buffer to store the the incoming message
maxLengthMaximum message length that can be stored in buffer (including null-terminating character)
Returns:
0 on success, error code on failure

Implemented in CDMASMSInterface, and GSMSMSInterface.

virtual int getCount ( size_t *  pCount ) [pure virtual]

Get the number of SMs in the incoming box.

Parameters:
pCountpointer to store the number of unprocessed SMs on
Returns:
0 on success, error code on failure

Implemented in CDMASMSInterface, and GSMSMSInterface.

virtual int init (  ) [pure virtual]

Initialize interface Configure SMS commands & register for SMS-related unsolicited result codes.

Implemented in CDMASMSInterface, and GSMSMSInterface.

virtual int send ( const char *  number,
const char *  message 
) [pure virtual]

Send a SM.

Parameters:
numberThe receiver's phone number
messageThe message to send
Returns:
0 on success, error code on failure

Implemented in CDMASMSInterface, and GSMSMSInterface.