Archive | Blackberry RSS feed for this section

BlackBerry Eclipse plugin 1.1 will fix some of the annoying problems

29 Mar

The next version of the BlackBerry Eclipse plugin will fix most of the annoying things about blackberry development.

Some of the most important things are:

1) No need to restart emulator for new build to be loaded to the emulator (Hallelujah!!!)

The new build should be just loaded onto the already started simulator, pretty much as on Android and iPhone.

2) Ability to add external libraries i.e. *.jar files to the project

This is actually pretty peculiar since RIM was pushing hard 3-d party (external library) integration as one of important concepts and obviously it would be very beneficial for the BlackBerry ecosystem but if you did not want to use JDE, there was pretty much no clean way to add external library. That is until the 1.1 plugin comes out from beta, or at least that what was promised at the New England BlackBerry developers meetup.

3) The BlackBerry plugin would follow the “Eclipse way”

The 1.1 plugin is very different from previous version. Instead of following the “JDE way” it will be much more the natural “Eclipse way”. This is both good and bad. This is very good for developers that have experience with Eclipse and just now start to develop for BlackBerry. This will however be somewhat painful for the seasoned developers who got used to the old plugin and will need to discover many things from scratch. (I personally felt quite lost with the new 1.1 plugin and decided to stick with the old one until 1.1 comes out of beta).

You can download the beta of 1.1 from here (you would need to have BlackBerry developer account which is free and can be obtained with simple sign up immediately)

Super App webcast Q&A follow-up

29 Mar

During the Super App webcast Mike Kirkup covered many questions from the attendees. I have gathered many of those in the webcast summary. He did not get through all of the questions and promised to answer all of the questions on blackberry development forum. He did just that and here is the Q&A extracted:

[Q] The problem I found with a super app that was tightly integrated with the address book is that people were looking to see an icon and not something that was just part of the existing BlackBerry UI.

[A] A good point.  Many users will still expect a simple icon for the application whether only to provide information on how to leverage the application or how to manipulate settings.  Fixmo is a really good example of this point.

[Q] Is there a way for my app to get notified when new notifications are shown on the device?

[A] Unfortunately, no.  But this sounds like a great feature request you should log via the BlackBerry Issue Tracker.

[Q] Is there a way to include full camera control in the application?

[A] Yes.  Check out JSR 135 (MMAPI) for more information on how to include the camera field within your application including the ability to modify zoom and flash settings.

[Q] With the definition of a “Super App” being one that you cannot live without, can a game be a super app?

[A] Great question!  Yes, a game definitely can be a “Super App” or take on many of the characteristics of a Super App including being notification driven, contextual (even location based), integrated with other applications and so on.  It isn’t hard to imagine having a game that you love so much that you can’t live without it.

[Q] Can I make a Super App by developing a BlackBerry Widget?

[A] Yes, definitely.  One of the most important attributes of the our Widget technology is that you can fully integrate your Widget into all of the same APIs that are available to Java applications whether exposed already through Javascript APIs or through your ability to write Javascript to Java APIs.

[Q] Do you plan on setting up a program to certify applications as Super Apps?

[A] No, we do not currently have any plans for certifying applications as a Super App today.  The concept here is to help people really understand not only the capabilities of the BlackBerry platform but also the possibilities on better engaging your users.

[Q] We have developed a collaboration application which works on a “pull” basis.  How can we leverage push?

[A] Check out our newly launched Push Services page for more information on how you can start leveraging push in your application whether for the enterprise or consumers.

[Q] Is it possible to add a custom menu item in any third party application?

[A] Yes, although not in a granular fashion today.  As part of the ApplicationMenuItem API you can specify that you want your menu item included in all applications on the device but you do not get to pick which applications if you don’t want all apps.  Can you submit a feature request in the Developer Issue Tracker if you think this is a good use case.

