AirPcap functions


Functions

void AirpcapGetVersion (PUINT VersionMajor, PUINT VersionMinor, PUINT VersionRev, PUINT VersionBuild)
 Return a string with the API version.
PCHAR AirpcapGetLastError (PAirpcapHandle AdapterHandle)
 Return the last error related to the specified handle.
BOOL AirpcapGetDeviceList (PAirpcapDeviceDescription *PPAllDevs, PCHAR Ebuf)
 Return the list of available devices.
VOID AirpcapFreeDeviceList (PAirpcapDeviceDescription PAllDevs)
 Free a list of devices returned by AirpcapGetDeviceList().
PAirpcapHandle AirpcapOpen (PCHAR DeviceName, PCHAR Ebuf)
 Open an adapter.
VOID AirpcapClose (PAirpcapHandle AdapterHandle)
 Close an adapter.
BOOL AirpcapSetLinkType (PAirpcapHandle AdapterHandle, AirpcapLinkType NewLinkType)
 Set the link type of an adapter.
BOOL AirpcapGetLinkType (PAirpcapHandle AdapterHandle, PAirpcapLinkType PLinkType)
 Get the link type of the specified adapter.
BOOL AirpcapSetFcsPresence (PAirpcapHandle AdapterHandle, BOOL IsFcsPresent)
 Configures the adapter on whether to include the MAC Frame Check Sequence in the captured packets.
BOOL AirpcapGetFcsPresence (PAirpcapHandle AdapterHandle, PBOOL PIsFcsPresent)
 Returns TRUE if the specified adapter includes the MAC Frame Check Sequence in the captured packets.
BOOL AirpcapSetFcsValidation (PAirpcapHandle AdapterHandle, AirpcapValidationType ValidationType)
 Configures the adapter to accept or drop frames with an incorrect Frame Check sequence (FCS).
BOOL AirpcapGetFcsValidation (PAirpcapHandle AdapterHandle, PAirpcapValidationType ValidationType)
 Checks if the specified adapter is configured to capture frames with incorrect an incorrect Frame Check Sequence (FCS).
BOOL AirpcapSetDeviceKeys (PAirpcapHandle AdapterHandle, PAirpcapKeysCollection KeysCollection)
 Set the list of decryption keys that the driver is going to use with the specified device.
BOOL AirpcapGetDeviceKeys (PAirpcapHandle AdapterHandle, PAirpcapKeysCollection KeysCollection, PUINT PKeysCollectionSize)
 Returns the list of decryption keys in the driver that are currently associated with the specified device.
BOOL AirpcapSetDecryptionState (PAirpcapHandle AdapterHandle, AirpcapDecryptionState Enable)
 Turns on or off the decryption of the incoming frames.
BOOL AirpcapGetDecryptionState (PAirpcapHandle AdapterHandle, PAirpcapDecryptionState PEnable)
 Tells if this open instance is configured to perform the decryption of the incoming frames.
BOOL AirpcapSetDeviceChannel (PAirpcapHandle AdapterHandle, UINT Channel)
 Set the radio channel of a device.
BOOL AirpcapGetDeviceChannel (PAirpcapHandle AdapterHandle, PUINT PChannel)
 Get the radio channel of a device.
BOOL AirpcapSetKernelBuffer (PAirpcapHandle AdapterHandle, UINT BufferSize)
 Set the size of the kernel packet buffer for this adapter.
BOOL AirpcapGetKernelBufferSize (PAirpcapHandle AdapterHandle, PUINT PSizeBytes)
 Get the size of the kernel packet buffer for this adapter.
BOOL AirpcapStoreCurConfigAsAdapterDefault (PAirpcapHandle AdapterHandle)
 Saves the configuration of the specified adapter in the registry, so that it becomes the default for this adapter.
BOOL AirpcapSetFilter (PAirpcapHandle AdapterHandle, PVOID Instructions, UINT Len)
 Set the BPF kernel filter for an adapter.
BOOL AirpcapGetMacAddress (PAirpcapHandle AdapterHandle, PAirpcapMacAddress PMacAddress)
 Return the MAC address of an adapter.
BOOL AirpcapSetMinToCopy (PAirpcapHandle AdapterHandle, UINT MinToCopy)
 Set the mintocopy parameter for an open adapter.
BOOL AirpcapGetReadEvent (PAirpcapHandle AdapterHandle, HANDLE *PReadEvent)
 Gets an event that is signaled when that is signalled when packets are available in the kernel buffer (see AirpcapSetMinToCopy()).
