| CE Gobi SDK 2.7 GobiApi

- Main Page
- Modules
- Classes
- Files

Functions
Network Access Service

## Functions
IMPORTGOBI ULONG GOBICMAPI | SetServingSystemCallback (tFNServingSystem pCallback)
IMPORTGOBI ULONG GOBICMAPI | SwiSetServingSystemInfoCallback (tFNSwiServingSystemInfo pCallback)
IMPORTGOBI ULONG GOBICMAPI | SetCurrentPlmnCallback (tFNCurrentPlmn pCallback)
IMPORTGOBI ULONG GOBICMAPI | Set3Gpp2SubscriptionInfo (BYTE *pNamId, MinBasedImsi *pMinBasedImsi, TrueImsi *pTrueImsi, BYTE *pMdnLen, BYTE *pMdn)
IMPORTGOBI ULONG GOBICMAPI | Get3Gpp2SubscriptionInfo (BYTE *pNamId, MinBasedImsi *pMinBasedImsi, TrueImsi *pTrueImsi, BYTE *pMdnLen, BYTE *pMdn)
IMPORTGOBI ULONG GOBICMAPI | SetDdtmPreference (BYTE ddtmPref, WORD ddtmAction, BYTE soListAction, BYTE numSoInstances, WORD *pArrServiceOption)
IMPORTGOBI ULONG GOBICMAPI | GetSysInfo (CdmaSystemInfo *pCdmaSystemInfo, HdrSystemInfo *pHdrSystemInfo, GsmSystemInfo *pGsmSystemInfo, WcdmaSystemInfo *pWcdmaSystemInfo, LteSystemInfo *pLteSystemInfo, TdscdmaSystemInfo *pTdscdmaSystemInfo)
IMPORTGOBI ULONG GOBICMAPI | GetErrRate (WORD *pCdmaFrameErrorRate, WORD *pHdrPacketErrorRate, BYTE *pGsmBitErrorRate, BYTE *pWcdmaBlockErrorRate, BYTE *pTdscdmaBlockErrorRate)
IMPORTGOBI ULONG GOBICMAPI | GetHdrColorCode (BYTE *pColorCode)
IMPORTGOBI ULONG GOBICMAPI | GetTxRxInfo (BYTE radioIf, RxInfo *pRxInfoCh0, RxInfo *pRxInfoCh1, TxInfo *pTxInfo)
IMPORTGOBI ULONG GOBICMAPI | SwiGetHrpdStats (BYTE *pDrcValue, BYTE *pDrcCover, BYTE *pArrUati, BYTE *pNumOfPilot, HrpdPilot *pHrpdPilot)
IMPORTGOBI ULONG GOBICMAPI | SwiGetCdmaDominantPn (WORD *p1xDominantPn, WORD *pDoDominantPn)
IMPORTGOBI ULONG GOBICMAPI | SetPLMNModeCallback (tFNPLMNMode pCallback)
IMPORTGOBI ULONG GOBICMAPI | SetSignalStrengthCallback (tFNSignalStrength pCallback, BYTE thresholdsSize, INT8 *pThresholds)
IMPORTGOBI ULONG GOBICMAPI | SetLURejectCallback (tFNLUReject pCallback)
IMPORTGOBI ULONG GOBICMAPI | SetRFInfoCallback (tFNRFInfo pCallback)
IMPORTGOBI ULONG GOBICMAPI | SetRoamingIndicatorCallback (tFNRoamingIndicator pCallback)
IMPORTGOBI ULONG GOBICMAPI | SetDataCapabilitiesCallback (tFNDataCapabilities pCallback)
IMPORTGOBI ULONG GOBICMAPI | GetHomeNetwork (WORD *pMCC, WORD *pMNC, BYTE nameSize, CHAR *pName, WORD *pSID, WORD *pNID)
IMPORTGOBI ULONG GOBICMAPI | SetNetworkPreference (ULONG technologyPref, ULONG duration)
IMPORTGOBI ULONG GOBICMAPI | GetNetworkPreference (ULONG *pTechnologyPref, ULONG *pDuration, ULONG *pPersistentTechnologyPref)
IMPORTGOBI ULONG GOBICMAPI | SetCDMANetworkParameters (CHAR *pSPC, BYTE *pForceRev0, BYTE *pCustomSCP, ULONG *pProtocol, ULONG *pBroadcast, ULONG *pApplication, ULONG *pRoaming)
IMPORTGOBI ULONG GOBICMAPI | GetCDMANetworkParameters (BYTE *pSCI, BYTE *pSCM, BYTE *pRegHomeSID, BYTE *pRegForeignSID, BYTE *pRegForeignNID, BYTE *pForceRev0, BYTE *pCustomSCP, ULONG *pProtocol, ULONG *pBroadcast, ULONG *pApplication, ULONG *pRoaming)
IMPORTGOBI ULONG GOBICMAPI | GetACCOLC (BYTE *pACCOLC)
IMPORTGOBI ULONG GOBICMAPI | SetACCOLC (CHAR *pSPC, BYTE accolc)
IMPORTGOBI ULONG GOBICMAPI | GetPLMNMode (ULONG *pMode)
IMPORTGOBI ULONG GOBICMAPI | GetPLMNName (USHORT mcc, USHORT mnc, ULONG *pNamesSize, BYTE *pNames)
IMPORTGOBI ULONG GOBICMAPI | GetRFInfo (BYTE *pInstanceSize, BYTE *pInstances)
IMPORTGOBI ULONG GOBICMAPI | PerformNetworkScan (BYTE *pInstanceSize, BYTE *pInstances)
IMPORTGOBI ULONG GOBICMAPI | PerformNetworkRATScan (BYTE *pInstanceSize, BYTE *pInstances, BYTE *pRATSize, BYTE *pRATInstances)
IMPORTGOBI ULONG GOBICMAPI | InitiateNetworkRegistration (ULONG regType, WORD mcc, WORD mnc, ULONG rat)
IMPORTGOBI ULONG GOBICMAPI | InitiateDomainAttach (ULONG action)
IMPORTGOBI ULONG GOBICMAPI | GetServingNetwork (ULONG *pRegistrationState, ULONG *pCSDomain, ULONG *pPSDomain, ULONG *pRAN, BYTE *pRadioIfacesSize, BYTE *pRadioIfaces, ULONG *pRoaming, WORD *pMCC, WORD *pMNC, BYTE nameSize, CHAR *pName)
IMPORTGOBI ULONG GOBICMAPI | GetServingNetworkCapabilities (BYTE *pDataCapsSize, BYTE *pDataCaps)
IMPORTGOBI ULONG GOBICMAPI | GetANAAAAuthenticationStatus (ULONG *pStatus)
IMPORTGOBI ULONG GOBICMAPI | GetSignalStrengths (ULONG *pArraySizes, INT8 *pSignalStrengths, ULONG *pRadioInterfaces)