[Q] Suppose the application flow is such that screen 1 pushes screen 2, screen 2 pushes screen 3 and from screen 3 the user needs to go to screen 1.  Should the application push screen 1 again or pop screens to get to screen1?

[A] You should definitely maintain the proper ordering of the screens on the stack for the user such that your application will automatically pop off the top screen on the stack when the user presses the escape key.  So, in this case, it depends on your ultimate goal of the screens.

[Q] This is a great presentation but it gives very little to seasoned developers.  Will you have additional presentations with more details and more code samples? (Editor: this, I think is actually my question slightly rephrased)

[A] Yes, definitely.  This is the introduction to the concept of Super Apps and you will see additional webinar presentations that go into substantially more detail on all of the key aspects of bringing Super Apps characteristics to your application.  The Big Ideas, Little Screens UI Webinar from Brian this month is a perfect example of more involved webinars.

[Q] What are the OS or device requirements for the Javascript examples provided?

[A] These are part of the new BlackBerry Widget technology and require v5.0 handheld software.

[Q] You mentioned the Super Apps website.  Where is that?

[A] www.blackberry.com/developers/superapps

He also promised to keep posting answers so see the original forum thread here for more information

New England BlackBerry Developer Meetup group – first meetup notes

17 Mar

Last night I have attended local New England BlackBerry developer meetup group. It was a great event with nice turnout of about 50 developers with special guest – Mike Kirkup – director of developer relations at RIM.

Mike is a great speaker and a great guy in general. BlackBerry developers are truly blessed with Mike in that sense. So much has been done to ease up on the hurdles of BlackBerry development recently that it is becoming cool to be BlackBerry developer once again.

The meetup was hosted by a local software development company – SoftArtisans. They develop SharePoint solutions for BlackBerry.

Mike was give the stage and he went over the BlackBerry super app concept which was similar to the BlackBerry super app concept webcast he gave recently but a little different of course with some stuff oriented more towards developers.

The highlight was of course the free panel Q&A session which was afterwards. Mike, as usual, did a very nice job answering the questions of the many developers who brought up interesting questions.

Upcoming Products

  • BES Express (or BESX) which is the free, striped down version of the BES server. This will allow smaller businesses to put their employees on BESX without hesitation which originated from the costs of licensing associated with putting employees on BES.
  • Upcoming WebKit browser which will be blazing fast and super blazing fast for JavaScript.
  • There will be no iPad like device.

“No iPad, no BlackPad, BluePad, RedPad etc…”

  • Advertising APIs. Right now RIM is conducting a closed beta with their partners and should be soon available to all independent developers. There is no cap on the volume, meaning pretty much anyone would be able to integrate advertising in their apps.
  • Push APIs (well this is not an upcoming event actually, it went live today at 9am). Push API is available to everyone now and is free!
  • App World 2.0 will soon be launched. The next version of the app world will support not only the PayPal but also the carrier and credit cards. The share of developers will most likely be different across all the optios and across the different network operators as well. PayPal option will remain 20/80% split with 80% going to the developers.
  • In a few weeks the new Eclipse plugin for BlackBerry development version 1.1 should be released, which will address many issues existing in the older 1.0 browser. The official release of 1.1 which should go out of beta will be fully supporting 64 bit systems.

Upcoming Events

  • Very soon we would have “fast simulator experience” so painful to many developers that when announced, it was followed by applause storm. So fast simulator experience means no more restarting the simulator to load the newly compiled version. (Yey!)
  • More aggressive promotion of the App World. Mike mentioned that RIM intentionally kept the App World low profile for the first year letting the carriers figure out their distribution strategies.
  • Super App competition. The super app competition will be carried out with a different prize distribution model than previously. RIM decided instead of rewarding a few leading application with big bonuses, reward more developers with moderate bonuses. Mike mentioned that they expect 3000-4000 apps submitted to the contest (both new and existing apps can be submitted) and if your app passes the first criteria of actually being a super app, then you are already entitled to something. Mike threw out “a free device” in the air but I guess it is not yet decided. They may go with a free device or maybe discounted developer conference or maybe we could choose. Let us know in the comments what you would prefer. The prizes will be handed out at BB Dev Con in San-Francisco at fall and the submission deadline will most likely be July 1-st but this is not confirmed yet.

