Course Content

If you are facing any issue in playing video please use Firefox browser.

Course Content

Description

Wi-Fi in Android

 

In today's video our topic is Wi-Fi in Android.

Wi-Fi facility is now very easily accessible and people are using it in their PC's, Smartphones, laptops etc... Even any non technical person is now using Wi-Fi and know how to use it.

Wi-Fi is the name of a popular wireless networking technology that uses radio waves to provide wireless high speed internet and network connections. Wi-Fi is simply a trademark phrased that means IEEE 802.11x.

The Wi-Fi alliance, the organisation that owns the Wi-Fi registered trademark term specifically defines Wi-Fi as any 'wireless local area network products that are based on the Institute of Electrical and Electronics Engineers' (IEEE) 802.11 standards'

Wi-Fi works with no physical wired connection between sender and receiver by using radio frequency technology. Wi-Fi would work within a range and all the devices which falls within this range can use it.

Applications in our Android can access almost all the information of a Wi-Fi connection.

Android provides WifiManager API to manage all aspects of Wi-Fi connectivity. We can instantiate this class by calling getSystemService method.

Syntax:

WifiManager mainWifiObj;

mainWifiObj=(WifiManager) getSystemService(Context.WIFI_SERVICE);

In order to scan a list of wireless networks, you also need to register your BroadcastReceiver. It can be registered using RegisterReceiver method with the argument of your receiver class object.

The Wi-Fi scan method can be started by calling the startScan method of the WifiManager class. This method returns a list of ScanResult objects.

Syntax :

List<ScanResult>wifiScanList=mainWifiObj.getScanResults();

String data=wifiScanList.get(0).toString();

We have different methods of WifiManager class, such as addNetwork(WifiConfiguration config), disconnet(), getWifiState(), isWifiEnabled().

FAQs

Recommended Courses

Share With Friend

Have a friend to whom you would want to share this course?

Download The Apps

Code Scan or Download the app
Google Play Store
297K+ Downloads
4.5 Rating
10K+ Reviews
  • Learn anywhere on the go
  • Get regular updates about your enrolled or new courses
  • Share content with your friends
  • Evaluate your progress through practice tests
  • No internet connection needed
  • Enroll for the webinar and join at the time of the webinar from anywhere