LightBlog

lundi 9 janvier 2017

HTC’s 2016 Revenue Hits 11-Year Low, While Huawei Grows Faster than Industry Average

Earlier in 2016, before we knew about the Pixels, everyone was speculating on which OEM would be manufacturing the 2016 Nexus. Leaks pointed out that HTC was on track to produce not one, but two 'Nexus' phones for Google, replacing the top contender Huawei who had been Google's choice for manufacturing the Nexus 6P.

But we all know how that played out. HTC manufactures the Pixel and Pixel XL, but does not feature any of its own branding on the devices (well, other than the battery), nor in their marketing and promotional materials. While HTC would not be getting brand image recognition from these phones, it would certainly benefit in the form of an additional revenue stream, albeit likely small. The latest reports indicate that this revenue stream may not be enough to help HTC's financial balance sheet back in the green in 2016 indeed.

HTC saw its revenues dip 16.4% month-on-month, and 1.7% year-on-year in December 2016. This is worrying news when you consider that the year-on-year comparison figures are from the era of the fiery-hot HTC One M9, while this year saw HTC releasing the rather well-received HTC 10. Total revenues dipped to a five-month low of NT$6.41 Billion ($199.96 Million) in December.

For the year 2016, revenues totaled NT$78.16 Billion, which represents a decline of 35% from the past year. This is also the lowest annual figure in 11 years. Revenues for Q4 2016 reached NT$22.2 Billion, which the report claims is comparable to the amount recorded in the third quarter. The final figure on Earning per Share for Q4 2016 came out to be a net loss of NT$2.18, setting HTC on track to its seventh quarterly loss in a row.


Meanwhile, Huawei saw a better 2016, despite losing out on the Pixels.

A separate report mentions that Huawei shipped a total of 139 Million smartphones in 2016, which is an increase of 29% of 2015. This is far better than the industry-wide growth of 0.6% which had been expected for 2016.

Huawei's total sales of all of its consumer product portfolio reached CNY178 Billion ($25.728 Billion), an increase of 42% year-on-year. Further, Huawei's 2016 lineup has been well-received in the global market.

2017 is also looking good for Huawei. The company has reached 'strategic cooperation agreements' with Google and Amazon to step into the AR/VR industry. The report further states that Huawei will work with Google on Project Tango as well.

What are your thoughts on the present financial success of Huawei, and the lack thereof of HTC? Let us know in the comments below!



from xda-developers http://ift.tt/2i9rZdw
via IFTTT

Android Nougat’s Freeform Window Mode: What It Is and How Developers Can Utilize It

Freeform window mode, as first demonstrated by Ars Technica

When Android 7.0 Nougat was first announced early in 2016, it brought with it a much-requested feature to the Android platform — multi-window support. Most people are aware of the split-screen multi-window support enabled by default on all Android Nougat phones and tablets. Android TV devices with Android Nougat come with support for picture-in-picture multi-window support.

However, there is a third multi-window mode present in Android Nougat that not very many people are aware of: freeform window mode. This mode allows Android to present apps as floating windows that can be moved and resized at will by the user. It's essentially Android's implementation of a stacking window manager.

 

In the Android SDK documentation, it states that:

Manufacturers of larger devices can choose to enable freeform mode, in which the user can freely resize each activity. If the manufacturer enables this feature, the device offers freeform mode in addition to split-screen mode.

And also, in the Android 7.0 CDD:

Device implementations with screen size xlarge SHOULD support freeform mode.

This indicates that any new large screen Android device that ships with Android 7.0 could potentially have freeform window mode enabled by the manufacturer.

However, this is absolutely not a hard requirement. It is possible to force any Android Nougat device (with developer options enabled) to support freeform window mode using one of two different methods:


Enabling freeform window mode on any Android Nougat device

Turning on the "Force activities to be resizable" option allows apps to run in freeform mode on any device

Method 1 (a computer with adb is required)

Make sure USB Debugging is enabled in Developer Options. Then, hook your device up to a computer with adb installed, and execute the following command:

  adb shell settings put global enable_freeform_support 1  

Method 2 (no additional requirements)

Enable the "Force activities to be resizable" option at the bottom of Developer Options.

Both of these methods require the System UI to be restarted before they can take effect. The easiest way to do this is to reboot your device (or, if your device is rooted, you can simply kill the com.android.systemui process)


OK, so freeform mode is enabled… now what?

If you enabled freeform mode using Method 1, then there will be a new button on app entries in the Overview menu to launch an app into freeform window mode.

With Method 2, however, it is not possible to launch an app into freeform mode through Android itself. Fortunately, it is possible for any third-party launcher to launch an app into freeform window mode using standard Android APIs that were finalized as part of API level 24.

