[GUIDE][Android Studio] Using Google Android Maps API v2 - IDEs, Libraries, & Programming Tools

NOTE : This Guide is Entirely Based on This Guide by Pavel Dudka on StackOverflow
Click to expand...
Click to collapse
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
As many of you would have already known, Google released a new IDE for Android App development named as Android Studio based on IntelliJ IDEA. But many have been experiencing some problems (including myself) while trying to use the Google Android Maps API v2. I finally followed a wonderful guide by Pavel Dudka on StackOverflow. So, i wanted to share the guide with you guys on XDA. So ... Here's the guide...
Take maps project from the Google Play Services samples and copy that to the separate directory. That is going to be our MapsApiV2 project we will be trying to run. It will be located at <sdk_location>/extras/google/google_play_services/samples. Place it somewhere. (eg: G:/workspace/ )
Copy the google-play-services_lib project directory to the same place (eg: G:/workspace/ ), so the working directory looks like this. Btw, lib project is located at <sdk_location>/extras/google/google_play_services/libproject
Now let's open Android Studio. On welcome screen press Import Project and import our maps project from G:/workspace/maps. Now we see a lot of complaints about unknown reference to GMS library:
Now we need to add Google Play Service as a reference library. Going to View -> Open Module Settings
On the Modules tab, click + button and select Import Module and import your GooglePlayServices lib. I didn't change anything in the wizards, so clicked Next all the way to the end:
Now you need to reference this imported library. Open this screen again (go to View -> Module Settings). Make sure you have your maps project and Dependency tab selected. Click + to add a dependency and select Library. Choose your imported library there:
Now we can see that it is not complaining about GMS library, but still complaining about support library:
Let's fix it. I have my support library located at <sdk location>/extras/android/support/v13/android-support-v13.jar. So let's try to add it to our workspace. Go to View -> Open Module Settings and select Libraries tab. Select + -> Java and select support library:
Now it is going to ask you which project to add this lib to, so make sure you have selected your maps project:
Now, You should be able to compile the maps project without any error. :good:

Reserved for updates
Sorry... Reserved for updates

Hey @niranjan94, i have do step for step of your guide but i get errors that the gms.maps packages not exist? I hope you can help me

Related

[APP] micro-httpd (GET / POST / CGI support) cross-compiled to Android

Hello,
A while ago I've managed to cross-compile a basic web server, resulting in a native ARM executable (you can find it here) that allows any other device to connect to port 80 (or whatever) and browse the contents of the phone.
Easy to exchange photos at a cafeteria which has wifi and both phones are connected - for example. No need for an FTP client, slow bluetooth, and so on...
However, I wanted more and since webserver was only handling GET (no POST / no CGI), I've started looking for an alternative that did the job.
Below, you will find a native ARM executable of micro-httpd, a light weight web server that supports CGI.
Download
Use it at your own risk!
mini_httpd_1.19.arm.tar.gz
It supports .htpasswd files to restrict access to folders - and it comes also with its own utility htpasswd which manipulates the password files.
micro-httpd website: http://www.acme.com/software/mini_httpd/
micro-httpd configuration options: http://manpages.ubuntu.com/manpages/maverick/man8/mini-httpd.8.html
You can use almost any CGI interpreter you want, minus PHP. The PHP 4 Android (a native implementation of PHP) has only CLI (command line support) and even if you could change the PHP code of the scripts to output the missing headers. BUT! It also outputs debug messages that you cannot control, in the output of the script!
Those messages are are considered errors in HTTP / CGI.
The creators of PHP interpreter say that is only meant for Scripting Languages for Android (SL4A) which works with what they have. You can read more here: http://groups.google.com/group/php-for-android/browse_thread/thread/79d0b5f856189675?pli=1. This topic also mentions an alternative (CGI this time) from GroomDroid but that is also unstable.
Enter PERL!
I had good success with Perl 4 Android
I can how host a blog on my phone - I've set up a big tutorial on how to configure everything here Running native CGI scripts (perl) with micro-httpd on Android.
Result
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Next step would be to try out a file manager and test file upload, then go even deeper to see if I can access various phone details and offer a sort of management interface for them on the web.
Source code
You will find the source code and the license (free) on the tutorial website above.
Seems interesting !