The painful question of over the air (OTA) OS upgrade was raised and Mike said that carriers feel  fairly confident with pushing OTA OS update starting with OS 4.6 since 4.5 being the first OS where OTA OS was introduced had some issues and bugs. He mentioned that from carrier’s experience OTA updates have a very high conversion rate. In the 80%-s while even the through browser+USB update is less than 20% conversion rate. Until most of the devices are 4.6 and up and carriers are more aggressive pushing updates to the devices, we will be stuck with the need to support older devices as old as 4.2.1. Which leads us to further interesting figures:

as of October 2009 the OS distribution is as follows:
4.2.1 97%
4.5 50-60%   – over the air update
4.6 30%
4.7 15%
5.0 5-6%
meaning supporting 4.2.1 will get you almost all the devices, while jumping to 4.5 and up will only give you about 50-60% and by going further up to 4.6, you will loose up to 30% of devices (this is due to huge number of older Curves and Pearls).
I will be wrapping up since this post is already quite long. Leave your thought in the comments!

Update

You can read additional notes summary at Chris Wong’s blog

You can download the Super Apps slides by Mike Kirkup which were presented at the meetup.

BlackBerry Upcoming WebKit Browser

17 Mar

RIM has unveiled the new upcoming BlackBerry browser based on the new WebKit engine.

At the New England BlackBerry meetup, Mike Kirkup mentioned that they are doing some neat tricks with precompiling JavaScript through MDS which makes the JavaScript blazing fast. You can see it for yourself in the embedded video.

The new WebKit browser will be available in the next OS release but the upgrade will be limited on per device manner since WebKit browser is quite resource demanding.

Anyways, it’s great news and good job RIM!

What makes blackberry app a super app – summary of webcast

25 Feb

What makes a Blackberry appliactoin to be a super app? This is the question that Mike Kirkup – head of developer relations at RIM tried to answer today in a free webcast. There has been an obsession recently with super phones and super apps as it seems. And why phones and/or apps have to be necessarily super?

So there seem to be two definitions of super apps according to Mike Kirkup.

If you take the blackberry phone from the user and he misses this app – then it is a super app since it provides an inherent value for the end user.

Another “definition” is more technical – so what are the main components that make a BlackBerry app a super app:

  • Always on experience
  • Seamless integration with 3d party apps
  • Notification driven
Not sure about you, but I see here a small misconception. On one side Mike says that if the application is extremely useful up to the point where if taken away from the user he will surely miss it but on the other hand there are specific points which actually make an app to be a super app. So what if the app is very useful to many people to the extent that they will surely miss it if taken away such as for example DailyHoroscope application for BlackBerry. Because many users of DailyHoroscope application are going crazy and flood us with mails in case we experience even minimal downtime. So the application is extremely useful to its users and certainly has value for them but according to the bullet points, DailyHoroscope is not a super app.
The source of confusion I think is that Mike meant if you take away BlackBerry device from the user, then other devices that may have similar apps will not be able to fill the gap. That’s what makes any BlackBerry app a super app I would guess. The push mechanism and the multitasking and deep integration is something that does not exist on iPhone and/or iPod Touch, but similar things exist on Android and WebOS and Maemo are also actively developed and progressing  towards richer and richer platform.

So what makes specifically BlackBerry platform a super app enabler platform accodring to RIM? The first and the point which was put most of the emphasis was the “multi-threaded OS with background apps”. Other enablers mentioned were:

  • Contextual integration with apps
  • Rich event based notification model that integrates deeply in the system
  • Efficient push services
  • Integrated LBS and Mapping

