Access wifi settings android

How to call Wi-Fi settings screen from my application using Android

Normally I am getting Wi-Fi setting screen on the emulator by clicking on the Settings > Wireless controls > wifi settings . I need to go directly to the Wi-Fi settings screen from my program when pressing on the Wi-Fi button which I have created. Contacts, Call Logs we can handle by using Intent.setData(android.provider.contacts. ). Is there any way to open settings sub-menus/menu from an android program?
Please give me advise or sample code on this.

9 Answers 9

Look at android.provider.Settings for a series of Intent actions you can use to launch various settings screens (e.g., ACTION_WIFI_SETTINGS ).

EDIT: Add the coding line.

to be more specific, android.app.activity.startActivity(new android.content.Intent.Intent(android.provider.settings.Settings.ACTION_WIFI_SETTINGS)); or with proper using, startActivity(new Intent(Settings.ACTION_WIFI_SETTINGS));

@Mr_and_Mrs_D: Possibly. I can see where the Settings app might not handle these Intents properly when the Settings app is already in memory, but I haven’t tried this specific scenario.

to open general wireless settings use this: startActivity(new Intent(Settings.ACTION_WIRELESS_SETTINGS));

@patrickjason91: «if it will be possible that the app’s Intent call can control some configuration to how the WiFi settings, or to any other settings screen in general, will display?» — not in general, and not using any documented extras.

Источник

Расширенные настройки Wi-Fi на Android-устройствах

Настройки Wi-Fi на Android устройствах, а на сегодняшний день это самый широкий рынок мобильных устройств – должен знать всякий владелец такого девайса. Существует несколько видов настроек:

Автоматическая настройка Wi-Fi сети на Android

Чаще всего пользователи системы Андроид, используют автонастройку доступа к беспроводной сети. Это показывает, что мобильный аппарат изначально настроен и готов к работе. Вам же потребуется только войти в раздел Wi-Fi на вашем аппарате и активировать Wi-Fi модуль.

Подключение Wi-Fi на Андроид

После включения модуля, система начнет искать возможные подключения и выдаст вам целый список доступных. Выберите интересующее подключение и если для синхронизации потребуется пароль, то введите его в отдельное поле.

Расширенные настройки сети Wi-Fi могут потребоваться, когда:

  • Беспроводная сеть, к которой вы собираетесь совершить подключение, скрыта от общего доступа.
  • Если в настройках доступа отключен протокол DHCP.

Ручная настройка Wi-Fi на Android

Для начала возьмите смартфон и перейдите в настройки Wi-Fi, после чего включите адаптер. После того как на экране возникнет список возможных подключений, у вас появится два варианта:

    Если требуется поменять конфигурацию уже имеющейся точки в связи со сменой настроек доступа, то найдите в списке, нужное название сети и удерживайте на ней палец, пока на экране не всплывет дополнительное меню. В нем и нужно выбрать функцию «Изменить конфигурацию сети Wi-Fi».

Читайте также:  Усилитель wifi своими руками банка

Удаление подключения Wi-Fi на Андроид

Добавление нового подключения Wi-Fi на Андроид

Ввод SSID сети на Андроид

Дополнительные параметры сети Wi-Fi на Андроид

Статические параметры сети Wi-Fi на Андроид

    IP-адрес – это адрес смартфона. Этот адрес должен оказаться в диапазоне, который указан в настройках точки доступа. Например, от 192.168.0.100 до 192.168.0.199. Иначе говоря, у вас имеется сотня вариантов. Изменению подвергается только конечное значение (100-199). Диапазон может быть менее широким. Да и сам адрес также может отличаться. Все эти особенности зависят от конфигураций маршрутизатора.

Ввод IP-адреса сети Wi-Fi на Андроид

Ввод шлюза сети Wi-Fi на Андроид

Ввод публичного шлюза сети Wi-Fi на Андроид

Настройка Wi-Fi на планшете или смартфоне с Андроид: Видео

Как сбросить настройки Wi-Fi

В самом начале нужно сказать, что вы изменяете конфигурацию только для выбранного подключения. То есть данные настройки не будут распространяться на остальные точки. Иначе говоря, чтобы сбросить конфигурацию Wi-Fi в вашем смартфоне для конкретного соединения, вам потребуется просто активировать модуль Wi-Fi и ту сеть, которую хотите удалить. В новом окне тапните на «Забыть сеть» или же нажмите на «Изменить конфигурацию».

Сброс сети Wi-Fi на Андроид

В первом варианте, конфигурации для этого подключения удалятся, и вам придется вводить пароль. Во втором варианте вы можете включить функцию DHCP в настройках IP. Она позволит вашему смартфону получать нужные настройки в автоматическом режиме.

Параметры сети Wi-Fi на Андроид

Откатить настройки Wi-Fi к первоначальному состоянию на Android автоматически невозможно. Все придется делать в ручном режиме. Но, так как в данном вопросе нет ничего сложного, то это не займет у вас много времени.

Источник

Understanding Android Wi-Fi Settings And Connections

Android tablets and most android mobile phones have the ability to connect to Wi-Fi wireless networks.

Wi-Fi is common wireless technology for connecting devices together on small business/home networks.

The same technology is used in public Wireless connection points, like coffee shops and hotels, for connecting to the Internet.

Before we look at how you setup and configure Wi-Fi on Android it is useful to have a basic understanding of how Wi-Fi networks work.

Wi-Fi Overview

Wi-Fi supports three connection modes:

Infrastructure mode is the most common and it is the mode used in home/business and public Wi-Fi networks.

Infrastructure mode requires a Wireless Access point which is usually provided by your home Wireless router.

The Access point forms the Wireless network, and all nodes or clients connect to the access point. See Setting up a home network.

