LinuxSDK  V1.4.0.5
Data Structures | Macros | Typedefs | Enumerations | Functions
SwiApiCdmaBasic.h File Reference

SWI CDMA specific basic APIs. More...

#include "SwiDataTypes.h"
#include "SwiRcodes.h"

Go to the source code of this file.

Data Structures

struct  SWI_STRUCT_Tech_Hdr_Mac_Index
 
struct  SWI_STRUCT_E911Mode
 
struct  SWI_STRUCT_PowerSaveEnter
 
struct  SWI_STRUCT_PowerSaveExit
 
struct  SWI_STRUCT_HdrNotificationStatus
 
struct  SWI_STRUCT_Idle_Digital_Mode
 
struct  SWI_STRUCT_Hdr_PowerSave_Enter
 
struct  SWI_STRUCT_Hdr_PowerSave_Exit
 
struct  SWI_STRUCT_MeidEsn
 
struct  SWI_STRUCT_LED_CFG_ENABLE
 
struct  SWI_STRUCT_EFileInfo
 
struct  CNS_HDRSCP_subtype_custom_config_type
 

Macros

#define G_SZ_FNERINAM1   "eri_nam1"
 
#define CNS_MAX_DATA_BLOCK_SIZE   120
 
#define LENGTH_NvNameNam   12
 
#define LENGTH_PhoneNumberMin   10
 
#define LENGTH_NVItemPayloadMax   240
 
#define LENGTH_Mdn   15
 
#define LENGTH_Min   10
 
#define LENGTH_PinPassword   4
 
#define LENGTH_SecureChallenge   8
 
#define LENGTH_SecureRebuttal   4
 
#define LENGTH_ProvisioningDate   8
 
#define LENGTH_CallNumber   32
 
#define LENGTH_CallExtendedNumber   64
 
#define SCP_PROT_SUBTYPE_MASK   0x000000F9
 
#define SCP_BCMCS_SUBTYPE_MASK   0
 
#define SCP_APP_SUBTYPE_MASK   1
 
#define SWI_MAX_LEDS   10
 

Typedefs

typedef enum
SWI_TYPE_Commit_ErrorMask 
SWI_TYPE_Commit_ErrorMask
 
typedef struct
SWI_STRUCT_Tech_Hdr_Mac_Index 
SWI_STRUCT_Tech_Hdr_Mac_Index
 
typedef enum SWI_TYPE_E911Mode SWI_TYPE_E911Mode
 
typedef struct SWI_STRUCT_E911Mode SWI_STRUCT_E911Mode
 
typedef struct
SWI_STRUCT_PowerSaveEnter 
SWI_STRUCT_PowerSaveEnter
 
typedef struct
SWI_STRUCT_PowerSaveExit 
SWI_STRUCT_PowerSaveExit
 
typedef enum
SWI_TYPE_PRI_VoiceDataMask 
SWI_TYPE_PRI_VoiceDataMask
 
typedef enum SWI_TYPE_CarrierID SWI_TYPE_CarrierID
 
typedef enum SWI_TYPE_DistributorID SWI_TYPE_DistributorID
 
typedef struct
SWI_STRUCT_HdrNotificationStatus 
SWI_STRUCT_HdrNotificationStatus
 
typedef enum SWI_TYPE_Digital_Mode SWI_TYPE_Digital_Mode
 
typedef struct
SWI_STRUCT_Idle_Digital_Mode 
SWI_STRUCT_Idle_Digital_Mode
 
typedef struct
SWI_STRUCT_Hdr_PowerSave_Enter 
SWI_STRUCT_Hdr_PowerSave_Enter
 
typedef struct
SWI_STRUCT_Hdr_PowerSave_Exit 
SWI_STRUCT_Hdr_PowerSave_Exit
 
typedef enum
SWI_TYPE_Device_CDMA_Settings 
SWI_TYPE_Device_CDMA_Settings
 
typedef struct SWI_STRUCT_MeidEsn SWI_STRUCT_MeidEsn
 
typedef enum
SWI_TYPE_General_Features 
SWI_TYPE_General_Features
 
typedef enum SWI_TYPE_LED_TYPE SWI_TYPE_LED_TYPE
 
typedef enum
SWI_TYPE_LED_ENABLE_STATE 
SWI_TYPE_LED_ENABLE_STATE
 
typedef struct
SWI_STRUCT_LED_CFG_ENABLE 
SWI_STRUCT_LED_CFG_ENABLE
 
typedef struct SWI_STRUCT_EFileInfo SWI_STRUCT_EFileInfo
 
typedef struct
CNS_HDRSCP_subtype_custom_config_type 
CNS_HDRSCP_subtype_custom_config_type
 

Enumerations

enum  SWI_TYPE_Commit_ErrorMask {
  SWI_COMMIT_ERRMASK_NONE = 0x00000000, SWI_COMMIT_ERRMASK_MDN = 0x00000001, SWI_COMMIT_ERRMASK_IMSI = 0x00000002, SWI_COMMIT_ERRMASK_USERIDPW = 0x00000004,
  SWI_COMMIT_ERRMASK_DATE = 0x00000008, SWI_COMMIT_ERRMASK_NAMORDER = 0x00000010
}
 
enum  SWI_TYPE_E911Mode { SWI_E911_MODE_Off, SWI_E911_MODE_On }
 
enum  SWI_TYPE_PRI_VoiceDataMask {
  SWI_PRI_DATA_1X = 0x0001, SWI_PRI_DATA_IS95 = 0x0002, SWI_PRI_DATA_AUTOCONNECT = 0x0004, SWI_PRI_VOICE = 0x0080,
  SWI_PRI_VD_ALL = 0xFFFF, SWI_PRI_VD_MASK_ENABLED = 0x8000
}
 
enum  SWI_TYPE_CarrierID {
  SWI_CARRIER_UNDEFINED = -1, SWI_CARRIER_RESERVED = 0, SWI_CARRIER_AC555_GENERIC, SWI_CARRIER_AC550_SPRINT,
  SWI_CARRIER_AC555_BELL, SWI_CARRIER_AC555_TELUS, SWI_CARRIER_AC555_VZW, SWI_CARRIER_AC555_WESTERNWIRELESS,
  SWI_CARRIER_AC555_SMARTCOM, SWI_CARRIER_AC555_ALLTEL, SWI_CARRIER_AC555_USCELLULAR, SWI_CARRIER_SB550T_SPRINT,
  SWI_CARRIER_SB555T_BELL, SWI_CARRIER_SB555T_TELUS, SWI_CARRIER_SB555T_VZW, SWI_CARRIER_AC555_CHINAUNICOM,
  SWI_CARRIER_AC555_HUTCHISONTHAILAND, SWI_CARRIER_AC555_MOVILNET, SWI_CARRIER_AC555_TARJETAS_IUSACELL_MEXICO, SWI_CARRIER_AC555_TELECOMNEWZEALAND,
  SWI_CARRIER_AC555_RELIANCE, SWI_CARRIER_AC555_TELSTRA, SWI_CARRIER_AC555_MOBILITYCANADA, SWI_CARRIER_AC555_VZW_PUERTO_RICO,
  SWI_CARRIER_AC555_PELEPHONE, SWI_CARRIER_AC555_BELL_CANADA, SWI_CARRIER_AC555_INDOSOL_INDONESIA, SWI_CARRIER_AC555_MIDWEST_WIRELESS,
  SWI_CARRIER_AC555_BELL_SOUTH_CHILE, SWI_CARRIER_AC555_BELL_SOUTH_PANAMA, SWI_CARRIER_AC555_TATA
}
 
enum  SWI_TYPE_DistributorID {
  SWI_DISTRIBUTOR_UNDEFINED = -1, SWI_DISTRIBUTOR_NONE = 0, SWI_DISTRIBUTOR_SIERRA_WIRELESS = 1, SWI_DISTRIBUTOR_EASTCOM = 2,
  SWI_DISTRIBUTOR_TONGFANG = 3, SWI_DISTRIBUTOR_ZTE = 4, SWI_DISTRIBUTOR_CHINA_PUTIAN = 5, SWI_DISTRIBUTOR_NCL = 6,
  SWI_DISTRIBUTOR_SHANGHAI_BELL = 7
}
 
enum  SWI_TYPE_Digital_Mode {
  SWI_HDR_MODE_NO_SERVICE = 0x00000000, SWI_HDR_MODE_AMPS = 0x00000001, SWI_HDR_MODE_CDMA = 0x00000002, SWI_HDR_MODE_GSM = 0x00000003,
  SWI_HDR_MODE_HDR = 0x00000004, SWI_HDR_MODE_WCDMA = 0x00000005, SWI_HDR_MODE_GPS = 0x00000006
}
 
enum  SWI_TYPE_Device_CDMA_Settings { SWI_REV_UNKNOWN = 0x00ff, SWI_REV_0 = 0x0000, SWI_REV_A = 0x0001 }
 
enum  SWI_TYPE_General_Features {
  SWI_GEN_FEATURE_IOTA_2_4 = 0x00000001, SWI_GEN_FEATURE_ENH_GPS = 0x00000002, SWI_GEN_FEATURE_ENH_LED = 0x00000004, SWI_GEN_FEATURE_RESERVED3 = 0x00000008,
  SWI_GEN_FEATURE_RESERVED4 = 0x00000010, SWI_GEN_FEATURE_RESERVED5 = 0x00000020, SWI_GEN_FEATURE_RESERVED6 = 0x00000040, SWI_GEN_FEATURE_RESERVED7 = 0x00000080,
  SWI_GEN_FEATURE_RESERVED8 = 0x00000100, SWI_GEN_FEATURE_RESERVED9 = 0x00000200
}
 
enum  SWI_TYPE_LED_TYPE {
  SWI_LED_TYPE_UNDEFINED = 0x00, SWI_LED_TYPE_POWER_AMBER = 0x01, SWI_LED_TYPE_SIGNAL_AMBER = 0x02, SWI_LED_TYPE_POWER_BLUE = 0x03,
  SWI_LED_TYPE_SIGNAL_BLUE = 0x04, SWI_LED_TYPE_GLOWTOP = 0x05, SWI_LED_TYPE_RESVD1 = 0x06, SWI_LED_TYPE_RESVD2 = 0x07,
  SWI_LED_TYPE_RESVD3 = 0x08, SWI_LED_TYPE_RESVD4 = 0x09
}
 
enum  SWI_TYPE_LED_ENABLE_STATE { SWI_LED_DISABLED = 0, SWI_LED_ENABLED = 1 }
 

Functions