The key to launching an app in freeform mode is to call the ActivityOptions.setLaunchBounds() method. This method takes a Rect as an argument, containing the window bounds that the app will launch with.

You can then start the app with startActivity(Intent, Bundle). If you don't already have an ActivityOptions bundle, you can create one with ActivityOptions.makeBasic() and then calling setLaunchBounds() on the freshly created bundle.

Note that by default, if there is already a task for the app present in the Overview screen, then Android will simply redirect you to the existing (fullscreen) task that was previously launched by the user. You will need to clear any tasks for the app in Overview before attempting to launch the app into a freeform window. (For apps with activities that launch in standard or singleTop modes, you can force a new window to open by adding the Intent.FLAG_ACTIVITY_MULTIPLE_TASK flag to the intent before calling startActivity().)


How does freeform mode work under-the-hood?

There is an excellent article written that explains how multi-window mode, including freeform mode, is implemented in Android Nougat. (NOTE: the article is written in Chinese, so be sure to run it through Google Translate)

In a nutshell, apps in freeform mode run in a separate stack from the rest of the system (think: virtual desktop). Therefore, it is not possible for freeform apps to run on top of the launcher or on top of another full-screen app.

Apps running in freeform mode (that don't have android:windowIsFloating set to true) have a DecorCaptionView added as a child of the top-level DecorView. This view contains a LinearLayout defining the window's caption bar for moving, maximizing, and closing the window. While I don't recommend it personally, it is possible to access and customize this view by getting the DecorView using Window.getDecorView(), casting it to a ViewGroup and then accessing its child views.

Any app that is designed to behave well in Android's standard split-screen multi-window mode will work in freeform mode. isInMultiWindowMode() will return true for apps running in freeform mode. There are a few other publicly-available classes and methods that an app can use that relate specifically to freeform mode:

  • Window.setDecorCaptionShade(): this method can be used to override the shade of the caption controls (the maximize and close button) for apps in freeform mode.
  • Window.setRestrictedCaptionAreaListener(): this can be used to detect when a window is moved around in freeform mode. The Window.OnRectrictedCaptionAreaChangedListener is called every time the position of the caption controls change (when a user moves the window around), and provides a Rect with the new bounds of the caption controls.
  • ActivityInfo.WindowLayout: this class contains information declared in the app's manifest as to the initial positioning of a freeform window that an app can request on launch. For example, you can list the following in the <activity> tag of your manifest:
      <layout      android:defaultHeight="640dp"      android:defaultWidth="360dp"      android:gravity="center" />  

    Then, when the device is already in freeform mode and the app is launched, it will launch with these specified boundaries.


Examples of freeform window mode in action

Taskbar adds a start menu and recent apps tray to compliment freeform window mode

In the summer of 2016, while Android Nougat was still a developer preview, I released an app called Taskbar that provides a Windows-like start menu and recent app list in a system overlay. It allows users on Nougat to launch apps in freeform window mode — and, since Taskbar uses an overlay, it can stay on screen in the freeform window environment. The combination of Taskbar and freeform mode gives any Android device, especially tablets, a PC-like feel.

You can download Taskbar on Google Play, or view the source code yourself on GitHub. In addition to the concepts mentioned in this article, I also employ a few tricks to keep the freeform mode environment active even when no freeform windows are displayed on screen. Users can also optionally set Taskbar as their default launcher to allow their device to boot automatically to the freeform mode environment.

Since there are no devices that officially ship with freeform window support enabled by the OEM (as of this writing), I recommend using Taskbar as a tool for developers to test their apps in the freeform window environment on devices that don't otherwise support it.

In addition to Taskbar, I've also modified the Launcher3 source code from AOSP to allow it to launch apps into freeform mode. This is a straight clone of the stock Android 7.1.1 launcher, with the bare minimum modifications necessary to allow it to launch freeform apps. I've provided this modified launcher in the hope that other developers will implement support for launching freeform windows in their custom launchers. You can view the source code on GitHub, or download a sample APK.

My hope is that developers of custom launchers can utilize this code and enable support for launching freeform window apps for those users that desire greater flexibility for window management on their large-screened devices.



from xda-developers http://ift.tt/2j0pnDv
via IFTTT

‘Leaked’ HTC Promotional Video Shows Smartphone Concept, Possible New Product

We're waiting to hear some gossip on the upcoming HTC flagship, but there's little going around on that phone yet (quite surprisingly, given previous HTC phones have been leaked to hell and back). What we have today is some tidbit on a phone that could be an HTC flagship, and that certainly looks interesting.

Leaker @evleaks brought to light an interesting video, which in traditional marketing fashion argues that people are different, but that our smartphones are not. The video mentions that smartphone makers make powerful phones, but these fail to connect to each of our unique and expressive personalities. What follows is the tried-and-true sales pitch in which the company tries to sell you on their product personalization. Looking past the advertisement, we find a curious little datum:

Once you get past the CMF Kitchen promo, you see a new HTC phone at the very end. Here's an image if you didn't quite catch it.

htc-vive-smartphone

The phone seen in the video bears the HTC Vive branding, and what appears to be a dual camera setup, which would certainly be something we could expect from HTC.

Evan Blass also shared another video of a phone referred to as 'HTC Ocean', which he clarifies is different from an upcoming HTC Ocean Note. The video showcases a different approach to UI navigation, making better use of the side frame for app launching and other tasks.

There is not a whole of info beyond these images and content-restrictive videos, but it does give us a clue on what to expect in 2017 from HTC. For one, HTC could be looking to leverage the name and brand identity of its Vive VR headset onto its smartphone lineup. This may involve releasing an HTC Vive smartphone.

However, as a reminder, this is still a leak, and as such, it should be taken with adequate doses of skepticism. Interestingly, Android Authority figured out that the videos posted by Evan are not new as they have been available for view publicly for a while now. Evan 'evleaks' Blass's track record is impressive when it comes to leaking unreleased tidbits about smartphones, but we can't help but remain skeptical on this one — the video is interesting either way, but we rather wait for more details and clarification before we start putting this puzzle together.

What are your thoughts on the 'leaked' smartphone concept? Let us know in the comments below!



from xda-developers http://ift.tt/2ivTqiG
via IFTTT

Win an Honor 6X! [Open to All Countries]

Honor dropped their new Honor 6X at CES last week, and it looks pretty great: dual cameras, a large battery, and a starting price of $249. It's available with 3 or 4GB of RAM, and 32 or 64GB of storage, and is using the Kirin 655 CPU, which offers a lot of power savings without compromising performance. We recently launched our Honor 6X forums, so be sure to check them out. Use the widget below to enter the contest!

Win an Honor 6X!



from xda-developers http://ift.tt/2j9DHqo
via IFTTT

dimanche 8 janvier 2017

Automatically Avoid Tolls in Google Maps with Tasker

I love getting around on my bicycle. Thanks to Google Maps, finding the destination and arriving there on time has never been an issue for me. There are a few caveats though if you are a cyclist:

  • I'm a roadie. Me and bike paths are not friends. I stick to roads, I don't feel comfortable zipping at 40km/h  centimeters from pedestrians. (For my imperial friends out there, it's inches too close, when I'm going way too fast). Therefore, unless a special occasion calls for it, I use Google Maps – driving navigation.
  • Google Maps also underestimates my ETA, which is annoying. I'm young and fit for now. I'm sure I will appreciate it more in my 50s. I'd like to see an average speed slider to adjust notifications about ETA and 'leave now to get on time' notifications.
  • When using Google Maps for cars, you have to be careful not to end up on a highway, (which is often the case around my area) or other roads that may not be suitable for cycling. But the same goes for the biking directions.
    img_20160229_123834

    Google forgot to mention: "Buy a mountain bike for this bit'

But that's just my preferences. For our motorist friends out there, you're probably more concerned about avoiding those toll roads when commuting. Sure, using the toll road a few times might not be too expensive, but it can be pricey if you use it quite extensively.

If you would rather avoid toll roads entirely, then you have to remember to manually toggle the option before starting navigation, or to start navigation and then manually specify to change your route. Luckily, we can use Tasker to specify our preferred route before starting navigation! We've provided a set of instructions below for you to replicate the project, otherwise you can simply skip to the bottom to download and import the project file. Whatever you prefer.

You will need:
Android version: 4.0+ (Used 7.0),
Apps: Google Maps
Plugin: AutoVoice
Needs: N/A

This project was initially created by Mishaal Rahman, but through discussion, experimentation, and collaboration was later expanded upon by myself.


Specifying driving instructions with Tasker

avoid highways with TaskerGoogle Maps provides you with some voice commands to toggle the tolls/highways/ferries option, which wasn't the case earlier on. You can request your route to be changed accordingly by saying:

"Avoid tolls/highways/ferries" (Come on Google it's called motorways around here!)

Frankly speaking, this is something I often forget to do when setting off. So here is how Tasker could help you. The profile "Avoid Tolls" will allow you to preset the travel mode. I have mine (avoid highways) linked to my bike mode. So whenever my phone is on the bike (NFC context inside my bike case) it will bring up the Google Maps directions for driving, avoiding motorways.

Here is how to avoid Tolls/Highways/Ferries with Tasker:

avoid highways with Tasker

Avoid Tolls/Highways/Ferries

  Profile: Avoid Tolls      Event: AutoVoice Recognized [ Configuration:Command: "navigate to" ]  Enter: Avoid Tolls      <tolls>      A1: Send Intent [ Action:android.intent.action.VIEW Cat:None Mime Type: Data:google.navigation:q=%avcommnofilter&avoid=t Extra: Extra: Extra: Package:com.google.android.apps.maps Class: Target:Activity ]      <highways>      A2: Send Intent [ Action:android.intent.action.VIEW Cat:None Mime Type: Data:google.navigation:q=%avcommnofilter&avoid=h Extra: Extra: Extra: Package:com.google.android.apps.maps Class: Target:Activity ]      <ferries>      A3: Send Intent [ Action:android.intent.action.VIEW Cat:None Mime Type: Data:google.navigation:q=%avcommnofilter&avoid=f Extra: Extra: Extra: Package:com.google.android.apps.maps Class: Target:Activity ]      A4: Kill App [ App:Google Use Root:Off ]  

The profile responds to our AutoVoice Recognized event and the command 'navigate to' then passes whatever you say afterwards as the destination. For instance, if you say "navigate to McDonald's" then Tasker will pass "McDonald's" as a destination to Google Maps while starting navigation with the avoid option you selected. Don't worry, Google Maps is fairly flexible about what you can put in the destination – you can even just say "home" or "work" assuming you have those locations set up in the Google Maps app. The destination is stored in %avcommnofilter (which is the first command available without the words put in the filter).

The intent created contains the limitations we want to apply:

  • Avoid tolls: avoid=t
  • Avoid highways: avoid=h
  • Avoid ferries: avoid=f

tasker avoid highwaysTo build an intent simply add a send intent action and fill in the following fields:

  Action:android.intent.action.VIEW  Data:google.navigation:q=%avcommnofilter&avoid=t,h,f  Package:com.google.android.apps.maps  Target:Activity  

Note the bolded t|h|f above, you can specify which avoid options you want by listing each letter in a comma separated list. Generally, motorists will specify just t for tolls, but if you want to avoid highways and ferries you can place h,f at that part. If you want to speed things up you can add the Kill App: Google App action, but this step is not required.

The project "Avoid Tolls with Tasker" contains all 3 intents, so if you are going to use the file, please disable the unwanted intents by clicking on the action to see which intent it is sending. While on it's own this project may not be the most impressive navigation tip, it can remove a lot of frustration from your navigation profiles. In my case, this Task helps to alleviate the frustration of forgetting to set the correct navigation option when I'm cycling. For Mishaal, it helps because he frequently starts navigation using his voice, but forgets to set the avoid tolls option.

Download the project here!

In order to import a Tasker project file, download the above file and save it anywhere in your internal storage. Open up Tasker and check to make sure that "beginner mode" is disabled in the preferences menu. Then, long-press on the "home" icon in the bottom left hand corner and click on "import". Find the prj.xml file you saved earlier, and select it to import it. You will now see a new tab in the bottom row containing all of the profiles and tasks we referenced in this article.

We hope you enjoy this little creation of ours, and let us know if you think we can make any enhancements!



from xda-developers http://ift.tt/2j79rfL
via IFTTT

How to Save your Parking Spot with Tasker

If you are enrolled in and regularly make use of Google Now, you might have seen the 'where I parked my car' card. This additional card is displayed whenever Google thinks you have stopped driving and left your vehicle.

I don't drive on a regular basis, rather I cycle everywhere and I find it very flattering each time Google serves me this card. It proves that Google doesn't know everything about us just yet, but if you're quick enough – the card can be used to find your bike again (unless it's been stolen).

With my incoming trip to China, I realized that Google services won't be helping me in my daily life. China blocks Google. So of course, that means no more Google Now as well. If you are lucky enough to go traveling where Google can't go or you are simply not a fan of Google Now, you might be interested in replicating the profile below. If not, you can always scroll to the bottom to download and import the project file.

You will need:
Android version: 4.0+ (Used 7.0),
Apps: Material Design Icons (optional)
Plugin: AutoVoice (optional), AutoTools (optional)) or Secure Settings (optional)
Needs: root (only if you wish to automatically toggle the location)

