[ROOT][APP] Logo+ - OSS Implementation of Lighting Effects for Razer Phone 2 - Razer Phone 2 Themes, Apps, and Mods

{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
My device has met with QC issues and I've elected not to replace it. Development on this project may stagnate
LogoPlus is an Open Source Alternative to the stock Razer Chroma Configurator app and corresponding service
The latest version can be downloaded from GitHub (cant load XDAs upload plugin in my browser for some reason)
Demo video attached to post #2
The current feature set includes:
Select custom notification color per app
Set LED brightness
Up to 4 apps' colors on the logo at once
5 different passive effects
Animation for phone ringing, with different colors per contact
Pocket mode. Lights turn off if placed into a pocket or bag
Automation integration (Tasker/Locale)
Charging animation
Custom effect programs
Music visualizer (controllable via automation plugin)
In order to use the app correctly, please disable the "Chroma" system app
Currently notifications will only be displayed when the phone is locked (screen off or on lock screen)
Also please enable notification access for the app as it currently doesnt ask for it automatically
Also please disable battery optimisation for the app so Android doesn't kill the service
Also I haven't done apps for a while, so please excuse the very messy code
XDA:DevDB Information
LogoPlus, Device Specific App for the Razer Phone 2
Contributors
CurtisMJ
Source Code: https://github.com/CurtisMJ/LogoPlus
Version Information
Status: Stable
Current Stable Version: 1.0.13
Stable Release Date: 2020-04-09
Created 2019-01-26
Last Updated 2020-04-09

Reserved
Changelog:
v1.0:
- Initial release
v1.0.1:
- Improved service coordination
- Code cleanup
- Added passive effects
v1.0.2
- Bug fixes and code cleanup
- Service co-ordination improvements
v1.0.3
- Moved to Room DB for persistence
- Support libraries migrated to AndroidX
- Various threading and coordination improvements
v1.0.4
- Main service is now a proper state machine, allowing for functionality to be more easily added in future
- Notification listener caches settings in RAM for better performance and efficiency
- Various bug fixes
v1.0.5
- Tweaked microcode to be more efficient, as a result, 6 colors can now be displayed at once for app notifications.
- State machine paths improved
- Separation of concerns in state machine, allowing for more possible backends for controlling the lights (such as stock ROM system services)
- Phone ring animation! Complete with specific colors per contact!
Disclaimer:
This build contains dormant code for both the rootless mode and music visualizer, 'cause using feature branches would mean I have my life together. I'll activate them when they're stable enough to actually use.
v1.0.6
- Pocket mode! When the screen is switched off, the app will query various sensors for a few seconds afterwards and if it is determined the device is placed in a pocket or bag, the lights will be disabled, which can save battery.
- Some explanations added for the 2 toggles in the passive effect screen
- Service worker wakelock renamed to more accurately describe its source
- Code cleanup
v1.0.7
- First stable release
- New icon
- Automation integration (Tasker) first phase
- In order for automation to work, the "Allow Automation" switch must be turned on from the main drawer
- New "Roll" passive effect
- Code cleanup and optimization
v1.0.8
- Charging animation
- Various improvements to state machine
- Now asks for exemption from battery optimization
- Sped up fadeout effect
v1.0.9
- Dependency updates (newer libsuperuser)
- Added custom effects!
NOTE: Custom effect programs must be compiled with Texas Instruments' Lysti compiler which can be found on the support page of the LP5523 controller.
See my Chroma research thread on XDA for details:
https://forum.xda-developers.com/razer-phone-2/development/research-oss-chroma-service-t3890290
v1.0.10
- Limit of 6 apps on LEDs at once has been reduced to 4 in order to generate higher quality microcode, as there was an issue with timing before which could make it unclear what color the logo is flashing
- Now uses E164 format phone numbers internally for comparison. This should make number identification for ring animation more reliable.
- Notification preference for apps now previews the color on the logo while picking
v1.0.11
- Music Visualizer! Toggle the visualizer switch in the drawer and then play some music!
Side note: I'm pretty sure this is bad for the LEDs. Use sparingly
v1.0.12
Now asks for recording permissions!
Also BitDefender didn't mark it as malicious! I have literally no idea!
v1.0.13
Added ability to control visualizer state from automation plugin! (Tasker, Locale)
You may wish to disable the toggle for automatic visualization state control in the main UI as this may interfere with your custom logic in your automation application of choice.

Reserved
Creating custom effects
The app supports loading of custom microcode programs into an effect slot. This allows for many possible lighting effects for the passive effect.
Please note that creating custom effects is very advanced! One should have at least some knowledge of assembly, programming and integrated circuits in general. Reading Texa Instruments' literature on the controller is strongly advised, the LED controller is very constrained in it's abilities.
In order to begin, you will need the TI Lysti compiler. You can find a link to it in post #1 of my Chroma Research Thread under "Controller OEM support"
The compiler compiles an assembly style language called Lysti into a .hex file. Rename the .hex to .txt and place the file somewhere on your phone's internal storage, then click the "Load Custom" button from in the app and select the file. The program will be validated and you will see either a success or failure message. Once loaded, the program will play as the passive effect if you have the "Custom" effect selected as your passive effect. Only one program at a time is currently supported.
Below is a sample of the "Pinwheel" effect used by the app in Lysti:
Code:
ENG1: dw 0000000001011000b ; R G B
ENG2: dw 0000000010100001b ; G B R
ENG3: dw 0000000100000110b ; B R G
ALL: dw 0000000111111111b
.segment program1
mux_map_addr ALL
set_pwm 0
trigger s{2|3}
loop2: mux_map_addr ENG1
ramp 2, 255
ramp 2, -255
ramp 2, -255
branch 0, loop2
rst
.segment program2
trigger w{1}
loop3: mux_map_addr ENG2
ramp 2, -255
ramp 2, 255
ramp 2, -255
branch 0, loop3
rst
.segment program3
trigger w{1}
loop4: mux_map_addr ENG3
ramp 2, -255
ramp 2, -255
ramp 2, 255
branch 0, loop4
rst
This compiles into the following .hex
Code:
00 58 00 A1 01 06 01 FF 9F 83 40 00 E0 0C 9F 80
20 FF 21 FF 21 FF A0 03 00 00 E0 80 9F 81 21 FF
20 FF 21 FF A0 01 00 00 E0 80 9F 82 21 FF 21 FF
20 FF A0 01 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
@ 04 program1
@ 0D program2
@ 14 program3
The first 12 lines consist of the compiled bytes of the program followed by the offsets for the 3 program counters (The controller is a triple core )

Wicked work mate!!! A music visualizer would be a great addition

Wicked work mate!!! A music visualizer would be a great addition. Are you able to compile it for as apk

DanXbix said:
Wicked work mate!!! A music visualizer would be a great addition. Are you able to compile it for as apk
Click to expand...
Click to collapse
Apk is available in the download tab. You might have to view the thread in a browser

CurtisMJ said:
Apk is available in the download tab. You might have to view the thread in a browser
Click to expand...
Click to collapse
yup worked it out was on phone lol

Update
New version v1.0.1 available in Downloads section!

amazing work!!!
working on phh-aosp

Awesome work! So glad someone has taken this on. Will definitely watch this thread and look forward to future updates, feature expansions, and bug fixes, etc. Good job so far.

Will it always be the case that the app requires root access?

I keep getting this when enabling the service

AbsoluteContingency said:
Will it always be the case that the app requires root access?
Click to expand...
Click to collapse
It might be possible to implement the functionality in a daemon, or even as a system service for custom ROMs where we can add source code (this is how Razer did it).
It's also probably possible to use Razer's own system service, but that's a lot of reverse engineering on the Chroma Configurator, and won't work for custom ROMs. Using root seems more aligned to the purpose of the app at the moment but I'll consider alternatives. Most of the magic was figuring out the microcode anyway

ctakah27 said:
I keep getting this when enabling the service
Click to expand...
Click to collapse
Just realized I have release builds up so the logs won't even be much use... Sorry about that, you can try clearing the app's data and see if it'll cooperate. I've got another version soon. I'll remember to enable debug build

Awesome work! This is functionality that should have shipped with the phone from the factory. Been running the pinwheel animation for the past 1.5 days and haven't noticed any increased battery usage.

CurtisMJ said:
... I've got another version soon. ...
Click to expand...
Click to collapse
Ok maybe not soon soon. But definitely this afternoon

OK, new build is up! v1.0.3
This is mostly just trying to stabilize the app. New features should come soon
If the release build gives issues, please switch to the debug build and capture some logcats. Only logcats for the application package is sufficient
Lastly, as I've changed the persistence system, unfortunately settings from v1.0.1 wont carry over

CurtisMJ said:
It might be possible to implement the functionality in a daemon, or even as a system service for custom ROMs where we can add source code (this is how Razer did it).
It's also probably possible to use Razer's own system service, but that's a lot of reverse engineering on the Chroma Configurator, and won't work for custom ROMs. Using root seems more aligned to the purpose of the app at the moment but I'll consider alternatives. Most of the magic was figuring out the microcode anyway
Click to expand...
Click to collapse
I'm gonna level with you man, I don't understand a lot of this. I was hoping it was as easy as having one that worked on custom ROMs and another that could be sideloaded as another app on the stock non-rooted RP2, but now that I'm thinking about it I suppose you are controlling a pretty odd piece of actual physical hardware that isn't exactly standard on phones.
I'll keep this thread around and check it every now and then to see if a non-root version ever comes around. It seems super cool, and I'm glad someone is tackling the logo, even if (at least right now) I can't take advantage of it. Keep up the cool work, dude.

For anyone that hasn't given this a go, try it! It's spectacular. Exactly what the Chroma app should be. The pinwheel effect is sexy af too! Good work, keep it up.
Briefly had a issue with it not turning off when screen was off, toggle seemed to do nothing, reinstall fixed it. No issues otherwise.

v1.0.4 has been uploaded
Still mostly a bugfix build
If the release build gives issues, please switch to the debug build and capture some logcats. Only logcats for the application package is sufficient

Related

Comm Manager skin Manila2D style

Made skin for Comm Manager (from latest M2D) its perfect match for M2D but I can't make the text in white [SOLVED]
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
*EDIT#2(25.09.08)*
Best to change reg like this HKLM\SOFTWARE\HTC\CommManager\TextColorSetting = FF FF FF 00 FF FF FF 00 FF FF FF 00 99 99 99 00 99 99 99 00 99 99 99 00 99 99 99 00
Changing the top bar font to match m2d font also would be good but i cant find where to change it.
*don't know what solved the text color problem cause as first registry edit didn't work*
*i changed start icon then wanted to turn it back so deleted shellres.96.*
*then copied other icons and after one of the resets the comm manager colors changed - strange but i like the result
Here are the files, just extract to \Windows
Looks good!
Great job
drmidnight said:
Looks good!
Click to expand...
Click to collapse
no, it doesn't.
as You said, black font is wrong and switch colors are unacceptable.
The settings icons are the original but inverted i posted here: http://forum.xda-developers.com/showpost.php?p=2678276&postcount=877
korro said:
no, it doesn't.
as You said, black font is wrong and switch colors are unacceptable.
Click to expand...
Click to collapse
What you mean switch colors are unacceptable?
Now its unfinished but if it possible to make the text white it will match M2D.
SOLVED
I don't know how but now registry edit worked!
1st post updated
bnm7bnm said:
Made skin for Comm Manager (from latest M2D) its perfect match for M2D but I can't make the text in white [SOLVED]
*EDIT*
Changed HKLM\SOFTWARE\HTC\CommManager\TextColorSetting = FF FF FF 00 FF FF FF 00 FF FF FF 00 FF FF FF 00 FF FF FF 00 FF FF FF 00 FF FF FF 00
Changing the top bar font to match m2d font also would be good but i cant find where to change it.
*don't know what solved the text color problem cause as first registry edit didn't work*
*i changed start icon then wanted to turn it back so deleted shellres.96.*
*then copied other icons and after one of the resets the comm manager colors changed - strange but i like the result
Here are the files, just extract to \Windows
Click to expand...
Click to collapse
Please can you reupload your preview images?, thanks in advance
images would be beneficial
Please some images.
good work but I would suggest making a cab with the registry changes as well or at least upload a modded reg key to your 1st post
EDIT:
Here is a modded reg key. Just extract it onto your device and import using your fav registery editor
I edited the reg key with the new color value but it's still black... I've soft reset twice now. Any ideas?
WOW... great work. thx for share
w0rdie said:
I edited the reg key with the new color value but it's still black... I've soft reset twice now. Any ideas?
Click to expand...
Click to collapse
1st you need to read the inital post completely...2nd see my post above yours for a painless fix
I imported that key and still... it's black.
w0rdie said:
I imported that key and still... it's black.
Click to expand...
Click to collapse
do a softreset, if you still cannot get it to go...edit the key manually as stated in the 1st post
ljinsane said:
do a softreset, if you still cannot get it to go...edit the key manually as stated in the 1st post
Click to expand...
Click to collapse
Not sure I'm being clear. I've done the manual edit... and I've imported your regkey... still, black text.
w0rdie said:
Not sure I'm being clear. I've done the manual edit... and I've imported your regkey... still, black text.
Click to expand...
Click to collapse
Same here.
sorry nevermind
yes I just copy them to the windows folder
מגניב ביותר.
very cool. i'll be using it.
which of the 6 button comm managers is this for?

Change Hilight Color From green to gray

HKLM/Software/HTC/Phone/highlightcolor - 11250603
HKCU/software/microsoft/today/HTC Black.tsk/Color_Highlight - 99 99 99 00
HKLM/software/microsoft/color/33 - 99 99 99 00
HKLM/software/microsoft/color/34 - 99 99 99 00
Change this registry keys as above.
Enjoy.
ps. this not change the Manila Highlight color of course.

How to enter EDL mode on Nokia 8

My nokia 8 is bricked again. It stuck in fastboot mode but cant flash with OST LA or NOST via normal download. they have a error code: 0xc6d7 and adb cmd write failed. How to enter EDL mode?
My Nokia 8(NB1 TA1004) is hard bricked. No screen, fastboot or adb mode is available. My PC only detects it via 9008 port. I tried to flash via QFIL after days of trying. I finally flashed but, it didn't reboot. The flashing process was very short (less than 30 secs). So, I assume that wasn't completed properly. Below is the log. Could anyone advise what went wrong? Also it would be great if you could send links to good stock roms for QFIL.
18:46:05: INFO: FH_LOADER WAS CALLED EXACTLY LIKE THIS
************************************************
C:\Program Files (x86)\Qualcomm\QPST\bin\fh_loader.exe --port=\\.\COM4 --reset --noprompt --showpercentagecomplete --zlpawarehost=1 --memoryname=ufs
************************************************
18:46:05: DEBUG: Binary build date: Jun 25 2019 @ 03:16:10
18:46:05: DEBUG: Build Version: 19.06.25.03.16.10
18:46:05: INFO: Current working dir (cwd): C:\Users\jongp\AppData\Roaming\Qualcomm\QFIL\COMPORT_4\
18:46:05: INFO: Showing network mappings to allow debugging
18:46:05: DEBUG: User set ZLPAWAREHOST to 1
18:46:05: INFO: User wants to talk to port '\\.\COM4'
18:46:05: DEBUG: port_fd=0x110
18:46:05: INFO: Took 0.00000000 seconds to open port
18:46:05: INFO: Sorting TAGS to ensure order is <configure>,<erase>, others, <patch>,<power>
18:46:05: INFO: Sending <configure>
18:46:05: DEBUG: CHANNEL DATA (P0000) (H00202) ( 227 bytes) - HOST TO TARGET -->
===========================================================================================================
<?xml version="1.0" encoding="UTF-8" ?>
<data>
<configure MemoryName="ufs" Verbose="0" AlwaysValidate="0" MaxDigestTableSizeInBytes="8192" MaxPayloadSizeToTargetInBytes="1048576" ZlpAwareHost="1" SkipStorageInit="0" />
</data>
============================================================================================================
18:46:05: DEBUG: CharsInBuffer=0 Trying to read from USB 8192 bytes
18:46:05: DEBUG: CHANNEL DATA (471 bytes) <-- TARGET to HOST
18:46:05: DEBUG: CharsInBuffer = 471
18:46:05: DEBUG: printBuffer:6017 PRETTYPRINT Buffer is 471 bytes
18:46:05: DEBUG: printBuffer:6094 3C 3F 78 6D 6C 20 76 65 72 73 69 6F 6E 3D 22 31 <?xml version="1
18:46:05: DEBUG: printBuffer:6094 2E 30 22 20 65 6E 63 6F 64 69 6E 67 3D 22 55 54 .0" encoding="UT
18:46:05: DEBUG: printBuffer:6094 46 2D 38 22 20 3F 3E 0A 3C 64 61 74 61 3E 0A 3C F-8" ?>.<data>.<
18:46:05: DEBUG: printBuffer:6094 6C 6F 67 20 76 61 6C 75 65 3D 22 43 61 6C 6C 69 log value="Calli
18:46:05: DEBUG: printBuffer:6094 6E 67 20 75 73 62 5F 61 6C 5F 62 75 6C 6B 5F 73 ng usb_al_bulk_s
18:46:05: DEBUG: printBuffer:6094 65 74 5F 7A 6C 70 5F 6D 6F 64 65 28 54 52 55 45 et_zlp_mode(TRUE
18:46:05: DEBUG: printBuffer:6094 29 20 73 69 6E 63 65 20 5A 6C 70 41 77 61 72 65 ) since ZlpAware
18:46:05: DEBUG: printBuffer:6094 48 6F 73 74 3D 27 31 27 22 2F 3E 0A 3C 2F 64 61 Host='1'"/>.</da
18:46:05: DEBUG: printBuffer:6094 74 61 3E 3C 3F 78 6D 6C 20 76 65 72 73 69 6F 6E ta><?xml version
18:46:05: DEBUG: printBuffer:6094 3D 22 31 2E 30 22 20 65 6E 63 6F 64 69 6E 67 3D ="1.0" encoding=
18:46:05: DEBUG: printBuffer:6094 22 55 54 46 2D 38 22 20 3F 3E 0A 3C 64 61 74 61 "UTF-8" ?>.<data
18:46:05: DEBUG: printBuffer:6094 3E 0A 3C 72 65 73 70 6F 6E 73 65 20 76 61 6C 75 >.<response valu
18:46:05: DEBUG: printBuffer:6094 65 3D 22 41 43 4B 22 20 4D 69 6E 56 65 72 73 69 e="ACK" MinVersi
18:46:05: DEBUG: printBuffer:6094 6F 6E 53 75 70 70 6F 72 74 65 64 3D 22 31 22 20 onSupported="1"
18:46:05: DEBUG: printBuffer:6094 4D 65 6D 6F 72 79 4E 61 6D 65 3D 22 55 46 53 22 MemoryName="UFS"
18:46:05: DEBUG: printBuffer:6094 20 4D 61 78 50 61 79 6C 6F 61 64 53 69 7A 65 46 MaxPayloadSizeF
18:46:05: DEBUG: printBuffer:6094 72 6F 6D 54 61 72 67 65 74 49 6E 42 79 74 65 73 romTargetInBytes
18:46:05: DEBUG: printBuffer:6094 3D 22 34 30 39 36 22 20 4D 61 78 50 61 79 6C 6F ="4096" MaxPaylo
18:46:05: DEBUG: printBuffer:6094 61 64 53 69 7A 65 54 6F 54 61 72 67 65 74 49 6E adSizeToTargetIn
18:46:05: DEBUG: printBuffer:6094 42 79 74 65 73 3D 22 31 30 34 38 35 37 36 22 20 Bytes="1048576"
18:46:05: DEBUG: printBuffer:6094 4D 61 78 50 61 79 6C 6F 61 64 53 69 7A 65 54 6F MaxPayloadSizeTo
18:46:05: DEBUG: printBuffer:6094 54 61 72 67 65 74 49 6E 42 79 74 65 73 53 75 70 TargetInBytesSup
18:46:05: DEBUG: printBuffer:6094 70 6F 72 74 65 64 3D 22 31 30 34 38 35 37 36 22 ported="1048576"
18:46:05: DEBUG: printBuffer:6094 20 4D 61 78 58 4D 4C 53 69 7A 65 49 6E 42 79 74 MaxXMLSizeInByt
18:46:05: DEBUG: printBuffer:6094 65 73 3D 22 34 30 39 36 22 20 56 65 72 73 69 6F es="4096" Versio
18:46:05: DEBUG: printBuffer:6094 6E 3D 22 31 22 20 54 61 72 67 65 74 4E 61 6D 65 n="1" TargetName
18:46:05: DEBUG: printBuffer:6094 3D 22 4D 53 4D 38 39 39 36 22 20 44 61 74 65 54 ="MSM8996" DateT
18:46:05: DEBUG: printBuffer:6094 69 6D 65 3D 22 53 65 70 20 32 30 20 32 30 31 37 ime="Sep 20 2017
18:46:05: DEBUG: printBuffer:6094 20 2D 20 32 30 3A 31 38 3A 34 30 22 20 2F 3E 0A - 20:18:40" />.
18:46:05: DEBUG: printBuffer:6094 3C 2F 64 61 74 61 3E </data>
18:46:05: DEBUG: printBuffer:6107
18:46:05: DEBUG: XML FILE (131 bytes): CharsInBuffer=471-131=340
-------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" ?>
<data>
<log value="Calling usb_al_bulk_set_zlp_mode(TRUE) since ZlpAwareHost='1'"/>
</data>
-------------------------------------------------------------------------------------------
18:46:05: INFO: TARGET SAID: 'Calling usb_al_bulk_set_zlp_mode(TRUE) since ZlpAwareHost='1''
18:46:05: DEBUG: XML FILE (340 bytes): CharsInBuffer=340-340=0
-------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" ?>
<data>
<response value="ACK" MinVersionSupported="1" MemoryName="UFS" MaxPayloadSizeFromTargetInBytes="4096" MaxPayloadSizeToTargetInBytes="1048576" MaxPayloadSizeToTargetInBytesSupported="1048576" MaxXMLSizeInBytes="4096" Version="1" TargetName="MSM8996" DateTime="Sep 20 2017 - 20:18:40" />
</data>
-------------------------------------------------------------------------------------------
18:46:05: DEBUG: Response was 'ACK'
18:46:05: INFO: fh.attrs.MaxPayloadSizeToTargetInBytes = 1048576
18:46:05: INFO: fh.attrs.MaxPayloadSizeToTargetInBytesSupported = 1048576
18:46:05: DEBUG: Got the ACK for the <configure>
18:46:05: INFO: Sending <power>
18:46:05: DEBUG: CHANNEL DATA (P0001) (H00203) ( 99 bytes) - HOST TO TARGET -->
===========================================================================================================
<?xml version="1.0" encoding="UTF-8" ?>
<data>
<power DelayInSeconds="10" value="reset" />
</data>
============================================================================================================
18:46:05: DEBUG: CharsInBuffer=0 Trying to read from USB 4096 bytes
18:46:05: DEBUG: CHANNEL DATA (352 bytes) <-- TARGET to HOST
18:46:05: DEBUG: CharsInBuffer = 352
18:46:05: DEBUG: printBuffer:6017 PRETTYPRINT Buffer is 352 bytes
18:46:05: DEBUG: printBuffer:6094 3C 3F 78 6D 6C 20 76 65 72 73 69 6F 6E 3D 22 31 <?xml version="1
18:46:05: DEBUG: printBuffer:6094 2E 30 22 20 65 6E 63 6F 64 69 6E 67 3D 22 55 54 .0" encoding="UT
18:46:05: DEBUG: printBuffer:6094 46 2D 38 22 20 3F 3E 0A 3C 64 61 74 61 3E 0A 3C F-8" ?>.<data>.<
18:46:05: DEBUG: printBuffer:6094 6C 6F 67 20 76 61 6C 75 65 3D 22 49 6E 73 69 64 log value="Insid
18:46:05: DEBUG: printBuffer:6094 65 20 68 61 6E 64 6C 65 50 6F 77 65 72 28 29 20 e handlePower()
18:46:05: DEBUG: printBuffer:6094 2D 20 52 65 71 75 65 73 74 65 64 20 50 4F 57 45 - Requested POWE
18:46:05: DEBUG: printBuffer:6094 52 5F 52 45 53 45 54 22 2F 3E 0A 3C 2F 64 61 74 R_RESET"/>.</dat
18:46:05: DEBUG: printBuffer:6094 61 3E 3C 3F 78 6D 6C 20 76 65 72 73 69 6F 6E 3D a><?xml version=
18:46:05: DEBUG: printBuffer:6094 22 31 2E 30 22 20 65 6E 63 6F 64 69 6E 67 3D 22 "1.0" encoding="
18:46:05: DEBUG: printBuffer:6094 55 54 46 2D 38 22 20 3F 3E 0A 3C 64 61 74 61 3E UTF-8" ?>.<data>
18:46:05: DEBUG: printBuffer:6094 0A 3C 6C 6F 67 20 76 61 6C 75 65 3D 22 49 73 73 .<log value="Iss
18:46:05: DEBUG: printBuffer:6094 75 69 6E 67 20 62 73 70 5F 74 61 72 67 65 74 5F uing bsp_target_
18:46:05: DEBUG: printBuffer:6094 72 65 73 65 74 28 29 20 61 66 74 65 72 20 31 30 reset() after 10
18:46:05: DEBUG: printBuffer:6094 20 73 65 63 6F 6E 64 73 2C 20 69 66 20 74 68 69 seconds, if thi
18:46:05: DEBUG: printBuffer:6094 73 20 68 61 6E 67 73 2C 20 64 6F 20 79 6F 75 20 s hangs, do you
18:46:05: DEBUG: printBuffer:6094 68 61 76 65 20 57 41 54 43 48 44 4F 47 20 65 6E have WATCHDOG en
18:46:05: DEBUG: printBuffer:6094 61 62 6C 65 64 3F 22 2F 3E 0A 3C 2F 64 61 74 61 abled?"/>.</data
18:46:05: DEBUG: printBuffer:6094 3E 3C 3F 78 6D 6C 20 76 65 72 73 69 6F 6E 3D 22 ><?xml version="
18:46:05: DEBUG: printBuffer:6094 31 2E 30 22 20 65 6E 63 6F 64 69 6E 67 3D 22 55 1.0" encoding="U
18:46:05: DEBUG: printBuffer:6094 54 46 2D 38 22 20 3F 3E 0A 3C 64 61 74 61 3E 0A TF-8" ?>.<data>.
18:46:05: DEBUG: printBuffer:6094 3C 72 65 73 70 6F 6E 73 65 20 76 61 6C 75 65 3D <response value=
18:46:05: DEBUG: printBuffer:6094 22 41 43 4B 22 20 2F 3E 0A 3C 2F 64 61 74 61 3E "ACK" />.</data>
18:46:05: DEBUG: printBuffer:6107
18:46:05: DEBUG: XML FILE (114 bytes): CharsInBuffer=352-114=238
-------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" ?>
<data>
<log value="Inside handlePower() - Requested POWER_RESET"/>
</data>
-------------------------------------------------------------------------------------------
18:46:05: INFO: TARGET SAID: 'Inside handlePower() - Requested POWER_RESET'
18:46:05: DEBUG: XML FILE (159 bytes): CharsInBuffer=238-159=79
-------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" ?>
<data>
<log value="Issuing bsp_target_reset() after 10 seconds, if this hangs, do you have WATCHDOG enabled?"/>
</data>
-------------------------------------------------------------------------------------------
18:46:05: INFO: TARGET SAID: 'Issuing bsp_target_reset() after 10 seconds, if this hangs, do you have WATCHDOG enabled?'
18:46:05: DEBUG: XML FILE (79 bytes): CharsInBuffer=79-79=0
-------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" ?>
<data>
<response value="ACK" />
</data>
-------------------------------------------------------------------------------------------
18:46:05: DEBUG: Response was 'ACK'
18:46:05: DEBUG: Got the ACK
18:46:05: INFO: ==============================================================
18:46:05: INFO: Files used and their paths
18:46:05: INFO: 1 'C:\Users\jongp\AppData\Roaming\Qualcomm\QFIL\COMPORT_4\port_trace.txt'
18:46:05: INFO: _ (done)
18:46:05: INFO: | |
18:46:05: INFO: __| | ___ _ __ ___
18:46:05: INFO: / _` |/ _ \| '_ \ / _ \
18:46:05: INFO: | (_| | (_) | | | | __/
18:46:05: INFO: \__,_|\___/|_| |_|\___|
18:46:05: INFO: {All Finished Successfully}
18:46:05: INFO: Overall to target 0.063 seconds (0.00 Bps)

Nokia 8 - Hard Bricked, flashing in EDL mode

Hi guys,
My Nokia 8(NB1 TA1004) is hard bricked. No screen, fastboot or adb mode is available. My PC only detects it via 9008 port. I tried to flash via QFIL after days of trying. I finally flashed but, it didn't reboot. The flashing process was very short (less than 30 secs). So, I assume that wasn't completed properly. Below is the log. Could anyone advise what went wrong? Also it would be great if you could send links to good stock roms for QFIL.
18:46:05: INFO: FH_LOADER WAS CALLED EXACTLY LIKE THIS
************************************************
C:\Program Files (x86)\Qualcomm\QPST\bin\fh_loader.exe --port=\\.\COM4 --reset --noprompt --showpercentagecomplete --zlpawarehost=1 --memoryname=ufs
************************************************
18:46:05: DEBUG: Binary build date: Jun 25 2019 @ 03:16:10
18:46:05: DEBUG: Build Version: 19.06.25.03.16.10
18:46:05: INFO: Current working dir (cwd): C:\Users\jongp\AppData\Roaming\Qualcomm\QFIL\COMPORT_4\
18:46:05: INFO: Showing network mappings to allow debugging
18:46:05: DEBUG: User set ZLPAWAREHOST to 1
18:46:05: INFO: User wants to talk to port '\\.\COM4'
18:46:05: DEBUG: port_fd=0x110
18:46:05: INFO: Took 0.00000000 seconds to open port
18:46:05: INFO: Sorting TAGS to ensure order is <configure>,<erase>, others, <patch>,<power>
18:46:05: INFO: Sending <configure>
18:46:05: DEBUG: CHANNEL DATA (P0000) (H00202) ( 227 bytes) - HOST TO TARGET -->
===========================================================================================================
<?xml version="1.0" encoding="UTF-8" ?>
<data>
<configure MemoryName="ufs" Verbose="0" AlwaysValidate="0" MaxDigestTableSizeInBytes="8192" MaxPayloadSizeToTargetInBytes="1048576" ZlpAwareHost="1" SkipStorageInit="0" />
</data>
============================================================================================================
18:46:05: DEBUG: CharsInBuffer=0 Trying to read from USB 8192 bytes
18:46:05: DEBUG: CHANNEL DATA (471 bytes) <-- TARGET to HOST
18:46:05: DEBUG: CharsInBuffer = 471
18:46:05: DEBUG: printBuffer:6017 PRETTYPRINT Buffer is 471 bytes
18:46:05: DEBUG: printBuffer:6094 3C 3F 78 6D 6C 20 76 65 72 73 69 6F 6E 3D 22 31 <?xml version="1
18:46:05: DEBUG: printBuffer:6094 2E 30 22 20 65 6E 63 6F 64 69 6E 67 3D 22 55 54 .0" encoding="UT
18:46:05: DEBUG: printBuffer:6094 46 2D 38 22 20 3F 3E 0A 3C 64 61 74 61 3E 0A 3C F-8" ?>.<data>.<
18:46:05: DEBUG: printBuffer:6094 6C 6F 67 20 76 61 6C 75 65 3D 22 43 61 6C 6C 69 log value="Calli
18:46:05: DEBUG: printBuffer:6094 6E 67 20 75 73 62 5F 61 6C 5F 62 75 6C 6B 5F 73 ng usb_al_bulk_s
18:46:05: DEBUG: printBuffer:6094 65 74 5F 7A 6C 70 5F 6D 6F 64 65 28 54 52 55 45 et_zlp_mode(TRUE
18:46:05: DEBUG: printBuffer:6094 29 20 73 69 6E 63 65 20 5A 6C 70 41 77 61 72 65 ) since ZlpAware
18:46:05: DEBUG: printBuffer:6094 48 6F 73 74 3D 27 31 27 22 2F 3E 0A 3C 2F 64 61 Host='1'"/>.</da
18:46:05: DEBUG: printBuffer:6094 74 61 3E 3C 3F 78 6D 6C 20 76 65 72 73 69 6F 6E ta><?xml version
18:46:05: DEBUG: printBuffer:6094 3D 22 31 2E 30 22 20 65 6E 63 6F 64 69 6E 67 3D ="1.0" encoding=
18:46:05: DEBUG: printBuffer:6094 22 55 54 46 2D 38 22 20 3F 3E 0A 3C 64 61 74 61 "UTF-8" ?>.<data
18:46:05: DEBUG: printBuffer:6094 3E 0A 3C 72 65 73 70 6F 6E 73 65 20 76 61 6C 75 >.<response valu
18:46:05: DEBUG: printBuffer:6094 65 3D 22 41 43 4B 22 20 4D 69 6E 56 65 72 73 69 e="ACK" MinVersi
18:46:05: DEBUG: printBuffer:6094 6F 6E 53 75 70 70 6F 72 74 65 64 3D 22 31 22 20 onSupported="1"
18:46:05: DEBUG: printBuffer:6094 4D 65 6D 6F 72 79 4E 61 6D 65 3D 22 55 46 53 22 MemoryName="UFS"
18:46:05: DEBUG: printBuffer:6094 20 4D 61 78 50 61 79 6C 6F 61 64 53 69 7A 65 46 MaxPayloadSizeF
18:46:05: DEBUG: printBuffer:6094 72 6F 6D 54 61 72 67 65 74 49 6E 42 79 74 65 73 romTargetInBytes
18:46:05: DEBUG: printBuffer:6094 3D 22 34 30 39 36 22 20 4D 61 78 50 61 79 6C 6F ="4096" MaxPaylo
18:46:05: DEBUG: printBuffer:6094 61 64 53 69 7A 65 54 6F 54 61 72 67 65 74 49 6E adSizeToTargetIn
18:46:05: DEBUG: printBuffer:6094 42 79 74 65 73 3D 22 31 30 34 38 35 37 36 22 20 Bytes="1048576"
18:46:05: DEBUG: printBuffer:6094 4D 61 78 50 61 79 6C 6F 61 64 53 69 7A 65 54 6F MaxPayloadSizeTo
18:46:05: DEBUG: printBuffer:6094 54 61 72 67 65 74 49 6E 42 79 74 65 73 53 75 70 TargetInBytesSup
18:46:05: DEBUG: printBuffer:6094 70 6F 72 74 65 64 3D 22 31 30 34 38 35 37 36 22 ported="1048576"
18:46:05: DEBUG: printBuffer:6094 20 4D 61 78 58 4D 4C 53 69 7A 65 49 6E 42 79 74 MaxXMLSizeInByt
18:46:05: DEBUG: printBuffer:6094 65 73 3D 22 34 30 39 36 22 20 56 65 72 73 69 6F es="4096" Versio
18:46:05: DEBUG: printBuffer:6094 6E 3D 22 31 22 20 54 61 72 67 65 74 4E 61 6D 65 n="1" TargetName
18:46:05: DEBUG: printBuffer:6094 3D 22 4D 53 4D 38 39 39 36 22 20 44 61 74 65 54 ="MSM8996" DateT
18:46:05: DEBUG: printBuffer:6094 69 6D 65 3D 22 53 65 70 20 32 30 20 32 30 31 37 ime="Sep 20 2017
18:46:05: DEBUG: printBuffer:6094 20 2D 20 32 30 3A 31 38 3A 34 30 22 20 2F 3E 0A - 20:18:40" />.
18:46:05: DEBUG: printBuffer:6094 3C 2F 64 61 74 61 3E </data>
18:46:05: DEBUG: printBuffer:6107
18:46:05: DEBUG: XML FILE (131 bytes): CharsInBuffer=471-131=340
-------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" ?>
<data>
<log value="Calling usb_al_bulk_set_zlp_mode(TRUE) since ZlpAwareHost='1'"/>
</data>
-------------------------------------------------------------------------------------------
18:46:05: INFO: TARGET SAID: 'Calling usb_al_bulk_set_zlp_mode(TRUE) since ZlpAwareHost='1''
18:46:05: DEBUG: XML FILE (340 bytes): CharsInBuffer=340-340=0
-------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" ?>
<data>
<response value="ACK" MinVersionSupported="1" MemoryName="UFS" MaxPayloadSizeFromTargetInBytes="4096" MaxPayloadSizeToTargetInBytes="1048576" MaxPayloadSizeToTargetInBytesSupported="1048576" MaxXMLSizeInBytes="4096" Version="1" TargetName="MSM8996" DateTime="Sep 20 2017 - 20:18:40" />
</data>
-------------------------------------------------------------------------------------------
18:46:05: DEBUG: Response was 'ACK'
18:46:05: INFO: fh.attrs.MaxPayloadSizeToTargetInBytes = 1048576
18:46:05: INFO: fh.attrs.MaxPayloadSizeToTargetInBytesSupported = 1048576
18:46:05: DEBUG: Got the ACK for the <configure>
18:46:05: INFO: Sending <power>
18:46:05: DEBUG: CHANNEL DATA (P0001) (H00203) ( 99 bytes) - HOST TO TARGET -->
===========================================================================================================
<?xml version="1.0" encoding="UTF-8" ?>
<data>
<power DelayInSeconds="10" value="reset" />
</data>
============================================================================================================
18:46:05: DEBUG: CharsInBuffer=0 Trying to read from USB 4096 bytes
18:46:05: DEBUG: CHANNEL DATA (352 bytes) <-- TARGET to HOST
18:46:05: DEBUG: CharsInBuffer = 352
18:46:05: DEBUG: printBuffer:6017 PRETTYPRINT Buffer is 352 bytes
18:46:05: DEBUG: printBuffer:6094 3C 3F 78 6D 6C 20 76 65 72 73 69 6F 6E 3D 22 31 <?xml version="1
18:46:05: DEBUG: printBuffer:6094 2E 30 22 20 65 6E 63 6F 64 69 6E 67 3D 22 55 54 .0" encoding="UT
18:46:05: DEBUG: printBuffer:6094 46 2D 38 22 20 3F 3E 0A 3C 64 61 74 61 3E 0A 3C F-8" ?>.<data>.<
18:46:05: DEBUG: printBuffer:6094 6C 6F 67 20 76 61 6C 75 65 3D 22 49 6E 73 69 64 log value="Insid
18:46:05: DEBUG: printBuffer:6094 65 20 68 61 6E 64 6C 65 50 6F 77 65 72 28 29 20 e handlePower()
18:46:05: DEBUG: printBuffer:6094 2D 20 52 65 71 75 65 73 74 65 64 20 50 4F 57 45 - Requested POWE
18:46:05: DEBUG: printBuffer:6094 52 5F 52 45 53 45 54 22 2F 3E 0A 3C 2F 64 61 74 R_RESET"/>.</dat
18:46:05: DEBUG: printBuffer:6094 61 3E 3C 3F 78 6D 6C 20 76 65 72 73 69 6F 6E 3D a><?xml version=
18:46:05: DEBUG: printBuffer:6094 22 31 2E 30 22 20 65 6E 63 6F 64 69 6E 67 3D 22 "1.0" encoding="
18:46:05: DEBUG: printBuffer:6094 55 54 46 2D 38 22 20 3F 3E 0A 3C 64 61 74 61 3E UTF-8" ?>.<data>
18:46:05: DEBUG: printBuffer:6094 0A 3C 6C 6F 67 20 76 61 6C 75 65 3D 22 49 73 73 .<log value="Iss
18:46:05: DEBUG: printBuffer:6094 75 69 6E 67 20 62 73 70 5F 74 61 72 67 65 74 5F uing bsp_target_
18:46:05: DEBUG: printBuffer:6094 72 65 73 65 74 28 29 20 61 66 74 65 72 20 31 30 reset() after 10
18:46:05: DEBUG: printBuffer:6094 20 73 65 63 6F 6E 64 73 2C 20 69 66 20 74 68 69 seconds, if thi
18:46:05: DEBUG: printBuffer:6094 73 20 68 61 6E 67 73 2C 20 64 6F 20 79 6F 75 20 s hangs, do you
18:46:05: DEBUG: printBuffer:6094 68 61 76 65 20 57 41 54 43 48 44 4F 47 20 65 6E have WATCHDOG en
18:46:05: DEBUG: printBuffer:6094 61 62 6C 65 64 3F 22 2F 3E 0A 3C 2F 64 61 74 61 abled?"/>.</data
18:46:05: DEBUG: printBuffer:6094 3E 3C 3F 78 6D 6C 20 76 65 72 73 69 6F 6E 3D 22 ><?xml version="
18:46:05: DEBUG: printBuffer:6094 31 2E 30 22 20 65 6E 63 6F 64 69 6E 67 3D 22 55 1.0" encoding="U
18:46:05: DEBUG: printBuffer:6094 54 46 2D 38 22 20 3F 3E 0A 3C 64 61 74 61 3E 0A TF-8" ?>.<data>.
18:46:05: DEBUG: printBuffer:6094 3C 72 65 73 70 6F 6E 73 65 20 76 61 6C 75 65 3D <response value=
18:46:05: DEBUG: printBuffer:6094 22 41 43 4B 22 20 2F 3E 0A 3C 2F 64 61 74 61 3E "ACK" />.</data>
18:46:05: DEBUG: printBuffer:6107
18:46:05: DEBUG: XML FILE (114 bytes): CharsInBuffer=352-114=238
-------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" ?>
<data>
<log value="Inside handlePower() - Requested POWER_RESET"/>
</data>
-------------------------------------------------------------------------------------------
18:46:05: INFO: TARGET SAID: 'Inside handlePower() - Requested POWER_RESET'
18:46:05: DEBUG: XML FILE (159 bytes): CharsInBuffer=238-159=79
-------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" ?>
<data>
<log value="Issuing bsp_target_reset() after 10 seconds, if this hangs, do you have WATCHDOG enabled?"/>
</data>
-------------------------------------------------------------------------------------------
18:46:05: INFO: TARGET SAID: 'Issuing bsp_target_reset() after 10 seconds, if this hangs, do you have WATCHDOG enabled?'
18:46:05: DEBUG: XML FILE (79 bytes): CharsInBuffer=79-79=0
-------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8" ?>
<data>
Many thanks,
Pil
<response value="ACK" />
</data>
-------------------------------------------------------------------------------------------
18:46:05: DEBUG: Response was 'ACK'
18:46:05: DEBUG: Got the ACK
18:46:05: INFO: ==============================================================
18:46:05: INFO: Files used and their paths
18:46:05: INFO: 1 'C:\Users\jongp\AppData\Roaming\Qualcomm\QFIL\COMPORT_4\port_trace.txt'
18:46:05: INFO: _ (done)
18:46:05: INFO: | |
18:46:05: INFO: __| | ___ _ __ ___
18:46:05: INFO: / _` |/ _ \| '_ \ / _ \
18:46:05: INFO: | (_| | (_) | | | | __/
18:46:05: INFO: \__,_|\___/|_| |_|\___|
18:46:05: INFO: {All Finished Successfully}
18:46:05: INFO: Overall to target 0.063 seconds (0.00 Bps)
Tear down the screen, remove the battery cable and then connect it again. Also connect the cable to the PC. Remember to install Qualcomm USB drivers.
Download 435J nb0 package and then flash it via NOST. That worked for me.
435J package:
NB1-435J-0-00WW-B01-OREO.zip | by Hikari Calyx for Nokia 8
Download GApps, Roms, Kernels, Themes, Firmware, and more. Free file hosting for all Android developers.
androidfilehost.com
NOST link:
Release NOST v0.6 · StollD/NOST
Fixed NOST running under user accounts with spaces in their name Fixed detection of .QLZ (i.e. uppercase) files. Removed the automated install of the USB Driver since it managed to crash the instal...
github.com

Manually adjust brightness to maximum/peak brightness without being in sunlight?

(Please delete my previous similar thread)
Most modern phones won't reach peak brightness unless they are in direct sunlight (by the light sensor). The slider at maximum brightness isn't really the phone's peak brightness. The slider is "capped" unless one modifies it somehow (the idea is to protect one's eyes, save battery life etc...).
For example, on gsmarena the specs for the S23's display are: "1200 nits (HBM), 1750 nits (peak)".
So, the slider only brings the phone's display to 1200 nits, while the display's full capacity is actually 1750 nits.
I don't want "daddy Samsung" to decide when my phone can reach maximum brightness or not [even if it is to protect my eyes or save battery etc..].
So, how do I enable my phone [in any way necessary] so that I can manually adjust it to maximum/peak brightness via the slider, without being in sunlight
You can just manually play with the settings:
Code:
$ settings list system|grep bright
screen_auto_brightness_adj=0.0
screen_brightness=22
screen_brightness_float=0.08333588
screen_brightness_for_vr=86
screen_brightness_mode=0
$ settings put system screen_brightness 100
Many LCD screens (and eInk screens) use the venerable TI LM3630A chip as LED driver.
Just find under /sys/devices/platform/<somewhere I²C>
I just looked and my Moto G is using a AW99703 instead.
Renate said:
You can just manually play with the settings:
Code:
$ settings list system|grep bright
screen_auto_brightness_adj=0.0
screen_brightness=22
screen_brightness_float=0.08333588
screen_brightness_for_vr=86
screen_brightness_mode=0
$ settings put system screen_brightness 100
Many LCD screens (and eInk screens) use the venerable TI LM3630A chip as LED driver.
Just find under /sys/devices/platform/<somewhere I²C>
I just looked and my Moto G is using a AW99703 instead.
Click to expand...
Click to collapse
Oh, interesting! But I'm in a bit over my head here...
Should I start by looking for a file named "TI LM3630A" somewhere within /sys/devices/platform/ ?
white-k said:
Should I start by looking for a file named "TI LM3630A" somewhere within /sys/devices/platform/ ?
Click to expand...
Click to collapse
It's not that complicated:
You can manually set the brightness with similar settings command (note: brightness could go to 100 or 255 or anything).
You could write a tiny app that just used the Android Java Settings.
Of course you'd have to have <uses-permission android:name="android.permission.WRITE_SETTINGS"/> in your AndroidManifest.xml
You could interact with the Linux driver. You have to enumerate:
Code:
# cd /sys/class/backlight/
# ls -l
lrwxrwxrwx 1 root root 0 1971-12-21 10:12 warm -> ../../devices/soc/c1b6000.i2c/i2c-6/6-0038/backlight/warm
lrwxrwxrwx 1 root root 0 1971-12-21 10:12 white -> ../../devices/soc/c1b6000.i2c/i2c-6/6-0038/backlight/white
# cd warm
# ls -l
-r--r--r-- 1 root root 4096 2023-06-17 09:04 actual_brightness
-rw-r--r-- 1 root root 4096 2023-06-17 09:04 bl_power
-rw-rw-rw- 1 root root 4096 2023-06-17 09:03 brightness
lrwxrwxrwx 1 root root 0 2023-06-17 09:04 device -> ../../../6-0038
-r--r--r-- 1 root root 4096 2023-06-17 09:04 max_brightness
drwxr-xr-x 2 root root 0 2023-06-17 09:04 power
lrwxrwxrwx 1 root root 0 2023-06-17 09:04 subsystem -> ../../../../../../../class/backlight
-r--r--r-- 1 root root 4096 2023-06-17 09:04 type
-rw-r--r-- 1 root root 4096 2023-06-17 09:04 uevent
If you alter this unilaterally you'll have to come up with some way to reconcile it with the settings.
You could interact directly over I²C to the chip itself, but you have to read the datasheet and know what all the numbers mean.
Code:
# ./lights
warm i2c-6 38
00 Control 06
01 Configuration 18
02 Boost Control 58
03 Brightness A 2f
04 Brightness B 6f
05 Current A 0a
06 Current B 0a
07 On/Off Ramp 0a
08 Run Ramp 0a
09 Interrupt Status 02
0a Interrupt Enable 00
0b Fault Status 00
0f Software Reset 00
12 PWM Out Low 00
13 PWM Out High 00
1f Revision 02
50 Filter Strength 00
white i2c-6 38
And you could fry stuff by writing the wrong numbers.
I did all this stuff for an app for my eInk device that uses two color temperatures of backlight. The stock controls were crap.
So I wrote my own that just used /sys/class/backlight/...
Oh, it could be that some limit is set in the DTB itself:
Code:
029260 [email protected] {
029270 compatible = "onyx,lm3630a";
02928c reg = < 0x38 >;
02929c status = "okay";
0292b0 lm3630-vdd-supply = < 0x18b >;
0292c0 lm3630,en_gpio = < 0xa1 0x4c 0x0 >;
0292d8 lm3630,bank_sel = < 0x6 >;
0292e8 lm3630,bank_swap = < 0x0 >;
0292f8 lm3630,linear_output = < 0x0 >;
029308 lm3630,max_current = < 0xa >;
029318 lm3630,default_brightness = < 0x0 >;
029328 lm3630,max_brightness = < 0xff >;
029338 lm3630,pwm_enable = < 0x0 >;
029348 }
Renate said:
It's not that complicated:
You can manually set the brightness with similar settings command (note: brightness could go to 100 or 255 or anything).
You could write a tiny app that just used the Android Java Settings.
Of course you'd have to have <uses-permission android:name="android.permission.WRITE_SETTINGS"/> in your AndroidManifest.xml
Click to expand...
Click to collapse
Wow, this is way beyond my comfort level. I'll ask my programmer friend if he can help me based on what you have written
Much appreciated!

Categories

Resources