## Detailed Description

## Function Documentation

IMPORTGOBI ULONG GOBICMAPI GetACCOLC | ( | BYTE * | pACCOLC | ) |

This function returns the Access Overload Class (ACCOLC) of the device QMI_NAS_GET_ACCOLC_MSG = 0x002C

Parameters

  pACCOLC | [ O ] - The ACCOLC

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI GetANAAAAuthenticationStatus | ( | ULONG * | pStatus | ) |

This function gets the AN-AAA authentication status QMI_NAS_GET_AN_AAA_STATUS_MSG = 0x0032

Parameters

  pStatus | [ O ] - AN-AAA authentication status

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI GetCDMANetworkParameters | ( | BYTE * | pSCI,
|  | BYTE * | pSCM,
|  | BYTE * | pRegHomeSID,
|  | BYTE * | pRegForeignSID,
|  | BYTE * | pRegForeignNID,
|  | BYTE * | pForceRev0,
|  | BYTE * | pCustomSCP,
|  | ULONG * | pProtocol,
|  | ULONG * | pBroadcast,
|  | ULONG * | pApplication,
|  | ULONG * | pRoaming
| ) |  |

This function gets the current CDMA network parameters QMI_NAS_GET_DEVICE_CONFIG = 0x002F

Parameters

  pSCI | [ O ] - Slot cycle index
  pSCM | [ O ] - Station class mark
  pRegHomeSID | [ O ] - Register on home SID?
  pRegForeignSID | [ O ] - Register on foreign SID?
  pRegForeignNID | [ O ] - Register on foreign NID?
  pForceRev0 | [ O ] - Force CDMA 1x-EV-DO Rev. 0 mode?
  pCustomSCP | [ O ] - Use a custom config for CDMA 1x-EV-DO SCP?
  pProtocol | [ O ] - Protocol mask for custom SCP config
  pBroadcast | [ O ] - Broadcast mask for custom SCP config
  pApplication | [ O ] - Application mask for custom SCP config
  pRoaming | [ O ] - Roaming preference

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI GetHomeNetwork | ( | WORD * | pMCC,
|  | WORD * | pMNC,
|  | BYTE | nameSize,
|  | CHAR * | pName,
|  | WORD * | pSID,
|  | WORD * | pNID
| ) |  |

