Discussion:
Delphi XE6 Android app doesn't show properly (seems to close).
(too old to reply)
Skybuck Flying
2014-07-26 19:55:52 UTC
Permalink
Hello,

I just created my first android app with Delphi XE6.

Debug and Release version can be installed in bluestacks, but when the app
is run it seems to close or minimize or something nothing is shown.

It's basically a simply app with a button and a label.

Also when trying to run it with Delphi XE6 default android emulator that
also fails, breakpoints/debugging also not possible.

gdbserver seems to be started but then closes.

I wonder if installation path with a space in folder name might be causing
troubles.

I installed Delphi XE6 to:
C:\Tools\RAD Studio\14.0\

I noticed \Studio\ was default... so maybe that a hint that spaces might
cause troubles, though default would be \program files\studio which also has
a space in it.

I also noticed spaces in alias causes problems with signing... a signing
alias may not contain a space or perhaps the parameter for alias needs to be
wrapped in quotes.

Any ideas why the app is not showing properly are welcome.

I haven't tried any iOS simulator yet... may try that later.

So far my experience has been/is that it's all quite slow... the compiling,
the building, the deploying, the starting... at least on android.

But it's probably faster than the competition... and a whole lot less
hassle.

Now if I can just get the app to work properly in android lol.

So far the youtube video is not exactly my experience:



Is it a lie... or is it a problem on my system ? I am using an old cpu: AMD
X2 3800+

Maybe emulator doesn't run properly on it because of newer instructions used
or so ?!

Don't know.

Bye,
Skybuck.
Skybuck Flying
2014-07-26 20:10:41 UTC
Permalink
Oh... I was messing around with delphi xe5 earlier... and I tried to create
a virtual device and such... and now it's being reported by android avd
manager that when delphi xe6 tried to launch it... that the launch failed.

So I guess the problem is with the virtual device.

First a proper virtual device must be created/installed so I will try that
now...

Delphi XE5 was already deinstalled because I was considering installing
delphi xe5 update 2.

But instead Delphi XE6 update 1 ISO was installed and is working.

So I will delete the old virtual machines/devices and try to create a new
one.

I do find it kinda odd that Delphi XE6 did not create it's own virtual
device...

Also AVD manager updating some stuff..

I also had to terminate some processes manually such as:

Rad Studio Installer.exe or something like that it was consuming a lot of
CPU.

Also arm-emulator.exe or something and...

adb.exe which seems to prevent an update from installing properly... folder
in use according to the manager.

I have no idea what adb.exe as this point but it is related... after it was
terminated the update could be done successfully by clicking try again.

So far so good...

Bye,
Skybuck.
Skybuck Flying
2014-07-26 20:39:49 UTC
Permalink
adb.exe is Android Debug Bridge...

http://developer.android.com/tools/help/adb.html

So it's indeed related.

Anyway... It could still be adventageous to install Delphi XE5 as well, I
think Delphi XE 5 can support android 2.2.3 or something... or maybe api 3.0
or something.

Delphi XE6 says android 4.0 supported which might be a bit high.

I am not sure if my mom's Samsung Galaxy Tab 10.1 automatically updates the
OS to latest Android API version ?

http://docwiki.embarcadero.com/RADStudio/XE6/en/Creating_an_Android_Emulator

I will still try and create a android 3.0 virtual machine to see if and how
badly delphi xe6 might fail to run it or maybe it will run.

I have no access to mom device's right now.

So then I ll have to assume 4.0... at least I might be able to test in
bluestacks.

And if it wont work on mom's tab later on... then I may give Delphi XE5 a
try.

I must remember not to associate delphi's files with it... because I do want
to use the latest Delphi XE6 for desktop apps and such.

Though usually I just open via IDE anyway and not windows explorer.

Taking a long time to download all these android sdk apis.... could be cool
though...

I like proper api versioning it's kinda cool if it works ;) :) =D

I wonder how many megabytes/gigabytes all apis combined are ?!

My C drive slowly getting full over the last few months... let's check:

