# WMStartScanExCallback

## Definitions

  `#include <nitro/wm.h>`

      typedef struct WMStartScanExCallback
      {
      u16         apiid;
      u16         errcode;
      u16     wlCmdID;
      u16     wlResult;
      u16         state;
      u16         channelList;
      u16         bssDescCount;
      WMBssDesc*  bssDesc[ 16 ];
      u16         linkLevel[ 16 ];

      } WMStartScanExCallback;

## Elements

apiid | This is the ID of the API that acts as the source for the callback generation. It is synonymous to the `WMApiid` enumerated type. Here, it is fixed as `WM_APIID_START_SCAN`.
errcode | This is the result of the asynchronous process. It is synonymous to the `WMErrCode` enumerated type.
wlCmdID | If errcode is `WM_ERRCODE_FAILED`, this function will store the ID of the command that was in error in the wireless firmware.
wlResult | If errcode is `WM_ERRCODE_FAILED`, this function will store the code was the source of the error in the wireless firmware.
state | If `errcode` is `WM_ERRCODE_SUCCESS`, the `WM Cause Code` generated by the callback is stored. There are two causes: `WM_STATECODE_PARENT_NOT_FOUND`, `WM_STATECODE_PARENT_FOUND`.
channelList | Regardless of whether the parent device is found or not found, the list of the scanned channels will be stored in a bit field format.
bssDescCount | If the state is `WM_STATECODE_PARENT_FOUND`, the number of parent devices discovered will be stored here.
bssDesc | If the state is `WM_STATECODE_PARENT_FOUND`, a pointer array to the buffer where each item of parent device information is stored will be stored here. Data lengths of each item of parent device information from the discovered parent devices sometimes differ, so in order to efficiently save the information in buffers of limited sizes, the discovered parent device information will be stored inside a buffer. Therefore, be aware that this member is not a pointer to the top of the `WMBssDesc` type array; it is an array of pointers to the `WMBssDesc` type. The size of the data entity for each of the parent device information items is shown in `WMBssDesc`.length (half-word (u16) units).
linkLevel | When the state is `WM_STATECODE_PARENT_FOUND`, an array of the link strengths of each of the discovered parent devices is stored here.

## Description

This is a structure that is passed to the callback function for `WM_StartScanEx`.

## Revision History

03/02/2005 Added a description about the bssDesc member
02/14/2005 Initial version