BOOL AirpcapRead (PAirpcapHandle AdapterHandle, PBYTE Buffer, UINT BufSize, PUINT PReceievedBytes)
 Fills a user-provided buffer with zero or more packets that have been captured on the referenced adapter.
BOOL AirpcapGetStats (PAirpcapHandle AdapterHandle, PAirpcapStats PStats)
 Get per-adapter WinPcap-compatible capture statistics.
BOOL AirpcapGetLedsNumber (PAirpcapHandle AdapterHandle, PUINT NumberOfLeds)
 Get the number of LEDs the referenced adapter has available.
BOOL AirpcapTurnLedOn (PAirpcapHandle AdapterHandle, UINT LedNumber)
 Turn on one of the adapter's LEDs.
BOOL AirpcapTurnLedOff (PAirpcapHandle AdapterHandle, UINT LedNumber)
 Turn off one of the adapter's LEDs.

Function Documentation

void AirpcapGetVersion PUINT  VersionMajor,
PUINT  VersionMinor,
PUINT  VersionRev,
PUINT  VersionBuild
 

Return a string with the API version.

Parameters:
VersionMajor Pointer to a variable that will be filled with the major version number.
VersionMinor Pointer to a variable that will be filled with the minor version number.
VersionRev Pointer to a variable that will be filled with the revision number.
VersionBuild Pointer to a variable that will be filled with the build number.

PCHAR AirpcapGetLastError PAirpcapHandle  AdapterHandle  ) 
 

Return the last error related to the specified handle.

Parameters:
AdapterHandle Handle to an open adapter.
Returns:
The string with the last error.

BOOL AirpcapGetDeviceList PAirpcapDeviceDescription PPAllDevs,
PCHAR  Ebuf
 

Return the list of available devices.

Parameters:
PPAllDevs Address to a caller allocated pointer. On success this pointer will receive the head of a list of available devices.
Ebuf String that will contain error information if FALSE is returned. The size of the string must be AIRPCAP_ERRBUF_SIZE bytes.
Returns:
TRUE on success. FALSE is returned on failure, in which case Ebuf is filled in with an appropriate error message.
Here's a snppet of code that shows how to use AirpcapGetDeviceList():

    CHAR Ebuf[AIRPCAP_ERRBUF_SIZE];
    AirpcapDeviceDescription *Desc, *tDesc;

    if(AirpcapGetDeviceList(&Desc, Ebuf) == -1)
    {
        printf("Unable to get the list of devices: %s\n", Ebuf);
        return -1;
    }
    
    for(tDesc = Desc; tDesc; tDesc = tDesc->next)
    {
        printf("%u) %s (%s)\n",
        ++i,
        tDesc->Name,
        tDesc->Description);
    }

VOID AirpcapFreeDeviceList PAirpcapDeviceDescription  PAllDevs  ) 
 

Free a list of devices returned by AirpcapGetDeviceList().

Parameters:
PAllDevs Head of the list of devices returned by AirpcapGetDeviceList().

PAirpcapHandle AirpcapOpen PCHAR  DeviceName,
PCHAR  Ebuf
 

Open an adapter.

Parameters:
DeviceName Name of the device to open. Use AirpcapGetDeviceList() to get the list of devices.
Ebuf String that will contain error information in case of failure. The size of the string must be AIRPCAP_ERRBUF_SIZE bytes.
Returns:
A PAirpcapHandle handle on success. NULL is returned on failure, in which case Ebuf is filled in with an appropriate error message.

VOID AirpcapClose PAirpcapHandle  AdapterHandle  ) 
 

Close an adapter.

Parameters:
AdapterHandle Handle to the adapter to close.

BOOL AirpcapSetLinkType PAirpcapHandle  AdapterHandle,
AirpcapLinkType  NewLinkType
 

Set the link type of an adapter.

Parameters:
AdapterHandle Handle to the adapter.
NewLinkType the "link type", i.e. the format of the frames that will be received from the adapter.
Returns:
TRUE on success.
the "link type" determines how the driver will encode the packets captured from the network. Aircap supports two link types:
  • AIRPCAP_LT_802_11, to capture 802.11 frames (including control frames) without any power information. Look at the Capture_no_radio example application in the developer's pack for a reference on how to decode 802.11 frames with this link type.
  • AIRPCAP_LT_802_11_PLUS_RADIO, to capture 802.11 frames (including control frames) with a radiotap header that contains power and channel information. More information about the radiotap header can be found int the Information About the Radiotap Header section. Moreover, the "Capture_radio" example application in the developer's pack can be used as a reference on how to decode 802.11 frames with radiotap headers.