This function retrieves information about the home network of the device QMI_NAS_GET_HOME_NETWORK_MSG = 0x0025

Parameters

  pMCC | [ O ] - Mobile country code
  pMNC | [ O ] - Mobile network code
  nameSize | [ I ] - The maximum number of characters (including NULL terminator) that the network name array can contain
  pName | [ O ] - The network name or description represented as a NULL terminated string (empty string returned when unknown)
  pSID | [ O ] - Home network system ID (0xFFFF - Unknown)
  pNID | [ O ] - Home network ID (0xFFFF - Unknown)

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI GetNetworkPreference | ( | ULONG * | pTechnologyPref,
|  | ULONG * | pDuration,
|  | ULONG * | pPersistentTechnologyPref
| ) |  |

This function returns the network registration preference QMI_NAS_GET_TECHNOLOGY_PREFERENCE_MSG = 0x002B

Parameters

  pTechnologyPref | [ O ] - Technology preference bitmap
  pDuration | [ O ] - Duration of active preference
  pPersistentTechnologyPref | [ O ] - Persistent technology preference bitmap

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI GetPLMNMode | ( | ULONG * | pMode | ) |

This function returns the PLMN mode from the CSP QMI_NAS_GET_CSP_PLMN_MODE_BIT_IND = 0x003C

Parameters

  pMode | [ O ] - PLMN mode

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI GetPLMNName | ( | USHORT | mcc,
|  | USHORT | mnc,
|  | ULONG * | pNamesSize,
|  | BYTE * | pNames
| ) |  |

This function returns PLMN name information for the given MCC/MNC QMI_NAS_GET_PLMN_NAME_MSG = 0x0044

Parameters

  mcc | [ I ] - Mobile country code
  mnc | [ I ] - Mobile network code
  pNamesSize | [I/O] - Upon input the size in BYTEs of the name structure array. Upon success the actual number of BYTEs copied to the name structure array
  pNames | [ O ] - The name structure array

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI GetRFInfo | ( | BYTE * | pInstanceSize,
|  | BYTE * | pInstances
| ) |  |

This function gets the current RF information QMI_NAS_GET_RF_BAND_INFO = 0x0031

Parameters

  pInstanceSize | [I/O] - Upon input the maximum number of elements that the RF info instance array can contain. Upon success the actual number of elements in the RF info instance array
  pInstances | [ O ] - The RF info instance array

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI GetServingNetwork | ( | ULONG * | pRegistrationState,
|  | ULONG * | pCSDomain,
|  | ULONG * | pPSDomain,
|  | ULONG * | pRAN,
|  | BYTE * | pRadioIfacesSize,
|  | BYTE * | pRadioIfaces,
|  | ULONG * | pRoaming,
|  | WORD * | pMCC,
|  | WORD * | pMNC,
|  | BYTE | nameSize,
|  | CHAR * | pName
| ) |  |

