|
LinuxSDK
V1.4.0.5
|
SWI CDMA specific SMS related APIs. More...
Go to the source code of this file.
Data Structures | |
| struct | SWI_STRUCT_CDMA_SMS_Status |
| struct | SWI_STRUCT_SMS_CdmaHeader |
| struct | SWI_STRUCT_CDMA_SMS_RetrieveSms |
| struct | SWI_STRUCT_CDMA_SMS_SendStatus |
| struct | SWI_STRUCT_CDMA_SMS_StoreSms |
| struct | CDMA_SMS_HEADER |
| struct | CNS_SMS_HEADER |
Macros | |
| #define | CNS_MAX_PACKET_SIZE 256 |
| #define | CNS_PACKET_HEADER_SIZE 10 |
| #define | CNS_MAX_PAYLOAD_SIZE (CNS_MAX_PACKET_SIZE - CNS_PACKET_HEADER_SIZE) |
| #define | CNS_SMS_HEADER_SIZE 6 |
| #define | CNS_SMS_MAX_SIZE (CNS_MAX_PAYLOAD_SIZE - CNS_SMS_HEADER_SIZE) |
| #define | MAX_SMSI_CALL_BACK 32 |
| #define | MAX_SMSI_TL_ADDRESS 50 |
Functions | |
| SWI_API SWI_RCODE | SwiPriGetSMSMask (swi_uint16 *smsMask, swi_uint32 timeout) |
| SWI_API SWI_RCODE | SwiPriGetMaxMosmsLen (swi_uint16 *puMaxLen, swi_uint32 timeout) |
| SWI_API SWI_RCODE | SwiSendCdmaSMS (swi_uint32 timeout) |
| SWI_API SWI_RCODE | SwiGetCdmaSMSMessageStatus (SWI_STRUCT_CDMA_SMS_Status *pSMS_Status, swi_uint32 timeout) |
| SWI_API SWI_RCODE | SwiRetrieveCdmaSMSMessage (SWI_STRUCT_CDMA_SMS_RetrieveSms *pSMS, swi_uint32 timeout) |
| SWI_API SWI_RCODE | SwiRetrieveSMSMessageEx (SWI_STRUCT_CDMA_SMS_RetrieveSms *pSms, swi_bool bDeleteAfterRetrieve, swi_uint32 timeout) |
| SWI_API SWI_RCODE | SwiSetMessageRetrieved (swi_uint16 msgID, swi_uint32 timeout) |
| SWI_API SWI_RCODE | SwiStoreCdmaSMSMessage (SWI_STRUCT_CDMA_SMS_StoreSms *pStoreSMS, swi_uint32 timeout) |
SWI CDMA specific SMS related APIs.
Copyright (c) 2011 Sierra Wireless, Inc. All rights reserved
| #define CNS_MAX_PACKET_SIZE 256 |
Maximum CnS packet size
| #define CNS_MAX_PAYLOAD_SIZE (CNS_MAX_PACKET_SIZE - CNS_PACKET_HEADER_SIZE) |
Maximum CnS packet payload size
| #define CNS_PACKET_HEADER_SIZE 10 |
Maximum CnS packet header size
| #define CNS_SMS_HEADER_SIZE 6 |
Maximum SMS header size
| #define CNS_SMS_MAX_SIZE (CNS_MAX_PAYLOAD_SIZE - CNS_SMS_HEADER_SIZE) |
Maximum SMS size
| #define MAX_SMSI_CALL_BACK 32 |
Maximum SMS callback length
| #define MAX_SMSI_TL_ADDRESS 50 |
Maximum SMS address length
| typedef struct CDMA_SMS_HEADER CDMA_SMS_HEADER |
Contains SMS header structure.
Note: While this appears redundant to SWI_STRUCT_SMS_CdmaHeader, they serve two different purposes. The below header is used to cast the payload, hence the strict definition of the member data types. SWI_STRUCT_SMS_CdmaHeader uses enum's in its members, to enforce proper setting by the developer for SDK/API use.
| typedef struct CNS_SMS_HEADER CNS_SMS_HEADER |
Contains general SMS header data.
| typedef enum SMSAPIUsage SMSAPIUsage |
An enumeration of SMS API type.
This enum will be used to indicate if the legacy SMS APIs [ SwiRetrieveSmsMessage ] are used instead of the new [ SwiRetrieveSmsMessageEx and SwiSetMessageRetrieved ] APIs. The two sets above are mutually exclusive. And the mode will be switched to whoever uses the APIs first. So, if the first call happens to a new API, the mode will be switched to that and shall remain so throughout the life of the program.
| typedef enum SWI_SMS_PACKET_TYPE SWI_SMS_PACKET_TYPE |
An enumeration of SMS packet type.
| typedef struct SWI_STRUCT_CDMA_SMS_RetrieveSms SWI_STRUCT_CDMA_SMS_RetrieveSms |
Contains CDMA SMS header.
This structure is used to provide input to, and receive output from the SwiRetrieveSMSMessage function.
| typedef struct SWI_STRUCT_CDMA_SMS_SendStatus SWI_STRUCT_CDMA_SMS_SendStatus |
Contains SMS Send Status notification data structure.
This data structure is used as a member of the notification SWI_NOTIFY_SmsSendStatus. Refer to the description of SWI_NOTIFY_SmsSendStatus for more detail.
| typedef struct SWI_STRUCT_CDMA_SMS_Status SWI_STRUCT_CDMA_SMS_Status |
Contains status of SMS messages on the modem.
This structure reports the number of SMS messages in each of the three buffers in the modem: urgent, regular, and voice.
| typedef struct SWI_STRUCT_CDMA_SMS_StoreSms SWI_STRUCT_CDMA_SMS_StoreSms |
Contains data used to store SMS.
This structure is used to provide input to the SwiStoreCdmaSMSMessage function.
| typedef struct SWI_STRUCT_SMS_CdmaHeader SWI_STRUCT_SMS_CdmaHeader |
Contains CDMA SMS header.
A portion of SWI_STRUCT_CDMA_SMS_RetrieveSms, this structure defines the header of incoming SMS messages. Most of the data items are defined in the CDMA specification and are not explained here. The enumerated types are described following this structure.
| typedef enum SWI_TYPE_PRI_SmsMask SWI_TYPE_PRI_SmsMask |
An enumeration of SMS support mask bit.
The enumerated mask bits identifies the SMS features supported by the modem.
| typedef enum SWI_TYPE_SMS_CauseCode SWI_TYPE_SMS_CauseCode |
An enumeration of SMS send cause code.
This enumeration identifies the possible Cause Code values that may be returned with the notification SWI_NOTIFY_SmsSendStatus
For detailed explanation of each of the codes, please refer to the IS-41 SMS Standard.
| typedef enum SWI_TYPE_SMS_DataEncodeType SWI_TYPE_SMS_DataEncodeType |
An enumeration of possible data encoding methods used on the SMS message body.
For a more complete list, see SMS standard TSB-58C.
| typedef enum SWI_TYPE_SMS_ErrorClass SWI_TYPE_SMS_ErrorClass |
An enumeration of SMS send error class
This enumeration identifies the possible Error Class values that may be returned with the notification SWI_NOTIFY_SmsSendStatus
| typedef enum SWI_TYPE_SMS_Language SWI_TYPE_SMS_Language |
An enumeration of SMS message body language.
| typedef enum SWI_TYPE_SMS_MsgCategory SWI_TYPE_SMS_MsgCategory |
An enumeration of SMS category.
| typedef enum SWI_TYPE_SMS_MsgDispMode SWI_TYPE_SMS_MsgDispMode |
An enumeration of SMS display mode.
| typedef enum SWI_TYPE_SMS_MsgIdType SWI_TYPE_SMS_MsgIdType |
An enumeration of SMS ID.
| typedef enum SWI_TYPE_SMS_ParamMask SWI_TYPE_SMS_ParamMask |
An enumeration of SMS parameter mask.
| typedef enum SWI_TYPE_SMS_Priority SWI_TYPE_SMS_Priority |
An enumeration of SMS priority.
| typedef enum SWI_TYPE_SMS_Privacy SWI_TYPE_SMS_Privacy |
An enumeration of SMS privacy.
| typedef enum SWI_TYPE_SMS_Teleservice SWI_TYPE_SMS_Teleservice |
An enumeration of SMS teleservice.
Refer to TIA/EIA-41-D Table 175 for further information.
| enum SMSAPIUsage |
An enumeration of SMS API type.
This enum will be used to indicate if the legacy SMS APIs [ SwiRetrieveSmsMessage ] are used instead of the new [ SwiRetrieveSmsMessageEx and SwiSetMessageRetrieved ] APIs. The two sets above are mutually exclusive. And the mode will be switched to whoever uses the APIs first. So, if the first call happens to a new API, the mode will be switched to that and shall remain so throughout the life of the program.
| Enumerator | |
|---|---|
| SMS_Use_Uninitialized |
Not know yet. |
| SMS_Use_Legacy |
Use legacy SWI SMS API |
| SMS_Use_New |
Use new SWI SMS API |
| enum SWI_SMS_PACKET_TYPE |
| enum SWI_TYPE_PRI_SmsMask |
An enumeration of SMS support mask bit.
The enumerated mask bits identifies the SMS features supported by the modem.
An enumeration of SMS send cause code.
This enumeration identifies the possible Cause Code values that may be returned with the notification SWI_NOTIFY_SmsSendStatus
For detailed explanation of each of the codes, please refer to the IS-41 SMS Standard.
An enumeration of possible data encoding methods used on the SMS message body.
For a more complete list, see SMS standard TSB-58C.
An enumeration of SMS send error class
This enumeration identifies the possible Error Class values that may be returned with the notification SWI_NOTIFY_SmsSendStatus
An enumeration of SMS message body language.
An enumeration of SMS ID.
An enumeration of SMS parameter mask.
| enum SWI_TYPE_SMS_Privacy |
An enumeration of SMS teleservice.
Refer to TIA/EIA-41-D Table 175 for further information.
| SWI_API SWI_RCODE SwiGetCdmaSMSMessageStatus | ( | SWI_STRUCT_CDMA_SMS_Status * | pSMS_Status, |
| swi_uint32 | timeout | ||
| ) |
This function queries the outstanding SMS message status
| pSMS_Status[OUT] | Outstanding SMS message status. |
| timeout[IN] | Function timeout in milliseconds. |
| SWI_API SWI_RCODE SwiPriGetMaxMosmsLen | ( | swi_uint16 * | puMaxLen, |
| swi_uint32 | timeout | ||
| ) |
This function gets maximum outgoing SMS length
| puMaxLen[OUT] | The destination in which the maximum length in bytes is returned. |
| timeout[IN] | Function timeout in milliseconds. |
| SWI_API SWI_RCODE SwiPriGetSMSMask | ( | swi_uint16 * | smsMask, |
| swi_uint32 | timeout | ||
| ) |
This function reports the modem's SMS capabilities.
| smsMask[OUT] | The destination in which the the data is returned. Possible mask bit values are defined in SWI_TYPE_PRI_SmsMask. |
| timeout[IN] | Function timeout in milliseconds. |
| SWI_API SWI_RCODE SwiRetrieveCdmaSMSMessage | ( | SWI_STRUCT_CDMA_SMS_RetrieveSms * | pSms, |
| swi_uint32 | timeout | ||
| ) |
This function retrieves an SMS message
| pSms[OUT] | SMS message struct. |
| timeout[IN] | Function timeout in milliseconds. |
| SWI_API SWI_RCODE SwiRetrieveSMSMessageEx | ( | SWI_STRUCT_CDMA_SMS_RetrieveSms * | pSms, |
| swi_bool | bDeleteAfterRetrieve, | ||
| swi_uint32 | timeout | ||
| ) |
This function retrieves an SMS message along with an option to delete it or not.
| pSms[OUT] | Memory to save SMS message retrieved. |
| bDeleteAfterRetrieve[IN] | Delete the message from modem after retrieval if TRUE; Otherwise leave it in the modem store. |
| timeout[IN] | Function timeout in milliseconds. |
| SWI_API SWI_RCODE SwiSendCdmaSMS | ( | swi_uint32 | timeout | ) |
This function starts sending stored SMS messages.
| timeout[IN] | Function timeout in milliseconds. |
| SWI_API SWI_RCODE SwiSetMessageRetrieved | ( | swi_uint16 | msgID, |
| swi_uint32 | timeout | ||
| ) |
This function sets a message as retrieved so modem can delete it
| msgID[IN] | SMS message ID to be deleted. |
| timeout[IN] | Function timeout in milliseconds. |
| SWI_API SWI_RCODE SwiStoreCdmaSMSMessage | ( | SWI_STRUCT_CDMA_SMS_StoreSms * | psStoreSms, |
| swi_uint32 | timeout | ||
| ) |
This function is used to store an SMS message.
| psStoreSms[OUT] | SMS message to store. |
| timeout[IN] | Function timeout in milliseconds. |