SWI_API SWI_RCODE SwiSetEFile (const swi_charp pszEFilename, swi_uint8 *pBuffer, swi_uint16 nBufLen, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetEFileInfo (const swi_charp pszEFilename, SWI_STRUCT_EFileInfo *psEFileInfo, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetEFileBlock (const swi_charp pszEFilename, swi_uint16 nSeq, swi_uint8 *pBuffer, swi_uint16 nBufLen, swi_uint32 *pnBlockSize, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiSetPRLSize (swi_uint16 Nam, swi_uint32 nSize, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiIsModemReady (swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetESN (swi_int32 *lEsn, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetMEIDESN (SWI_STRUCT_MeidEsn *pMeidEsn, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetPRLVersion (swi_uint16 *pPrlVersion, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetTemperature (swi_int32 *iTemperature, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetActivationStatus (swi_uint16 *pActivationStatus, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetPhoneNumber (swi_charp PhoneNumber, swi_uint32 BufferSize, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPriGetVoiceDataMask (swi_uint16 *voiceDataMask, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetCarrierID (swi_int16 *pnCarrierID, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetDistributorID (swi_int16 *pnDistributorID, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetSystemTime (swi_uint16 *year, swi_uint16 *month, swi_uint16 *day, swi_uint16 *weekDay, swi_uint16 *hour, swi_uint16 *minute, swi_uint16 *second, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetE911Mode (swi_uint16 *e911Mode, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiSetE911Mode (swi_uint16 e911Mode, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetECIO (swi_uint16 *pEcio, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetNamInfo (swi_uint16 *cntNamProfile, swi_uint16 *nextNamProfile, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstGetCurrentNam (swi_uint16 *CurrentNam, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetNamValidStatus (swi_uint16 *pNamValidStatus, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstSetCurrentNam (swi_uint16 CurrentNam, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetProvisioningDate (swi_uint16 namIndex, swi_charp pszProvisioningData, swi_uint32 length, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetCdmaIMSI (swi_uint16 namIndex, swi_charp pszMIN, swi_uint32 length, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstUnlock (swi_uint32 SubsidyLock, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiSetIMSI (swi_uint16 namIndex, const swi_charp pszMIN, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstLock (swi_uint16 Type, swi_uint16 Nam, swi_uint16 *commitResult, swi_uint16 *failureMask, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiResetModem ()
 
SWI_API SWI_RCODE SwiSetModemOffline ()
 
SWI_API SWI_RCODE SwiGetLockStatus (swi_uint16 *pLockStatus, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetAutoLock (swi_uint16 *autoLock, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiSetAutoLock (swi_uint16 autoLock, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiLockModem (const swi_charp Password, swi_uint16 *pResponse, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiChangeLockPIN (const swi_charp OldPassword, const swi_charp NewPassword, swi_uint16 *pResponse, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetERIVer (const swi_charp pszERIFilename, swi_uint16 *pnERIVer, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPowerSaveExit ()
 
SWI_API SWI_RCODE SwiSetPower (swi_uint16 fwPowerState)
 
SWI_API SWI_RCODE SwiNotifyEx (swi_uint16 eNotify, swi_uint16 mask, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstGetAccolc (swi_uint16 Nam, swi_uint16 *Accolc, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstSetAccolc (swi_uint16 Nam, swi_uint16 Accolc, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstGetSci (swi_uint16 *Sci, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiSetPRL (swi_uint16 NamIndex, swi_uint8 *pPRLBuffer, swi_uint16 nPRLBufLen, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiSetPRLEx (swi_uint16 NamIndex, swi_uint8 *pPRLBuffer, swi_uint16 nPRLBufLen, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiSetERI (swi_uint8 *pERIBuffer, swi_uint16 nERIBufLen, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetTotalUpTime (swi_uint32 *pTotalUpTime, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstGetImsiMS1 (swi_uint16 Nam, swi_uint32 *IMSI, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstSetImsiMS1 (swi_uint16 Nam, swi_uint32 Imsi_MS1, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstGetImsiMS2 (swi_uint16 Nam, swi_uint16 *Imsi_MS2, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstSetImsiMS2 (swi_uint16 Nam, swi_uint16 Imsi_MS2, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstGetNamName (swi_uint16 Nam, swi_charp pszNamName, swi_uint32 length, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstSetNamName (swi_uint16 Nam, const swi_charp pszNamName, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstGetImsiMcc (swi_uint16 Nam, swi_uint16 *Mcc, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstSetImsiMcc (swi_uint16 Nam, swi_uint16 Mcc, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstGetImsi1112 (swi_uint16 Nam, swi_uint16 *Digits1112, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiPstSetImsi1112 (swi_uint16 Nam, swi_uint16 Digits1112, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiSetAKey (swi_charp szAKey, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiRtnReset (swi_uint8 nType, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetTechHdrMacIndex (SWI_STRUCT_Tech_Hdr_Mac_Index *pTechHdrMacIndex, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetLEDEnable (swi_bool *pbEnable, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiSetLEDEnable (swi_bool bEnable, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetLEDEnableEx (SWI_STRUCT_LED_CFG_ENABLE *pLED, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiSetLEDEnableEx (const SWI_STRUCT_LED_CFG_ENABLE *pLED, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetGeneralFeatureSupport (swi_uint32 *pMask, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetDeviceEVDOSetting (swi_uint16 *pwMask, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiSetDeviceEVDOSetting (swi_uint16 wMask, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetStationClassMark (swi_uint8 *pbSCM, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetPRIVersion (swi_uint8 *pMajor, swi_uint8 *pMinor, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiGetPortMapping (swi_uint8 *pnPortMapping, swi_uint32 timeout)
 
SWI_API SWI_RCODE SwiSetPortMapping (swi_uint8 nPortMapping, swi_uint32 timeout)
 

Detailed Description

SWI CDMA specific basic APIs.

Copyright (c) 2011 Sierra Wireless, Inc. All rights reserved

Macro Definition Documentation

#define CNS_MAX_DATA_BLOCK_SIZE   120

modem can only handle 120 size blocks.

#define G_SZ_FNERINAM1   "eri_nam1"
#define LENGTH_CallExtendedNumber   64

Max Extended Caller ID length

#define LENGTH_CallNumber   32

Max Caller ID length

#define LENGTH_Mdn   15

Min Caller ID length

#define LENGTH_Min   10

Max MDN length

#define LENGTH_NVItemPayloadMax   240

Max phone number length

#define LENGTH_NvNameNam   12

Max NAM length

#define LENGTH_PhoneNumberMin   10

Min phone number length

#define LENGTH_PinPassword   4

Max MIN length

#define LENGTH_ProvisioningDate   8

Max provision date length

#define LENGTH_SecureChallenge   8

Max Secure challenge length

#define LENGTH_SecureRebuttal   4

Max secure rebuttal length

#define SCP_APP_SUBTYPE_MASK   1

scp app subtype mask

#define SCP_BCMCS_SUBTYPE_MASK   0

scp bcmcs subtype mask

#define SCP_PROT_SUBTYPE_MASK   0x000000F9

scp prot subtype mask

#define SWI_MAX_LEDS   10

Max number of LEDs

Typedef Documentation

Contains HDR SCP data.

This is data structure for CNS_HDRSCP_SUBTYPE_CUSTOM_CONFIG_I item. To be used with CNS_PST_NV object ID.

Contains Emergency 911 notification data

See Also
SWI_NOTIFY_E911Mode

Contains EFile information data.

Contains HDR PowerSave (Enter) notification data.

This data structure is used as a member of the notification SWI_NOTIFY_Hdr_PowerSave_Enter. Refer to the description of SWI_NOTIFY_Hdr_PowerSave_Enter for more detail.

Contains HDR PowerSave (Exit) notification data.

This data structure is used as a member of the notification SWI_NOTIFY_Hdr_PowerSave_Exit. Refer to the description of SWI_NOTIFY_Hdr_PowerSave_Exit for more detail.

Contains HDR notification data.

Contains previous and current digital mode.

See Also
SWI_TYPE_Digital_Mode

Contains LED configuration data.

Contains MEID and ESN data.

Contains PowerSave (Enter) notification data.

This data structure is used as a member of the notification SWI_NOTIFY_PowerSaveEnter. Refer to the description of SWI_NOTIFY_PowerSaveEnter for more detail.

Contains PowerSave (Exit) notification data.

This data structure is used as a member of the notification SWI_NOTIFY_PowerSaveExit. Refer to the description of SWI_NOTIFY_PowerSaveExit for more detail.

Contains HDR MAC index information

An enumeration of supported carrier ID.

An enumeration of the possible bits in the failure mask field returned by SwiPstLock.

An enumeration of CDMA service settings.

An enumeration of digital mode.

An enumeration of supported distributor ID.

An enumeration of Emergency 911 mode

When in E911 mode, some modem functionality may not be available. The modem can forced out of E911 mode using SwiSetE911Mode.

An enumeration of CDMA features.

An enumeration of LED enable state.

An enumeration of LED type.

An enumeration of Voice/Data Support mask bit.

Enumeration Type Documentation

An enumeration of supported carrier ID.

Enumerator
SWI_CARRIER_UNDEFINED 

Not defined

SWI_CARRIER_RESERVED 

Reserved

SWI_CARRIER_AC555_GENERIC 

Generic

SWI_CARRIER_AC550_SPRINT 

Sprint

SWI_CARRIER_AC555_BELL 

Bell Mobility

SWI_CARRIER_AC555_TELUS 

Telus

SWI_CARRIER_AC555_VZW 

Verizon Wireless

SWI_CARRIER_AC555_WESTERNWIRELESS 

Western Wireless

SWI_CARRIER_AC555_SMARTCOM 

SmartCom

SWI_CARRIER_AC555_ALLTEL 

AllTel

SWI_CARRIER_AC555_USCELLULAR 

US Cellular

SWI_CARRIER_SB550T_SPRINT 

(Thera) Sprint

SWI_CARRIER_SB555T_BELL 

(Thera) Bell Mobility

SWI_CARRIER_SB555T_TELUS 

(Thera) Telus

SWI_CARRIER_SB555T_VZW 

(Thera) Verizon Wireless

SWI_CARRIER_AC555_CHINAUNICOM 

China Unicom

SWI_CARRIER_AC555_HUTCHISONTHAILAND 

Hutchison Thailand

SWI_CARRIER_AC555_MOVILNET 

MovilNet

SWI_CARRIER_AC555_TARJETAS_IUSACELL_MEXICO 

Iusacell Mexico

SWI_CARRIER_AC555_TELECOMNEWZEALAND 

Telecom NewZealand

SWI_CARRIER_AC555_RELIANCE 

Reliance

SWI_CARRIER_AC555_TELSTRA 

Telstra

SWI_CARRIER_AC555_MOBILITYCANADA 

Mobility Canada

SWI_CARRIER_AC555_VZW_PUERTO_RICO 

Verizon Wireless Puerto Rico

SWI_CARRIER_AC555_PELEPHONE 

Pelephone

SWI_CARRIER_AC555_BELL_CANADA 

Bell Canada

SWI_CARRIER_AC555_INDOSOL_INDONESIA 

Indosol

SWI_CARRIER_AC555_MIDWEST_WIRELESS 

MidWest Wireless

SWI_CARRIER_AC555_BELL_SOUTH_CHILE 

South Chile

SWI_CARRIER_AC555_BELL_SOUTH_PANAMA 

South Panama

SWI_CARRIER_AC555_TATA 

Tata

An enumeration of the possible bits in the failure mask field returned by SwiPstLock.

Enumerator
SWI_COMMIT_ERRMASK_NONE 

No error

SWI_COMMIT_ERRMASK_MDN 

MDN not set

SWI_COMMIT_ERRMASK_IMSI 

IMSI not set

SWI_COMMIT_ERRMASK_USERIDPW 

No User ID/Password

SWI_COMMIT_ERRMASK_DATE 

No Provisioning Date

SWI_COMMIT_ERRMASK_NAMORDER 

Max

An enumeration of CDMA service settings.

Enumerator
SWI_REV_UNKNOWN 

Unknown

SWI_REV_0 

CDMA Rev 0

SWI_REV_A 

CDMA Rev A

An enumeration of digital mode.

Enumerator
SWI_HDR_MODE_NO_SERVICE 

No service

SWI_HDR_MODE_AMPS 

Amps

SWI_HDR_MODE_CDMA 

CDMA

SWI_HDR_MODE_GSM 

GSM

SWI_HDR_MODE_HDR 

HDR (EVDO)

SWI_HDR_MODE_WCDMA 

WCDMA

SWI_HDR_MODE_GPS 

GPS

An enumeration of supported distributor ID.

Enumerator
SWI_DISTRIBUTOR_UNDEFINED 

Not defined

SWI_DISTRIBUTOR_NONE 

Reserved

SWI_DISTRIBUTOR_SIERRA_WIRELESS 

SWIR

SWI_DISTRIBUTOR_EASTCOM 

Easter Communications

SWI_DISTRIBUTOR_TONGFANG 

TSINGHUA TONGFANG

SWI_DISTRIBUTOR_ZTE 

ZTE

SWI_DISTRIBUTOR_CHINA_PUTIAN 

NANJING PUTIAN ZHONGYOU

SWI_DISTRIBUTOR_NCL 

NCL Technology

SWI_DISTRIBUTOR_SHANGHAI_BELL 

SHANGHAI BELL

An enumeration of Emergency 911 mode

When in E911 mode, some modem functionality may not be available. The modem can forced out of E911 mode using SwiSetE911Mode.

Enumerator
SWI_E911_MODE_Off 

E911 mode off

SWI_E911_MODE_On 

E911 mode on

An enumeration of CDMA features.

Enumerator
SWI_GEN_FEATURE_IOTA_2_4 

IOTA

SWI_GEN_FEATURE_ENH_GPS 

Enhanced GPS

SWI_GEN_FEATURE_ENH_LED 

Enhanced LED

SWI_GEN_FEATURE_RESERVED3 

Reserved

SWI_GEN_FEATURE_RESERVED4 

Reserved

SWI_GEN_FEATURE_RESERVED5 

Reserved

SWI_GEN_FEATURE_RESERVED6 

Reserved

SWI_GEN_FEATURE_RESERVED7 

Reserved

SWI_GEN_FEATURE_RESERVED8 

Reserved

SWI_GEN_FEATURE_RESERVED9 

Reserved

An enumeration of LED enable state.

Enumerator
SWI_LED_DISABLED 

Disabled

SWI_LED_ENABLED 

Enabled

An enumeration of LED type.

Enumerator
SWI_LED_TYPE_UNDEFINED 

Undefined

SWI_LED_TYPE_POWER_AMBER 

Power amber

SWI_LED_TYPE_SIGNAL_AMBER 

Signal amber

SWI_LED_TYPE_POWER_BLUE 

Power blue

SWI_LED_TYPE_SIGNAL_BLUE 

Signal blue

SWI_LED_TYPE_GLOWTOP 

Glowtop

SWI_LED_TYPE_RESVD1 

Reerved

SWI_LED_TYPE_RESVD2 

Reerved

SWI_LED_TYPE_RESVD3 

Reerved

SWI_LED_TYPE_RESVD4 

Reerved

An enumeration of Voice/Data Support mask bit.

Enumerator
SWI_PRI_DATA_1X 

1x data calls supported

SWI_PRI_DATA_IS95 

IS95(QNC/Fax/Dialup) data calls supported

SWI_PRI_DATA_AUTOCONNECT 

nternal use for Watcher only

SWI_PRI_VOICE 

Voice calls supported

SWI_PRI_VD_ALL 

Internal Use

SWI_PRI_VD_MASK_ENABLED 

Enabled bit (Internal use only)

Function Documentation

SWI_API SWI_RCODE SwiChangeLockPIN ( const swi_charp  OldPassword,
const swi_charp  NewPassword,
swi_uint16 pResponse,
swi_uint32  timeout 
)

This function changes the user’s passcode (PIN).

The return value: SWI_RCODE_REQUEST_TIMEOUT requires special care. If the OldPassword was accepted, the new setting will be made. A subsequent retry will report an invalid password (OldPassword) because the new password is in effect. On the other hand, if the OldPassword was rejected, the settings are unchanged. A retry will report an invalid password, because the user failed to match. Both cases give exactly the same result on a retry! The recommended course of action is to have the application silently retry the command using the NewPassword value in both the old and new parameters. If the modem accepts this, then the change is complete. If the modem rejects it, then OldPassword was likely rejected in the orginal call and the user will have to start the process over.

Parameters
OldPassword[IN]The original passcode; to permit the user to make the change.
NewPassword[IN]The new setting for the passcode.
pResponse[OUT]The result of the requested change: 0 = change rejected; 1 = change accepted
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetActivationStatus ( swi_uint16 pActivationStatus,
swi_uint32  timeout 
)

This function reports the activation status of the modem.

This function can be used to determine if the modem has been activated with at least one NAM account profile. If not, the application should only offer the user E911 service and a mechanism to activate the modem with the service provider, either by OTASP or direct data entry.

Parameters
pActivationStatus[OUT]The destination in which the status is returned: 0 = False; 1 = True.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetAutoLock ( swi_uint16 autoLock,
swi_uint32  timeout 
)

This function reports the state of the autolock feature.

The setting of autolock is controlled with SwiSetAutoLock.

Parameters
autoLock[OUT]The status of the autolock feature: 0 = disabled; 1 = enabled
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetCarrierID ( swi_int16 pnCarrierID,
swi_uint32  timeout 
)

This function reports the ID of the carrier the modem is configured for.

Parameters
pnCarrierID[OUT]Carrier ID. Possible enumerated values are defined in SWI_TYPE_CarrierID.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetCdmaIMSI ( swi_uint16  namIndex,
swi_charp  pszMIN,
swi_uint32  length,
swi_uint32  timeout 
)

This function returns the MIN (Mobile Identifi-cation Number) string of the specified NAM account profile.

This function returns the NMSI digits of the CDMA IMSI (refer to IS-95B). The length of the MIN string can be up to 10 bytes.

Parameters
namIndex[IN]Index (base 0) of the NAM account to query. See SwiGetNamInfo.
pszMIN[OUT]The MIN string of the selected NAM profile.
length[IN]Size of the buffer to receive the result.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetDeviceEVDOSetting ( swi_uint16 pwMask,
swi_uint32  timeout 
)

This function gets device CDMA setting.

Parameters
pwMask[OUT]Pointer to save mask retrived for device CDMA setting. 0: CDMA Rev 0; 1: CDMA Rev A.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetDistributorID ( swi_int16 pnDistributorID,
swi_uint32  timeout 
)

This function reports the ID of the Distributor the modem is configured for.

Parameters
pnDistributorID[OUT]Distributor ID. Possible enumerated values are defined in SWI_TYPE_DistributorID
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetE911Mode ( swi_uint16 e911Mode,
swi_uint32  timeout 
)

This function This function reports the current E911 mode of the modem. Modem features may be disabled in E911 mode, based on service provider settings.

The modem enters E911 mode when a voice call is originated using one of the pre-programmed emergency numbers. The mode is cleared after five minutes or manually via SwiSetE911Mode.

There is a notification (SWI_NOTIFY_E911Mode) to report the modem’s entry and exit from E911 mode.

Parameters
e911Mode[OUT]The destination in which the mode is returned: 0 = Off; 1 = On
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetECIO ( swi_uint16 pEcio,
swi_uint32  timeout 
)

This function reports the current EC/IO value

The EC/IO value returned is positive, and should be negated to be interpreted correctly.

Parameters
pEcio[OUT]The destination in which the EC/IO value is returned.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetEFileBlock ( const swi_charp  pszEFilename,
swi_uint16  nSeq,
swi_uint8 pBuffer,
swi_uint16  nBufLen,
swi_uint32 pnBlockSize,
swi_uint32  timeout 
)
SWI_API SWI_RCODE SwiGetEFileInfo ( const swi_charp  pszEFilename,
SWI_STRUCT_EFileInfo psEFileInfo,
swi_uint32  timeout 
)
SWI_API SWI_RCODE SwiGetERIVer ( const swi_charp  pszERIFilename,
swi_uint16 pnERIVer,
swi_uint32  timeout 
)

This function gets the ERI version stored in the modem.

Parameters
pszERIFilename[IN]ERI Filename stored in modem.
pnERIVer[IN]ERI File Version.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetESN ( swi_int32 lEsn,
swi_uint32  timeout 
)

This function returns the device's unique identity as a string. The returned value is the ESN (Electronic Serial Number) of the modem.

Managing display of the ESN as a string is up to you. In the CDMA marketplace, the ESN is usually presented as the single 8-character string, in the form of a hexadecimal number; for example: CE0271C8.

Parameters
lEsn[OUT]ESN returned from modem.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetGeneralFeatureSupport ( swi_uint32 pMask,
swi_uint32  timeout 
)

This function gets the device's General Feature support capabilities.

See SWI_TYPE_General_Features for mask definitions.

Parameters
pMask[OUT]Bitmask of capability settings
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetLEDEnable ( swi_bool pbEnable,
swi_uint32  timeout 
)

This function gets the device's LED enable state.

This functionality is not support on all devices. A successful return indicates the functionality exists and the current setting of the LED.

Parameters
pbEnable[OUT]Current state of LED setting (0=disabled, 1=enabled).
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetLEDEnableEx ( SWI_STRUCT_LED_CFG_ENABLE pLED,
swi_uint32  timeout 
)

This function gets the device's LED enable state.

This API extends SwiGetLEDEnable by adding a bit mask for indicating LED groups (ie. pwr/signal and glowtop).

This functionality is not support on all devices. Check SwiGetGeneralFeatureSupport() for SWI_GEN_FEATURE_ENH_LED to determine if enhanced LED support is available. If so, this API must be used in place of SwiGetLEDEnable().

Parameters
pLED[IN]LED enable state returned from modem.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetLockStatus ( swi_uint16 pLockStatus,
swi_uint32  timeout 
)

This function reports the state of the user security lock.

Parameters
pLockStatus[OUT]The status of the user security lock: 0 = not locked; 1 = locked
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetMEIDESN ( struct SWI_STRUCT_MeidEsn pMeidEsn,
swi_uint32  timeout 
)

This function returns the device's unique identity The returned value is the MEID (Mobile Equipment Identifier) and ESN (Electronic Serial Number) of the modem.

Managing display of the MEID and ESN is up to the caller

Parameters
timeout[IN]Function timeout in milliseconds
pMeidEns[OUT]The destination in which the MEID and ESN is returned.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetNamInfo ( swi_uint16 cntNamProfile,
swi_uint16 nextNamProfile,
swi_uint32  timeout 
)

This function reports information about the modem’s NAM profile table: the number of profiles supported, and the next empty table entry.

Parameters
cntNamProfile[OUT]The total number of NAM profiles the modem can support.
nextNamProfile[OUT]The index number (base 0) of the next empty profile. 0xFFFF indicates no empty profiles.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetNamValidStatus ( swi_uint16 pNamValidStatus,
swi_uint32  timeout 
)

This function returns the NAM valid status

Parameters
pNamValidStatus[OUT]Returns the NAM valid status. 0x0000 – Incomplete NAM, Service Required 0x0001 – Complete NAM 0x0002 – Incomplete NAM, exceptional Service Required
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetPhoneNumber ( swi_charp  PhoneNumber,
swi_uint32  BufferSize,
swi_uint32  timeout 
)

This function returns the phone number from the currently active NAM account profile.

The phone number is returned as an null-termi-nated ASCII string of 10-15 numerals.

The current NAM account profile is set with SwiPstSetCurrentNam.

Parameters
PhoneNumber[OUT]The destination in which the current account phone number is returned.
BufferSize[IN]The maximum size of the output string(PhoneNumber).
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetPortMapping ( swi_uint8 pnPortMapping,
swi_uint32  timeout 
)

This function gets the current port mapping

Parameters
pnPortMapping[OUT]Pointer pointing to current port mapping returned
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetPRIVersion ( swi_uint8 pMajor,
swi_uint8 pMinor,
swi_uint32  timeout 
)

This function retrieves the modem's PRI version.

Parameters
pMajor[OUT]PRI major version
pMinor[OUT]PRI minor version
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetPRLVersion ( swi_uint16 pPrlVersion,
swi_uint32  timeout 
)

This function gets PRL version

Parameters
pPrlVersion[OUT]Version number of the current PRL.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetProvisioningDate ( swi_uint16  namIndex,
swi_charp  pszProvisioningData,
swi_uint32  length,
swi_uint32  timeout 
)

This function returns the date on which a specified NAM index was activated (written).

The provisioning date is set whenever the NAM profile is written. The date comes from the CDMA network at the time the account profile is written, or as soon as CDMA coverage is available.

Parameters
namIndex[IN]The (base 0) index number of the NAM account profile to query. See SwiGetNamInfo.
pszProvisioningData[OUT]Date string in the form YYYYMMDD. An empty account index will report all zeroes.
length[IN]The maximum size of the output string.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetStationClassMark ( swi_uint8 pbSCM,
swi_uint32  timeout 
)

This function gets device's Station Class Mark

Parameters
pbSCM[OUT]Pointer to data buffer.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetSystemTime ( swi_uint16 year,
swi_uint16 month,
swi_uint16 day,
swi_uint16 weekDay,
swi_uint16 hour,
swi_uint16 minute,
swi_uint16 second,
swi_uint32  timeout 
)

This function returns the date and time from the CDMA network.

Parameters
year[OUT]Year as a binary number; such as 0x7D0 for year 2000.
month[OUT]Month in binary
day[OUT]Day date in the month in binary
weekDay[OUT]Day of the week as a numeric: 0x0001 = Mon, 0x0001 = Mon, 0x0007 = Sun
hour[OUT]Hour in binary (24-hour clock). For example: 0x0016 = 10 PM
minute[OUT]Minutes in binary
second[OUT]Seconds in binary
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetTechHdrMacIndex ( SWI_STRUCT_Tech_Hdr_Mac_Index pTechHdrMacIndex,
swi_uint32  timeout 
)

This function gets the device HDR MAC index value.

Parameters
pTechHdrMacIndex[OUT]Mac Index. (see SWI_STRUCT_Tech_Hdr_Mac_Index)
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetTemperature ( swi_int32 iTemperature,
swi_uint32  timeout 
)

This function reports the temperature of the radio within the modem.

The modem firmware monitors the radio temperature to protect electronics and prevent drift from specification. Consult the product specification for the specific type of unit you are using to determine the way the modem handles high temperatures.

Parameters
iTemperature[OUT]Temperature in degrees C.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiGetTotalUpTime ( swi_uint32 pTotalUpTime,
swi_uint32  timeout 
)

This function returns the Devices Life Timer value

Parameters
pTotalUpTime[OUT]Device Life Timer value.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiIsModemReady ( swi_uint32  timeout)

This function reports whether the modem is in a state where it is ready for normal operation. This function should be called after successfully calling SwiRegisterCallback, and before any other API function call.

This function should always be called after successfully calling SwiRegisterCallback (which is always called after SwiApiOpen, and before any other API function call.

When the modem undergoes a power cycle (typically after inserting the modem or resuming from a reset or host suspend), the modem may take some time to initialize. During this period, the modem may not respond to any API modem functions, in spite a successful call with SwiApiOpen. This function is used to test for this condition, and should be repeatedly called until it succeeds.

Parameters
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiLockModem ( const swi_charp  Password,
swi_uint16 pResponse,
swi_uint32  timeout 
)

This function toggles the state of the user security lock.

Parameters
Password[IN]The user’s passcode to contol the modem lock.
pResponse[OUT]The modem’s response to the password provided: 0 = passcode rejected; 1 = accepted - state toggled
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiNotifyEx ( swi_uint16  eNotify,
swi_uint16  mask,
swi_uint32  timeout 
)
SWI_API SWI_RCODE SwiPowerSaveExit ( )

This function forces modem out of CDMA deep sleep.

Typically prior to dialing a number using the dialpad, using the phone book or when RAS dialing, this function should be called to wake up the modem if it is in CDMA power save mode.

Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPriGetVoiceDataMask ( swi_uint16 voiceDataMask,
swi_uint32  timeout 
)

This function reports the modem's voice/data capabilities

Parameters
voiceDataMask[OUT]The destination in which the data is returned. Possible mask bit values are defined in SWI_TYPE_PRI_VoiceDataMask (See SwiStructs.h for details)
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstGetAccolc ( swi_uint16  Nam,
swi_uint16 Accolc,
swi_uint32  timeout 
)

This function gets the Access Overload Class setting.

Parameters
Nam[IN]NAM index.
Accolc[OUT]Accolc setting
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstGetCurrentNam ( swi_uint16 CurrentNam,
swi_uint32  timeout 
)

This function returns the currently active NAM index number.

This account profile is used for all call connections. Use SwiPstSetCurrentNam to change the active account.

Parameters
CurrentNam[OUT]The index (base 0) of the currently active NAM account profile.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstGetImsi1112 ( swi_uint16  Nam,
swi_uint16 Digits1112,
swi_uint32  timeout 
)

This function gets IMSI_1112.

Value must be decoded for proper display.

Parameters
Nam[IN]NAM index.
Digits1112[OUT]Encoded IMSI_1112
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstGetImsiMcc ( swi_uint16  Nam,
swi_uint16 Mcc,
swi_uint32  timeout 
)

This function gets Mobile Country Code (MCC).

Value must be decoded for proper display.

Parameters
Nam[IN]NAM index.
Mcc[OUT]Encoded MCC
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstGetImsiMS1 ( swi_uint16  Nam,
swi_uint32 IMSI,
swi_uint32  timeout 
)

This function retrieves 1st part of IMSI

Use SwiPstGetImsiMS2 to retrieve 2nd part. Both IMSI parts must be retrieved and decoded for complete IMSI display.

Parameters
Nam[IN]NAM index.
IMSI[OUT]Encoded IMSI value.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstGetImsiMS2 ( swi_uint16  Nam,
swi_uint16 Imsi_MS2,
swi_uint32  timeout 
)

This function retrieves 2st part of IMSI.

Use SwiPstGetImsiMS1 to retrieve 1st part. Both IMSI parts must be retrieved and decoded for complete IMSI display.

Parameters
Nam[IN]NAM index.
Imsi_MS2[OUT]Encoded IMSI value.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstGetNamName ( swi_uint16  Nam,
swi_charp  pszNamName,
swi_uint32  length,
swi_uint32  timeout 
)

This function retrieves NAM name.

Parameters
Nam[IN]NAM index.
pszNamName[OUT]Nam Name String.
length[IN]Length of string buffer passed in.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstGetSci ( swi_uint16 Sci,
swi_uint32  timeout 
)

This function gets the Slot Cycle Index value.

Parameters
Sci[OUT]The Slot cycle index setting.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstLock ( swi_uint16  Type,
swi_uint16  Nam,
swi_uint16 commitResult,
swi_uint16 failureMask,
swi_uint32  timeout 
)

This function closes the activation process, either cancelling the changes or committing them to storage.

The modem must have been unlocked via SwiPstUnlock prior to this command.

In the event of a failure, the entire process of activation should be repeated. The failure mask reports all known reasons why a commit failed. See Activation process in the API Reference for a description of the complete activation process.

Parameters
Type[IN]0 = cancel changes; 1 = commit changes
Nam[IN]Index (base 0) of the NAM account profile to commit or cancel. See SwiGetNamInfo.
commitResult[OUT]0 = Fail - see remarks; 1 = Success
failureMask[OUT]Bit-mapped failure reason, see SWI_TYPE_Commit_ErrorMask for possible values
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstSetAccolc ( swi_uint16  Nam,
swi_uint16  Accolc,
swi_uint32  timeout 
)

This function Sets the Access Overload Class value.

Parameters
Nam[IN]NAM index.
Accolc[IN]Accolc setting
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstSetCurrentNam ( swi_uint16  CurrentNam,
swi_uint32  timeout 
)

This function sets the index to a NAM account profile to make the active account for connec-tions and other queries.

The modem must be reset via SwiResetModem to have the change take effect.

The current setting can be read using SwiPstGetCurrentNam.

Parameters
CurrentNam[IN]Index (base 0) to set as the currently active NAM account profile. See SwiGetNamInfo.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstSetImsi1112 ( swi_uint16  Nam,
swi_uint16  Digits1112,
swi_uint32  timeout 
)

This function sets IMSI_1112

Value must be encoded before written to modem.

Parameters
Nam[IN]NAM index.
Digits1112[IN]Encoded IMSI_1112
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstSetImsiMcc ( swi_uint16  Nam,
swi_uint16  Mcc,
swi_uint32  timeout 
)

This function sets the Mobile Country Code (MCC).

Parameters
Nam[IN]NAM index.
Mcc[IN]Encoded MCC
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstSetImsiMS1 ( swi_uint16  Nam,
swi_uint32  Imsi_MS1,
swi_uint32  timeout 
)

This function sets 1st part of IMSI.

IMSI must be encoded before writing to modem.

Parameters
Nam[IN]NAM index.
Imsi_MS1[IN]encoded IMSI value.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstSetImsiMS2 ( swi_uint16  Nam,
swi_uint16  Imsi_MS2,
swi_uint32  timeout 
)

This function sets 2nd part of IMSI.

IMSI must be encoded before writing to modem.

Parameters
Nam[IN]NAM index.
Imsi_MS2[IN]Encoded IMSI value.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstSetNamName ( swi_uint16  Nam,
const swi_charp  pszNamName,
swi_uint32  timeout 
)

This function sets the NAM name

Parameters
Nam[IN]NAM index.
pszNamName[IN]Nam Name String.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiPstUnlock ( swi_uint32  SubsidyLock,
swi_uint32  timeout 
)

This function uses the subsidy lock value (OTSL, MSL, or SPC) to unlock access to activate (write) a NAM account profile.

Parameters
SubsidyLock[IN]Either the OTSL, or the MSL (also known as the SPC). This number is provided by the service provider.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiResetModem ( )

This function resets the modem.

This is typically done after modifying particular modem settings that require a reset for the new settings to take effect.

During the period in which the modem resets and re-initializes, the modem will not respond to any API requests.

After the reset, any previously enabled notifications must be re-enabled, and any previous modem states and/or information may no longer be valid.

Typical scenarios requiring a modem reset include:

  • Modem activation
  • Modifying system select setting (SwiPstSetSystemPref)
  • Changing the current active NAM (SwiPstSetCurrentNam)
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiRtnReset ( swi_uint8  nType,
swi_uint32  timeout 
)

This function performs a RTN or PRI reset on the device.

This will reset the device to factory state. Note that this action may take several moments.

Parameters
nType[IN]Type of reset (PRI_RESET = 1,RTN_RESET = 2)
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiSetAKey ( swi_charp  szAKey,
swi_uint32  timeout 
)

This function sets the 20 Digit AKey.

AKey Checksum is managed internally by the API. Modem must be MSL unlocked to write this item. Modem should be relocked after written.

Parameters
szAKey[IN]AKey to be written to modem.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiSetAutoLock ( swi_uint16  autoLock,
swi_uint32  timeout 
)

This function This function sets the state of the automatic user security lock on the modem.

If you enable the autolock, the lock will be on the next time the modem is started (reset or power cycled). The state of the current autolock setting can be read using SwiGetAutoLock.

A locked modem is unlocked with SwiLockModem.

Parameters
autoLock[IN]The autolock state setting: 0 = Off; !0 = Enabled
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiSetDeviceEVDOSetting ( swi_uint16  wMask,
swi_uint32  timeout 
)

This function sets device CDMA setting

Parameters
wMask[IN]Mask to be set for device CDMA setting. 0: CDMA Rev 0; 1: CDMA Rev A.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiSetE911Mode ( swi_uint16  e911Mode,
swi_uint32  timeout 
)

This function turns off the E911 mode of the modem.

The modem enters E911 mode when a voice call is originated using one of the pre-programmed emergency numbers. The mode is cleared after five minutes, or this function can be used to force the modem back to normal operations.

There is a notification (SWI_NOTIFY_E911Mode) to report the modem’s entry and exit from E911 mode.

Parameters
e911Mode[IN]Must be zero (0).
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiSetEFile ( const swi_charp  pszEFilename,
swi_uint8 pBuffer,
swi_uint16  nBufLen,
swi_uint32  timeout 
)
SWI_API SWI_RCODE SwiSetERI ( swi_uint8 pERIBuffer,
swi_uint16  nERIBufLen,
swi_uint32  timeout 
)

This function write the ERI data to the modem.

Before calling this API, make sure that the modem is SPC (or MSL) unlocked. After calling this API, whether the operation is successfull or not, should call SwiResetModem

Parameters
pERIBuffer[IN]Pointer to the entire ERI data buffer.
nERIBufLen[IN]Size of the ERI data.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiSetIMSI ( swi_uint16  namIndex,
const swi_charp  pszMIN,
swi_uint32  timeout 
)

This function sets the MIN string for the specified NAM account profile.

The MIN is a string of the NMSI digits of the CDMA IMSI (refer to IS-95B). The MIN must be from 1 to 10 bytes long. The modem will pad with zeroes for MINs less than 10 bytes. The balance of the IMSI is pre-programmed at the factory for the particular service provider.

The data is not committed until SwiPstLock is called. See "Activation process" in documentation for a description of the activation process.

Parameters
namIndex[IN]Index (base 0) of the NAM account to set. See SwiGetNamInfo.
pszMIN[IN]MIN to store.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiSetLEDEnable ( swi_bool  bEnable,
swi_uint32  timeout 
)

This function sets the device's LED enable state.

This functionality is not support on all devices. A successful return indicates the functionality exists and the LED setting was set. To determine if feature is supported, use SwiGetLEDEnable().

Parameters
bEnable[IN]LED setting (0=disabled, 1=enabled)
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiSetLEDEnableEx ( const SWI_STRUCT_LED_CFG_ENABLE pLED,
swi_uint32  timeout 
)

This function sets the device's LED enable states.

This API extends SwiSetLEDEnable by adding a bit mask to control LED groups.

This functionality is not support on all devices. A successful return indicates the functionality exists and the LED setting was set. To determine if feature is supported, check for SWI_GEN_FEATURE_ENH_LED using SwiGetGeneralFeatureSupport(). If supported, this API must be used in place of SwiSetLEDEnable().

Parameters
pLED[IN]Table of LED settings. 0 = disable, 1 = enable. Note: Type field is not used.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiSetModemOffline ( )

This function This function set the modem to offline mode.

This is typically done before saving data to the modem and then reset the modem with SwiResetModem. The benefit to bring the modem to offline mode is to limit modem's operation during this mode.

Typical scenarios requiring a modem reset include:

  • Modem activation
  • Modifying system select setting (SwiPstSetSystemPref)
  • Changing the current active NAM (SwiPstSetCurrentNam)

During this mode, the modem might error out on certain operations like, voice/data/SMS related call.

SWI_NOTIFY_Power[_Power.State == SWI_Type_PowerOffline] notification will be sent when the modem completes the offline. See SWI_NOTIFY_Power for details.

To exit this mode, application needs to call SwiResetModem.

Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiSetPortMapping ( swi_uint8  nPortMapping,
swi_uint32  timeout 
)

This function sets the port mapping

Parameters
nPortMapping[IN]Port mapping to set.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiSetPower ( swi_uint16  fwPowerState)
SWI_API SWI_RCODE SwiSetPRL ( swi_uint16  NamIndex,
swi_uint8 pPRLBuffer,
swi_uint16  nPRLBufLen,
swi_uint32  timeout 
)

This function upload the PRL binary data to the modem.

If this API returns error then call it one more time with the same parameters. Before calling this API, make sure that the modem is SPC (or MSL) unlocked. After calling this API, whether the operation is successfull or not, should call SwiResetModem

Parameters
NamIndex[IN]NAM index.
pPRLBuffer[IN]Pointer to the entire binary data of PRL to upload.
nPRLBufLen[IN]Size of the binary data.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiSetPRLEx ( swi_uint16  NamIndex,
swi_uint8 pPRLBuffer,
swi_uint16  nPRLBufLen,
swi_uint32  timeout 
)

This function upload the PRL binary data to the modem. If this API returns error then call it one more time with the same parameters. This API differs from SwiSetPRL in that this call does not need modem to be SPC (or MSL) unlocked. After calling this API, whether the operation is successfull or not, should call SwiResetModem

Parameters
NamIndex[IN]NAM index.
pPRLBuffer[IN]Pointer to the entire binary data of PRL to upload.
nPRLBufLen[IN]Size of the binary data.
timeout[IN]Function timeout in milliseconds.
Returns
See SwiRcodes.h
SWI_API SWI_RCODE SwiSetPRLSize ( swi_uint16  Nam,
swi_uint32  nSize,
swi_uint32  timeout 
)

Linux SDK V1.4.0.5
Copyright (c) 2011 Sierra Wireless, Inc. All rights reserved