This project was initially created by Mishaal Rahman, but through discussion, experimentation, and collaboration was later expanded upon by myself.


Dude, where's my car? Save my Parking Spot

Default Location saved Location Failed

This profile is fairly simple. In my set up, I've made it so I can save my parking spot using a desktop widget. If however you prefer to use voice activation or a notification button, I have provided instructions below for those cases. In any case, when the profile is activated, the location is stored in a variable and recalled when needed.

It's good to point out that Android does a pretty decent job of managing your location access to ensure minimal battery drain, but if you prefer to keep your location services disabled you have to enable location services so Tasker can get a location fix. The more location services you have enabled the quicker the fix.

By default, Android will check for your location using GPS, mobile data, and WiFi in the 'High Performance' mode. If you always leave location services on, move on to the next part. Otherwise, you can toggle location with the below run shell action in Tasker (requires root).

  settings put secure location_providers_allowed=gps,network,wifi  

Alternatively, you can use the Secure Settings plug-in to toggle these (here is how to make Secure Settings work on Android Nougat). Finally, for those of you without root access, if you grant the SECURE_SETTINGS permission to AutoTools you can then toggle location using that plug-in.

Save the location

Save the Location

  LocCar           Abort Existing Task          A1: Variable Clear [ Name:%LastLocation Pattern Matching:Off ]           A2: Notify Cancel [ Title:Location Issue Warn Not Exist:Off ]           A3: Get Location [ Source:Any Timeout (Seconds):20 Continue Task Immediately:Off Keep Tracking:Off Continue Task After Error:On ]           A4: Variable Set [ Name:%LastLocation To:%LOC Recurse Variables:Off Do Maths:Off Append:Off ]           A5: Notify [ Title:Location Saved Text:Tap to Navigate Icon:hd_location_place Number:0 Permanent:Off Priority:5 ] If [ %LastLocation Set ]          A6: Set Widget Icon [ Name:LocCar Icon:content://com.android.externalstorage.documents/document/primary%3AMaterial-Icons-010317-032209%2Fres%2Fdrawable-xxxhdpi%2Fic_car.png ] If [ %LastLocation Set ]           A7: Notify [ Title:Location Issue Text:Im sorry location could no be set. Icon:hd_aaa_ext_car Number:0 Permanent:Off Priority:5 Actions:(1) ] If [ %LastLocation !Set ]           A8: Set Widget Icon [ Name:LocCar Icon:content://com.android.externalstorage.documents/document/primary%3AMaterial-Icons-010317-032710%2Fres%2Fdrawable-xxxhdpi%2Fic_car.png ] If [ %LastLocation !Set ]  

screenshot_20170103-165204

Getting location (A1-A4)

There are a few things I want to do before getting the location fix. Because most of the time %LOC (Tasker's global location variable) will have a value assigned to it already (last location fix), I only want to use the location coordinates requested through the profile. I will use the global variable %LastLocation to store these coordinates. If the task has been run again due to an error or a timeout, I need to clear the existing warning notification with the Notify Cancel action.

Notifications (A5,A7)

Fail Success

There are two outcomes of the Get Location action. We will end up with a new set of coordinates, or the action will fail to acquire the coordinates. If the fix is found, a notification will be displayed. Note the name of this notification. We will use this name to trigger the Return Location profile later. If a location fix is not made, or the coordinates are the same as before the Get Location action, we want to display a warning with an option to re-run the same task again (Action Perform Task assigned as a button).

Button (A6,A8)

I mentioned earlier that there will be a button which will change the color to show us a state of our parking profile. Color codes are:

  • white (ready)
  • red (fail)
  • green (armed)

All you need is a Tasker widget (not the shortcut) placed on your home screen for the task which will save the location. Make sure to assign an icon to this task to be able to add a task shortcut from the widget screen. I'm using this instead of the shortcut as I get Tasker to change the color of the icon according to the current state.
One of my favorite ways of getting the icons is the Material Design Icon collection, as you can find the one that suits you and quickly provide its color alternatives.
I have labeled the actions to show which one corresponds with fail/success outcomes. The IF condition %LastLoctation = set/not-set determines that outcome.

Return the location

Return Location

   ReturnLocation           A1: Send Intent [ Action:android.intent.action.VIEW Cat:None Mime Type: Data:google.navigation:q=%LastLocation&mode=w Extra: Extra: Extra: Package:com.google.android.apps.maps Class: Target:Activity ]           A2: Set Widget Icon [ Name:LocCar Icon:content://com.android.externalstorage.documents/document/primary%3AMaterial-Icons-010317-032200%2Fres%2Fdrawable-xxxhdpi%2Fic_car.png ]           A3: Wait [ MS:0 Seconds:3 Minutes:0 Hours:0 Days:0 ]           A4: Variable Clear [ Name:%LastLocation Pattern Matching:Off ]  

screenshot_20170103-044653

The task is very simple. We will run a Google Maps intent which will contain a  location link:

  Action: android.intent.action.VIEW  Data: google.navigation:q=%LastLocation&mode=w  Package: com.google.android.apps.maps  Target: Activity  

Our location global variable will supply the necessary coordinates. Once this is done, we just need to clean up the variable (please add a wait action) and change the color of the widget icon to white.

Profile: Return To Location

screenshot_20170103-044743

Return to Location profile

  Profile: Return To Location          Event: Notification Click [ Owner Application:* Title:Location Saved ]  Enter:        ReturnLocation  

Now that we've set our car's location, we will create a profile that is triggered when we manually request our car's location at a later time. To trigger this task from the notification we created earlier, create an event Notification Click and add the name of the notification created earlier (Location Saved)

You now have a complete profile ready.

Using Voice Commands

AutoVoice profile

  Profile: Save Location          Event: AutoVoice Recognized [ Configuration:Easy Commands: save my location,save this location,save my parking spot,save this parking spot,remember my parking spot,remember my location,mark this location,mark this spot,mark this parking spot  Responses: okay i'll save your parking spot ]  Enter: LocCar     

Should you wish to add a voice trigger to save your parking spot location, create a profile using the AutoVoice Recognized event. Fill the input with the potential spoken commands that you would use separated by commas. If you wish to hear the response – include one in the Responses menu. Once this is done, link this with the LocCar task created earlier.

If you wish to use an AutoVoice command to find your saved location as well. Create a new AutoVoice Recognized event, and link it to the ReturnLocation Task.


Conclusion

It is easy to assume that everyone has access to the same resources, but this is not often the case. Should you find yourself needing a simple way to save your parking spot without relying on Google services – or you simply prefer avoiding Google services entirely, this project is for you.

This project can also be modified and used for other purposes, unlike Google Now's parking card, so see if you can come up with something better. You can also experiment with AutoNotification to make the notifications more pretty or more interactive. I kept the entire project close to the vanilla Tasker experience (apart from using AutoVoice).

Download the project here!

In order to import a Tasker project file, download the above file and save it anywhere in your internal storage. Open up Tasker and check to make sure that "beginner mode" is disabled in the preferences menu. Then, long-press on the "home" icon in the bottom left hand corner and click on "import". Find the prj.xml file you saved earlier, and select it to import it. You will now see a new tab in the bottom row containing all of the profiles and tasks we referenced in this article.

We hope you enjoy this little creation of ours, and let us know if you think we can make any enhancements!



from xda-developers http://ift.tt/2j6zaF2
via IFTTT

Dissecting Performance: A Look at What Makes the OnePlus 3 & 3T Excellent Real-World Performers

To Android enthusiasts, speed matters — we recognize we use our phones for hours upon hours every day, often in quick and short bursts, and we want the best out of our time and often-expensive flagships.

Surprisingly enough, it's some of the least expensive flagships that performs the best in the real world — we are talking about the OnePlus 3 and OnePlus 3T, the affordable premium smartphones that still manage to pack bleeding edge hardware. The processing package of these phones should be enough to suggest exceptional performance: a Snapdragon 820/1, 6GB of  DDR4 RAM, and even UFS 2.0 storage, the only component that has an update available in modern smartphones like the Huawei Mate 9. For all intents and purposes, the OnePlus 3 and 3T have the best chipset and RAM configuration that non-Samsung and non-Huawei Android smartphones can have at this moment in time, and they will stay at the top until the new wave of early 2017 flagships hit the market.

But as we've seen time and time again, good hardware does not necessarily lead to excellent performance. In fact, we saw some glaring flaws in some of the most theoretically powerful smartphones of 2016, something that's become a sort of tradition with certain OEMs. Leaving aside the specifics, we know that an OEM's software and the implementation of the hardware at hand can have a tremendous impact in the resulting real-world performance. Thermals, for example, are very important for sustained smartphone usage, and while the Snapdragon 810 is long dead-and-buried (well, almost), we still see some Snapdragon 820 devices heat up quite a bit more than others. That being said, we found the OnePlus 3 in particular to do an excellent job in this regard, so we know that, at the very least, OnePlus learned from the mistakes it made with the OnePlus 2, and that the OnePlus 3 doesn't butcher its meaty hardware through shoddy implementations.

What about real world performance? There are a myriad of factors that affect the resulting speed of the actual user experience, from the heft of the OS and bloatware to the frequency scaling algorithms employed by the OEM. As we've explained in a recent editorial, measuring real-world performance is a hard thing to do, but we can look at the objective causes – code, measurable behavior and design – to get an idea of what makes a phone perform (or appear to perform!) faster. Below we'll explain and demonstrate some of the more curious factors that help the OnePlus 3 and 3T achieve such excellent real-world performance.


Animation Tricks

This first example is a kind of illusion rather than an intricate software-hardware implementation. As many of you know, Animations can convey a strong feeling of speed and fluidity to the user — this is why one of the most popular pieces of advice ever given on XDA and other Android communities is setting the animation speed to x0.5 in the "developer options" menu. Many people swear this makes their devices "much faster", but in reality, the application state itself is loading at the same speed — the information is just displayed quicker, the response time looks shorter. If the activity being loaded or rendered is indeed very simple and takes next to no time to be fully displayed, then this animation speed change is even more effective. The same goes for loading applications from RAM and general in-app navigation, as these settings govern everything from app transitions to in-app animations and the speed of certain UI elements and menus.

OEMs understand the importance of animations, with a clear example being HTC and its M8, M9 and HTC 10 devices. The HTC M8 originally surprised users due to its speed and responsiveness — it's true that it employed excellent hardware for the time (that Snapdragon 801 holds up even today), but a not-so-sung-about aspect of this apparent prowess was HTC's use of animations. Not only did they speed up many transitions by default, but they flat-out removed some of them, such as going back to the homescreen. OnePlus does something very similar with the OnePlus 3 and 3T, a neat trick that the company's co-founder Carl Pei is not very shy about in interviews. In order to make the phone appear faster while still having animations that behave like Android proper, they add a subtle fade-out to the homescreen return animation, for example, in order to have it "end" sooner – smoothly and without jarring cuts – while still appearing fluid and very comparable to a Stock Android device.

In the first example above, the alpha begins changing shortly after the card begins moving downwards, while remaining visible enough for the user to subconsciously pick-up on the motion. This tricks you into recognizing it as the original Android transition (with a change in vertical speed), but you also see it end sooner as it fades before it reaches the bottom. This animation is most noticeable when lengthening the animations through the aforementioned developer options. The same effect is applied when opening applications, either hot or cold, from the homescreen, although in this instance it is a lot more subtle, although not as confined to the beginning of the animation as seen on the Pixel XL. You can also see that the Pixel XL's window expansion has a deceleration that makes it finish after the OnePlus 3T's, which keeps a linear speed throughout. That last segment of the animation actually costs the Pixel XL a few extra milliseconds, although it arguably looks cleaner and more inline with Material Design guidelines.

CPU Scaling and App Opening Speeds

This one is a curious aspect that I never see brought up when discussing app opening speeds, or general performance for that matter, and it's a shame that it isn't given how interesting it is. When Qualcomm brought up the "faster app launch times, and smoother, more responsive user interactions" featured in the Snapdragon 820 and 821, they didn't specify how this was achieved. In reality, it's due to a pretty clever feature that Qualcomm makes available on the chip for OEMs that purchase Snapdragon 820 and 821 processors, but not all manufacturers decide to implement it or implement it in the same way. Essentially, the OnePlus 3 and OnePlus 3T are able to detect when Android is opening an application, and then quickly scale up and max out the clockspeeds on all cores in a short burst in order to get the fastest opening speed the device can achieve.

This is due to an overbearing boost framework Qualcomm offers to OEMs, with some of it being observable CAF sources and part of it being proprietary (which means they couldn't disclose much to me about it) — custom ROM makers can opt to strip this out of their ROMs when building from CAF, as SultanXDA did in favor of his own custom implementation (which is also very clever and works well). According to Qualcomm, there is no public name for this feature, and it's indeed not something that's been widely discussed. OnePlus isn't the only OEM to implement this either, but as said earlier, OEMs can and do use the feature differently. For example, the OnePlus 3 boosts the CPU frequency both when opening applications and when loading them from the recents menu but at different maximum frequencies, whereas the Google Pixel boosts both activities at the same peak frequencies. Moreover, app opening is not the only activity "boosted" by Qualcomm's framework: it can also tap into boot processes, scrolling events, and also offers optimizations for a better browsing experience.

What's perhaps most interesting is that this "boost mode" is the only way in which the OnePlus 3T can achieve the peak 2.19GHz frequency on the little cluster. OnePlus was very conservative in its official specification sheet, as they rightly state that the OnePlus 3T's little cluster has a peak frequency of 1.6GHz, just like the original OnePlus 3. This much is true for many day-to-day operations, but Qualcomm's boost framework is designed specifically around ramping up the little cluster frequency of the Snapdragon 821-AC to 2.19GHz when launching applications, as confirmed to XDA by Qualcomm. The chipset maker also informed us that the Snapdragon 821-AB (found in the Pixel and Pixel XL) can also access this "boost mode", albeit up to a maximum of 2GHz in the efficiency cluster (by default); interestingly enough, the Pixel XL keeps it conservative as even in this scenario, the peak frequencies are 2.15GHz+1.6GHz.

F2FS with UFS 2.0

Another often-understated contributor to the exceptional real-world performance of 2016 flagships is the kind of storage they implement, and the read and write speeds they achieve. This helps in many operations including (and especially) opening applications, meaning many of the famous app opening tests you find on YouTube have a significant reason to detail not just the processor employed, but the storage type as well. The OnePlus 3 and OnePlus 3T are two of many devices that now employ UFS 2.0 storage, in particular a chip manufactured by Samsung. The Galaxy S6 was the first smartphone to utilize UFS storage, which marked a significant improvement over the previous eMMC solutions. The UFS 2.0 standard has faster theoretical maximums than a typical eMMC 5.1 solution, allows for simultaneous read and write processes, and it also includes new protocols and methods to reduce inefficiencies. UFS also has great performance scalability, uses little power and is optimized for mobile like eMMC. High-resolution video recording and storage-intensive tasks as well as loading heavy applications and games are some of the usage scenarios that see tangible benefits from this storage solution.

efs2-0comparison

Source: Samsung

While many phones today use UFS 2.0 storage (and some even come with UFS 2.1), OnePlus managed to squeeze the most out of the UFS 2.0 chip on their OnePlus 3 by switching to F2FS starting with Android Nougat (and once you reset your device, as the switch requires formatting that would compromise your data). They informally began testing the feature with their Marshmallow community builds, too, and it's one of the reasons why the OnePlus 3T (F2FS by default) had a small performance advantage over the OnePlus 3 in both storage benchmarks and controlled app-opening tests. F2FS (Flash-Friendly File System) is a file system developed by Samsung in 2013 to cater to the specific characteristics of NAND-based storage solutions, specifically for use on Linux-based operating systems. It employs a log-structured file system, which writes all modifications to disk sequentially in a circular buffer structure, and it's faster than the traditional EXT4 standard on flash memory in most cases. XDA users have been experimenting with this for years, by the way, and you too can reformat your cache partition through TWRP if your kernel supports F2FS.

launchf2fs launchext4

Not many OEMs have adopted into F2FS because there are still issues to solve, but some like Motorola have already tried it on their largely-Stock ROMs, making performance all that much sweeter. Furthermore, because of the CPU scaling mentioned above while opening applications, it's ensured that you'll get the most out of the UFS 2.0 storage because it eliminates possible bottlenecks caused by an interactive frequency scaling in the CPU. We took a look at the OnePlus 3 and OnePlus 3T's storage solutions and file systems to clear up some misconceptions, and found that F2FS did indeed make a substantial difference in synthetic benchmarks like AndroBench, but also a noticeable and replicable difference in real-world scenarios such as app and game opening speeds, which we measured using Discomark, gathering large samples and controlling for variables. At the time, it was hard to discern why the OnePlus 3T's performance was slightly superior to the OnePlus 3's (early graphs shown above), but further tests with a reformatted OnePlus 3 showed that, under F2FS, the difference almost disappears regardless of storage capacity, as OnePlus' UFS 2.0 chip didn't increase storage by employing parallel chips.


What have we learned?

The biggest takeaway of this short exploration is the fact that OnePlus managed to achieve superior performance on the OnePlus 3 and 3T (compared to other OEMs) despite the fact that their devices largely employ the same hardware as other flagships. The RAM amount of the OnePlus 3 wasn't properly utilized at launch, and OnePlus is still satisfied with a ro.sys.fw.bg_apps_limit value of 32 (instead of the initial 20), which is still lower than the peak of 60 some more intrepid OEMs chose for their 4GB RAM devices. This puts a cap in the number of applications that can remain open at any given time (keep in mind you can edit this value if you so choose), meaning that if anything, RAM is the one aspect where the OnePlus 3 doesn't use its hardware to the fullest extent.

But as we've shown with the animations example, performance can appear to improve with mere tweaks to the design of the user experience. There are plenty of examples around, but the UI design and animation type or speed choices ultimately make a perceptible difference to the end user; using animations intelligently is not just smoke and mirrors, it's a smart design practice that other companies like Apple have also exploited to great extent in order to have their phones appear better than they are. OnePlus did a pretty good combination of design tricks and cutting-edge software to make the most out of the hardware in many regards, and the result is what I personally understand to be the fastest phone currently available (although the Pixel and Pixel XL certainly trade blows with it when it comes to smoothness and responsiveness). We hope you enjoyed these curious tricks and stay tuned for more dissections in the future!

What neat tricks have you found make your device faster? Share your observations in the comments!

>>> Check Out XDA's OnePlus 3 Forums!



from xda-developers http://ift.tt/2iX8qK5
via IFTTT