Aucun résultat trouvé
July 10, 2014David Isbitski
With the launch of the Fire, Amazon’s first Android-based phone, you can now create experiences where customers interact in an entirely new way with your apps. With Dynamic Perspective, apps can have peek, tilt and zoom capabilities all based on customer head movements. You can also use the Firefly button to identify virtually anything and enable actions your customers can take based on what they identify. By enhancing or optimizing your apps for Fire, you have the opportunity to enable experiences that combine realistic visuals and bring new depth to what customers can do on a phone. And while you think about the new experiences you can offer your user, you can get the current version of you app running on Fire with little or no modification. Here are 10 tips to help you get your apps running on Fire phone today!
Fire uses the Amazon Appstore exclusively, and we’ve streamlined the process to make it easy to submit your app. Registration is free, fast, has no annual subscription cost, and supports both free and paid apps. Once your Fire phone app is submitted you also have the option to distribute the apps across Kindle Fire, Fire TV and Android devices simply by selecting those device targets in the developer console. The boxes indicating your intent to publish on other devices will be pre-checked in the console. Most Fire apps will also work on Kindle Fire tablets and Android devices, so just keep those checked if you are not sure. To get started:
Fire phone development APIs fall into two categories: Dynamic Perspective SDK and Firefly SDK. Both SDKs are available through the standard Android SDK Manager as a single add-on and support a variety of programming languages.
To download the add-on simply open the Android SDK Manager from a command line or from within Android Studio and do the following:
The SDK includes everything you need to get started including multiple sample projects and Android Studio gradle support.
You also have the option to download the Fire Phone SDK directly without installing the add-on here.
Fire is based on the latest version of Fire OS 3.5, which is based on Android API level 17. Android app compatibility is supported on Fire OS, so if an app runs on Android it can run on Fire with little or no effort. Simply drag and drop your Android APK and receive feedback on your app's compatibility within 90 seconds. You will also have access to additional Fire phone test results that enable you to see how your app looks and performs on Fire phone. The test results are presented in 6 hours and include carousel, peek and tilt actions.
Checking APK compatibility and submitting can be done in just a few steps:
Fire represents a huge leap forward in mobile user experiences. As a developer, you’ll want to design the best customer experience possible for this new platform. To help you achieve that, we’ve outlined the core design principles that will allow you to take advantage of Fire’s unique Dynamic Perspective features in our guide here.
The good news is that if you are an Android developer your app will work on Fire with little or no work, and as you will see, just a few modifications to your app’s user experience will let it better take advantage of all that the Fire SDK has to offer.
For additional best practices for designing Fire phone user experiences check out our blog post here.
The quickest optimization you can make is to set the application Theme in your Android app’s AndroidManifest.xml file. This updated Amazon theme will set app fonts, color pallet and skinned controls to match Fire phone’s design guidelines.
Simply set the android:theme argument to the application section of the Android Manifest to Theme.DeviceDefault, as introduced in Android 4.0, and your application will pick up the skinned controls that match Fire phone.
The Fire Foundation Controls are included in the Dynamic Perspective SDK and give your app 2D controls designed and built for use with the device. These controls currently include SidePanel, HeaderNavigationBar, TabBar, ToolBar and MediaController. All of these controls can be implemented in three steps just as you would with any Android control.
Step 1: Prepare the Android Manifest
The Android manifest needs to be modified to include a <uses-library> tag to load the Foundation Controls library (in addition to setting the theme as mentioned in Tip 3).
Step 2. Place the control in your XML Layout file
In this example Android layout file we are referencing the new header navigation bar and utilizing two additional files. Strings.xml will contain the names of our menu items and header_menu.xml file defines the menu items for the HeaderNavigationBar's actions menu.
XML layout for HeaderNavigationBar inside of a RelativeLayout view:
Strings.xml containing menu item names:
Header_menu.xml containing action menu items:
Step 3. Implementing the Control
All of the APIs for Fire phone will be installed into your <Android_SDK>/sdk/add-ons/addon-amazon_fire_phone_sdk_addon-amazon-17 folder including the SDK samples. To access the controls you will need to reference them from your own app. For example, to implement the HeaderNavigationBar make sure you reference the amazon.widget.* package and implement the control. The following code shows how to inflate the XML layout into a view, obtain a reference to the HeaderNavigationBar, use the reference to set a click listener on the actions menu, and implement up navigation.
In the case of the HeaderNavigationBar we will also disable the Android title bar before inflating the layout. We can also programmatically change menu items by setting properties directly on the HeaderNavigationBar like so:
For more details on implementing Foundation Controls in your Android app check out our Implementing Foundation Controls for Fire phone guide here.
One easily identifiable layout characteristic of Amazon Fire apps is the Side Panel layout included as part of the Fire Foundation Controls. Implementing the Side Panel layout will go a long way to giving your app that Fire phone look and feel.
With this control, no matter what the current view in your app, a user can always access your menu or a context aware page just by executing a quick swipe or gesture.
For example, doing a quick right-flick of the phone (or swiping in from the left) can expose a navigation pane. You can also put a context-sensitive pane a flick away in the other direction. In the picture above, the middle content panel is a Music Store. The left panel is a navigation panel, and the right panel is context sensitive, and when the user is looking at music in the content panel, the right panel will show recommendations.
SidePanel Layout works very similar to the HeaderNavigationBar described above. You will need to reference the EAC library in your Android Manifest like above, reference the same amazon.widget library in your java code and then define the left, right and content panels in your XML layout file.
A full Side Panel sample project is included with the Fire SDK under the /Samples/SidePanels folder and you can get more details about implementing a Side Panel layout here.
If you don't have a Fire phone you can also use the simulator included in the SDK to test your SidePanel implementations.
In addition to the 2D Foundation Controls, Dynamic Perspective includes a rich set of APIs and Controls to help developers incorporate peek, tilt and zoom capabilities within their apps while adding a sense of realistic depth and perspective. These controls work behind the scenes with Fire’s advanced camera and sensors to automatically adjust their appearance based on how your application is being viewed. These new UI Controls are part of the Euclid package included in the Fire phone SDK.
For the most part, Euclid controls are very similar to their Android and Foundation Controls counterparts. Euclid controls retain the name of the original base control, but with a "Z" prepended to the name. For example, a Button control becomes a ZButton control.
Figure 1- Example of Euclid Controls. From left to right: ZCheckbox, ZButton, ZSwitch and ZRadioButton
Euclid simplifies the process of adding 3D effects to your Android apps. Because most Euclid layout and widget classes are derived from either standard Android or Amazon Foundation Control classes, you are probably already familiar with the most common methods and attributes of Euclid controls and should be able to convert your app to use the new Dynamic Perspective UI with few code updates.
The following aspects of a control remain unchanged when you swap a stock Android control for its Euclid equivalent, such as changing a Button to a ZButton:
The biggest difference between Euclid and 2D widgets is how their visual assets are produced and rendered. These differences provide new behaviors but also set some limits on what you can change. Euclid widgets are artist-created textured mesh files, including collections of vertices, edges and faces that define the shape of 3D objects.
Although you can set the color of a 3D widget, you cannot add a border, set a custom background, or make changes in View.OnDraw(). However, 3D controls do provide the same access to behaviors such as animations and head tracking without additional code.
The following summary highlights the changes between 2D and 3D controls:
For more information on implementing Euclid controls be sure to check out our Dynamic Perspective UI Migration Guide here. For suggestions on when to use the standard Android widgets, 2D controls and the new Euclid controls check out our comparison matrix here.
With the Firefly SDK, developers can build apps that recognize real world objects - QR and bar codes, artwork, songs, movies and more - and let customers interact with them. Firefly combines Amazon's deep catalog of physical and digital content with multiple image, text and audio recognition technologies to quickly identify over 100 million movies, TV episodes, songs and products. It can also recognize URLs, email addresses and phone numbers. Customers simply press the Firefly button to discover helpful information and take action in seconds. You can use the Firefly SDK to supplement item identification or build actionable options for customers after an item is recognized. For example, iHeartRadio used the Firefly SDK’s built-in music recognizer and music database to identify a song playing. Then they built their own Firefly action to create a station based on the song Firefly recognized.
Integration with Firefly requires the creation of a plug in. You can get complete details on implementing a Firefly plugin on our developer portal here.
The immersive apps you create for Fire phone are also eligible for new developer promotions. We have updated Appstore Developer Select and Amazon Mobile Ads API with more incentives.
Now is the time to submit your apps and games! Apps that are submitted and approved by July 18 will be in the Amazon Appstore when Fire ships on July 25.
Be sure to check out these additional Fire phone developer resources:
June 25, 2014Paul Cutsinger
Fire, the first smartphone designed by Amazon, introduces a new technology called Firefly which enables customers to quickly identify printed web and email addresses, phone numbers, QR and bar codes, plus over 100 million items, including movies, TV episodes, songs, and products. Customers simply press and hold the dedicated Firefly button to discover useful information and take action in seconds.
With the Firefly SDK, developers can build apps that recognize real world objects—music, movies and more—and let customers interact with them. As a developer, you can create more immersive experiences that increase both engagement and the frequency of app use. The Firefly SDK comes with built-in recognizers and databases for products, music, movies, URLs, and websites, as well as built-in actions such as dialing a phone number, looking up an object on Amazon or going to a website. Developers can use the Firefly SDK to take advantage of the built-in recognizers, databases and actions.
An important success metric for any app is engagement, a measure of how frequently and how long people use your app. You need to find ways to bring customers back day after day. Building a Firefly-enabled app is a new technique you can use to get customers to discover your app, sign up and then to come back frequently.
A Firefly-enabled app delivers actionable options (for example, customers can buy concert tickets for a recognized artist) or supplemental item information (for example, the amount of calories in a drink). Customers then have fast and easy access back to your apps, services and brand when they’re actively engaged and interested.
Here are a few examples of how iHeartRadio, StubHub and MyFitnessPal have made use of Firefly to give their apps greater exposure to both new and returning customers. All of these examples start when the customer activates Firefly. They do this by pushing and holding the Firefly button on the left side of Fire. Once an item is identified, a list of actions showing the Firefly-enabled apps is offered.
iHeartRadio enables customers to listen to live radio stations, create their own artist or song-based custom station from a catalog of more than 19 million free songs, or tune in to thousands of shows and personalities on demand for free. When paired with Firefly, the customer can identify a song with one button press and then directly launch iHeartRadio to create their own station based on that artist.
The team at iHeartRadio utilized the Firefly SDK’s built-in music recognizer and music database to identify songs. They built their own Firefly action to create iHeartRadio Custom Stations based on the artist and song that Firefly recognizes. “Our integration allows listeners using Firefly to seamlessly discover music in a whole new way,” said Brian Lakamp, President of Digital for Clear Channel/iHeartRadio. “The Firefly SDK implementation enables music lovers to quickly dive into an iHeartRadio custom experience featuring a variety of songs similar to the one they just heard with just a touch of a button.”
StubHub allows fans to buy and sell event tickets. StubHub used the Firefly SDK to let customers identify songs playing in the background and take various actions. “StubHub used the FireFly SDK and the built-in song recognizer, added a Firefly database of concerts and created a ticket purchase action so when customers hear a song in the background they can find out if the band is playing in their area and buy tickets,” said Brendan Weinstein, Android Development Lead at StubHub. “We extended the experience further by using the Dynamic Perspective SDK to bring users right into the concert—letting them look around a stadium or arena to get the feel for the specific seat they are interested in.”
This is a new way for customers to use the StubHub services. When they use Firefly to identify a song or an artist, they have direct access to the Firefly-enabled StubHub app and can be browsing upcoming events before the song is even over.
MyFitnessPal is a free and easy health and fitness system that helps you attain fitness goals. Using Firefly’s built-in product recognizers, the team at MyFitnessPal has added custom actions to give customers nutrition information and to help them easily track their daily calorie intake.
When a customer scans a physical product, barcode or QR code for a food item, MyFitnessPal’s actions and extra information about that food are offered to the customer. They can then tap the item and go directly and add that food item to their diary in the MyFitnessPal app.
In all of these examples, the app and its services were activated in the context of the customer’s activity. They didn’t need to open an app and navigate to the right screen. Instead, they were able to identify a song, product, barcode, QR code or movie soundtrack, and then launch directly into the app they wanted to use.
Firefly-enabled apps have more options for bringing in new customers and then engaging with them more frequently. Better engagement leads to higher customer satisfaction and ultimately, to better revenue.
The SDK for Firefly includes the library, developer guides, docs and several samples to get you going.
June 18, 2014David Isbitski
Today in Seattle, Amazon founder Jeff Bezos unveiled Fire, the first phone designed by Amazon. Fire is the first and only smartphone with Dynamic Perspective and Firefly. Dynamic Perspective is an entirely new technology that responds to the way a customer holds, views and moves the phone. For example, Zillow is using the Dynamic Perspective SDK to create the ability to zoom in on pictures within their app by just moving the phone closer to the user. The revolutionary Firefly technology already recognizes movies, music and more and with the Firefly SDK developers can extend the use of the Firefly button to enable new actions their users can take based on what they can identify. As a developer, these new technologies enable you to create more immersive experiences in your apps and games that increase user engagement.
The Fire SDKs are available now, and make it easy for developers to take advantage of these features in their apps. These SDKs were designed to offer developers power and flexibility with pre-built controls, low level APIs, and complete UI frameworks. You can download both SDKs here.
Fire apps are built with the same familiar Android development environment you are used to. Fire provides a powerful set of hardware to bring your apps alive. With 2 gigabytes of RAM, a powerful Qualcomm Snapdragon 800 Quad-core 2.2 GHz CPU and an Adreno 330 GPU, Fire will support the high performance game experiences customers crave. For detailed technical specifications of Fire, click here.
Zillow used the Dynamic Perspective SDK to integrate real-time information into their app’s user experience. In the Zillow app for Fire, customers can view new listings or nearby homes for sale and rent, right on the Fire carousel without having to open the Zillow app. In addition, Zillow brought a new photo experience to the device so users can use their head to zoom in on a bedroom or peek to see what's around the kitchen corner. “Real estate shopping is an inherently mobile experience so any chance we have to bring listings or new information to a home shopper while they're out on the go is a great thing,” said Jeremy Waxman, Vice President of Marketing and Mobile, Zillow. “Photos are incredibly impactful for home shoppers—it is the most common activity for users of our app. We are thrilled to be able to go one step beyond static images and offer our users the opportunity to zoom in on the photos and then peek around the room with the Dynamic Perspective SDK.”
Ezone.com, the creators of Snowspin and Crazy Snowboard, used the Dynamic Perspective SDK to allow a customer to navigate the endless runner game with just their head—no tapping on the screen necessary. Using head and hand movements, users can control direction and speed. Users can interact with games in a more immersive way – without their hands getting in the way of game play. Additionally, Ezone.com created a special flip jump in Snowspin currently exclusive to Fire customers with just a flick up of the head. “Porting our existing Android versions of Snow Spin and Crazy Snowboard to Fire couldn’t have been easier, and we were able to add new innovative game moves such as a double backflip with just the flick of your head, enabling even higher scores,” said Simon Edis, CEO of Ezone.com. “The Amazon team had all the tools ready to go, making it super easy for us to just drop them in our games and publish.”
CrowdStar used the Dynamic Perspective SDK to create the ability for Covet Fashion users to select their favorite fashion choices for their model. Using zoom and tilt, players can see details of outfits to vote on looks. “Dynamic Perspective is so innovative we’ve just begun to figure out how to take advantage of all the technology has to offer. The simplicity of the user interface and design around a one handed experience will really allow us full creativity as we look ahead in our portfolio of apps and games,” said Jefferey Tseng, CEO of Crowdstar. “Dynamic Perspective has unlocked capabilities we’ve always wanted to create in our game—incorporating zoom and pan in an incredibly natural way without having to touch the screen, is the first example.”
Firefly understands your surroundings, instantly helping you to learn more, discover new things, and take action on the world around you. It can scan physical objects, identify them, and obtain related information about them. Everything from book covers, album covers, bar codes, QR codes, movies, television shows, songs and more. Developers can use the Firefly API to supplement item identification or build actionable options for customers after an item is recognized. For example, iHeartRadio used the Firefly SDK’s built-in music recognizer and music database to identify a song playing. Then they built their own Firefly action to create a station based on the song Firefly recognized.
Because phones are often used with only one hand, Fire also offers one-handed shortcuts that go above and beyond touch. These shortcut gestures allow you to simply angle the device and “peek” into additional information that your apps can display on screen. For example, customer ratings in the Amazon Appstore instantly appear over each app’s icon when the device is tilted. Navigation is enhanced with gestures: moving back is as simple as flicking up on the screen with a finger, while tilting the device in either direction brings up two additional panels for navigation and contextual information. Gestures can even be integrated inside your games so that users can experience the game in a more intuitive way. Imagine moving a character on screen simply by titling the device instead of having to cover what’s on the screen with your finger.
Fire enables new ways of interacting with your phone by simply rotating the device around X, Y and Z axes. These gestures were designed to be used with only a single hand, a common scenario when using a phone. We’ve created a framework that integrates directly with these gestures and Fire’s new sensors, making it a simple process to integrate within your own apps.
Fire SDKs and APIs
The underlying technology for Dynamic Perspective and Firefly is sophisticated, but Amazon makes it simple for developers to harness their capabilities. See a full breakdown of the SDKs and their contents here.
Dynamic Perspective SDK
The Dynamic Perspective SDK includes a series of APIs and Controls to help developers create peek, tilt and zoom capabilities within their app based on customer head movements, create multi-dimensional game play, or provide quick navigation menus by tilting the device to the left or right. These experiences are created through a variety of visual effects including adding shadows, depth and tracking head and motion gestures. For example, you could create an app that allows you to peek at how many pages are left in the book you are reading, or browse your apps as if you were flipping through a physical file drawer. Flat cartoonish icons and graphics could be replaced with realistic visuals that use lighting, shadows and motion to create an experience you would want to show off at every opportunity.
With the Firefly SDK, developers can build apps that recognize real world objects—music, movies and more—and let customers interact with them. As a developer you can create more immersive experiences that increase both engagement and the frequency of app use. The Firefly SDK comes with built-in recognizers and databases for products, music, movies, URLs, and websites, as well as built-in actions such as dialing a phone number, looking up an object on Amazon or going to a website. Developers can use the Firefly SDK to take advantage of the built-in recognizers, databases and actions.
Fire is based on Fire OS so if an app runs on Android it can run on Fire with little to no work. For a developer who just wants to get started with Fire they can do a simple port, or they can use the Fire SDKs to easily integrate UI features such as shadows or hovering images within the app or game, or creating left and right panels based on Fire’s three-panel UI design.
Fire uses the same familiar Android development environment, and while Android Studio is fully supported IDE, you can also use Eclipse and other IDEs. Android Studio Gradle support is also supported for builds. An API simulator for the Side Panels and Carousel is included to test code on stock Android emulators and devices without needing a physical Fire device.
We know that many Android apps and games are built with various technologies so the Fire SDK includes support for those as well. Unity, HTML5 and C++ are all supported. For additional details on using third-party frameworks click here.
By optimizing your apps for Fire, you have the opportunity to create compelling experiences that combine realistic visuals, with both depth and perspective allowing customers to use their smartphone in ways never done before. Starting today we are updating Appstore Developer Select offerings, Amazon Mobile Ads API, and Amazon Testing Service with special Fire incentives.
Amazon Developer Select: Amazon will offer 500,000 Amazon Coins ($5,000 value) for each of your qualifying paid apps or apps with in-app purchasing that meet the additional program requirements for Fire Phone. You can create campaigns via the Promotions Console to give these Coins away to consumers purchasing any of your paid apps or in-app items. For more details on the Amazon Developer Select program for Fire click here.
Amazon Mobile Ads API: Developers earn $6 for every thousand interstitial ads displayed across any supported device in August and September (up to one million impressions per app per month) when they distribute their apps on Fire phones and send the first ad request from a qualified app. For more details on the Amazon Mobile Ad Network Interstitial CPM Offer promotion click here.
Amazon App Testing Service: We have also expanded our testing tool to Fire. Developers can now test their Fire apps before submitting them to the Amazon Appstore. Developers simply drag and drop an app and most will receive feedback about their app’s compatibility within 90 seconds. Additionally, registered developers have access to additional Fire test results that check the app’s experience. These tests enable developers to see how an app looks and performs on an actual device sitting in an Amazon device lab.
With the launch of Fire, Amazon now offers a complete device and apps ecosystem spanning across tablet, phone and TV. Customers pay for your apps once and interact with the experiences you create across all their screens. As a developer, you only need to submit your app once and with few changes make it available to your customers across all Amazon devices. Now is the time to submit your apps and games!
Additional Fire Developer resources: