On board android development - Android Software/Hacking General [Developers Only]

Im a fairly knowledgeable computer user without a computer!
I love to write programs!
It really is a shame that there is not an onboard development kit for this platform.
I have tried several implementations available in the market. None of them seem to satisfy my thirst.
Before I gave up on sl 4 a, I learned a little about android virtual machine. When coupled with the right tools, and knowledge, full access to the android java api are possible.
Being that I don't have a computer, I cannot compile any wrappers to handle superclassing the api. As you may know a simple hello world gui will not run on android without a superclass.
It is not my aim to go for full fledged on board development. The overhead is way too high. Ie battery power, syntactical semantics storage space for libraries yada yada yada...
Mozilla has the rhino javascript engine which can execute code within the android virtual machine. However as I said before super classing presents a very serious problem.
I aim to write a bridge in java and javascript. However I have no tools to do the java side work.
I do have access to a shell account with a working j d k, but the j d k is not fully compatible with the android sdk. On top of that I'm faced with the 50 megabytes quota offered with my free shell account. The android sdk is 2.5 gigabytes in size approximately.
To sum it all up there are a few files that I need from the android sdk that will allow me to compile java programs using my free shell, and then convert them for usage on the android virtual machine.
The files in question are as follows:
aapt - weird android packaging mechanism
dx - android virtual machine byte code converter.
From my research I have learned that dx is actually a java program that runs in the standard java implementation.
Well whatever the case is I need these programs running on an Ix86 Unix bsd architecture if anyone out there can supply them pre assembled.
This is not an official request for comments but all comments are appreciated.
Sent from my HTC Magic using Tapatalk

This is how I run my scripts from the shell.
Rhino came to me from sl4a. Sl4a project is unsuccessful @ functional implementation of rhino JavaScript for android at time of this writing.
For whatever purpose sl4a does not execute the dalvik command properly ($BOOTCLASSPATH is being pushed out of context via Rhino or the dalvikvm onLoad) so even though you can install the JavaScript interpreter from sl4a you can't use it without some fancy footwork.
I had to change permissions on my dalvik cache folders as well to get it working on my droid. For some reason the system did not want to accept the rhino library into its dex cache (using cyanogen mod. 6). Just do rwx permissions for everyone on
/data/cache
and
/system/cache
Note that the above file systems are usually mounted read only.
Note also that this is a single line shell command. put it in an sl4a shell script or run it from the terminal.
/system/bin/dalvikvm -Xbootclasspath:/system/framework/core.jar:/system/framework/ext.jar:/system/framework/framework.jar:/system/framework/android.policy.jar:/system/framework/services.jar:/mnt/sdcard/com.googlecode.rhinoforandroid/extras/rhino/rhino1_7R2-dex.jar -Xss128k org.mozilla.javascript.tools.shell.Main -O -1
Running this command in the terminal will activate a javascript interpreter shell that has full access to the android java framework.
If you would like to run a script instead of an interactive shell please append the following to the preceding command
-f /path/to/your/script/yourscriptName.js
That line would make an interesting argument to your new shell script!
For more information about Rhino see my next post for suggestions and resources.
if you are interested in this project now is a very good time to learn java programming! I just started yesterday and I haven't been to sleep yet! lol. it is also considered a requirement to learn the android java api if you plan to capitalize on its functionality.
Aye.. time for more coffee ..
- Posted via mobile

SL4A - http://code.google.com/p/android-scripting/
Android API - http://developer.android.com/reference/packages.html
Rhino API - http://www.mozilla.org/rhino/apidocs/index-all.html
Rhino Documentation - http://www.mozilla.org/rhino/doc.html
Suggested Reading
JavaScript The Definitive Guide: 5th
Edition
some books on Java ... classes,
interfaces, overrides, packages,
sub classing, super classing,
inheritance, extends, import
// its pretty much like jascript without
// all that stuff
some books on Android Programming
- Posted via mobile

Avid Droidery said:
To sum it all up there are a few files that I need from the android sdk that will allow me to compile java programs using my free shell, and then convert them for usage on the android virtual machine.
The files in question are as follows:
aapt - weird android packaging mechanism
dx - android virtual machine byte code converter.
Click to expand...
Click to collapse
So no one out there develops for android under linux?
I downloaded the source tree for the davlik virtual machine but there is no make file to compile the project! Tell me that is not aggravating!
The web quotes a file "envsetup.sh" and a command called "lunch" to be run in a 'build' directory. None of these files were supplied with the download. Practices in idiocy should be banned from the web! Lol.
So let's say I used 'git' to grab the source tree of a single project in the android sdk. How am I supposed to build a project with no make file???
The normal way to do this... is to run the gui setup called 'android.' that does me no good. I only have ssh access to my build server!
Is there no 1 out there who can build these files for linux and supply them to me? From what I understand all you need to do is successfully install and configure the sdk and these files will b available to you in the tools directory.
I would like to file an issue about having no text based setup for the android sdk. In the real world we may not always be able to use a graphical user interface. especially under linux/unix/posix! But what good would that do me? I needed these files 3 days ago
*update issue filed under general build questions google groups (PC WIZ)
So let's recap.. if you are using the android sdk under linux or if you have physical access to a unix machine and some spare time I could really use your help!!!!
I would like to make this topic become a reality soon.
- Posted via mobile (as always)