BOOL AirpcapGetLinkType PAirpcapHandle  AdapterHandle,
PAirpcapLinkType  PLinkType
 

Get the link type of the specified adapter.

Parameters:
AdapterHandle Handle to the adapter.
PLinkType Pointer to a caller allocated AirpcapLinkType variable that will contain the link type of the adapter.
Returns:
TRUE on success.
the "link type" determines how the driver will encode the packets captured from the network. Aircap supports two link types:
  • AIRPCAP_LT_802_11, to capture 802.11 frames (including control frames) without any power information. Look at the Capture_no_radio example application in the developer's pack for a reference on how to decode 802.11 frames with this link type.
  • AIRPCAP_LT_802_11_PLUS_RADIO, to capture 802.11 frames (including control frames) with a radiotap header that contains power and channel information. More information about the radiotap header can be found int the Information About the Radiotap Header section. Moreover, the "Capture_radio" example application in the developer's pack can be used as a reference on how to decode 802.11 frames with radiotap headers.

BOOL AirpcapSetFcsPresence PAirpcapHandle  AdapterHandle,
BOOL  IsFcsPresent
 

Configures the adapter on whether to include the MAC Frame Check Sequence in the captured packets.

Parameters:
AdapterHandle Handle to the adapter.
IsFcsPresent TRUE if the packets should include the FCS. FALSE otherwise
Returns:
TRUE on success.
In the default configuration, the adapter includes the FCS in the captured packets. The MAC Frame Check Sequence is 4 bytes and is located at the end of the 802.11 packet, with both AIRPCAP_LT_802_11 and AIRPCAP_LT_802_11_PLUS_RADIO link types. When the FCS inclusion is turned on, and if the link type is AIRPCAP_LT_802_11_PLUS_RADIO, the radiotap header that precedes each frame has two additional fields at the end: Padding and FCS. These two fields are not present when FCS inclusion is off.

BOOL AirpcapGetFcsPresence PAirpcapHandle  AdapterHandle,
PBOOL  PIsFcsPresent
 

Returns TRUE if the specified adapter includes the MAC Frame Check Sequence in the captured packets.

Parameters:
AdapterHandle Handle to the adapter.
PIsFcsPresent User-provided variable that will be set to true if the adapter is including the FCS.
Returns:
TRUE if the operation is successful. FALSE otherwise.
In the default configuration, the adatper has FCS inclusion turned on. The MAC Frame Check Sequence is 4 bytes and is located at the end of the 802.11 packet, with both AIRPCAP_LT_802_11 and AIRPCAP_LT_802_11_PLUS_RADIO link types. When the FCS inclusion is turned on, and if the link type is AIRPCAP_LT_802_11_PLUS_RADIO, the radiotap header that precedes each frame has two additional fields at the end: Padding and FCS. These two fields are not present when FCS inclusion is off.

BOOL AirpcapSetFcsValidation PAirpcapHandle  AdapterHandle,
AirpcapValidationType  ValidationType
 

Configures the adapter to accept or drop frames with an incorrect Frame Check sequence (FCS).

Parameters:
AdapterHandle Handle to the adapter.
ValidationType The type of validation the driver will perform. See the documentation of AirpcapValidationType for details.
Returns:
TRUE on success.
Note:
By default, the driver is configured in AIRPCAP_VT_ACCEPT_EVERYTHING mode.

BOOL AirpcapGetFcsValidation PAirpcapHandle  AdapterHandle,
PAirpcapValidationType  ValidationType
 

Checks if the specified adapter is configured to capture frames with incorrect an incorrect Frame Check Sequence (FCS).

Parameters:
AdapterHandle Handle to the adapter.
ValidationType Pointer to a user supplied variable that will contain the type of validation the driver will perform. See the documentation of AirpcapValidationType for details.
Returns:
TRUE if the operation is succesful. FALSE otherwise.
Note:
By default, the driver is configured in AIRPCAP_VT_ACCEPT_EVERYTHING mode.

BOOL AirpcapSetDeviceKeys PAirpcapHandle  AdapterHandle,
PAirpcapKeysCollection  KeysCollection
 

Set the list of decryption keys that the driver is going to use with the specified device.

