# Class DeviceInfo#getWifiList

DeviceInfo

- Defined in: deviceInfo.js

Class Summary
Constructor Attributes | Constructor Name and Description
--- | ---
| DeviceInfo#getWifiList(successCallback, errorCallback) Gets list of detected wifi networks.

## Class Detail

DeviceInfo#getWifiList(successCallback, errorCallback)
Gets list of detected wifi networks.

    // Javascript code
    function getWifiList () {
      function successCb(cbObject) {

         console.log("cbObject : " + JSON.stringify(cbObject));

         for(var i=0; i < cbObject.networkInfo.length; i++) {
             console.log("network info : ssid " + cbObject.networkInfo[i].ssid);
             console.log("network info : signalLevel " + cbObject.networkInfo[i].signalLevel);
         }
      }

      function failureCb(cbObject) {
         var errorCode = cbObject.errorCode;
         var errorText = cbObject.errorText;
         console.log ("Error Code [" + errorCode + "]: " + errorText);
      }

      var deviceInfo = new DeviceInfo();
      deviceInfo.getWifiList(successCb, failureCb);
    }

Parameters:
{Function} successCallback
  success callback function.
{Function} errorCallback
  failure callback function.

Since:
  1.3
Returns:
  {Object}

  Property | Type | Description
  --- | --- | ---
  networkInfo | Array | Array of Wifi network information objects
  networkInfo.signalLevel | Number | Signal level (0 ~ 100)
  networkInfo.ssid | String | SSID

See:
  DeviceInfo.connectWifi()