Mike argued that the possibility of deep native integration allows easier “native” application integration in a cohesive manner into the system. The main point seems to be that since the applications do not have to invent everything from scratch by using built in components/services etc, the applications can deliver unified user experience which lowers the learning curve for the applications and eliminates most of the confusion in mastering a new app.

Starting from OS 5.0 RIM introduced (or better say exposed to 3d party developers) much richer built in components such as autocomplete, file picker, map field, browserfield, media player components (JSR 135 or MMAPI)

The power of push. Mike mentioned that RIM invented the push and were running it in production for more than 10 years and they know exactly what they are doing. (hear that Apple? haha… ). The push limitation for BIS is 8KB while for BES it is much higher and is specified by BES administrator but is hard limited (by I think 1MB in the older BES versions with much higher limit value in BES 5.0 – I think around 10Mb)

Overall it was an interesting webcast and Mike did a great job talking about all the things that are great about BlackBerry platform. I personally was a little disappointed since I expected much more technical session.

Q/A Session:

Q&A session was quite interesting. Mike zipped through more than 200 questions in less than 40 minutes with great and to the point answers. Thank you Mike! I documented the most interesting Q&As to my taste and the ones that are most likely to be interesting to other developers.

  • When advertising will be available?
  • For BB alliance the beta will be opening very soon. For the rest of the publishers – the time line promised by Mike was approximately 2 month
  • Time for application approval?
  • Depends on the type of the application submitted. In general it is about 10 days but they are supposedly getting at about 48 hours time
  • Is the PUSH service free for all the developers?
  • It is free for almost all the alliance partners but they are working on releasing it to all the developers
  • All those super apps running in the background will make the devices slow – what about more resources for the devices?
  • Mike said that they will continue to innovate in the device area but the overall answer was extremely vague
  • More tutorials and code?
  • There is a lot of tutorials and code currently available online but it is hard to find it. Current knowledge base will be restructured and reorganized and mostly replaced by developer resources which is some new knowledge base.
  • Book for developers from RIM?
  • Working on that with authors and the community RIM is unlikely to release the book of its own.
  • Developers competition for super apps? Is it something that is coming?
  • RIM is planning to run super app development challenge in 4 regions very soon and pick up the best super apps and showcase them in BBDevCon in the end of September
  • When 5.0 JDE will be out of Beta?
  • 5.0 JDE will be out of beta soon and will finally NOT require simulator restart to push the new build to the simulator (YEY!!! Great news, hopefully Eclipse will mirror that as well)
  • UI tools for GUI building
  • Working on UI tool which will be drag and drop tool that will generate Java code for you (That would be a blessing, although knowing how RIM executes development tools projects, the tool might very likely be quite unusable for anything more serious than placing a label field with “Hello World”)
  • Paid applications worldwide timeline?
  • Worldwide is particularly difficult since RIM is supporting more than 150 countries. Support will be rolled out increasingly
  • Is JDE going to be phased out in favor of Eclipe?
  • Not right now. When RIM will feel that Eclipse has matured enough it will happen, but in general Eclipse is destined to replace the JDE
  • Are other development platforms going to be supported except Windows?
  • Mac is in the pipeline and support is likely to appear until the end of the year
  • App World is not as advertised as Apple’s App Store
  • Rim will start being much more aggressive about promoting App World in the future but this is highly dependent on RIMS relations with carriers since RIM is tightly integrated with carriers and they rub each other’s shoulder. (well, of course…)
  • Payments through carriers as opposed to payment through PayPal
  • App World 2.0 will have options to pay with either credit card, PayPal or through the carrier
  • Is Verizon’s store going to compete with App World?
  • Not really as RIM is not competing with any of the 3d party stores like Handango, GetJar etc…
  • Are subscription based payments going to be supported in App World 2.0?
  • It is not clear exactly what it is going to be, but some sort of subscription payment will be available
  • What is the best cross framework to use for developing for BB? PhoneGap
  • PhoneGap is great but the apps built with those cross platform frameworks will not be super apps! This is not possible since those frameworks are targeting the lowest common denominator.
  • Suggested books?
  • There are 2 good books John Wargo which is more like a reference manual. Anthony Rizk is more smooth read book and is less like reference.
  • What is the OS version to use as the lowest common denominator for development of super apps?
  • 4.6
  • Can I create a super app with SDK prior to 4.6
  • Yes you certainly can – many of the capabilities are available in the prior versions of the platforms
  • What is the process of migrating a simple app into a super app?
  • Think about how your simple app can take advantage of all the mentioned components that comprise a super app. Start thinking about your application and you will most likely realize that there are many ways to improve
  • Monitoring f uninstall of your own app – will it possible?
  • This is something that should be available in the next version of the next version.
  • Are free apps going to be able to use payments for donations?
  • Certainly – using in app payments is possible for that
  • Is advertising network be available worldwide?
  • Yes at the launch the advertising service will be available worldwide and then local advertising agencies will be added locally
  • What are you doing for developer training especially in Asia and Africa?
  • RIM will run BlackBerry developer days around the world. Follow our development blog for more details and updates.
  • Knowledge base is broken, I can not find any information there
  • The KB will be phased out and replaced with BB resource center
  • When normal developers will be able to use BIS?
  • This is something that RIM will be doing soon
  • Samples of a super apps?
  • Poynt app that was highlighted through MWC definitely have several characteristics of a super app
  • Are there any security risks with all this deep integration of the apps into the system
  • There is a
  • Any battery drain issues with the application always on interfacing with different system components?
  • RIM will release a simulator that will be able to simulate battery drain of the applications

