Thursday 11 August 2011

Eclipse build workspace task stuck

Today I have strange problem with Eclipse. When I try to configure build path of one of my project Eclipse start to build workspace but couldn't finish. Build workspace task just hang.

I have to start task manager (TIP : in Windows you can do that by pressing CTRL+SHIFT+ESC keys)and kill Eclipse process.

I ask Google and find this page http://www.eclipsezone.com/eclipse/forums/t61566.html. There was advice there to run Eclipse with -clean parameter. And it work like a charm :).
But what this parameter do? From Eclipse documentation :
if set to "true", any cached data used by the OSGi framework and eclipse runtime will be wiped clean. This will clean the caches used to store bundle dependency resolution and eclipse extension registry data. Using this option will force eclipse to reinitialize these caches.

Lot of more information you can find on article mentioned above.

Wednesday 10 August 2011

5 Android developers mistakes

There is a lot of mistakes you can make when you develope new application. I want to show you 5 of them I found to be important.

1.Soon release
Developers often think that they should release their application as soon as possible. It is true but you have to remember that your product should be complete before you can sell it. Image that you just bought a bread but it is baked only in half ;). Remember to always implements core functions before you release application. Some people may argue and say that when you release you have feedback from your users. It is true but remember that in Android Market each user can give a rate to your application. If it lack of main functionality people will rate it low. It is always better to take your time and make you application a “killer app”.

2.Lot of bugs
This problem usually comes with soon release. When you want to release soon you software is not well tested and usually full of annoying bugs. Always make at least this tests :
*Check your application in as many resolutions and screen destinity as you can. You can do that by creating custom Android emulators using SDK.
*Simulate usually use of phone. Try to response to income call when your application is running, answer to incoming text message etc.
*
It is impossible to find all the bugs in your application (every not trivial software have at least one bug).

3. Commercials only apps
Developers often create application only to put commercials in it. They put commercials in each screen of they app. Remember that people doesn’t like this boxes. They can click it to appreciate your work or because commercial is interesting for them, but if you design your application in way that users can click in commercial by mistake sooner or later (often sooner) people become irritated by your program and they will uninstall it. Android Market gives you tools to monitor how many active installations you have. Even if your goal is to make money on commercials remember that your application have to be useful first.

4.Too often updates
When you release your application you will get user feedback or bugs reports (Android Market give you great tool for bugs reporting). Don’t try to implements new features or fix bugs as fast as possible and release new version. I suggest to plan update once a week or even one update in two weeks periods.This have another advantage : you application will be shown in “Just in” applications in Android Market. Make a lot of small updates may irritate your users.

5. Ignoring users requests
User pleasant should be always main purpose of creating a application. If you will listen to your users and make changes as they request your application will be popular and will bring you profits. People often leave comments in Android Market and let you know what is wrong with application or what should you add. It is grate source of new ideas and improvements.

Thursday 28 July 2011

New external hard drive

Yesterday I had bought new external HDD. It is Iomega® Prestige™ External Hard Drive and I use it as my backup device. There aren't many reviews of this model so I will write short one. I suggest to always have good backup solution. It cost me a lot of stress when HDD in my PC start to making noises and suddenly die. I lost a lot of data including Android market key store file :/. As a result I can't update my applications because updates have to be signed with same key as original app file. So always key backup of your key store file and remember passwords to key store and keys it contains.

Now something about new disk. It is 3,5 inch model with external power. It use USB 2.0 and is preformatted with NTFS (1,36 TB). Inside there is Samsung HD154UI drive. It is quite heavy. More data you can find here.


I ran just one benchmark :



It shows that avarange read speed is 26.5 MB/s. It is standard result for USB 2.0 external hard drive. Access time may be little bit better but it is backup drive so it is not so important.

With this disk you get a lot of free software including :

-Trend Micro Internet Security (1 year free subscription)
-Iomega QuickProtect for Windows
-MozyHome Online Backup(2GB for free)
-EMC Retrospect Express HD for Windows
-EMC Retrospect Express for Windows
-EMC Retrospect Express for Mac

I will install only EMC Retrospect on my laptop and write a post about it.

If you have any questions about drive or included software leave a comment and I will try to answer all questions :).

Friday 22 July 2011

How to sign Android apk file

After developing Android application you want to release it. To do that you have to prepare apk package. One of the steps is signing apk file. This can be done using Eclipse ADT plugin export wizard or jarsigner and keytool from standard Java distribution. I want to show you how to sing apk file using Eclipse.

Right click on your application in Package Explorer and select Android Tools -> Export Signed Application Package...

You will get this window :




Just specify project name here. Click Next.

In next window you can choose keystore. If you exporting your application for first time choose Create new keystore, select name for keystore and your password. Remember that password! It is very important because you won’t be able to update your application if you loose you key or forget password. Google check if your update is signed with same key that was used to sign earlier release. If not user won't be able to update and the only way to upload your application to Android market is change package name and release it as a new product.



Next step is providing details about your key. You should use one key to sign all your applications. Just fill this window with information about you. Remember to choose long validity (for exemple 30 years). After you finish click next.


Here you have to choose destination of apk file.



When you click finish you will get apk file which is ready to upload to Android market.

Thursday 21 July 2011

Hello World :)

Hi everyone!

My name is Maciek, I'm from Poland and I want to start another blog about Android programming. What you can expect to find here? Mainly how to code and how to use tools to develop Android applications. Some posts may be about programming in general. I also hope that I will learn something from you. If you have any comments or suggestions about this blog fell free to leave a comment. So I hope that both you and I will enjoy. Let's start!