mercredi 14 février 2018

How to Customize the Google Pixel 2 Always On Display’s Brightness without Root

Google's latest flagship smartphones, the Pixel 2 and Pixel 2 XL, are the first Google smartphones to offer an Always on Display feature. Other smartphones such as most Samsung Galaxy flagships have had such a feature for awhile, but with the introduction of the feature on the Pixel flagships also came the source code for the feature, which allows for it to work on older Nexus and the first generation Pixel phones. The Always on Display currently shows the time, date, alarm, notification icons, and the currently playing background song via Now Playing (though that can be customized). We're here to show you today how to customize another aspect of the Pixel 2's Always on Display: its brightness.

The AOD feature can be useful when you have the device sitting on your desk off to the side, but that really depends on your lighting situation. In many instances, the AOD can seem too dim to actually be readable. Do a quick Google search for "Pixel 2 Always on Display brightness" and you'll see tons of complaints about how dim it can be.

The problem here is that the brightness of the AOD is tied to Adaptive Brightness, Google's automatic brightness feature which I'm sure most people have enabled. Depending on the amount of ambient light, the AOD can go from a minimum brightness value of 2 to a maximum of 28. That's out of 255, which is the maximum integer value of the display brightness in settings. In essence, the brightest the AOD can ever get with Adaptive Brightness is about 11% of the maximum display brightness—which is pretty pitiful in many cases. Thankfully, this can be tweaked, and the best part is that it doesn't require you to root your phone.


Customize Google Pixel 2 Always on Display's Brightness

What we'll be doing here is changing a hidden setting that is only available starting with Android 8.1 Oreo. That's not a problem as every Pixel 2 owner should already be running the latest release, but it's worth mentioning regardless. The hidden setting is only accessible through the Android Debug Bridge (ADB), which means you'll need to connect your phone to your PC. If you have a computer handy, then you're ready to follow these steps:

  1. Set up ADB as described in this previous tutorial.
  2. Open a command prompt or terminal and enter a command in the following format: adb shell settings put global always_on_display_constants "screen_brightness_array=-1:0:1:2:3"
  3. Replace the "0:1:2:3" from the above command with any set of 4 numbers from 0 to 255 (such as "2:25:100:250"). Leave the "-1" in place.

Customize the Always on Display Brightness on the Google Pixel 2 and Pixel 2 XL

Now, your Always on Display brightness can be tweaked to be way higher than ever before! If you're curious what each number in the array represent, the first number you put in is for a "night" condition (very, very low ambient light), the second for a "low" light condition, the third for a "high" light condition, and the last for "sun" (very, very high ambient light).

Customize the Always on Display Brightness on the Google Pixel 2 and Pixel 2 XL

The above shows the default values in the AOD brightness array. You can refer to this if you ever want to revert the changes you make here.

Bonus: Other Always on Display Tweaks

Besides the brightness tweak, there are some other settings related to the Pixel 2 Always on Display that you can modify. Here's the list:

  • dimming_scrim_array: Integer array to map ambient brightness type to dimming scrim. This essentially "masks" the AOD with an overlay to dim it even further (not really sure why one would want this).
  • prox_screen_off_delay: Delay time (in milliseconds) from covering the proximity sensor to turning off the screen.
  • prox_cooldown_trigger: The threshold time (in milliseconds) to trigger the cooldown timer, which will turn off proximity sensor for a period.
  • prox_cooldown_period: The period (in milliseconds) to turning off the proximity sensor if prox_cooldown_trigger is triggered.

Here's an example of how to use some of these values to tweak the AOD. Let's say I want to make it so the screen turns off 5 seconds after the phone's proximity sensor is covered when the Always on Display is showing. I would enter this command:

  adb shell settings put global always_on_display_constants "prox_screen_off_delay=50000"  

Customize the Always on Display Brightness on the Google Pixel 2 and Pixel 2 XL

You can play around with these settings to customize the behavior of the AOD, though these are all you'll be able to modify without root access, unfortunately.



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

Aucun commentaire:

Enregistrer un commentaire