Gets information regarding the system that currently provides service to the device QMI_NAS_GET_SERVING_SYSTEM_MSG = 0x0024

Parameters

  pRegistrationState | [ O ] - Registration state
  pCSDomain | [ O ] - Circuit switch domain status
  pPSDomain | [ O ] - Packet switch domain status
  pRAN | [ O ] - Radio access network
  pRadioIfacesSize | [I/O] - Upon input the maximum number of elements that the radio interfaces can contain. Upon successful output the actual number of elements in the radio interface array
  pRadioIfaces | [ O ] - The radio interface array
  pRoaming | [ O ] - Roaming indicator (0xFFFFFFFF - Unknown)
  pMCC | [ O ] - Mobile country code (0xFFFF - Unknown)
  pMNC | [ O ] - Mobile network code (0xFFFF - Unknown)
  nameSize | [ I ] - The maximum number of characters (including NULL terminator) that the network name array can contain
  pName | [ O ] - The network name or description represented as a NULL terminated string (empty string returned when unknown)

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI GetServingNetworkCapabilities | ( | BYTE * | pDataCapsSize,
|  | BYTE * | pDataCaps
| ) |  |

Gets information regarding the data capabilities of the system that currently provides service to the device QMI_NAS_GET_SERVING_SYSTEM_MSG = 0x0024

Parameters

  pDataCapsSize | [I/O] - Upon input the maximum number of elements that the data capabilities array can contain. Upon success the actual number of elements in the data capabilities array
  pDataCaps | [ O ] - The data capabilities array

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI GetSignalStrengths | ( | ULONG * | pArraySizes,
|  | INT8 * | pSignalStrengths,
|  | ULONG * | pRadioInterfaces
| ) |  |

This function gets the current available signal strengths (in dBm) as measured by the device QMI_NAS_GET_SIGNAL_STRENGTH_MSG = 0x0020

Parameters

  pArraySizes | [I/O] - Upon input the maximum number of elements that each array can contain can contain. Upon successful output the actual number of elements in each array
  pSignalStrengths | [ O ] - Received signal strength array (dBm)
  pRadioInterfaces | [ O ] - Radio interface technology array

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI InitiateDomainAttach | ( | ULONG | action | ) |

This function initiates a domain attach (or detach)

Parameters

  action | [ I ] - PS attach action (attach or detach)

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI InitiateNetworkRegistration | ( | ULONG | regType,
|  | WORD | mcc,
|  | WORD | mnc,
|  | ULONG | rat
| ) |  |

This function initiates a network registration QMI_NAS_INITIATE_ATTACH_MSG = 0x0023

Parameters

  regType | [ I ] - Registration type
  mcc | [ I ] - Mobile country code (ignored for auto registration)
  mnc | [ I ] - Mobile network code (ignored for auto registration)
  rat | [ I ] - Radio access type (ignored for auto registration)

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI PerformNetworkRATScan | ( | BYTE * | pInstanceSize,
|  | BYTE * | pInstances,
|  | BYTE * | pRATSize,
|  | BYTE * | pRATInstances
| ) |  |

This function performs a scan for available networks (includes RAT) QMI_NAS_PERFORM_NETWORK_SCAN_MSG = 0x0021

Parameters

  pInstanceSize | [I/O] - Upon input the maximum number of elements that the network info instance array can contain. Upon success the actual number of elements in the network info instance array
  pInstances | [ O ] - The network info instance array
  pRATSize | [I/O] - Upon input the maximum number of elements that the RAT info instance array can contain. Upon success the actual number of elements in the RAT info instance array
  pRATInstances | [ O ] - The RAT info instance array

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI PerformNetworkScan | ( | BYTE * | pInstanceSize,
|  | BYTE * | pInstances
| ) |  |

This function performs a scan for available networks

Parameters

  pInstanceSize | [I/O] - Upon input the maximum number of elements that the network info instance array can contain. Upon success the actual number of elements in the network info instance array
  pInstances | [ O ] - The network info instance array

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI SetACCOLC | ( | CHAR * | pSPC,
|  | BYTE | accolc
| ) |  |

