Is it possible to install and launch a native Google Glass App with the Preview GDK without having to use launchy?
I'm having a hard time finding a tutorial/reference on how to do this.
Thanks!
Yes. I'd start with one of the GDK Sneak Peek sample projects and make sure you can install one of those and launch it. You can even change the voice command from "start to stopwatch" to "release the hounds" or something and check that that works. The way glassware launches is different from conventional Android apps, so your manifest file will need to be different.
Here's the official documentation:
https://developers.google.com/glass/develop/gdk/input/voice#starting_glassware
Related
I'm using Android Studio and I was wondering if there is a way to see what file/script is executed when I press a button in the Virtual Phone. Is it even possible?
I have a big project I did a long time ago and don't remember in what file the code is written. I need to find a way to show in what directory is located.
Example:
Press Search Button
- Show directory where that action is located.
"app/src/search/search-bar.java"
For that, you must have to go through AndroidManifest.xml file to check which Activity is launcher Activity.
Then go in the source file(.java) of launcher Activity, from there you can find a way to check where it will go by discovering any Intent.
The best way is to debug your project by putting breakpoints.
You should be able to see such information in the logcat at the bottom of the screen.
You can make use of Android Profiler available in Android Studio 3.0 or higher. You can access it from View > Tool Windows > Android Profiler.
This will give you all the required information, You can see the Activities name which is running in the mobile. You can even track your CPU, Memory and network usages with this tool.
Sample:
Read more about Android Profiler here
I hope my question is suitable here. I recently started learning android - making buttons, using google maps and other basic stuff. I saw a thread recently (can't find it) about this and I got interested in it: https://github.com/jackpal/Android-Terminal-Emulator/wiki
This is an open source android terminal emulator. It also seems to have a library called EmulatorView with which people can call methods etc. What I would like to do is use this app inside my own app. Instead of just looking at the file system on the android phone etc. my app would connect to the console of a serial device like a router, usb to serial. Something I usually use minicom for on my pc. As in there could be a button in my app and if I press it it opens the console of the attached router and I could issue administrative commands.
I was wondering what the easiest way to do this would be? Would it be to try and use this library and make my own terminal, seems quite hard, or would it be to copy their source into a project and try to edit it? Seems messy to organize everything, and could be hard too? Then use some library like this to connect to the serial device? http://slickdevlabs.com/slick-usb-2-serial-library/
What would the first steps be, make a terminal like the open source app has, use their library or paste in their code? Then try and edit it to do something over serial?
I have tried to use their example for using their library (jackpal.androidterm.sample.telnet), but it crashes when I click open shell, I was wondering if this open shell button in their example was what I needed?
I decided I would learn more by writing the app myself using the library.
Well i `ve made an app using java me and as graphics i used lwuit library which i added into the midlet`s jar. On Nokia it runs smooth and i wanted to port it to android. So i found out about microemulator http://microemu.blogspot.ro/2008/11/running-java-me-applications-on-android.html and i followed those steps and i got the apk. However when i run it into the Android Emulator it closes at start. I don`t know what may be the problem because i was able to convert the demo jar app into apk and it ran succesfuly.
Any ideas on what should i do?
I suggest you port your application to Codename One which should be pretty simple. It has proper Android support which will make your application look and act native on Android.
I want to monitor(I want to check whether one currently running application fetches my contacts details) all installed application of android operating system using one application. Can any one help me to sort this out or is possible to create such application in android.
I want to monitor all installed application of android operating system using one application.
What is your definition of monitor?
To know when packages are added refer to this
To know which applications are running in the fg/bg use this
To know what the CPU speed and other stats use adb shell ps. Yes, you can run adb commands from an apk
The ActivityManager class is quite helpful
You can look at this topic on androidforums with similar question. Maybe it helps to begin. Or you can look at this helper function
Is it possible to start a midlet automatically straight away after the user has installed it ?
So once the midlet is installed it launches.
No it is not possible.
AMS installs the app, and then in most of the phone it will ask user for start app. we can't load automatically.
Its not possible but you can achieve a slightly similar effect if you are able to make use of the midlet install notify in the jad
http://java.sun.com/products/midp/OTAProvisioning-1.0.pdf
then use push registry as your server would be notified that the application has been installed
http://developers.sun.com/mobility/midp/questions/pushregistry/
One of the problems here is the signing model for permissions to allow for this to happen, you will probably need to look at Java Verified or similar
At least on Nokia S40 devices, there is the manifest attribute Nokia-MIDlet-auto-start: http://library.forum.nokia.com/topic/Java_Developers_Library/GUID-C5D3E0F5-72B9-4EE7-8BA7-20DE4A538FB8.html