[APP][1.6+] KeyEvent Display v0.0.4

Description
Once, I was playing with a number of Chinese tablets and trying different ROMs on them as they are technically the same hardware (HSG X5A variants).
I've had some problems getting the hard buttons to work though, so I wrote this application to detect key events and print them out. It will print out the following:
KeyEvents: The KeyEvents as Android understands them (KeyUp, KeyDown, KeyLongPress, KeyMultiple)
LogCat: Any relevant messages in logcat. Its filtered based on keywords declared in arrays.xml
Kernel: Any relevant messages in the kernel log. Its filtered based on keywords declared in arrays.xml. Kernel log parsing needs root.
The three checkboxes at the top control what information will be displayed.
This is a personal debug tool, but I hope it will be of some use to someone else.
No Ads.
Notes
While the application is running, the only "hard" keys which should work is "Home" and power. All others will produce their keycodes.
The SU request is to read the kernel log, so I can check if any keyevents are thrown by the kernel.
The location of keylayout files in Android is /system/usr/keylayout.
Kernel log parsing needs root
Both logcat and kernel log monitoring will only display lines containing words from two arrays in arrays.xml (i.e. you need to recompile the app to change them at the moment)
Currently the filters are:
Logcat:
HwGPIOE->GPDA
keycode
keycharacter
Kernel:
HwGPIOE->GPDA
keycode
keycharacter
Permissions
READ_LOGS: Used to access the Logcat log.
WRITE_EXTERNAL_STORAGE: Used to write the exported data to the SD card.
Changelog
v0.0.1: First public release.
v0.0.2: Improved stability, added Exit button.
v0.0.3: Code updates.
v0.0.4: Changed drawables, added sharing, added more info in export text
Acknowledgements
Original icon by OCAL (http://www.clker.com/clipart-style-paintbrush.html).
Licence
Licensed under the Apache Licence 2.0: http://www.apache.org/licenses/LICENSE-2.0.txt
Links
Market link: https://market.android.com/details?id=aws.apps.keyeventdisplay
Webpage: http://aschillings.co.uk/html/keyevent_display.html
Github: https://github.com/alt236/KeyEvent-Display---Android
Screenshots
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
|
This could be handy for anyone trying to redesign an apple BT keyboard for use with Android.

[APP] iptraf 3.0.0 for Android (with APK Installer)

Introduction:
Here's the classic iptraf for Android!
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Installation:
You need to have a rooted phone and busybox installed on /system/xbin
You also need to have about 1Mb free on your /system partition.
Usage:
To use iptraf, you need to either have an SSH server on your phone (for example DroidSSHd) and connect using Putty from your PC, or you can use the Terminal Emulator (please see attached screenshots).
Any terminal emulator application should work, but iptraf requires at least 80×24 characters screen so for smaller screens you might need to reduce the font size a lot to make it fit.
The price is payed for the installer and the effort to have iptraf cross-compiled for Android, since iptraf is distributed under GPL license. Put in a different way, you are just buying me a beer for making it easier for you to have iptraf on your phone!
Filters:
If you decide to connect using SSH, the trouble is that iptraf will show the SSH traffic too – something that you might not want to have there constantly updating.
It would seem intuitive to create a filter which excludes SSH port from the traffic, but once you do that, iptraf will not show anything else; iptraf actually has an “implicit no-display” policy meaning that once you apply a filter (include / exclude) nothing else is displayed, even if the filter is Exclude mode. You will need to have an additional Include entry added to the filter (after the Exclusion entry taking care of the SSH port) where everything is 0 and all the ports have an Y next to them. Please check attached screenshots as an example on how the entries of the filter should look like.
Please do not forget to “Apply filter…” every time you change something in the filters. X saves the filter, Ctrl-X cancel the changes, but even if you press X, the filter is not yet applied unless you Apply the filter.
Download
Please donate by buying it from the Google Play :fingers-crossed:
Use it at your own risk!
IptrafInstaller.apk
Source code: https://code.google.com/p/iptraf-installer/
Could you please make the sources of the iptraf binary available?
(preferably on github)
1 Euro to download from Android Market? That sucks
M66B said:
Could you please make the sources of the iptraf binary available?
(preferably on github)
Click to expand...
Click to collapse
As soon as possible ... I am working on an updated version.
defim said:
1 Euro to download from Android Market? That sucks
Click to expand...
Click to collapse
Well, you can actually download for free from few posts above.
I'm to lazy to update app by manual download .apk

[Tool][Windows] Cassini.1.2 - Now Compress Any App! (*)

{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Now Support all Apps! (*)​
Download - Cassini.1.2 - 3.5MB [Google Drive]
Download - Cassini.1.2 - 3.5MB [Dev-Host]​
About
First of all, the reason that this program took this much time to come out is because my career-deciding exams where on. So I'm sorry about that.
The newest edition features a GUI - like UI that helps user to easily create new projects (for rom or collection of apps) and manage them.
With the new algorithm the for compression you can ensure that almost all of your apps get compressed successfully! You just have find the perfect set of settings for that particular app. Use it ti compress apps and get a performance boost for your phone as well as save some space!​
Setting Up your PC!
Note: You can skip this step if you already have Java installed on your PC, or you don't want to use the Sign Apk setting for compression.
Download The following resources first:
Java SE Run-time Environment 7 [ Java Dependencies For Signing APK tool ]
Now let's begin setting up your PC,
Install the above mentioned programs.
Go to Advanced System Properties.
It looks like this:
Go to Environment Variables, then create a new System Variable, having name JAVA_HOME and value as the path where you have installed the JRE.
It looks like this:
Now after creating the JAVA_HOME variable, search for Path system variable in the System Variables list. Now this is a bit tricky. Once found click on it and then on Edit. Move the cursor to the end of the string till you see ";" (without quotes), add the path to your JRE bin folder just after it.
It looks like this:
Manual for Cassini.1.2 - Information about the program.​
Include this in your signature if you like and support Cassini and you are using the apps compressed by Cassini!
​
:good: Hit thanks if you liked it! :good:​
Screens for Cassini.1.2
Screenshots of Cassini.1.2

[Solved] [ADB] [Batch] Install Apps over ADB using .bat script by-mBEDed

{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Install apps over ADB
Install apks on any Android device running any Android version over ADB!​
Hi all,
From a long time i was fiddling around with a problem of installing/downloading apps after installing a new ROM.
Thus i came up with an idea of a Batch File to install all of your apks from your system
to your phone in a few tips and taps. Hah! Found my solution .
How does it look?
To see some screenshots, please click below.
Tested on
The script had been tested on Nexus 5x, Nexus 5, Moto G4 but should work on any android device.
Downloads
Google Drive - Here is the link to Drive.
Link Below - You can also find the file below.
Installation instructions
Prerequisites
1. Platform Tools for Windows (ADB),
2. APK files,
3. Target phone connected to PC and
4. A cup of COFFEE or TEA as you like it.
Process
1. Download it from the attachments below or from the drive link above or here.
2. Copy the file to the ADB folder.
3. Execute the file.
4. You can either place your apps in "D:\Apps" folder. (Sllloooowwwww.....)
OR​Change the folder location in batch file itself. (Requires some Coding Skills)
OR​Batch file will ask you to change the location, if required. (Easy Installation, Pick Me!)
Troubleshooting
I don't think it's needed. But even then if you get any problem do write. I'll be happy to resolve it.
Enjoy, and also don't forget to write anything (Good, Bad or Thanks etc.)!
thank you so much if works like a charm!
Been locking for something similar.
Is it possible to take that script to next level, and make it as, a list of apps, and for them to be downloaded on the phone. I mean give order through ADB for each apps step by step, instead of folder, to be downloaded.
how to add online option like google drive folder in to the script

Categories

Resources