This function sets the Access Overload Class (ACCOLC) of the device QMI_NAS_SET_ACCOLC_MSG = 0x002D

Parameters

  pSPC | [ I ] - NULL terminated string representing the six digit service programming code
  accolc | [ I ] - The ACCOLC

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI SetCDMANetworkParameters | ( | CHAR * | pSPC,
|  | BYTE * | pForceRev0,
|  | BYTE * | pCustomSCP,
|  | ULONG * | pProtocol,
|  | ULONG * | pBroadcast,
|  | ULONG * | pApplication,
|  | ULONG * | pRoaming
| ) |  |

This function sets the desired CDMA network parameters QMI_NAS_SET_DEVICE_CONFIG = 0x0030

Parameters

  [ | I ] - Six digit service programming code
  pForceRev0 | [ I ] - (Optional) Force CDMA 1x-EV-DO Rev. 0 mode?
  pCustomSCP | [ I ] - (Optional) Use a custom config for CDMA 1x-EV-DO SCP?
  pProtocol | [ I ] - (Optional) Protocol mask for custom SCP config
  pBroadcast | [ I ] - (Optional) Broadcast mask for custom SCP config
  pApplication | [ I ] - (Optional) Application mask for custom SCP config
  pRoaming | [ I ] - (Optional) Roaming preference

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI SetDataCapabilitiesCallback | ( | tFNDataCapabilities | pCallback | ) |

This function enables/disables the serving system data capabilities callback function QMI_NAS_GET_SERVING_SYSTEM_IND 0x0024 TLV Data Service Capability 0x11

Parameters

  pCallback | [ I ] - Callback function (0 = disable)

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI SetLURejectCallback | ( | tFNLUReject | pCallback | ) |

This function enables/disables the LU reject callback function with QMI_NAS_SET_EVENT_REPORT 0x0002 TLV 0x12

Parameters

  pCallback | [ I ] - Callback function (0 = disable)

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI SetNetworkPreference | ( | ULONG | technologyPref,
|  | ULONG | duration
| ) |  |

This function sets the network registration preference QMI_NAS_SET_TECHNOLOGY_PREFERENCE_MSG = 0x002A

Parameters

  technologyPref | [ I ] - Technology preference bitmap
  duration | [ I ] - Duration of active preference

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI SetPLMNModeCallback | ( | tFNPLMNMode | pCallback | ) |

This function enables/disables the PLMN mode callback function QMI_NAS_GET_CSP_PLMN_MODE_BIT_IND 0x003C

Parameters

  pCallback | [ I ] - Callback function

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI SetRFInfoCallback | ( | tFNRFInfo | pCallback | ) |

This function enables/disables the RF information callback function with QMI_NAS_SET_EVENT_REPORT 0x0002 TLV 0x11

Parameters

  pCallback | [ I ] - Callback function (0 = disable)

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI SetRoamingIndicatorCallback | ( | tFNRoamingIndicator | pCallback | ) |

This function enables/disables the roaming indicator callback function QMI_NAS_GET_SERVING_SYSTEM 0x0024 QMI_NAS_SERVING_SYSTEM_IND 0x0024 TLV Roaming Indicator Value 0x10

Parameters

  pCallback | [ I ] - Callback function (0 = disable)

Returns
  See GobiErrorCodes.h

IMPORTGOBI ULONG GOBICMAPI SetSignalStrengthCallback | ( | tFNSignalStrength | pCallback,
|  | BYTE | thresholdsSize,
|  | INT8 * | pThresholds
| ) |  |

This function enables/disables the signal strength callback function with QMI_NAS_SET_EVENT_REPORT 0x0002 TLV 0x10

Parameters

  pCallback | [ I ] - Callback function (0 = disable)
  thresholdsSize | [ I ] - Number of elements the threshold array contain (a maximum of 5 thresholds is supported), must be 0 when disabling the callback
  pThresholds | [ I ] - Signal threshold array (each entry in dBm), must be 0 when disabling the callback

Returns
  See GobiErrorCodes.h