Parameters:
AdapterHandle Handle an open adapter instance.
KeysCollection Pointer to a PAirpcapKeysCollection structure that contains the keys to be set in the driver.
Returns:
TRUE if the operation is successful. FALSE otherwise.
The AirPcap driver is able to use a set of decryption keys to decrypt the traffic transmitted on a specific SSID. If one of the keys corresponds to the one the frame has been encrypted with, the driver will perform decryption and return the cleartext frames to the application. The driver supports, for every device, multiple keys at the same time.

At this time, the only supported decryption method is WEP.

The configured decryption keys are device-specific: they will not be used by other airpcap devices besides the specified one.

The keys are applied to the packets in the same order they appear in the KeysCollection structure until the packet is correctly decrypted, therefore putting frequently used keys at the beginning of the structure improves performance.

Note:
: this is a Device-related function: when you change the channel from an open capture instance, the change will be immediately reflected on all the other capture instances.

BOOL AirpcapGetDeviceKeys PAirpcapHandle  AdapterHandle,
PAirpcapKeysCollection  KeysCollection,
PUINT  PKeysCollectionSize
 

Returns the list of decryption keys in the driver that are currently associated with the specified device.

Parameters:
AdapterHandle Handle to an open adapter instance.
KeysCollection User-allocated PAirpcapKeysCollection structure that will be filled with the keys.
PKeysCollectionSize IN: pointer to a user-allocated variable that contains the length of the KeysCollection structure, in bytes. OUT: amount of data moved by the driver in the buffer pointed by KeysBuffer, in bytes.
Returns:
TRUE if the operation is succesful. If an error occurs, the return value is FALSE and KeysCollectionSize is zero. If the provided buffer is too small to contain the keys, the return value is FALSE and KeysCollectionSize contains the needed KeysCollection length, in bytes. If the device doesn't have any decryption key configured, the return value is TRUE, and KeysCollectionSize will be zero.
This function returns the list of decryption keys in the driver that are associated with the specified device. The AirPcap driver is able to use a set of decryption keys to decrypt the traffic transmitted on a specific SSID. If one of the keys corresponds to the one the frame has been encrypted with, the driver will perform decryption and return the cleartext frames to the application. The driver supports, for every device, multiple keys at the same time.

The configured decryption keys are device-specific, therefore AirpcapGetDeviceKeys() will return a different set of keys when called on different devices.

At this time, the only supported decryption method is WEP.

Note:
: this is a Device-related function: when you change the channel from an open capture instance, the change will be immediately reflected on all the other capture instances.

BOOL AirpcapSetDecryptionState PAirpcapHandle  AdapterHandle,
AirpcapDecryptionState  Enable
 

Turns on or off the decryption of the incoming frames.

Parameters:
AdapterHandle Handle to the adapter.
ValidationType Either AIRPCAP_DECRYPTION_ON or AIRPCAP_DECRYPTION_OFF
Returns:
TRUE on success.
The decryption keys can be configured with the AirpcapSetDeviceKeys() function.
Note:
By default, the driver is configured with AIRPCAP_DECRYPTION_ON.

BOOL AirpcapGetDecryptionState PAirpcapHandle  AdapterHandle,
PAirpcapDecryptionState  PEnable
 

Tells if this open instance is configured to perform the decryption of the incoming frames.

Parameters:
AdapterHandle Handle to the adapter.
ValidationType Pointer to a user supplied variable that will contain the decryption configuration. See PAirpcapDecryptionState for details.
Returns:
TRUE if the operation is succesful. FALSE otherwise.
The decryption keys can be configured with the AirpcapSetDeviceKeys() function.
Note:
By default, the driver is configured with AIRPCAP_DECRYPTION_ON.

BOOL AirpcapSetDeviceChannel PAirpcapHandle  AdapterHandle,
UINT  Channel
 

Set the radio channel of a device.

Parameters:
AdapterHandle Handle to the adapter.
Channel the new channel to set.
Returns:
TRUE on success.
Valid channels are in the range 1-14. The default channel setting is 6.

Note:
: this is a Device-related function: when you change the channel from an open capture instance, the change will be immediately reflected on all the other capture instances.

BOOL AirpcapGetDeviceChannel PAirpcapHandle  AdapterHandle,
PUINT  PChannel
 

Get the radio channel of a device.

Parameters:
AdapterHandle Handle to the adapter.
PChannel Pointer to a user-supplied variable into which the function will copy the currently configured radio channel.
Returns:
TRUE on success.
Valid channels are in the range 1-14. The default channel setting is 6.

