Android 101: Developing Android Applications for BlackBerry devices

quantityforeheadMobile - Wireless

Dec 10, 2013 (3 years and 8 months ago)

167 views

Android 101: Developing Android
Applications for BlackBerry devices

JAM819

Levon Levonian,
Itthipon

Dilokrattanapijit

26
-
27 September, 2013

developer.blackberry.com/android

Overview

2


What is the BlackBerry Runtime for Android Apps?


Runtime
Features


BlackBerry 10.2


Android Compatibility


Maps and Native


Demo


Development Basics


Online Packager


Success Stories


Q&A

3

What is the Android Runtime?

5 Minute Overview

developer.blackberry.com/android

What is the Android Runtime?

Overview

4


Open source Android 4.2.2 (Jelly
Bean) Application Framework running
on top of
BlackBerry 10
and Libraries



Enables repackaged Android apps to
be installed and run inside it



Deep integration with
BlackBerry
native framework to make Android
apps indistinguishable from native
apps



Repackaging your Android app can
take as little as 2 minutes

BlackBerry 10 OS

QNX

Android Runtime

Dalvik

VM

5

BlackBerry 10.2 Android Features

Usability and Compatibility

developer.blackberry.com/android

BlackBerry 10.2 Roadmap

6

http://www.flickr
.com/photos/flyi
ngdutchphotos/
2063336707/siz
es/l/in/photostre
am/

BlackBerry 10.2 Android

7

A8


10.2 Beta (June)


Jelly Bean 4.2.2


Hardware acceleration


Tooling Update v1.6

A9


10.2 Gold (August)


Surface texture


Accessibility


8

Android Compatibility

Usability and Functionality

developer.blackberry.com/android

Android Compatibility

Usability and Functionality

9


About 70% of all Android apps are compatible today



Not all Android APIs are supported


Hardware and OS dependencies



Limited to the
personal

perimeter


No access to data in the work perimeter


Cannot deploy to BlackBerry World Work



Full compatibility list see:


developer.blackberry.com/android/
apisupport


10


Support for location based intents to display maps



Use
WebView

+ web services (Google, Bing, etc.) to
display map content within apps



Open Street Maps is also supported



More details on mapping support can be found on the
API Support Page


developer.blackberry.com/android/
apisupport




Android Compatibility

Want to use Maps?

11


Support to include Native code (JNI) is not currently
available to Android apps on BlackBerry 10, only Java



More details on the BlackBerry Native SDK can be found
within the Native
mircrosite


developer.blackberry.com/native



JAM820:
Android
201


Porting
your Android
apps
to
Cascades
(Thu
@
16:45, Breakout 2)


BlackBerry 10 Features

Want to use Native code?

12

Demo

developer.blackberry.com/android

13

Development Basics

Repackage, Sign and Submit!



developer.blackberry.com/android

14

Development Basics



Tooling Options


Online Packager


Eclipse Plug
-
in


SDK (Command Line)


Re
-
package APK to

BAR file format

Debug Tokens

Test Application


Signature Keys

Sign application



BlackBerry World

-

Submit App for Approval

-

Publish signed BAR files

-

Run reports

Repackage

Deploy

Distribute

Development Basics

15


Tools


Online Packager Tool


Quickest/easiest way to get apps converted


Eclipse Plug
-
in
-

For most Android developers


Command
-
line Tools SDK
-

Advanced development options



Basic concepts


Simulators
-

BlackBerry
PlayBook

and BlackBerry 10 (Z10 & Q10)


Code Signing


Development Debug Tokens

16

Development Basics

Online Packager

Provide your email
address and agree to
the SDK terms. (1/6)

17

Development Basics

Online Packager

Run the Java applet. (2/6)

18

Development Basics

Online Packager

Provide the path to an APK file and your Android SDK. (3/6)

19

Development Basics

Online Packager

View the results of the
verification script which was
run on your APK. (4/6)

20

Development Basics

Online Packager

Setup your signature
keys, or if done so
already, proceed to
repackage and sign
your app. (5/6)

21

Development Basics

Online Packager

Provide the APK,
SDK and p12 paths,
enter your signing
password, and your
company. (6/6)

22

Development Basics

Online Packager

The applet will
repackage the APK
file to a BAR file and
sign the new app
with your signature
keys.



APK

BAR

23

Development Basics

Online Packager

You can now submit the BAR file to the BlackBerry World storefront!

24

Development Basics

ADT Plug
-
in


ADT Plug
-
in for Eclipse + BlackBerry Plug
-
in for ADT



BlackBerry PlayBook,
BlackBerry 10 and
simulators are just another
device target for your
existing Android project



Debugging applications on
BlackBerry just like on
other Android devices




25

Repackage your APK to a BAR file in 4 steps…


1) Check your APK for compatibility


apk2barVerifier


2) Repackage your APK file as a BAR


apk2bar


3) Sign your application


blackberry
-
signer


4) Deploy your application


blackberry
-
deploy



C:
\
Program Files
\
Android
\
android
-
sdk
\
bin>

apk2barVerifier HelloWorld.apk


C:
\
Program Files
\
Android
\
android
-
sdk
\
bin>

apk2bar HelloWorld.apk


C:
\
Program Files
\
Android
\
android
-
sdk
\
bin>

blackberry
-
signer

storepass
password

HelloWorld.bar


C:
\
Program Files
\
Android
\
android
-
sdk
\
bin>

blackberry
-
deploy

installApp

device
169.254.0.1

package HelloWorld.bar


password
password

Development Basics

Command
-
line SDK


BlackBerry 10 device simulator allows you to load and
test your Android apps in a simulated environment
without the need for a physical device



Virtual machine for VMware for Windows, Mac or Linux.



Recommended on a system that supports Virtualization
extensions for best performance



Supports hardware accelerated GLES 1.0, 1.1 and 2.0



26

Development Basics

BlackBerry 10 Simulator


Simulator Features


Swipe gestures


Device rotation, tilt, orientation


Sensors, GPS, NFC, Battery level


SD card simulation



Pre installed BlackBerry applications


BlackBerry Hub, BBM, Browser, Contacts, Calendar, Settings


27

Development Basics

BlackBerry 10 Simulator


BlackBerry 10 Device Simulator


Supports both 1280x768 (Z10) and
720x720 (Q10) displays in a single
download



Download latest Simulator


developer.blackberry.com/android/tools/


28

Development Basics

BlackBerry 10 Simulator

29

Success Stories

developer.blackberry.com/android

30

Success Stories

Songza

31

Success Stories

32

Success Stories

Photo Studio

33


BlackBerry Runtime for Android apps
microsite


developer.blackberry.com/android/



BlackBerry Runtime for Android apps roadmap


developer.blackberry.com/android/tools/roadmap/



Repackaging and development tools


developer.blackberry.com/android/tools/



Getting started tutorial


developer.blackberry.com/android/documentation/gettingstarted.html



BlackBerry World
microsite


developer.blackberry.com/
blackberryworld



For More Information…

THANK YOU

JAM819

Levon Levonian,
Itthipon

Dilokrattanapijit

26
-
27 September, 2013

developer.blackberry.com/android