575 GB still free... so that should be plenty for now... yeah for
terradrives ! ;) =D

Euhm... I did notice another little problem which I definetly didn't like...

My first little android appie... consumed 200 MBs ! in my delphi
folder/image.

That sux bad !

Cause I like to copy & paste folders to do manual versioning... this would
quickly consume my delphi source code image's space which would suck bad.

Furthermore moving the project files/sources to another folder caused a
little build failure... re-saving the project file solved that problem it
seemed.

(I was testing replaces spaces with underscores to see if that solved the
alias problem/signing problem... but it turned out at least the alias itself
must not contain spaces for now.)

Bye,
Skybuck.
Skybuck Flying
2014-07-27 02:57:28 UTC
Permalink
So far the android emulators that come with the android sdk are very slow..
too slow to do anything serious.

I will still try and see if it helps to run/debug a delphi xe6 app now that
the emulator is running a little bit.

I wonder if there are maybe other options for run android/emulators that
perform faster.

vmware comes to mind... maybe even bluestacks.

Bye,
Skybuck.
Skybuck Flying
2014-07-27 03:07:06 UTC
Permalink
I was just gonna retest the debugging... but since updating the android sdk
a new problem seems to have emerged:

[PAClient Error] Error: E2820 Could not find program, 'C:\Tools\RAD
Studio\14.0\PlatformSDKs\adt-bundle-windows-x86-20131030\sdk\tools\ZipAlign.exe'

Hmm I am guessing either the tool is missing or the folder was changed.

I think probably last... it renamed old sdk to old or something and then did
something new probably..

Let's check that:

Current subfolder is:

adt-bundle-windows-x86-20131030
adt-bundle-windows-x86-20131030

Seems similiar so no... folder name was not changed... hmm weird...

Now me at a loss.. i ll try resaving the project file.

Rebuilding/Recompiling/Redeploying etc too, result:

No problem remains...

Developing android applications with Delphi XE 6 remains a pipe dream for
now.

It's probably at the same quality level as Delphi for .NET which also ended
up in the trash can.

What the faith will be for Delphi XE and android support remains to be seen.

For now I have hit nothing but problems, configuration questions, what kind
of resolution a device, missing specs somewhat... questions about memory, vm
sizes, etc.

Huge ammounts of time wasted, though that goes a little bit with the
territory.. of learning a new platform, but this is not a platform, this is
fragmentation at it's finest. Like getting shot with a shotgun ;)

Many emulators also seemed to fail, UI stopped working, or eventually it
would work but very slowly...

So for it's quite sick in a bad way mind you.

Bye,
Skybuck.
Skybuck Flying
2014-07-27 03:50:49 UTC
Permalink
Ok problem solved...

There are two blue packages, and then there is a third green package called
"build-tools" version 20... look very carefully it's easy to miss cause it's
skewed font looks like it's obsolete or something but it's required...

Re-building little test appie, Deploying little test appie. Last time I
looked at apk file it was 5 MB ! just for "hello world" I guess it's fire
monkey framework or some delphi special framework inside of it or
something...

So far so good... both successfull... now I ll try to run it with the latest
android 4.4.2 os device emulator to see if it will debug properly.

I don't like the new run without and run with debugging icons in delphi
xe5/xe6.

I liked the red bug icon better it was more clear. Had to cancel it guess it
didnt run with debugging.

Also I consider: "run" to be without debugging. But apperently Delphi
inverted this logic somewhere along the way.

Wasn't it called: "run with debugging" sometime ago... oh well maybe I am
dreaming.

Weird to call it: "run without debugging".

I consider debugging to be something special. And just run to be normal.

Interesting it asks if I want to start the debugger/emulator or something
cause it wasn't running hmm..

I wonder if the usb cable can be virtualized or a protocol used or so...

So far so good, title says: AMD 5554:Latest.

I wonder what this number means... is that a port number or something ?
Perhaps that's the reason why the emulator
is so slow... it's communicating via a protocol/network communications
protocol.

Instead of directly hooking into the emulator or so... at hooking points or
so ?! ;)

