Attention Android Developers, learn how to convert your APK to a BlackBery 10 app in a few minutes

With the arrival of the new Android Runtime for BlackBerry 10, supporting Jelly Bean 4.2.2, now you can convert pretty much any Android app to a BlackBerry 10 app.

Recently, new tools were also released to help you on that process, they are called BlackBerry Tools for Android Development 2.0 Beta (see details).

Two of the main updates are:

  • No need to download the entire (and heavy) Android SDK
  • Now the command-line tools have a Graphical User Interface (GUI) to guide the developer throughout the conversion process

In this tutorial, you will see all the necessary steps to convert your APK to a BAR (BlackBerry Archive) in order to have you app available in the BlackBerry World application store.

Let’s get started?

Step 1: Click here to download the Command-line tools for Android Apps 2.0.1 Beta (3.3MB)

Step 2: Extract the .zip contents to your computer
Extract the .zip content to any folder in your computer.

Step 2.5: Make sure you have an ID token to sign BlackBerry 10 apps. You need to sign your app if you plan to submit it to BlackBerry World. If you don’t have your ID token already, please follow the two steps below, otherwise just jump to Step 4.

  • Request your BlackBerry ID token here. Choose the first option (“For BlackBerry 10…”) and you will be redirected to the BlackBerry ID login page (create one BlackBerry ID if you don’t have one, you will need to confirm via email, then click back on the link above to login). After logging in with your BlackBerry ID, the next step is to choose a password (keystore) for your BlackBerry ID token (recommendation: choose a simple password such as 87654321 to avoid forgetting it). Then your bbidtoken.csk will be generated and downloaded to your computer. Save the file in the following folder (create the folder if you don’t have one):
    * Windows XP: %HOMEPATH%\Local Settings\Application Data\Research In Motion
    * Windows Vista, Windows 7, and Windows 8: %HOMEPATH%\AppData\Local\Research In Motion
    * Mac OS: ~/Library/Research In Motion
  • After having your bbidtoken.csk in the right folder, you will also have to generate an author.p12 file, which will show up beside your bbidtoken.csk file. In order to create your author.p12, from Finder (Mac) or Windows Explorer (Windows), navigate to the folder extracted on Step 2 and find the /bin folder. In there, you will find a guy called blackberry-keytool. With your Terminal (Mac) or Prompt (Windows) opened, drag that guy and release it on top of your terminal window. Then type -genkeypair -storepass -dname “cn=Your Name”.
    The instruction will look like this: “extracted folder path”/bin/blackberry-keytool -genkeypair -storepass -dname “cn=Your Name”
    Press ENTER to run the command and your author.p12 file will show up beside your bbidtoken.csk in the right folder. That’s it! Now you can sign BlackBerry 10 apps and submit them to BlackBerry World. Let’s get back to the porting steps, you can jump to Step 4.

Step 3: Open Terminal on a Mac or Command Prompt on Windows
Mac: click to the magnifying glass (top right on your screen) and type Terminal
Windows: click on START, then RUN then type cmd
Hit ENTER.

Step 4: Open the APK Packager GUI
On Finder (Mac) or Windows Explorer (Windows), navigate to the extracted folder on Step 2 and find the /bin folder. In there, you will find a guy called blackberry-apkpackager. With your Terminal (Mac) or Prompt (Windows) opened, drag that guy and release it on top of your terminal window, then type -gui. It means you will execute the command blackberry-apkpackager passing the instruction -gui to open its GUI (Graphical User Interface, or visual assistant).
The instruction will look like this: “extracted folder path”/bin/blackberry-apkpackager -gui
Hit ENTER and this window will open:

Step 5: Convert your APK
With your GUI opened, select your APK, check the option DEPLOY and then click on the PACKAGE button.

If you don’t want to sign your application, but test it on a BlackBerry 10 device, you will need a Debug Token. To create one and send it to your device, with your GUI opened, click on ADVANCED SETTINGS and with DEVELOPMENT MODE checked, click on the button beside the Author field. Then, with your device connected via USB, click on DEPLOY DEBUG TOKEN.

Step 6: Testing your new app on your BlackBerry 10 device
As soon as the packaging process finishes, the BlackBerry Deploy window shows up:

Check if your device is with DEVELOPMENT MODE on (SETTINGS>SECURITY AND PRIVACY>DEVELOPMENT MODE).
If you’re connected via USB, remember that the device IP will be 169.254.0.1, if it’s over Wifi, type the network IP. Type your device password and click on INSTALL.

That’s it! Now you can test your .bar (BlackBerry 10 app) converted from an .apk (Android App) on your device.

If you decide to submit your .bar to BlackBerry World, remember to repeat Step 5, now checking the option SIGN.

Then create your vendor account on https://appworld.blackberry.com/isvportal, submit your docs and as soon as you’re approved, you will be able to submit your signed .bar and publish your app to the entire community of BlackBerry 10 users all over the world.

If you are an old BlackBerry developer used to keep (and do backups) of your signing keys (barsigner.csk…), that process has changed (as you saw above). Now everything is done with your bbidtoken.csk, which can be downloaded to any computer every time you need to sign apps (just repeat Step 2.5 to get there).

But what happens if I’m an older developer, always did backups of my keys and have apps already on BlackBerry World?
Great question! And the solution is very simple, you just need to link your new bbidtoken with your old barsigner.csk, once.

Having problems converting your APK?
In a few cases, APKs can have execution problems, because they use some native core Android services. In the case of maps, the MapView v2 won’t work, and the solution is: 1) use MapView v1, or 2) replace your map with a WebView and use Google Maps with HTML5.

Good luck and happy porting!

BlackBerry Launches Tech Center in Rio de Janeiro in Partnership with PUC-Rio

The BlackBerry Tech Centers in Brazil are designed to help students and developers take advantage of the growing global mobile ecosystem

BlackBerry® (NASDAQ: BBRY; TSX: BB) opened the doors of its fourth BlackBerry® Tech Center in Brazil. The center launched recently is a partnership with PUC-Rio. The program serves a dual purpose: to provide ongoing training and the space and resources necessary to help students and developers to create and test new mobile applications, and to nurture their entrepreneurship by helping to generate business opportunities for them.

The Honorable John Baird, Canadian Minister of Foreign Affairs, who participated in the Tech Center launch ceremony said, “PUC-Rio has a long history of collaboration with Canada, especially with the University of Waterloo. The partnership between BlackBerry and PUC-Rio with the opening of the Tech Center will foster innovation, create jobs, growth and prosperity in both of our countries and in international markets”.

Continue Reading…

Creating Innovative Interfaces with Design Thinking

After speaking “code” all year long, for my last talk in 2013, I decided to talk about topic that I also love: Design Thinking. It has amazing tools and methods to create innovative products, interfaces and services.

Let’s focus on empathy, on defining the problem with point of views and personas, on ideation, prototyping and testing. Let’s INNOVATE!

Thanks for all the support in 2013, BIG thanks to all developers, designers and students who saw my talks, asked questions and made me a better evangelist.

Thank you BlackBerry and Developer Relations, go #TeamBlackBerry!

Creating High Performance Mobile Apps with HTML5, HTML5DevConf San Francisco

On October 22nd I had the great pleasure to present at HTML5DevConf in San Francisco, with around 2000 developers attending the conference, with speakers from important companies such as Google, Adobe, Intel, PayPal, Parse and a lot more.

My talk was called “Creating High Performance Mobile Apps with HTML5″ and here is the talk description:
Learn how to create amazing HTML5 apps for mobile devices — always focusing on the best performance possible — using debugging and inspection tools. This presentation covers how to package applications for BlackBerry 10 devices and how to set up your environment to get live reloads on your mobile devices. Open source JavaScript libraries for our UI are mentioned, and it goes through some of the important ins and outs of mobile development using HTML5.

Hope you enjoy the slides. Keep in touch: (@demianborba)

Adobe AIR 3.5 Overview for BlackBerry 10.2, presented at BlackBerry Jam Asia 2013

Convert any SWF into a BlackBerry 10.2 Application (GAP for AIR)

Important: This is not an official BlackBerry tool and there is no plan to provide support or updates. Use it at your own risk.

Hello fellow Flash developers! This is Demian Borba (@demianborba), BlackBerry Developer Evangelist and I’d like to share something special with you all.

Normally, to convert SWFs into for BlackBerry 10 apps, you have to use the command line, which is not very comfortable and productive for some developers, myself included. You can also use IDEs, but sometimes you want to just use a simple GUI tool.