Problems running BlackBerry Simulator (fledge) on Windows 7 64 bit

22 Jan

As I already wrote, BlackBerry development is not a lot of fun.  Not only you basically can not develop in Linux and OS X (although there are some workarounds, it makes the process even more painful than it already is). But you will also have problems with 64 bit operating systems. RIM is in a position that they do not officially support 64 bit systems.

The main problem with 64 bit Windows 7 for me was that I can not close the simulator (or actually the “fledge” application that runs the simulators). There are 2 possible solutions to this problem:

  1. Kill the task through task manager
  2. The simulator should close if you are in debug mode and you disconnect the debug session

There is also another inconvenience which is caused by your cautiously guarding Windows system. It will warn you every time that (Oh my!) fledge will change something on your computer. You know – the standard User Control Account message. To avoid that message always popping up, you will have to adjust your setting in User Control Account panel. Hit “Windows” then just type UCA, you will get it. Adjust it to the minimum and you’r good to go.

BlackBerry development with Eclipse plugin – fixing corrupted *.jdp file

13 Aug

It’s not a secret that Eclipse plugin is very buggy and although it has improved a lot over the time, the blackberry plugin still has a lot of issues and quirks. One of the problems that have been bugging me a lot was that sometimes the *.jdp file gets corrupted. This is the file where BB plugin for Eclipse saves most of the meta data for the project, including the files that are included in the project and consequently need to be compiled. So, many times I had problems with SVN meta data files corrupting this project, or sometimes perfectly legitimate *.java files that get stuck in the *.jdp file, but do not exist anymore. The result of the *.jdp file being corrupted is that your application does no longer get compiled and redeployed when you run it. And the worst part, Eclipse would not explicitly let you know about this. It would silently fail and not re-deploy the app. So unless this is the first time you run the application, or the changes you made are not visually obvious, you would not know about this. But this is completely separate issue. One of the many issues with BB Eclipse plugin already covered. Each time I have been struggling (sometimes for significant amount of times). Couple times I was able to manually delete files from the *.jdp file (although this is not recommended by RIM) and this solved the problem, but mostly I had to recreate the whole project from scratch, which if your project is large and, which is more important has dependencies on libraries, may become painful if you need to do this every few days.