Note:
: this is a Device-related function: when you change the channel from an open capture instance, the change will be immediately reflected on all the other capture instances.

BOOL AirpcapSetKernelBuffer PAirpcapHandle  AdapterHandle,
UINT  BufferSize
 

Set the size of the kernel packet buffer for this adapter.

Parameters:
AdapterHandle Handle to the adapter.
BufferSize New size, in bytes.
Returns:
TRUE on success.
Every AirPcap open instance has an associated kernel buffer, whose default size is 1 Mbyte. This function can be used to change the size of this buffer, and can be called at any time. A bigger kernel buffer size decreases the risk of dropping packets during network bursts or when the application is busy, at the cost of higher kernel memory usage.

Note:
: don't use this function unless you know what you are doing. Due to chaching issues and bigger non-paged memory consumption, Bigger buffer sizes can decrease the capture performace instead of improving it.

BOOL AirpcapGetKernelBufferSize PAirpcapHandle  AdapterHandle,
PUINT  PSizeBytes
 

Get the size of the kernel packet buffer for this adapter.

Parameters:
AdapterHandle Handle to the adapter.
PSizeBytes User-allocated variable that will be filled with the size of the kernel buffer.
Returns:
TRUE on success.
Every AirPcap open instance has an associated kernel buffer, whose default size is 1 Mbyte. This function can be used to get the size of this buffer.

BOOL AirpcapStoreCurConfigAsAdapterDefault PAirpcapHandle  AdapterHandle  ) 
 

Saves the configuration of the specified adapter in the registry, so that it becomes the default for this adapter.

Parameters:
AdapterHandle Handle to the adapter.
Returns:
TRUE on success. FALSE on failure.
Almost all the AirPcap calls that modify the configuration (AirpcapSetLinkType(), AirpcapSetFcsPresence(), AirpcapSetFcsValidation(), AirpcapSetKernelBuffer(), AirpcapSetMinToCopy()) affect only the referenced AirPcap open instance. This means that if you do another AirpcapOpen() on the same adapter, the configuration changes will not be remembered, and the new adapter handle will have default configuration settings.

Exceptions to this rule are the AirpcapSetDeviceChannel() and AirpcapSetDeviceKeys() functions: a channel change is reflected on all the open instances, and remembered until the next call to AirpcapSetDeviceChannel(), until the adapter is unplugged, or until the machine is powered off. Same thing for the configuration of the WEP keys.

AirpcapStoreCurConfigAsAdapterDefault() stores the configuration of the give open instance as the default for the adapter: all the instances opened in the future will have the same configuration that this adapter currently has. The configuration is stored in the registry, therefore it is remembered even when the adapter is unplugged or the machine is turned off. However, an adapter doesn't bring its configuration with it from machine to machine.

the configuration information saved in the registry includes the following parameters:

  • channel
  • kernel buffer size
  • mintocopy
  • link type
  • CRC presence
  • Encryption keys
  • Encryption Enabled/Disabled state

The configuration is adapter-specific. This means that changing the configuration of an adapter doesn't modify the one of the other adapters that are currently used or that will be used in the future.

Note:
AirpcapStoreCurConfigAsAdapterDefault() must have exclusive access to the adapter -- it will fail if more than one AirPcap handle is opened at the same time for this adapter. AirpcapStoreCurConfigAsAdapterDefault() needs administrator privileges. It will fail if the calling user is not a local machine administrator.

BOOL AirpcapSetFilter PAirpcapHandle  AdapterHandle,
PVOID  Instructions,
UINT  Len
 

Set the BPF kernel filter for an adapter.