With that in mind, the Tech Center Maceio in Brazil and I designed/developed a visual tool for the desktop (Mac and Windows) called GAP (Graphical Aid Plus) Alpha for AIR, which executes all the command line instructions under the hood.

As you might know, BlackBerry 10.2 now supports Adobe AIR 3.5, which includes Stage3D and StageVideo, great APIs for games and video. With GAP Alpha for AIR you can convert any SWF into a BlackBerry 10.2 application.

Let me tell you how it works!

1. Download and Install GAP

Before you download GAP Alpha for AIR, please make sure you download and install the current BlackBerry 10 SDK for Adobe AIR.

Download GAP Alpha for AIR (Mac Version, 29.9MB)
Download GAP Alpha for AIR (Windows Version, 22.9MB)

Once you have GAP installed, you will be able to (visually):

  • Request signing keys
  • Register signing keys
  • Backup signing keys
  • Restore signing keys
  • Create and install debug tokens
  • Create BB10 apps from any SWF
  • Install .bar files in the simulator or any device

Continue Reading…

UX/UI Guidelines for Built for BlackBerry Applications (BlackBerry Jam Americas 2013)

Creating High Performance Mobile Apps with HTML5 (Adobe Max 2013)

Meet GAP Alpha for HTML5, no need to use command line anymore

Important: This is not an official BlackBerry tool and there is no plan to provide support/updates. Use it at your own risk.

Hello BlackBerry 10 developers focused on HTML5 and WebWorks, I’m happy to share this nice tool called “Graphical Aid Plus Alpha for HTML5″. With this visual tool (GUI), there is no need to use command line anymore, and you can:

- Order your signing keys
- Register your keys
- Backup your keys
- Restore your keys
- Create and install debug tokens
- Build WebWorks apps (without having to zip your files)
- Install .bar files in the simulator or any device

Credits to Iago Barboza (Developer), Dieges Lima (Designer) and Leandro Sales (ScrumMaster and Coordinator), members of the Tech Center in Brazil at Federal University of Alagoas, supervised by me (@demianborba) and Rodrigo Peixoto (Application Development Consultant), not forgetting the extra help from Tainá Ribeiro (Designer) and Dielson Sales (Developer).

Before you download GAP Alpha for HTML5, please make sure you download and install the current BlackBerry 10 WebWorks SDK.

Click here to download the GAP Alpha for HTML5 for the Mac (29 MB)
Click here to download the GAP Alpha for HTML5 for Windows (22 MB, open the .exe to start)

Enjoy!

Wow! No more re-packaging when testing HTML5 apps on your device

If you are a HTML5 developer targeting the BlackBerry platform, you know that for creating apps and testing on devices you have 2 options:

A. Use a visual tool like “Graphical Aid Plus Alpha for HTML5″ (details here)

or

B. Use command line:
1. Select all of your files (CSS, JS, HTML and any other local files like videos, mp3s, images etc, INCLUDING the config.xml file)
2. Zip all these files
3. Run bbwp to PACKAGE and SIGN your application
4. Use blackberry-deploy to install the app on your device
* If you need to remember all these steps, we have short video tutorials here.

And if you do changes to your app and need to test it again on your device, you need to increase the buildId and repeat ALL these steps again. Painful, right?

Not anymore! Let me show you how you can avoid repackaging over and over again, every time you have changes to your app:

VIDEO TUTORIAL:

Normally on your config.xml file, you have the first file that opens (i.e. index.html) defined in the tag “content” with the attribute “src”:

The good news is that you can point this index.html to be a local file on your server or computer (i.e. When using Wifi, my computer IP is http://192.168.1.141. When connected via USB, my computer IP is http://169.254.0.2):

But you can’t forget to whitelist your computer or server, by adding this to your config.xml file:

To get live updates on your device (without having to refresh, close or open the app) you can get LiveReloader for just 9.99 dollars and install on your computer. With that in place (after adding the JS code to your index file), as soon as you hit SAVE on your computer, it will update the app on your device, automagically!!

Now you can package for the last time, and do all changes on your computer.

And when you have your app all set, remember to remove the IP and set it back to index.html before submitting it to AppWorld.

Good luck and happy coding!! #GoBB10 GoHTML5

Page 1 of 41234»