Skip to content Skip to sidebar Skip to footer

Android Ics 4.1 - Usb Ethernet - How To Toggle Ethernet Connectivity State?

I purchased an android device (Rikomagic MK 802IIIs) to connect to my TV. I have developed a simple application that requires an internet connection (currently connected via a USB

Solution 1:

I had the same problem with my Android HDMI TV stick. Because it wasn't my intention to write an own app for this I had a look at scripting possibilities.

Running dhcpcd eth0 in a root terminal first seemed to work but caused Android's settings app to crash. So I set up a static IP in Android's ethernet settings and just disable and enable the device by running ifconfig eth0 down ; ifconfig eth0 up. This works reliably.

To run this command every time after boot with su privileges I use SManager.

I don't know if this is a solution for you but if not you could toggle ethernet state simply by executing ifconfig eth0 up and ifconfig eth0 down with root privileges from your own app:

Post a Comment for "Android Ics 4.1 - Usb Ethernet - How To Toggle Ethernet Connectivity State?"