So the easiest way I found so far to solve this problem is:

  1. Delete the *.jdp file (you can just rename it to *.jdp.OLD)
  2. Delete the project from Eclipse (right click the project and choose delete). DO NOT however check the checkbox “delete the contents of the project from disk”
  3. Create a new project and point it to the same place.

Since all the Eclipse project related files remain untouched, you should get your project exactly at the same state it was before it got corrupted, minus the corrupted part. Why – because when you re-create the project Eclipse plugin should re-create the *.jdp file.

Showing a dialog (or screen) from a background thread on BlackBerry

9 Jun

If you need to pop up a dialog or any screen actually from a process that runs in background on BlackBerry, it is fairly easy to do, unfortunately it is (as pretty much everything with BlackBerry development)  easy to figure out how to do.

The following piece of code should do the trick:

		synchronized (Application.getEventLock())
		{
			Ui.getUiEngine().pushGlobalScreen(new CLAScreen(), 1, UiEngine.GLOBAL_QUEUE);
		}

There are also a few things you should be aware of when using this code:

  1. Your backgroud process should implement UiEngine. Easy way is to extend Application.
  2. If you change UiEngine.GLOBAL_QUEUE to UiEngine.GLOBAL_MODAL, the dialog will block your thread until it is closed

Android development vs. Blackberry Development

11 Apr

I was contemplating quite a lot about the title for this post. Originally I wanted to give it the title of “Why developing for Blackberry sucks” but then I thought it might be too harsh and does not really reflect the content of the post which is about comparing the experience of developing for Android and experience of developing for Blackberry and settled for the current title. There were other titles revolving in my head, but all of them were just variations of  the original “why developing for Blackberry sucks”

I have been developing for Android for some time and lately I have been working on developing for Blackberry and I must say development for Android wins hands down in all aspects. Many times, especially frustrated with Blackberry buggy IDE or other cumbersome experience I wanted to write this post, but I had to find the time for it.

So what is so bad about Blackberry development? It starts at the very basics – development environment. Google has developed a very nice plugin for Eclipse which works very well and even has the basics of support for visual editing of user iterface screens. RIM – the company behind Blackberry for a long time had their own development environment – JDE. Written using basic SWING components, there’s no need to mention how bare boned and outdated it looked. They have recently introduced Eclipse plugin as well, but it is pretty buggy and half baked. It is hundreds times better than the first version of the plugin, but it is still from being stable and feature rich.

Then we have the emulators – gosh, why do I have to restart the emulator everytime I want to test a new build? It can take up to a few minutes to restart the emulators for the more advanced models. To feel the pain, just imagine the nightmare of programming the UI for Blackberry in that setup. And no, there is no visual helper that can show the layout quickly, not to mention visual builder.

The compiler, or more exactly the packager – “rapc” has many times weird problems and behaves like a whiny child with lots of attitude problems. Same goes for the MDS server emulator.

Compared to Android, this can be nightmare. Yes I’ve had some issues and observed buggy behavior with aapt while developing for Android, but it was quite easy to resolve. For the UI part of the development, Android beats Blackberry as well. Constructing layout using XML is much easier than writing actual Java code. (Apple had actually went one step furthergiving the developers visual tools.)

Localization is much easier in Android as well. Besides conceptually being easy, the support of the Eclipse plugin for localization is half baked and buggy and what’s most important, it is not that easy to find documentation on how to implement localization for Blackberry in Eclipse.

The last but not the least (and in fact probably most important) is the vibrant, enthusiastic and active community of the Android platform. It is so much easier to find answers to any problems you have while developing for Android. I was a little considered about Android being all open source in a sense that there is no central authority with central responsibility for certain things, and Blackberry has all this and it turns out that what many enthusiasts can do, easily outweighs any size company organized or not.