Now I will have to wait multiple minutes while android boots...

A black boot screen will eventually come up with a shiny grey/light blue
android logo... with white shiney light traveling over it ;)

Me waiting... waiting... :)

I am still waiting, since my posting of the zipalign problem another 40
minutes or so have past... and android 4.4.2 still booting.

The slowness is pretty unbelievable when compared with bluestacks which does
run very fast.

It's pretty safe to say that the emulators that come with the android sdk
are totally useless for now.

Maybe they can be run on another computer or so to speed stuff up once it's
running but I doubt it even without running delphi the emulators can be
started and take very long.

I am now going to cancel this because it's taking too bloody long.

The only thing left to test is add "windows 32 bit platform" and use a
feature called: "mobile preview".

This is kinda lame but maybe this will allow me to debug it which will then
probably work fine... but still fail on bluestacks/android.

I think it's safe to say that Delphi XE6 for mobile development for now is a
big fail... at least with a single pc.

I still don't know why my simple appie won't run on bluestacks...

And I also don't know yet how to install this app on the emulator which is
also kinda annoying.

The menus are different from everything I have seen on the internet so
far... in blue stacks as well as in the emulator...

Inconsistency is the one word to describe all of this crap. There is plenty
of inconsistency. This can be called: "inconsistency-planet".

Even simply things like: "about phone" or "about tablet" or missing,
Figuring out something simple like which android version is running seems to
be impossible for now, no app, no menu, nadda, google will be misleading it
offers solutions which are not real solutions inside these emulators because
of the inconsistency between real world (?) and emulator world(?) weird !

Bye,
Skybuck.
Skybuck Flying
2014-07-29 07:18:25 UTC
Permalink
Some of the slowness can be explained by out of memory situations and paging
to disk.

At least Andriod Studio consumes close to 1.4 GB of RAM.

BlueStacks can also consume close to 1.4 GB of RAM.

By inspecting "Free" on task manager's performance tab this can be
witnessed.

A solution to improve performance is to first close one of the two and then
start the other.

This will prevent massive paging to disk which is slow.

This improves performance considerably.

If Delphi and Android emulators also have this problem is unknown for now.

Running Delphi and other apps at the same time would definetly increase the
paging problem.

I would definetly recommend a development system with at least 8 GB of ram
perhaps even more.

Bye,
Skybuck.
Skybuck Flying
2014-07-31 05:05:50 UTC
Permalink
I saw somebody mention that Delphi XE5 apps do work in BlueStacks player.

So I just installed Delphi XE5 and then I made a little test appie... and it
actually runs in BlueStacks player.

First there is a black screen... and then it takes a while... but eventually
the button1 and label1 did show up and pressing the button did modify the
label1.text.

Thus so far it's working... which is a blessing... no buggy android studio
needed... no akward eclipse needed... and best of all no shitty complex java
exception language bullshit needed ! ;) =D LOL.

And now I can go make a very dirty nasty appie that will set the world on
fire ! ;) =D

Joepie lol.

Bye,
Skybuck.
Skybuck Flying
2014-07-31 05:07:27 UTC
Permalink
"Skybuck Flying" wrote in message news:adaf9$53d9cea4$5419aafe$***@news.ziggo.nl...

I saw somebody mention that Delphi XE5 apps do work in BlueStacks player.

So I just installed Delphi XE5 and then I made a little test appie... and it
actually runs in BlueStacks player.

First there is a black screen... and then it takes a while... but eventually
the button1 and label1 did show up and pressing the button did modify the
label1.text.

Thus so far it's working... which is a blessing... no buggy android studio
needed... no akward eclipse needed... and best of all no shitty complex java
exception language bullshit needed ! ;) =D LOL.

And now I can go make a very dirty nasty appie that will set the world on
fire ! ;) =D

Joepie lol.

Bye,
Skybuck.

(Oh and one more thing... the samples/demos in Delphi XE 5 have all kinds of
missing properties... very sloppy of them... shows how little the test stuff
! ;) ha-ha.)

Loading...