• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!
  • Fill out your device list and let everyone know which phones you have!    Edit Your Device Inventory

[ROOT/Magisk] Enable Always on Ambient Display on Oxygen OS 11 Beta 1

Search This thread

Quinny899

Recognized Developer / Recognized Contributor
Jan 26, 2011
8,530
7,782
23
Salford, Greater Manchester, UK
quinny898.co.uk
Contrary to what OnePlus have said, the code for the Always on Ambient Display is in the first beta of Oxygen OS 11. All you have to do is enable the feature, which is disabled in the "OPFeatures" framework. This is very simple, and can be done in two lines in a root terminal (ie. do "su" first):

Code:
setprop sys.aod.debug_support_always_on 1
pkill systemui

After you have done this, the option to enable it will appear in Settings > Display > Ambient Display > Always on ambient display.

This doesn't survive a reboot, but you can have Magisk do it on boot for you. Only the first line is required for this (since SystemUI won't have started yet), simply drop the .sh file from the attached zip into /data/adb/service.d, set its permissions to rwxr-xr-x (chmod 755) and reboot. Please note that the zip is not flashable and cannot be used as a Magisk module. Something as simple and temporary as this (hopefully anyway, OnePlus have said this feature will come later) doesn't need a full blown Magisk module.

 

Attachments

  • aodenable-NOT-FLASHABLE.zip
    218 bytes · Views: 2,131

DanGLES3

Senior Member
Nov 11, 2017
749
725
You can, but Magisk isn't really built for modules to do tiny things like this. One liners are what service.d scripts are for.
I'm aware of that, i just think users would be more comfortable installing a module than moving files, i just like making things easy for people ya know

About Service.d/Post-fs-data imo it would be cool if Magisk had a built in interface to manage/install scripts as Magisk is great for boot scripts but offers no straightforward method of installing/managing them other than making modules or manually moving files
 

Attachments

  • aod.zip
    2.6 KB · Views: 1,106

Quinny899

Recognized Developer / Recognized Contributor
Jan 26, 2011
8,530
7,782
23
Salford, Greater Manchester, UK
quinny898.co.uk
I'm aware of that, i just think users would be more comfortable installing a module than moving files, i just like making things easy for people ya know

About Service.d/Post-fs-data imo it would be cool if Magisk had a built in interface to manage/install scripts as Magisk is great for boot scripts but offers no straightforward method of installing/managing them other than making modules or manually moving files

Agreed, maybe it'll come with the often-teased Xposed style injections one day
 
  • Like
Reactions: DanGLES3

GeneFitz23

Member
Aug 29, 2013
48
21
I'm aware of that, i just think users would be more comfortable installing a module than moving files, i just like making things easy for people ya know

About Service.d/Post-fs-data imo it would be cool if Magisk had a built in interface to manage/install scripts as Magisk is great for boot scripts but offers no straightforward method of installing/managing them other than making modules or manually moving files
Thank you!
 

ontwykende

Senior Member
Feb 25, 2017
80
18
Thank you very much for this.
Is there any shortcut for notification bar for fast on/off ?
And can I use Taskrer sehell command to Toggle AOD on/off (for example when "do not disturbe mode is on" or when I put phone to pocket). Something like options that existed in Exposed AOD Mod?
 

Quinny899

Recognized Developer / Recognized Contributor
Jan 26, 2011
8,530
7,782
23
Salford, Greater Manchester, UK
quinny898.co.uk
Thank you very much for this.
Is there any shortcut for notification bar for fast on/off ?
And can I use Taskrer sehell command to Toggle AOD on/off (for example when "do not disturbe mode is on" or when I put phone to pocket). Something like options that existed in Exposed AOD Mod?

It turns off automatically when it's in your pocket, but for DnD you probably would need to find the setting that controls it and toggle that
 
Jan 23, 2021
4
0
Nah mine works as intended I dunno honestly that's what I'm tryna figure out is magisk needed for certain versions of the 7t because I can go into settings and extra the only thing I noticed that does not function as should is the ambient light
 

vtec303

Senior Member
Sep 19, 2007
1,417
441
Manchester
OnePlus 7 Pro
OnePlus 8 Pro
I'm aware of that, i just think users would be more comfortable installing a module than moving files, i just like making things easy for people ya know