The access point, and network is identified by a SSID or security identifier.

A Wi-Fi access point is also configured to use a preset Wireless channel. Commonly used channels are 1,6,11. See Wiki

If you are responsible for setting up your home Wi-Fi access point /router then you would the access point up to use a channel that isn’t being used by another access point in your location.

You can use wi-Fi test Apps on your device to see what channels are being used in your location.

Wi-Fi Connection Manager

Android phones and tablets come with a Wi-Fi Connection Manager, which lets you manage your Wi-Fi connections.

There are also many more sophisticated connection manager Apps available to download from the Google Play store.

The connection manager will automatically scan for Wi-Fi networks and lets you add and remove wireless connections.

To Open the connection manager go to Settings>Wireless and Network and press on the Wi-Fi Link.

Читайте также:  Минимальный сигнал вай фай

wi-fi-connection-manager

The connection manager will open and display a list of Wi-fi networks that are currently in range and their status, as well as Wi-Fi connections that have been saved.

wi-fi-connection-manager-networks

  • Connected – you are currently connected to this network
  • Saved– this network is already setup and you can connect to it
  • None– This network connection hasn’t been setup yet.
  • Out of range – Saved connection not in range.

To connect to a new network press the network name and enter the network password or passphrase if the network is secured.

wi-fi-connect-network

Once you have connected the connection settings are saved so that you don’t need to re-enter the password each time you connect.

If you don’t know the password then you might be able to use the WPS option if it is available on the Wireless Access Point (see later)

Older versions of the Android the connection manager show how the connection is secured, and if it supports WPS

android-wifi-wps-available

Secured and Unsecured Networks

Most networks are secured which means that you will need to enter a password or passphrase to connect to them.

On a secured network the network traffic is encrypted and not vulnerable to eavesdropping.

Most public networks use unsecured networks and don’t require a password to connect to them.

However some have a secondary login web page that you need to login to in orderto connect.

You should be careful when using any public networks even secured ones. See Connecting Your Android Tablet to Public Wi-Fi Hotspots

WPS Setup (Wi-FI Protected Setup)

Android supports WPS which lets you connect to a new network without having the manually enter a password.

However to use it your Wi-Fi router/access point must support it, and have it enabled.

The old connection manage shows the WPS link above the network list.

wps (wireless protected setup)

On Android 5 and above you need to press the more link and select advanced.

wifi-advanced-android

There are two option available the easiest and quickest is the push button option.

This again requires support at the Access point and you must have physical access to the access point to press it.

wifi-advanced-settings-android

This article explains the procedure in more detail.

Public Network Notifications

By default this option is enabled, and so when android detects a new unsecured network it will notify you. (screen shot above)

However it will not automatically connect to the network.

Moving With Android

As you move around with your tablet/phone you will come into range of other networks, some maybe new, others will already be saved. You will also fall out of range of the network you are currently connected to.

As you move and lose an existing connection Android will automatically connect to another saved network that is in range.

If it comes across a public network you will receive a notification and a prompt to allow you to connect.

There is a new feature available in Android 5.1 and above on Google nexus phones and tablets called Wi-Fi assist which will automatically connect you to trusted public networks that are available.

Читайте также:  Wi fi приставка кино

You can also get Apps from the app store that do the same thing.

Quickly Enable and Disable Wi-fi

You can tell whether or not Wi-Fi is enabled or disabled by looking in the system status area on the top right of the screen.

To enable or disable Wi-fi go to Settings>Wi-Fi>Wireless & Networks and toggle it on or off.

enable-disable-wifi

Viewing Your Saved Networks

You can see a list of all of your saved networks by going to Settings>wi-fi>Wireless & Networks. Press the more link (three vertical dots top right) and press saved networks.(Android 5 and above)

Removing a Saved Network

To Remove a network from the saved list click it and then click forget

remove-wifi-network

The next time you try to connect to that network you will need to enter the password.

Airplane Mode and Wi-Fi

airplane-mode-android

If you turn on Airplane mode which is a requirement when flying the Wi-fi and Bluetooth networks are disabled by default.

However you can enable them once you are in Airplane mode providing the operator allows this.

Here is a video which take your through the process:

Wi-Fi Direct

Wi-fi-direct

Wi-Fi direct allows you to connect two Wi_Fi equipped devices together without requiring an access point.

Essentially it works the same ways as Bluetooth but is much faster and is designed to be used for the same type of applications.

Here is a video from the Wi-Fi Alliance that explains how it works.

Here is video that shows you how to transfer files between phones using Wi-Fi direct and EFS file explorer.(skip to about 3:45.

Common Questions and Answers

Q- Will turning Off Wi-Fi save battery life?

A- Yes Next to the screen Wi-Fi is probably the next biggest drain on you battery and if you are reading Kindle Books on your Tablet you don’t really need to be connected to the Internet.

Q- I’m having trouble connecting in certain parts of my house?

A- Wi-fi signals don’t travel too well through walls and if you live in a large house then you may need install a second Wi-Fi access point to get a better coverage. See extending a home network on my other site.

If you have several access points in your house and find that you still have problems make sure you are connected to the access point that has the better signal.

Q- Will Pressing the WPS button on my Home router change my current Wi-Fi password?

A- No it just allows another device to connect without having to enter the password.

Related Articles and Resources:

  • Connect Tablet to Mobile phone network with Wi-Fi
  • Twin Hotspots –
  • INSSider is a Wi-Fi network discovery tool. It displays every wireless hotspot’s MAC address, encryption, signal strength and channel. Very Useful troubleshooting tool. It comes as a windows program and Android APP.
  • Understanding and Using Bluetooth

Источник

Оцените статью
Adblock
detector