Showing posts with label Android. Show all posts
Showing posts with label Android. Show all posts

Sunday, September 28, 2014

Android on Ubuntu & tricks with Thinkpad laptop

Want to install android on a virtual machine on your Ubuntu? Well it's not that hard, have a look at this tutorial which simply tells you how to do it :-)

http://www.howtogeek.com/164570/how-to-install-android-in-virtualbox/

Important Update : Talking about it being easy, if you are having a Lenovo or Asus laptop remember to download the special iso file made for laptops with special hardware. android-x86-4.0-r1-thinkpad.iso in my case. Also after you are finished installing and you do not have the mouse in the Virtual box windows when u start the Android, read this article at PC world which helps you with that :-P

http://www.pcworld.com/article/2048220/hybrid-hijinks-how-to-install-android-on-your-pc.html

It basically only is saying the following which is useful for you : "Click Machine in VirtualBox’s toolbar, and select Disable Mouse Integration. Dialog boxes may appear; if so, click through them and continue. Disabling mouse integration allows you to manually control whether your mouse is controlling your primary OS or Android-x86. Pressing the right Ctrl button on your keyboard switches between the two operating systems. To swipe, click and hold the mouse button, and then move the mouse.
With that taken care of, you’re free to explore Android on your PC!"

Thursday, March 03, 2011

Android & WiFi information, Wifimanager + Wifiinfo

For having access to the WiFi connection, you can use the WifiManager and WifiInfo classes in Android SDK. The following code can show you how you can do get access to things like your IP address, the connected network name or the available networks around you :

        WifiManager myWifiMananger = (WifiManager) getSystemService(WIFI_SERVICE);

        WifiInfo myNetInfo = myWifiMananger.getConnectionInfo();

        showIp.append(changeIp(myNetInfo.getIpAddress()) + " \n");

        showIp.append(myNetInfo.getSSID() + " ");

        List<ScanResult> scanList = myWifiMananger.getScanResults();

        for(ScanResult element : scanList){

         showIp.append(element.SSID + " Level: " + element.level + " freq : " + element.frequency + " Cap: " + element.capabilities + "\n");

        }
//DONT forget that the getIpAddress returns an int value. Convert it to string :
public String changeIp(int ipAddress){

     return String.format("%d.%d.%d.%d",

       (ipAddress & 0xff),

       (ipAddress >> 8 & 0xff),

       (ipAddress >> 16 & 0xff),

       (ipAddress >> 24 & 0xff));

    }



*** VERY IMPORTANT : To use this you need to add couple of lines to android manifest(XML file -> AndroidManifest.xml).

<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />

  <uses-permission android:name="android.permission.CHANGE_WIFI_STATE" />

Thursday, October 21, 2010

Can't find equal sign on Android keyboard

Nope, you are not blind. They managed to hide it on the 3rd page of your keyboard !!! Press the "?123"(12# in some keyboards) Symbol on the bottom Left(right in some local keyboards). Then Press "ALT"(my Norwegian local keyboard ALT button was "1/2") on the Left-hand side to bring up a new variety of symbols including the equal sign.