Radio Services
[WiFi Middleware]


Functions

alp_status_t alp_wifi_bitrate_get (AlpWifiContext *wifi_context, int *bitrate)
void alp_wifi_close (AlpWifiContext *wifi_context)
alp_status_t alp_wifi_get_channel (AlpWifiContext *wifi_context, unsigned char *channel)
alp_status_t alp_wifi_get_device_information (AlpWifiContext *wifi_context, AlpWifiDeviceInformation *device_info)
alp_status_t alp_wifi_get_essid (AlpWifiContext *wifi_context, char *essid)
alp_status_t alp_wifi_get_mac_address (AlpWifiContext *wifi_context, char *mac_address)
AlpWifiContextalp_wifi_open ()
alp_status_t alp_wifi_power_set_state (AlpWifiContext *wifi_context, bool activate)
alp_status_t alp_wifi_radio_get_state (AlpWifiContext *wifi_context, bool *radio_enabled)
alp_status_t alp_wifi_radio_set_state (AlpWifiContext *wifi_context, bool radio_enabled)
alp_status_t alp_wifi_scan_get (AlpWifiContext *wifi_context, AlpWifiAccessPoint **discovered_ap, int *size)
alp_status_t alp_wifi_scan_refresh (AlpWifiContext *wifi_context, bool synchronous)
alp_status_t alp_wifi_signal_get_level (AlpWifiContext *wifi_context, unsigned char *signal_level)


Function Documentation

alp_status_t alp_wifi_bitrate_get AlpWifiContext wifi_context,
int *  bitrate
 

Retrieve several informations about the Wifi device

Parameters:
[in,out] wifi_context an open Wifi context (must be not NULL)
[out] bitrate default bitrate in Mbits (must be not NULL)
Returns:
ALP_STATUS_WIFI_NO_ERROR or an error code if any

void alp_wifi_close AlpWifiContext wifi_context  ) 
 

Close the WiFi context and free all data

Parameters:
[in,out] wifi_context an open Wifi context (must be not NULL)

alp_status_t alp_wifi_get_channel AlpWifiContext wifi_context,
unsigned char *  channel
 

Retrieve the current channel if connected

Parameters:
[in,out] wifi_context an open Wifi context (must be not NULL)
[out] channel the level of signal between 1 and 14 (must be not NULL)
Returns:
ALP_STATUS_WIFI_NO_ERROR or an error code if any

alp_status_t alp_wifi_get_device_information AlpWifiContext wifi_context,
AlpWifiDeviceInformation device_info
 

Retrieve several informations about the Wifi device

Parameters:
[in,out] wifi_context an open Wifi context (must be not NULL)
[out] device_info informations about the Wifi device (must be not NULL)
Returns:
ALP_STATUS_WIFI_NO_ERROR or an error code if any
Remarks:
depending on the device and how the radio is shutting down, MAC address could be set to the empty string when the radio is off

alp_status_t alp_wifi_get_essid AlpWifiContext wifi_context,
char *  essid
 

Retrieve the current ESSID

Parameters:
[in,out] wifi_context an open Wifi context (must be not NULL)
[out] essid the current essid which can contains ALP_WIFI_ESSID_SIZE characters (including '', must be not NULL)
Returns:
ALP_STATUS_WIFI_NO_ERROR or an error code if any

alp_status_t alp_wifi_get_mac_address AlpWifiContext wifi_context,
char *  mac_address
 

Retrieve the MAC address of the Wifi device

Parameters:
[in,out] wifi_context an open Wifi context (must be not NULL)
[out] mac_address the MAC address (with a size at least ALP_WIFI_MAC_ADDRESS_SIZE)
Returns:
ALP_STATUS_WIFI_NO_ERROR or an error code if any

AlpWifiContext* alp_wifi_open  ) 
 

Open a WiFi context in order to use some services on the device

Returns:
a valid WiFi context or NULL if error
Remarks:
the context must be freed using alp_wifi_close()

alp_status_t alp_wifi_power_set_state AlpWifiContext wifi_context,
bool  activate
 

Set the power management ON or OFF

Parameters:
[in,out] wifi_context an open Wifi context (must be not NULL)
[in] activate true for PM ON
Returns:
ALP_STATUS_WIFI_NO_ERROR or an error code if any

alp_status_t alp_wifi_radio_get_state AlpWifiContext wifi_context,
bool *  radio_enabled
 

Retrieve the Wifi radio status

Parameters:
[in,out] wifi_context an open Wifi context (must be not NULL)
[out] radio_enabled pointer on the radio state (true if ON, false if OFF, must be not NULL)
Returns:
ALP_STATUS_WIFI_NO_ERROR or an error code if any

alp_status_t alp_wifi_radio_set_state AlpWifiContext wifi_context,
bool  radio_enabled
 

Set the Wifi radio status

Parameters:
[in,out] wifi_context an open Wifi context (must be not NULL)
[in] radio_enabled true for ON, false for OFF
Returns:
ALP_STATUS_WIFI_NO_ERROR or an error code if any

alp_status_t alp_wifi_scan_get AlpWifiContext wifi_context,
AlpWifiAccessPoint **  discovered_ap,
int *  size
 

Retrieve the result of a Wifi scan

Parameters:
[in,out] wifi_context an open Wifi context (must be not NULL)
[out] discovered_ap list of access points
[out] discovered_ap size of the list of access points (or -1 of error)
Returns:
ALP_STATUS_WIFI_NO_ERROR or an error code if any
Remarks:
-use alp_wifi_scan_refresh before -don't forget to free the list of access points

alp_status_t alp_wifi_scan_refresh AlpWifiContext wifi_context,
bool  synchronous
 

Force the wifi driver to re-scan the area

Parameters:
[in,out] wifi_context an open Wifi context (must be not NULL)
[in] synchronous true to wait for the end of the scan
Returns:
ALP_STATUS_WIFI_NO_ERROR or an error code if any
Remarks:
the synchronous re-scan can take several seconds, the asynchronous re-scan can give incomplete scan results

alp_status_t alp_wifi_signal_get_level AlpWifiContext wifi_context,
unsigned char *  signal_level
 

Retrieve the current signal level if connected

Parameters:
[in,out] wifi_context an open Wifi context (must be not NULL)
[out] signal_level the level of signal between 0 and 4 (must be not NULL)
Returns:
ALP_STATUS_WIFI_NO_ERROR or an error code if any


Generated on Wed Jul 30 07:06:44 2008 by Doxygen 1.4.6 for ALP SDK + Hiker Documentation

Copyright © 1999-2008 ACCESS CO., LTD. All rights reserved.