RIL_GetGPRSAddress (Compact 2013)

3/26/2014

This function gets the PDP address for a particular context.

Syntax

HRESULT RIL_GetGPRSAddress(
  HRIL hRil,
  DWORD dwContextID,
  WCHAR* pwszGPRSAddress,
  DWORD pGprsAddrCch
);

Parameters

  • dwContextID
    Specifies the context identifier.
  • pwszGPRSAddress
    Returns the GPRS address.
  • pGprsAddrCch

    • Asynchronous
      [in]NULL.
    • Synchronous
      [in] Specifies the character count of the buffer pointed to by pwszGPRSAddress.
      [out] Specifies the number of characters copied, including terminating null characters or the required character count of the buffer including terminating null characters.

Return Value

Asynchronous

Positive HRESULT values indicate success and are used as command identifications for matching the asynchronous call result. Negative HRESULT values indicate an error. HRESULT error values of E_XXX are defined in winerror.h. HRESULT error values of RIL_E_XXX are defined in Ril.h.

An asynchronous result callback of RIL_RESULT_OK indicates success. The lpData notification parameter points to an array of WCHAR values that indicate the address.

Synchronous

HRESULT value S_OK indicates success. Information is returned in the data structure pointed to by pGprsAddrCch. HRESULT values of E_XXX indicate an error. Errors are defined in winerror.h.

Remarks

This function is asynchronous when the input value of pGprsAddrCch is NULL. The RIL proxy translates the RIL_GetGPRSAddress function into IOCTL_RIL_GetGPRSAddress when the RIL proxy calls RIL_IOControl.

This function is synchronous when pGprsAddrCch is not set to NULL. The RIL driver must also support RIL_NOTIFY_GETGPRSAddress for the synchronous function. In the registry key HKEY_LOCAL_MACHINE\Comm\Cellular\RIL\CapsNotificationImplParams, the value RIL_CAPS_NOTIFICATION_GPRSADDRESS is used to determine if RIL_NOTIFY_GETGPRSAddress is supported. If the RIL_CAPS_NOTIFICATION_GPRSADDRESS value is not set to TRUE, RIL_E_SYNCHRONOUS_DATA_UNAVAILABLE is returned. You can use RIL_GetDevCaps (hRil, RIL_CAPSTYPE_NOTIFICATIONIMPLEMENTATION) to determine which notification values are set to TRUE.

Requirements

Header

ril.h

Library

Ril.lib

See Also

Reference

RIL Functions
RIL_Initialize