About Service.d/Post-fs-data imo it would be cool if Magisk had a built in interface to manage/install scripts as Magisk is great for boot scripts but offers no straightforward method of installing/managing them other than making modules or manually moving files
Thanks a bunch! Much much easier.
 

ontwykende

Senior Member
Feb 25, 2017
80
18
Nah mine works as intended I dunno honestly that's what I'm tryna figure out is magisk needed for certain versions of the 7t because I can go into settings and extra the only thing I noticed that does not function as should is the ambient light
I am on international version O2_BETA_01 and in my case I needed to unveil "when to show" option in display-ambient display, by using shell command /script from here.
 

ontwykende

Senior Member
Feb 25, 2017
80
18
I still didn't find out how to turn it on/off from tasker... only to use shell command from first post?
is there any other shell command just to turn AOD on/off and not to hide options from display/settings ?
 
Last edited:

lil_kujo

Senior Member
Oct 29, 2015
805
443
I still didn't find out how to turn it on/off from tasker... only to use shell command from first post?
is there any other shell command just to turn AOD on/off and not to hide options from display/settings ?
Your right it does work excellent made a script from FKM to trigger both upon reboot. Thank
With FKM script manager you don't need to use a terminal you can run right from that app
 

ontwykende

Senior Member
Feb 25, 2017
80
18
Your right it does work excellent made a script from FKM to trigger both upon reboot. Thank
With FKM script manager you don't need to use a terminal you can run right from that app
what I would like is to turn the AOD on or off with the shell command from Tasker ... For example, the AOD can only be ON when I have a new notification OR it can be completely Off when the "Do not disturb mode" is on (I already have task to turn Do not disturbe mode ih house (wifi zone) during night).
 
Jan 23, 2021
4
0
I am on international version O2_BETA_01 and in my case I needed to unveil "when to show" option in display-ambient display, by using shell command /script from here.
Ahhhh I see now I don't have that " when to show " option
 

Attachments

  • Screenshot_20210125-043727.jpg
    Screenshot_20210125-043727.jpg
    172.6 KB · Views: 307

Top Liked Posts

  • There are no posts matching your filters.
  • 12
    Contrary to what OnePlus have said, the code for the Always on Ambient Display is in the first beta of Oxygen OS 11. All you have to do is enable the feature, which is disabled in the "OPFeatures" framework. This is very simple, and can be done in two lines in a root terminal (ie. do "su" first):

    Code:
    setprop sys.aod.debug_support_always_on 1
    pkill systemui

    After you have done this, the option to enable it will appear in Settings > Display > Ambient Display > Always on ambient display.

    This doesn't survive a reboot, but you can have Magisk do it on boot for you. Only the first line is required for this (since SystemUI won't have started yet), simply drop the .sh file from the attached zip into /data/adb/service.d, set its permissions to rwxr-xr-x (chmod 755) and reboot. Please note that the zip is not flashable and cannot be used as a Magisk module. Something as simple and temporary as this (hopefully anyway, OnePlus have said this feature will come later) doesn't need a full blown Magisk module.

    9
    You can, but Magisk isn't really built for modules to do tiny things like this. One liners are what service.d scripts are for.
    I'm aware of that, i just think users would be more comfortable installing a module than moving files, i just like making things easy for people ya know

    About Service.d/Post-fs-data imo it would be cool if Magisk had a built in interface to manage/install scripts as Magisk is great for boot scripts but offers no straightforward method of installing/managing them other than making modules or manually moving files
    3
    Of course I can share.
    I also played around and did a qick setting toggles (AOD on/Off from notification bar).
    -AOD_Notification.prj.xml is project to be inport to Tasker, it contains 2 profiles - for notification On and Off and 2 tasks
    -AOD.tsk.xml is just task for qick toggle and it should be inport in tasker and selected in notification bar menu)

    AND ONE MORE TIME, big THANK YOU to Quinny899 , without you none of this would be possible.
    3
    If anyone was wondering, this also works on Stable OOS 11.0.0
    2
    Is there an Amoled protection? Meaning is the AOD clock moving a bit to avoid burnin?

    Yes. It moves all around the screen, much more than the Pixel one