appears to successfully toggle it back ON/Enabled...also, disabling USB access by the method above appears to NOT persist through a reboot so this likely would need to be part of a script run by your app or part of your app if you need to maintain a disabled port for the sake of securityUSB Disable/Enable method described here also appears to work on USB mass storage (thumb drive) - i.e. when disabled, the "udisk" folder shows up empty in ESFileExplorerThis has only been proven in concept by trying from a shell session.]]>Thu, 02 Jul 2015 19:03:34 GMThttp://www.jgwebdesigns.net/android-development-tips-and-tricks/hiding-the-android-system-uiTo hide/show the UI from with your app...After a lot of searching on the internet, I managed to get the System Bar to hide and appear in a 4.2 device using the commands belowTo Hide:Runtime.getRuntime().exec("service call activity 42 s16 com.android.systemui");Or use 79 instead of 42 for API less than 14.

To Show:Runtime.getRuntime().exec("am startservice --user 0 -n com.android.systemui/.SystemUIService");]]>Thu, 02 Jul 2015 15:18:41 GMThttp://www.jgwebdesigns.net/android-development-tips-and-tricks/extracting-manifest-info-from-an-apk-fileIf you ever need to extract information from a APK's manifest file (e.g. to get the name of the launch activity),You can use Android application packaging tool (AAPT) found under the build-tools folder under your Android SDK installation$ aapt dump--values xmltree <name>.apk AndroidManifest.xmland then you have to parse the output to find needed info. The output is a little "rough" but usable.The parts in bold above are fixed/required. The "<name>.apk" is the name of the APK file from which you're extracting the manifest.

You probably want to redirect the output to a local file to have for future reference, since the line above just outputs to the screen. So...for exampleC:\Eclipse_ADT\adt-bundle-windows-x86_64-20140702\sdk\build-tools\17.0.0> aapt dump--values xmltree <app-name>.apk AndroidManifest.xml > C:\temp\app-name_Manifest.txt]]>Thu, 02 Jul 2015 15:09:16 GMThttp://www.jgwebdesigns.net/android-development-tips-and-tricks/background

Unless stated otherwise, everything discussed herein is related to development I've done on semi custom hardware, (Freescale-based, derived from a FS reference platform) with a rooted BSP/OS (also based on a Freescale reference build). I have not built the BSP (nor have I ever built a BSP)