Ok I got dx up and running.
I found where to get the files prebuilt.
http://android.git.kernel.org/?p=pl...11c17b4f5507f00905ec73f2fb90eaa387f72;hb=HEAD
Yes in platform/prebuilt .. @ the android source code repository.
I also downloaded aapt but the library files are not available on my system for this build. I don't have the rights to upgrade my development server. Stay tuned.
Here is stderr output from './aapt':
./aapt: /usr/lib/libz.so.1: no version information available (required by ./aapt)
./aapt: /lib/tls/i686/cmov/libc.so.6: version `GLIBC_2.4' not found (required by ./aapt)
If you are thinking of downloading any files from the source code repository using your android device you will be very disappointed! wget fails to download the raw views of the files and reports them as garbage. The built in download manager just keeps tellin me download unsuccessful. In short it took me the better part of 3 hours to get 3 files using 3 different downloaders.
I was unable to download the shell script 'dx' nor was I able to cut copy paste the full source because android would not let me everything it did let me copy had line terminators removed. Somebody needs to fix that clipboard!! Tell me that's not aggravating!
In retrospect the browser should not say 'select text' as a menu option. It should say 'select some of this text, mangle it and then send it to the clipboard' lol.
Anonymous ftp access should be an open source requirement! I blame today's shortcomings on all open source licenses! Lmfao.
- Posted via mobile

Anyone out there care to donate a 19th/Early 20th century laptop?
I am starting to think like a rhino. I can tell because I'm ready to run my head through the wall! @ aggravating factors.
I am beginning to believe that the android platform is cursed! Lol.
The android devices are awesome! I don't really mean to offend anyone but the software is ****. The source code tree doesn't even resemble a tree.
No offense to Linus Torvalds But you shoulda stuck to hardware programming. I would like to show you a picture of what a git managed project looks like to me.
{
"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"
}
I don't know anything technical about it but I think you missed a paper or two on derivative theory. I dont know calculus but everyone knows that a seed from a tree makes a new tree. In retrospect, common sense is pure logic dressed up by the mind as a perception of reality.
My perception of your project and the issue of fault may be wrong but this monstrosity is hosted on your site (android.git.kernel.org)
Please don't get me wrong sir linux is the best damn thing running and everyone involved in its development owes that to you.
I really wish the android platform would have stuck with the tried and true GNU development system. Where source code (seeds) can be downloaded as a seperate package and module dependencies (earth, water, sun, etc..) are easily solved.
I predict this platform will fail within the next 10 years because of this build system. It is quite simply too complicated for new programmers to get on board with fresh ideas. Not to mention the amount of prior knowledge and lofty resources it requires to do so. This is a systemic issue. The flow of integration and information is invaluable to software development. I'm here to tell you the **** doesn't flow.
If anyone dares to challenge these points of authority, might you consider telling me why an open source platform with open source software does not have a bona fide linux distribution like Gentoo, damn small linux, or micro linux? I assure you it is not because no one would use it.
- Posted via mobile

Here is a great program if your'e interested in this script business.
http://code.google.com/p/android-scripting/downloads/detail?name=textedit-sl4a.apk&can=2&q=
Let's face it when it comes to the android appearing to multitask things properly it's all about the app! The dialogs are weak but the functionality is perfect. Happy scripting!
- Posted via mobile

Avid Droidery said:
Here is a great program if your'e interested in this script business.
http://code.google.com/p/android-scripting/downloads/detail?name=textedit-sl4a.apk&can=2&q=
Let's face it when it comes to the android appearing to multitask things properly it's all about the app! The dialogs are weak but the functionality is perfect. Happy scripting!
- Posted via mobile
Click to expand...
Click to collapse
Thx ill check it out
Sent from my HTC Knight using telepathy

JKILO said:
Sent from my HTC Knight using telepathy
Click to expand...
Click to collapse
That is even funnier than the guy I saw run into a car on his bicycle today! Luckily for everyone involved he wasn't hurt. Not so sure about his phone though.
You are welcome.
- Posted via mobile

Update. This project is on pause until further notice. I have been thwarted at every attempt to succeed in this endeavor therefore is my understanding that I must retool and upgrade my resources before I am able to provide a definite solution.
Feel free to ask any questions regarding my current research.
Standing by ...
- Posted via mobile

I managed to wrestle my old workstation out of storage.
Some stats
Pentium D 975 Dual Core 3.0 GHz. EM64T
4GB Ram
175 GB HITACHI SATA Gen II HD on Intel RAID Controller
FOXCONN 975X7AB MOBO
I built it back in '07 but she still runs like a champ!
Anyway just wanted to gloat a little... If you were stuck working on an android you might be as happy about your situation! Heck, I'd be happier with a knock off Chinese netbook running Windows CE 5.0. @ 255 MHz.
I predict this platform will fail within the next 10 years because of this build system. It is quite simply too complicated for new programmers to get on board with fresh ideas. Not to mention the amount of prior knowledge and lofty resources it requires to do so. This is a systemic issue. The flow of integration and information is invaluable to software development. I'm here to tell you the **** doesn't flow.
Click to expand...
Click to collapse
So what does flow? It isn't the Android API! Let's compare some code on the topic of User Interface Design and Implementation.
An application with a single button the android way:
Code:
public class MyActivity extends Activity {
protected void onCreate(Bundle icicle) {
super.onCreate(icicle);
setContentView(R.layout.content_layout_id);
final Button button = (Button) findViewById(R.id.button_id);
button.setOnClickListener(new View.OnClickListener() {
public void onClick(View v) {
// Perform action on click
}
});
}
}
Oh wait a second were not done yet! The following code belongs in a separate file:
Code:
// .... some of this document was removed to improve clarity.
<Button
android:id="button_id"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:text="@string/self_destruct"
android:onClick="selfDestruct" />
Seriously all that for one f*%#&n button? It doesn't even do anything when you push it..
Ok that's uh... hmm interesting to say the least. :barf:
Let's look at the same thing in HTML+JS:
Code:
<FORM>
<INPUT TYPE="button" NAME="button" Value="Push Me" onClick="alert('I am not a killer, but don't push me!');">
</FORM>
Simpleton you say? Try this on for size:
Code:
;---------- [Create the Button Control] ----------
INVOKE CreateWindowEx, 0, addr ButtonClass, addr szButText,\
WS_CHILD or WS_VISIBLE or BS_PUSHBUTTON or BS_ICON or \
BS_LEFT or BS_VCENTER or BS_TEXT,\
100, 50, 100, 40, hWnd, 702, hInstance, 0
mov hButCtrl, eax
;---------- [Load the Image] ----------
invoke LoadIcon, hInstance, 901
mov hImage, eax
invoke SendMessage, hButCtrl, BM_SETIMAGE, IMAGE_ICON, hImage
The code above is actually just a snippet from a source file for a 32-Bit Program for Windows written in assembler. But the concept is the same. There is no code here for a click action. To make the example more interesting, this button has an icon drawn onto it.
Sure, I could provide more examples in different languages, but I believe my point is clear here.
Am I the only person here who realizes somebody screwed up when they thought of the API for this platform? I don't understand the reasoning behind this. The programmer spends more time implementing than creating under this platform. When I look at the more complicated apps that are available in the market I have to say well done! But I also have to say "I am sorry about your losses."
Honestly I don't know what to say other than "I wish I was head of R&D for Google over in Mountain View Ca." These guys obviously have no idea what they are doing.
Point and case made by example.
Who wants to collab. with me on an all HTML based GUI framework for the android? Honestly I would love to. Google says this platform is all about code reuse... Hmm... how come there is no /usr/lib directory? You can use their platform to make libraries! but they are for private use only unless you write a 12 chapter book (in code) explaining to the android what people can do with it. Of course then you have to write a real 12 chapter book for the developers on how to use the API you exposed. :barf: :barf: :barf:
Anyway to make matters worse... It is actually easier to program their platform using javascript, but in my honest opinion... It isn't worth the [bad language] trouble... Here's another code excerpt for android in JavaScript:
Code:
// a plethora of code removed to improve clarity....
var buttonRun = new Button(Activity);
buttonRun.setLayoutParams(new LayoutParams(
LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT, 1));
buttonRun.setText(Droid.translate("RUN"));
buttonRun.setOnClickListener(function () {
// code to do some stuff here
});
// even more code removed to improve clarity...
If you are used to reading my posts you will have to excuse my malformed paragraphing. I am used to composing all my posts by voice recognition
So what does all this mean? In regard to the thread topic, this means that you have your work cut out for you. Just look at the JavaScript code above and see how ridiculously close it is to writing a program that must be compiled. Mind you that is only the code to create ONE button. Looking back even further, it was easier in ASSEMBLER.
Ok, Android Scripting. Its more than a great Idea... It's the best Idea anyone ever created for this platform. Its too bad that an entire platform API has to be written nearly from scratch before we can take full use of it. Well, I am working on an implementation of rhino. Everything compiles smoothly from eclipse but I can't really test anything or come up with any ideas because I know I'm headed down the wrong path.
Well I brought you here for your interest so let me boost your interest.
You want GUI programming in script? Visit the following link and click on:
http://droidscript.blogspot.com/2010/03/droidscript-getting-started.html
I wonder why that project 'died' in its infancy He certainly accomplished quite a bit!
LOL I was right about this platform before I ever opened the IDE! LOL

One more point of interest...
Assembler is the fastest (and most powerful) programming language on the planet. I never thought I would live to see the day that I would find another language (other than C++) that was harder to program with. I was wrong. And I will be wrong about this platform coming to a failure if google pulls its head out of its ass (and gives me or my ideas a job.) LOL.
Note to google devs: Keep It Simple Stupid. HTML5 Based Interface is the only way to go. Especially for a device with limited capabilities. The code is already out there and implemented. It only needs to be adapted. Seriously, throw backwards compatibility out the window and work with something that has the roots, credibility, and global support to be worthy of said term.
Anybody who wants to run that bull**** will have to settle for an 'OnBoard Legacy Code Emulator.' Personally I don't have the time to be bothered with your crypto-pseudo-bloatware and neither does my microprocessor. And just in case you are wondering, I am usually the person who has to say: "I told you so."

I have always thought of it to be like you have revealed it to us... Snap, this just means the end of my Android programmer life... so long Androooiid, so long Google !

Re: onboard android programming
I use JavaIDEdroid program with DroidDevelop for compile my android programs on my android device.
I can't paste links here, but you can find its on the market.
They use eclipse Java compiler and some another utilities to provide ability to create correctly working apk files at output.

wow. this is the only posting mentioning DroidDevelop.

Related

C Code in G1? JF? Anyone?

I'm just wondering is anyone trying this yet? i mean is it even possible?
Just a thought for you big shot android devs out there JF, Haykuro, LucidREM
Google "android jni"
Well, a quick trip around google would have helped you.
Android is using java, and currently it's not possible to use anything else.
But anyway, would you rather compile all of your code for multiple architectures? J makes things easier here...
You can write cli-apps in C though... i heard something about that there was plans to make other languages available in android, but i wouldn't hold my breath
Also, why is this related to JF/Haykuro/LucidREM?
I think you can do this with JNI: http://en.wikipedia.org/wiki/Java_Native_Interface
Using an ARM native compiler (such as the ones at CodeSourcery, http://www.codesourcery.com/sgpp/lite/arm/portal/[email protected]=lite) you can compile your apps and run them fine on the G1
Code:
$ arm-none-linux-gnueabi-gcc -static foo.c -o foo
$ adb push foo /data/foo # we are pushing to /data as it is +rwx (read, write, execute) for a standard user.
$ adb shell /data/foo
a=1
b=2
foo=a+b
foo=3
^^^
OH I love when I stumble across a post like this and have something new to play with.
The problem is due to the different location of the linker and mainly the different libc you have to statically link everything.
I have been having a hell of a time getting DPKG to build statically.
I picked up a copy of the newly released book, Unlocking Android, at Barnes and Noble yesterday. There is a whole chapter devoted to writing native apps using C (and ARM assembler) with the CodeSourcery tools linked above. The author walks through the steps you need to do to dynamically link the libraries so you don't end up with enormous statically linked executables. Well worth the price.
It is surprising what you can do with C on the phone, its actually not too difficult. The method outlined below doesn't use the non native toolchains and if you use the sourcery toolchain (as mentioned above) you will end up with bigger binaries as you need to link in a standard glibc and not androids bionic libc. This may or may not be important for your project.
The other advantage of the steps below is that you will build and link against any library that is available to the android platform
The easiest way that I've found to start when porting or writing new applications is this method.
1) Check out the current git android source.
2) Build the entire tree, "make" in the top level directory.
3) Create a new directory in mydroid/external/packagename/
4) Copy one of the simple android Android.mk (Make) files from a "like" target.
(If doing a library, choose a library, if coding an executable , choose that).
5) source the mydroid/build/envsetup.sh in the users bashrc
6) cd to your directory, then instead of the usual "make" do an mm.
This should create a binary, which you can adb push to the phone and run at the console.
You can do all the usual things if linked properly, like write the framebuffer using sdl, play sounds, create network connections.
Just remember that you dont have a standard libc (glibc) to play around with you have "bionic". If you are missing your favourite glibc function , it is probably intention and not abug. You'll either need to port it or make do with the functions provided by bionic.
These instructions are for a "pure" C program. you can mix the java like dex calling by 'shelling' out to the C application when you need performance, however premature optimization is the root of all evil, you'll be surprised what performance you can pull from davlik (And I expect the VM guys to improve this even further).
I know that is a lot to digest. Will do the best I can to answer your questions. I'm by no means an expert in the area, but have learned a bit about C on android.
Well I don't know much about all this but what i know is that e.g.
ScummVM IS written in C++ , and so is g-arcade.
His FAQ says:
"How did you do this? Is it Java?
No. ScummVM is a C++ program. For this port, I turned it into a really big JNI library so Android still thinks it's running a Java program, but almost all of it is implemented in C++."
(http://sites.google.com/site/scummvmandroid/faq#TOC-How-did-you-do-this-Is-it-Java-)
So if some1 wanna port MAME, feel free to xD

[Q] Running a C++ binary

So this is probably a silly question.
I have this rather complicated app that would be a heck of a lot of work to convert to Java.
It runs in the command line and works fine in Linux.
Trying to run it fails, but x86 bytecode probably isn't very ARM friendly.
Is there a specific way I need to compile the application?
Is it even possible to run it from a console emulator?
Thanks.
Try Android NDK
I am also new to Android Dev ( 15+ years Linux, 10+ years Java, etc.)
I am not an expert but for your purposes you need the "Android NDK" in addition to the "Android SDK" that most developers utilize.
"The Android NDK is a toolset that lets you embed components that make use of native code in your Android applications.
Android applications run in the Dalvik virtual machine. The NDK allows you to implement parts of your applications using native-code languages such as C and C++. "
Basically the tools are needed to cross compile C++ source code for the target ARM environment.
I am prevented from posting the download URL for some bizarre reason, but it is listed under "Native Development Tools" on the left side of the web page for the standard "Android SDK" download.
Yeah that's because you are new. It's a system to prevent spammers from posting URLs.
When you have a couple of posts the restriction will disappear
Anyway; found it, seems to be what I'm looking for.
I'll check it out in the morning.
Big thanks
Dmitry Moskalchukhas written a patch for the ndk to better support c++ see crytax dot net there are posts on google groups android-ndk talking about it
Thxs for the info. I was aware that the NDK did not include all of the libs that desktop Linux/UNIX developers expect. The suggested patched version adds the STL libs back in.
Sent from my PC36100 using XDA App
There are A LOT of libraries missing
I guess I'll just keep it a hosted app.
Thanks for all the input

[Q] [Attn: Devs]Gnash Cross Compilation for Android Chrome Lite

I have a few questions for the devs here. Please forgive any assumptions that may be incorrect. I've tried to do as much research as I can online but I think I need a more experienced Android dev to help me solidify my direction. Thank you in advance for your time.
That being said, I have some experience with a device known as the GP2X. It uses ARM architecture and, in the past, I have been able to cross compile for it. Notably the Stella VCS 2600 emulator. I do have some open source experience, but I've never had any formal training in programming. Seeing that Android uses the DVM to sandbox program code, I'm still a little iffy on what I can and can't get away with programatically.
First off, I've read that the Android Chrome Lite browser allows plugins/extensions through the NPAPI. I'm assuming this is the stock web browser. It's not clear to me at the moment what the default browser is or how it works. It appears that Gnash has a C++ NPAPI plugin that may need to be cross compiled and I'm hoping to get away with as little Java coding as possible.
My main questions are:
1. Does the stock browser allow NPAPI plugins?
2. If question 1 is true, does the plugin have to be compiled in ARM architecture? Are there any caveats to this?
3. From what I've been able to gather, Chrome Lite looks in the following location for Plugins:
Code:
/data/data/com.android.browser/app_plugins
Is this correct?
4. If a plugin is dropped in the correct folder, and assuming that the mime types are associated, will the Android browser recognize/utilize it? In which case, I'm sure there would be an API call that would cause it to rescan like Firefox or Opera would.
5. If cross compilation is necessary, is it better to use OpenGL, AGG, or Cairo as far as wide Android compatibility? Again, I don't know what's native or widely available in Android. I guess I'm looking for Best Practices.
I just wanted some feedback from someone knowledgeable before I go through the trouble of setting up a toolchain to handle this. Seeing that the community has been looking for a Flash player, I wanted to see if Gnash had any practical value on Android.
Thank you in advance for your time and again, please pardon my ignorance. I have holes in my knowledge and I want to get a little closer to understanding this particular subject before investing my time in development.
References:
NPAPI
http://en.wikipedia.org/wiki/NPAPI
Android Browser Plugin Path (I had to extrapolate from the batch file)
http://wiki.eclipse.org/Android_Selector_1.1
Gnash NPAPI Documentation
http://www.gnu.org/software/gnash/manual/gnashref.html#plugincppapi

App requests?

I know this is a potentially dangerous post, but I'm looking for suggestions for things to port. I make no promises that I'll be willing/able to port any suggested software.
Some ground rules before you hit 'reply'
1) Don't ask for Chrome. I won't port it. Period.
2) The source code must be available and not have any _obvious_ specific ties to non-open source code. Eg: some proprietary or closed source library which it depends on.
3) Code must be in C or C++ (I can deal with porting some assembly if needed)
4) Project must be of a _reasonable_ size for 1 person. Honestly, I do this on my own and in my spare time. Some apps can be just massively overwhelming to port. That being sad, sometimes the big ones are also easy.... so use your own judgement here.
5) Tell me why you want it ported. Whats your "use case".
6) Drivers aren't out of the question, but they generally take significantly more work.
Feel free to +1 others suggestions.
Ok.. <puts on protective gear>.. fire away!
Cheers!
Thanks for all your awesome work.
While this isn't an app, I think that the kexec kernel-mode driver idea that was tossed around earlier would be waay more useful than an individual app. Every time it was brought up somebody said "Oh, that won't be much work." And then nobody did anything :-/
So, I'm hugely grateful for the time you put in here, but I think I'd be even huger-ly grateful-er if you opened the door to other OSs.
Sent from my SCH-I535 using xda app-developers app
What would be good is:
http://ekiga.org/download-ekiga-binaries-or-source-code
But I'm pretty sure it uses some libraries not avail
I wish XNA could run on Windows RT. It'd be funny to see Terraria and Magicka on Windows RT...
Firefox would be nice, but without a Thumb-2 JITter, it's not worth it.
Would be nice to have InSSIDer. I use it a lot on my laptop, rather leave it at home.
https://github.com/metageek-llc/inSSIDer-2
Myriachan said:
I wish XNA could run on Windows RT. It'd be funny to see Terraria and Magicka on Windows RT...
Firefox would be nice, but without a Thumb-2 JITter, it's not worth it.
Click to expand...
Click to collapse
I would say to take a look at monogame. It can actually build microsoft store apps including ARM support, so coercing it into functioning on the windows desktop may be possible. Otherwise it might end up being a rule 4 :/
There are hacks out there to run terraria on MonoGame instead of XNA, most of them pretty complete but sometimes have the odd graphical glitch. A full source port to MonoGame would be far more reliable, and actually very simple, but sadly its closed source (although not obfuscated).
One of the supposedly more reliable ones: http://www.terrariaonline.com/threads/wip-monogame-terraria-terraria-for-linux.72997/
Isn't rule one covered by rule four?
SixSixSevenSeven said:
Isn't rule one covered by rule four?
Click to expand...
Click to collapse
No.
People can have bad judgement.. so I'm making an explicit point about Chrome.
Personally i Was really disappointed by the lack of a transmission remote app when i discovered métro interface!
Plus there are many utorrent app...
SO, i think TR Gui source code is available, i think there is many people interested, And i think it will not be too difficult to develop, that can be a wonderfull idea (especially for me ) to make this one
Just found one. TCPMP, this player worked great during the PocketPC/Windows Mobile era. It moved from open source to a commercial different version which is closed source but I believe the link below has the source.
http://www.hpcfactor.com/downloads/tcpmp/
This would bring about a player that supports MKV playback.
lambstone said:
Just found one. TCPMP, this player worked great during the PocketPC/Windows Mobile era. It moved from open source to a commercial different version which is closed source but I believe the link below has the source.
http://www.hpcfactor.com/downloads/tcpmp/
This would bring about a player that supports MKV playback.
Click to expand...
Click to collapse
There is no source code downloadable from that site. All the links are non-existent. Please post the source code if you have it.
Cheers!
bfosterjr said:
There is no source code downloadable from that site. All the links are non-existent. Please post the source code if you have it.
Cheers!
Click to expand...
Click to collapse
Does this help http://code.google.com/p/tcpmp-revive/source/browse/#svn/trunk
mr djé said:
Personally i Was really disappointed by the lack of a transmission remote app when i discovered métro interface!
Plus there are many utorrent app...
SO, i think TR Gui source code is available, i think there is many people interested, And i think it will not be too difficult to develop, that can be a wonderfull idea (especially for me ) to make this one
Click to expand...
Click to collapse
http://forum.xda-developers.com/showthread.php?t=2101891
mr djé said:
Personally i Was really disappointed by the lack of a transmission remote app when i discovered métro interface!
Plus there are many utorrent app...
SO, i think TR Gui source code is available, i think there is many people interested, And i think it will not be too difficult to develop, that can be a wonderfull idea (especially for me ) to make this one
Click to expand...
Click to collapse
I think the problem with the current torrent apps are you either have to pay to get the ability to download files in the background, or the app doesn't support it. I'd like to see a free torrent client that allows background downloading, even if it means speed has to be throttled a bit.
To the OP what is your favorite browser? If it is not Chrome(or Chromium), do you think it is possible to port that browser? At this point I'll even take Safari as I am starting to hate all the crashes that occur for me in IE.
bigsnack said:
I think the problem with the current torrent apps are you either have to pay to get the ability to download files in the background, or the app doesn't support it. I'd like to see a free torrent client that allows background downloading, even if it means speed has to be throttled a bit.
To the OP what is your favorite browser? If it is not Chrome(or Chromium), do you think it is possible to port that browser? At this point I'll even take Safari as I am starting to hate all the crashes that occur for me in IE.
Click to expand...
Click to collapse
Safari is not open source so cannot be ported.
Chrome is a rule 4 - or in other words is too much effort for 1 man to do in a reasonable time frame.
Firefox is also a rule 4, plus its a ***** to get it to compile properly under microsoft tools apparently, plus its javascript engine is raw ARMv7 JIT whereas windows RT bugs with that and would require a THUMB2 JIT. Chrome also would have javascript issues, although in chrome you can have an interpreted javascript engine I think which would just be hideously slow in comparison.
Opera - Closed source.
The list goes on unfortunately. Browsers are complex creatures. Most will come under rule 4 though.
bigsnack said:
I think the problem with the current torrent apps are you either have to pay to get the ability to download files in the background, or the app doesn't support it. I'd like to see a free torrent client that allows background downloading, even if it means speed has to be throttled a bit.
To the OP what is your favorite browser? If it is not Chrome(or Chromium), do you think it is possible to port that browser? At this point I'll even take Safari as I am starting to hate all the crashes that occur for me in IE.
Click to expand...
Click to collapse
What the hell are you doing to get all these crashes? I have yet to have IE crash on 8 or 8.1 on RT in desktop or metro.
My only suggestion would be a gui SFTP client. This is probably the one utility I am currently missing on my Surface RT (I use ssh to remote into Linux systems both for work and personal use, point #5). To clarify, I do use the psftp client in the putty suit, and that works well enough, just takes a bit more time and effort than something like winscp. I can continue to use this if an gui alternative is not feasible.
I recall someone requesting winscp at some point in the past, so I searched around this forum and I did find a couple of people that took a stab at it, but with no results, and I haven't found a clear explanation on what the hang up was. Looking at the readme winscp appears to be written in c++ at least (point #3):
To build WinSCP you need:
- Embarcadero C++ Builder XE2 Professional.
- Copy MFC source code from Borland C++ Builder 6 Professional and
build its Unicode version (see readme_mfc.txt).
- nasm from http://www.nasm.us/
- To build 64-bit version of drag&drop shell extension, you need
Windows Platform SDK:
http://msdn.microsoft.com/en-us/windows/bb980924
Click to expand...
Click to collapse
I am unsure if the aforementioned Windows Platform SDK is available for Windows RT, or if it is even needed since Windows RT is not 64-bit.
Is nasm the problem? It looks to be an x86/x64 assembler... which of course wouldn't work on ARM... unless I just don't get what an assembler is...
Not being much of a coder I also don't know if one can import a Borland C++ project into Visual Studio, so maybe that is also a problem too.
So I guess I'm not sure on a lot of the points on the ground rules list...
domboy said:
My only suggestion would be a gui SFTP client. This is probably the one utility I am currently missing on my Surface RT (I use ssh to remote into Linux systems both for work and personal use, point #5). To clarify, I do use the psftp client in the putty suit, and that works well enough, just takes a bit more time and effort than something like winscp. I can continue to use this if an gui alternative is not feasible.
I recall someone requesting winscp at some point in the past, so I searched around this forum and I did find a couple of people that took a stab at it, but with no results, and I haven't found a clear explanation on what the hang up was. Looking at the readme winscp appears to be written in c++ at least (point #3):
I am unsure if the aforementioned Windows Platform SDK is available for Windows RT, or if it is even needed since Windows RT is not 64-bit.
Is nasm the problem? It looks to be an x86/x64 assembler... which of course wouldn't work on ARM... unless I just don't get what an assembler is...
Not being much of a coder I also don't know if one can import a Borland C++ project into Visual Studio, so maybe that is also a problem too.
So I guess I'm not sure on a lot of the points on the ground rules list...
Click to expand...
Click to collapse
Borland C++ is an alternative set of 3rd part C++ tools. Would take a bit of work to get a borland project to compile it under microsoft tools.
Nasm is an x86/x64 assembler yes. Assembly language is pretty much the lowest level of programming possible before writing in raw hex or binary. It is *HIGHLY* CPU dependent. Specifically the set of commands available in assembly is the plain text form of the exact instruction set the CPU has available which for x86 is different from ARM. The fact that nasm is required means that the project will have assembly in it, therefore an RT port will not be undertaken (one of the rules in the OP).
Sorry man, its proprietary tools and parts of it are unportable anyway. Doesnt mean another SFTP client can't be ported, just this one.
Here's my wishlist. I've poked at some of them, but I don't really have time to finish any of them.
WinPCap - Iirc, the biggest issue was that it was written targeting an older version of NDIS. The usecase would be to provide network support for BOCHS.
QEmu - There's a build of QEmu that builds on MSVC called WinQEmu, but it's dynarec recompiles to x86 only. I believe the official QEmu repo doesn't support MSVC, and I don't know if it can recompile to THUMB-2.
A good IRC client - X-Chat and mIRC run poorly under the emulator, and the few .net clients I've tried are meh. X-Chat has too many GCC-specific requirements, and mIRC isn't open source, I just want a good IRC client.
An X Server - I've been unable to find an X server that builds with MSVC, or anything short of Cygwin for that matter, but I'd love to have one.
Calibre is a good eBook manager I think this is the correct source code https://code.launchpad.net/calibre
I'm not good with this source code stuff so if its to much you dont need to make a port but if you can it would be appreciated thanks
Sent from my SGH-M919 using Tapatalk 4
cx1 said:
What the hell are you doing to get all these crashes? I have yet to have IE crash on 8 or 8.1 on RT in desktop or metro.
Click to expand...
Click to collapse
Browsing news sites and/or using Spotify.

[Guide] [Explained] Your first Android App

Introduction​
Hello guys and welcome to my first guide (be indulgent please haha)
In this guide I will show you how to build your first Android app, knowing java langage will be very helpful to follow up but it's not required.
In addition, we will not see a lot of Java in this introductory tutorial.
That said, if you want to go further in the development of Android applications, you will need to know Java.
In this guide we will create a very simple Android application ("Hello World!) The goal is to see basis of development.
What to expect from this guide
Setting up the development environment
A very simple example
I’ll be using Windows for this tutorial. However, there will be not much difference on another system (GNU/Linux or Mac OS X). You just need to adapt the instructions to your particular situation.
The toolbox : JDK
The toolbox : JDK​
As I said quickly in the introduction, Android applications are developed in Java. You may already have some of the tools that I will present here if you ever developed in Java. Well, so much better! It is much less work for you.
A word about Java
One characteristic of Java is portability, which means that computer programs written in the Java language must run similarly on any hardware/operating-system platform. This is achieved by compiling the Java language code to an intermediate representation called Java bytecode, instead of directly to platform-specific machine code. Java bytecode instructions are analogous to machine code, but they are intended to be interpreted by a virtual machine (VM) written specifically for the host hardware. End-users commonly use some special tools installed on their own machines.
These tools are included in the JDK. In addition, the JDK contains the JRE (so also the virtual machine), which is handy.
To summarize, there has two cases:
You are a simple user of Java : you must have JRE.
You are a developer : you need the JDK tools
Frequently asked question :
Since I tried to put myself in Java, I may already have JDK installed ... How do I know if this is the case ?
We will make a very simple little test (or rather 2 ).
Start by opening a command prompt in Windows (Start -> Programs -> Accessories -> Command Prompt) or a terminal if you're on a Mac or GNU / Linux.
To know if JRE is installed, type the following command:
Code:
java -version
To know if JDK is installed, type the following command:
Code:
javac
In both cases, if the command is not recognized, is that you do not have the tool in question (JRE or JDK).
If you have only the JRE, install the JDK.
If you have nothing ... Install the JDK: p (the JRE is included anyway).
In short, now that you know where you stand with your Java environment, you can do (or not btw) the installation.
While all of these explanations were not necessarily required, it is still better to know what is installed, right ?
Installing the JDK
The installation of the JDK will be faster than his explanations, I promise
downloading
To start, go to this address.
Click the "Download JDK" button.
On the next page, accept the license agreement and click on the executable to download : jdk-7u51-windows-x64.exe in my case
installation
To start the installation, double-click the executable previously downloaded and let it guide you (or run it from a terminal).
And voilà ! Here is the first brick laid.
Next steps are installing android sdk, eclipse and ADT plugin or you can just download and install adt bundle wich provide you with :
Eclipse + ADT plugin
Android SDK Tools
Android Platform-tools
The latest Android platform
The latest Android system image for the emulator
Thanks to @FreakOde and @Chain Hacker
Specific tools for Android : Android SDK
Specific tools for Android : Android SDK​
We have just installed the JDK. So now you have the tools to develop a Java program. That said, an Android application is a particular Java program. You have the basic tools but not the specific tools to Android.
The tool you are missing is the SDKAndroid. It contains what you need, not to develop a standard Java program, but to develop an Android application.
Download the Android SDK and decompression
To download the Android SDK, go here and choose the file depending on your system.
As you can see, this file is compressed (zip for Windows and Mac or tgz for GNU / Linux). Unzip it where you want on your hard drive.
Remember exactly where you put the decompressed content. His path will be needed for the future. I recommend a safe place that will not move.​
Personally, I put the contents of the zip in : C:\Android\android-sdk-windows
Add the SDK to PATH
Frequently asked question :
Ok I do not mind ... but what's the point?
No worries, before the manipulation, let me explain what it is.
What is the PATH?
When Windows (and this is the same principle on Mac or GNU / Linux) executes a command, it will search for it in specific directories...if it is not found in these directories, it considers that it does not know it and returns an error.
These specific directories are defined in what is called an environment variable: a variable (which, by definition, contains a value) accessible by Windows, everywhere, all the time.
The environment variable in question is PATH. To see its value, type the following in the command prompt in Windows:
Code:
echo %PATH%
You get a series of directories separated by ";".
It is in each of these directories that Windows searches for commands that you ask.
For example, the java command that we used earlier, is located in the C:\Windows\System32. Well I'm sure that this directory is in your PATH.
So now, we'll need that Windows knows where the new commands of the Android SDK are.
To add it to your path, execute this command :
Code:
set PATH=%PATH%;"path to android sdk"
So in my case I should execute
Code:
set PATH=%PATH%;C:\Android\android-sdk-windows
One last step is required to install the Android SDK. Do not worry, this is the easiest.
Installing Android platforms
The last step is to install at least one version of Android platform. According to the version of Android, APIs differ a little. At the time of this writing, the latest version of Android is version 4.4.2 (KitKat).
In the SDK directory, an executable is present: SDK Manager.exe. It's a small interface to manage versions of Android.
Run it to start the installation.
Among the available packages, choose the one you want:
{
"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"
}
Personally, I took everything! To be sure not to return.
On Mac and GNU/Linux, run from a terminal the "android" command in the directory / tools /.
The installation will take a few minutes (to me it was quite long since I took everything ...).
Once installation is complete, we can move to: Installing Eclipse.
Development environment : Eclipse
Development environment : Eclipse​As for the JDK, it may be that you already have Eclipse installed. If this is the case, great. You can now move on to the next section.
Otherwise, we will install it together.
Frequently asked question :
But in fact, what is Eclipse?
Eclipse is what we call an IDE or "Integrated Development Environment". This is a software that allows you to write programs more easily than simple Notepad in Windows (although it is possible). Besides the color code, it will bring you useful tools to compile your programs, debugging, etc.. It can be used to develop with any type of language, but we use it to make Java.
In addition, Eclipse is designed to be augmented with plug-ins. Thus, there is a plugin to develop Android applications ...! We'll see this in the next section.
Do you like it? Well let's go for the download and installation!
Download
First of all, go here and download Eclipse.
Choose 32 Bit or 64 Bit depending on your configuration (if you do not know , take 32 Bit ) .
On the next page , click on the big green arrow and ... wait for it to finish!
Installing Eclipse
Installing Eclipse really comes down to ... unzip the downloaded file!
You can place it anywhere on your hard drive. Personally ( on Windows ), the story that things are organized , I placed the folder " eclipse" in C:\Program Files ( or C :\Program depending on your version of Windows).
To start Eclipse, run the executable found in the directory "eclipse" (really , you guessed ? haha ) .
At startup, Eclipse will ask you the location of your Workspace. This is the directory that contains all the data related to your Java programs ( and thus your Android applications). Your source code will be stored there. This is the time , if you have a hard drive dedicated to your data, choose a directory therein. Otherwise, you can leave the default directory.
Well. Now , to develop our Android apps more easily , we need a small plugin.
A small plugin for Eclipse ADT
A small plugin for Eclipse ADT​
As I briefly mentioned in the previous section, Eclipse has been designed to be able to receive plugins. Depending on whether you are Java, PHP, Javascript developer, (...) you have at your disposal a whole bunch of plugins that make your life easier.
The plugin for the Android application development is called ADT (Android development tools).
This time we will not download the plugin on the website of his publisher but directly from Eclipse.
ADT installation:
So first start Eclipse. In the "Help" menu, select "Install New Software ...".
In the window that opens, click on "Add ..."
Enter the following values​​:
Name: Android Plugin (for example)
Location: https://dl-ssl.google.com/android/eclipse/
Click OK, and wait a few seconds. Then you get this window:
http://img15.hostingpics.net/pics/156355window.jpg
Check the "Developer Tools" (which also tick the underlying tools) and click "Next". In the next window, click again on "Next"
In the next window, accept the terms of the license agreements and click "Finish"
During installation, you may get a security warning.
It tells you that Eclipse does not know what you are installing. But we, we know. So you can safely confirm by clicking "Ok".
At the end of the installation, you are prompted to restart Eclipse.
We have one small thing to do before moving on to the next part: Configure the ADT plugin. We will tell the plugin where the Android SDK.
In the "Window" menu, select "Preferences".
In the left pane, choose "Android"
Click "Browse ..." and choose the location of the SDK installed earlier in this tutorial.
Click "Apply" then "Ok". And voila!
Setting a virtual device (for testing)​
To test our application, we use a virtual phone! Very convenient because it's cheap (well it's free )
Our virtual phone (yes you can have more than one if you want) are called "AVD", which leans "Android Virtual Device". It fits with what you want to do.
To begin, click on the little button as shown in the screenshot
This opens the AVD Manager. You should have no AVD yet. To create one, click "New ...". The following window is very important because it will define your "phone":
Configuring AVD could be a complete tutorial ... We therefore remain there for the moment.
Click the "Create AVD" button to complete the creation of your virtual mobile. You then end up with a beautiful AVD in your list. You can then close the "AVD Manager" to finally move to developing your first Android app
New Android project​
Finally! We reach the goal! Now it's good, our environment is in place. If you have not had any problems so far, you are ready to create a new Android project.
Create a new project
To begin, select from the menu "File" -> "New" -> "Project". With the ADT plugin, you now have the option to create a "Android Application Project". Select this option and click "Next". Then you come to the window, which allows you to initialize your Android project:
Here are the important information to fill :
Application name: This time it is the name of your application. That will appear in the very eyes of the user. You can put special characters if you wish.
Project Name : This is the name that will define your Eclipse project. You can put whatever you want but avoid spaces and other special characters.
Package name: By convention, the name of a package is in the form of a "url upside down ." You can put your personal domain name or whatever you want. As long as you do not post your application on a large scale , it is not very important.
Minimum required SDK: This is the minimum number required API to run your application. You can not install the application on a mobile with an older API.
Build Target : Select the version of Android on which you want to work .
Click "Finish" to create your project.
Application code
Code créé par défaut
Here is the code created by default:
Code:
package com.test.helloxda_university;
import android.os.Bundle;
import android.app.Activity;
import android.view.Menu;
public class MainActivity extends Activity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
}
}
This code contains various elements:
Package Name
some "import" android.*** : Required libraries to the script
The class MainActivity that inherits from Activity.
I will not detail what constitutes the onCreate() method because we will now change it.
Code of our "Hello XDA-University!"
The purpose of our application is to say "Hello XDA-university". For this, we need a field "text". On Android, a field of this type is a TextView (Android, all the elements are based on the View class).
We create our TextView with the following line:
Code:
TextView tv = new TextView(this);
This requires to import the corresponding library:
Code:
import android.widget.TextView;
we apply a text to our TextView:
Code:
tv.setText("Hello XDA-university !");
Finally, we apply the TextView to the current view:
Code:
setContentView(tv);
You will notice the following line:
Code:
super.onCreate(savedInstanceState);
It can tell Android how to start the application (we call the onCreate method of the parent class by passing the savedInstanceState, which is the previous state of the application).
Complete code (what a code!) of our application:
Code:
package com.test.helloxda_university;
import android.app.Activity;
import android.os.Bundle;
import android.widget.TextView;
public class MainActivity extends Activity {
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
TextView tv = new TextView(this);
tv.setText("Hello XDA-university !");
setContentView(tv);
}
}
With this, our text should be able to be displayed without issues.
Launch the application in the AVD
To launch the application, choose "Run" from the menu ... "Run"
The AVD will then take a few moments to start: you will see the letters "ANDROID" in gray on black background. This might take some time depending on your configuration.
Once the AVD is fully started, your application will launch automatically:
Ta daaaa!
Well I told you: nothing transcendent ... But we must start somewhere.
We arrive at the end of this tutorial dedicated to the establishment of an environment of Android development. This is not the only way.
There are many steps to finally not much except a little "Hello!" ... But you are now armed to get started with Android. I leave it to you to learn the art of developing Android applications: Sights, Activities, Intents, etc. ....
I hope you learned something with me and if you have any questions do not hesitate to ask me.
this is a great writeup. Thank you!
wfarid said:
this is a great writeup. Thank you!
Click to expand...
Click to collapse
You are welcome mate
subscribed for now. I might need this later. TQ
This is something great you have done dear..:good::good: Great tut BTW..:angel:
Probably u could have just told them to download "android bundle" from developer site..that could have saved a lot of their work
Cool..!
Sent from my Nexus 5 using XDA Premium 4 mobile app
great guide!
Just a suggestion: I think You can also avoid the virtual device's setup for testing because eclipse let You also to test the apps directly on the smartphone if You have usb debugging enabled ... it's quicker for me because a virtual device requires memory to run ..
Awesome TUT
Subscribing it might need it in future!!
Yhank You !
Dude a suggestion don't get angry you can just link to the ADT bundle instead of downloading SDK and Eclipse separately... By the way nice guide for starters.. :good: But you could have also included using XML stuff and not just the coding.. Just a suggestion.. After all they also need XML to master developing...
Amazing!!! I just start learning Java for a couple week now but now I can learn Android dev at the same time too. :good:
Hi...! Congratulations! Its an excelent guide. Im not a developer but reading the lines makes me want to learn more. If you ever want it to be translated just let me know. Salutes from Argentina!
Enviado desde mi Moto X mediante Tapatalk
Finally someone makes a guide using proper english!
Google has all this explained on the android website but it is as if they dont know english and wrote it all from a translator without the grammer!
So thank you! But a tad bit to late, i did all this a year ago (took me a few weeks)

Categories

Resources