Skip to main content

Run / Install / Debug Android applications over Wi-Fi? - Android Tutorial

What is the need through Wi-Fi?
i. This will save your phone from irregular charges.
ii. A remedy for short length USB cables 

There are several methods to achieve this, here we can see how to do with the plugin.

A better method through Android-Studio plugin

Follow the steps to achieve this:

1 ) A plugin for Android studio exits , called   ADB WiFi Connect.
     (There are some other plugin such as WiFi ADB ULTIMATE, Android wifi ADB)

2) Go to file -> settings -> Plugins -> Browse Repositories

3) Look for ADB WiFi Connect , click on INSTALL , and then restart on prompt

4) You will see a new icon , which is your new plugin. Like in an image


Now to make this work :

5) Go to your phone's developer option and enable DEBUGGING (must)

6) Also enable , ALLOW DEBUG OVER TCP/NETWORK

7) Attach your phone via USB , and make sure, both phone and your PC/laptop are connected to the same network (either Hotspot or WiFi)

8) CLICK ON THE NEW ICON (ie your ADB WiFi Connect) the screen looks like


9) Your phone get's detected and get's connected over WiFi/Hotspot , and hence now you may disconnect the USB. This is a one time process, hence you may not need to keep phone connected over USB.
_______________________________________________________________________________________

Happy Coding...

Comments

Popular posts from this blog

Get Phone Number from Contact List - Android Tutorial

When you create an application to send sms or an application to make calls, getting a destination number from the contacts list is a common task. In this Android tip, I am going to show the code to fetch a number from the contacts list. Now let me tell you how to achieve the goal. First, you need to create an Intent object for the PICK_ACTION action. To open the contacts list, the table that contains the contacts information must be specified as a parameter of the constructor of the Intent class. You can refer to the table using ContactsContract.Contacts.CONTENT_URI. Then call the startActivityForResult () method passing the Intent object and request code to open the contacts list. After a contact is selected from the contacts list, to get the result, you need to override the onActivityResult(int reqCode, int resultCode, Intent data) method of the activity. You can call the getData() method of the data parameter to get the table or uri that contains the selected contact. From the t

Spinner with Search on DropDown - Android Tutorial

If you have more values on Dropdown of Spinner its hard to select the last item by making a long scroll. To overcome this issue Android introduced a component called  AutoCompleteTextView Yes it is!!! Then why Spinner with Search? There may be some requirement even though gave much knowledge about it. There is a simple and good library that helps us to achieve this -  SearchableSpinner Gradle dependencies {     ...     implementation 'com.toptoche.searchablespinner:searchablespinnerlibrary:1.3.1' } Usage Now replace your Normal Android Spinner on XML with the following < com.toptoche.searchablespinnerlibrary.SearchableSpinner     android:id="@+id/id_city"     android:layout_width="match_parent"     android:layout_height="wrap_content"     android:background="@android:color/transparent"     android:padding="5dp" /> ___________________________________________________________

Set Focus on Spinner when select Item on Vertical Scroll - Android Tutorial

We may face an issue on Spinner lies on long vertical scroll, (i.e.) when selected and item from dropdown the focus moves to top of scroll. To avoid this please follow this piece of code spinner.setFocusableInTouchMode( true ); spinner.setOnFocusChangeListener( new View.OnFocusChangeListener() {     @Override     public void onFocusChange(View v, boolean hasFocus) {         if (hasFocus) {             if (spinner.getWindowToken() != null ) {                 spinner.performClick();             }         }     } });   _______________________________________________________________________________ Happy Coding...