Parameters:
AdapterHandle Handle to the adapter.
Instructions pointer to the first BPF instruction in the array. Corresponds to the bf_insns in a bpf_program structure (see the WinPcap documentation at http://www.winpcap.org/devel.htm).
Len Number of instructions in the array pointed by the previous field. Corresponds to the bf_len in a a bpf_program structure (see the WinPcap documentation at http://www.winpcap.org/devel.htm).
Returns:
TRUE on success.
The AirPcap driver is able to perform kernel-level filtering using the standard BPF pseudo-machine format. You can read the WinPcap documentation at http://www.winpcap.org/devel.htm for more details on the BPF filtering mechaism.

A filter can be automatically created by using the pcap_compile() function of the WinPcap API. This function converts a human readable text expression with the tcpdump/libpcap syntax into a BPF program. If your program doesn't link wpcap, but you need to generate the code for a particular filter, you can run WinDump with the -d or -dd or -ddd flags to obtain the pseudocode.

BOOL AirpcapGetMacAddress PAirpcapHandle  AdapterHandle,
PAirpcapMacAddress  PMacAddress
 

Return the MAC address of an adapter.

Parameters:
AdapterHandle Handle to the adapter.
PMacAddress Pointer to a user allocated MAC address. The size of this buffer needs to be at least 6 bytes.
Returns:
TRUE on success.

BOOL AirpcapSetMinToCopy PAirpcapHandle  AdapterHandle,
UINT  MinToCopy
 

Set the mintocopy parameter for an open adapter.

Parameters:
AdapterHandle Handle to the adapter.
MinToCopy is the mintocopy size in bytes.
Returns:
TRUE on success.
When the number of bytes in the kernel buffer changes from less than mintocopy bytes to greater than or equal to mintocopy bytes, the read event is signalled (see AirpcapGetReadEvent()). A high value for mintocopy results in poor responsiveness since the driver may signal the application "long" after the arrival of the packet. And a high value results in low CPU loading by minimizing the number of user/kernel context switches. A low MinToCopy results in good responsiveness since the driver will signal the application close to the arrival time of the packet. This has higher CPU loading over the first approach.

BOOL AirpcapGetReadEvent PAirpcapHandle  AdapterHandle,
HANDLE *  PReadEvent
 

Gets an event that is signaled when that is signalled when packets are available in the kernel buffer (see AirpcapSetMinToCopy()).

Parameters:
AdapterHandle Handle to the adapter.
PReadEvent Pointer to a user-supplied handle that in which the read event will be copied.
Returns:
TRUE on success.
Note:
the event is signalled when at least mintocopy bytes are present in the kernel buffer (see AirpcapSetMinToCopy()). This event can be used by WaitForSingleObject() and WaitForMultipleObjects() to create blocking behavior when reading packets from one or more adapters (see AirpcapRead()).

BOOL AirpcapRead PAirpcapHandle  AdapterHandle,
PBYTE  Buffer,
UINT  BufSize,
PUINT  PReceievedBytes
 

Fills a user-provided buffer with zero or more packets that have been captured on the referenced adapter.

Parameters:
AdapterHandle Handle to the adapter.
Buffer pointer to the buffer that will be filled with captured packets.
BufSize size of the input buffer that will contain the packets, in bytes.
PReceievedBytes Pointer to a user supplied variable that will receive the number of bytes copied by AirpcapRead. Can be smaller than BufSize.
Returns:
TRUE on success.
802.11 frames are returned by the driver in buffers. Every 802.11 frame in the buffer is preceded by a AirpcapBpfHeader structure. The suggested way to use an AirPcap adapter is through the pcap API exported by wpcap.dll. If this is not possible, the Capture_radio and Capture_no_radio examples in the AirPcap developer's pack show how to properly decode the packets in the read buffer returned by AirpcapRead().

Note:
this function is NOT blocking. Blocking behavior can be obtained using the event returned by AirpcapGetReadEvent(). See also AirpcapSetMinToCopy().

BOOL AirpcapGetStats PAirpcapHandle  AdapterHandle,
PAirpcapStats  PStats
 

Get per-adapter WinPcap-compatible capture statistics.

Parameters:
AdapterHandle Handle to the adapter.
PStats pointer to a user-allocated AirpcapStats structure that will be filled with statistical information.
Returns:
TRUE on success.

BOOL AirpcapGetLedsNumber PAirpcapHandle  AdapterHandle,
PUINT  NumberOfLeds
 

Get the number of LEDs the referenced adapter has available.

Parameters:
AdapterHandle Handle to the adapter.
NumberOfLeds Number of LEDs available on this adapter.
Returns:
TRUE on success.

BOOL AirpcapTurnLedOn PAirpcapHandle  AdapterHandle,
UINT  LedNumber
 

Turn on one of the adapter's LEDs.

Parameters:
AdapterHandle Handle to the adapter.
LedNumber zero-based identifier of the LED to turn on.
Returns:
TRUE on success.

BOOL AirpcapTurnLedOff PAirpcapHandle  AdapterHandle,
UINT  LedNumber
 

Turn off one of the adapter's LEDs.

Parameters:
AdapterHandle Handle to the adapter.
LedNumber zero-based identifier of the LED to turn off.
Returns:
TRUE on success.


AirPcap documentation. Copyright (c) 2006 CACE Technologies. All rights reserved.