[Kernel][26/04][N7100 N7105 N7108 R950] Perseus

Status
Not open for further replies.
Search This thread

qwertyedu

Senior Member
Nov 5, 2010
59
5
LG G8X ThinQ
Realme X2 Pro
Up this, i would like to know too and i can't seem to get it right
Thanks for supporting me :) Anyone got any idea ???

---------- Post added at 12:24 AM ---------- Previous post was at 12:19 AM ----------

About the issues with Pegasus Prime SOC in Note 2 (gpu glitching/arctifacts/Apps FC's)

After a few days of testing i confirm that the solution adviced by AndreiLux itself works great.
If you experience FC's in graphic intensive apps, or a common glitch which corrupts the screen in a "checkboard" style image, all you need to do is to raise gpu voltages a bit.
As AndreiLux explained, he develops the kernel with his GS3 as a base, which uses a different Exynos cpu revision (1.1). The note 2 houses a new revision (2.0) that has a different clock speed management alongside with other improvements.

Issue:
Gpu fails to up the requested clockspeed in the scaling policy because theres not enough voltage in clock speeds. Raising the clockis from the minimum speed to intermediary then to the max crashes the driver and resets the gpu state. Raising the voltages of the lower clocks fixes the issue. Clocks above 533mhz are not affected, althought ive opted to raise them a bit just to play safe.

To fix the general stability issues, open Stweaks and raise the voltages like this:

54mhz: 875mv (was 825)
108mhz: 900mv (was 850)
160mhz: 950mv (was 938)
266mhz: 975mv (was 963)
350mhz: 1050mv (was 1013)
440mhz: 1100mv (was 1075)
533mhz: 1150mv (was 1138) [optional: stock voltage is fine]
640mhz: 1150mv (was 1125) [optional: stock voltage is fine]
---- no need to be touched ---
733mhz: same as stock
800mhz: same as stock

These are fail safe voltages under any circumstances. Note that ive opted to raise at least 0.50 on voltages, but i dont exclude that a 0.25 could lead to same results. So a small undervoltage is still possible.
This issue fortunately is not widespread, only a few users are effected. If you are one of those please take my advice and see if that helps.
Also this method greatly reduces lags when opening folders or when scrolling thru pages.

AndreiLux if you can, please add this post to the OP. Ive discovered that other users suffer from this issue, you can look a few pages back.
It would be ok if you can raise the stock voltages of the gpu with a small 0.25 increment to see if the kernel keeps staying stable out of the box.

Thanks AdreiLux for this fix. If helped, spread the word. I would like to see this post in the OP as i had a very hard time figuring this out.
Anybody knows how to make the LED blink like the one in BB phones ?? The stock one in note2 is slow and feels like crap.. I tried to change the values in stweaks but in vain.. Help :)

Up this question if you wish to have the same :)
 

Pyr0x64

Senior Member
Mar 7, 2010
699
111
Merseyside
How do BB phones blink?
If you remove the tick from the fading option in STweaks and lower the fade-in and fade-out time periods you can speed up the LED blinking
 

mkanet

Senior Member
Jul 31, 2010
241
38
2 Issues with update 35: Please help...

I noticed a very specific performance issue. When I typing in landscape mode in certain resource intensive applications, there is an extreme lag/delay in landscape typing (on all keyboard apps). This lag is very noticeable for fast typists like me. I can often type a whole word before the word displays on the screen. If select "Performance" governer, this problem goes away. I am not sure if there are any drawbacks to using "Performance" governer all the time; or if there is any way to fine tune settings specifically for this problem using perseus default governer. I would really appreciate any help with this.

Also, I noticed that certain programs that need direct access to the LED for customized LED actions/notifications, behave unpredictably. Is the new LED options compatible with 3rd party applications, such as email apps that customize LED color during notications? Is there a better way to customize LED email notifications so they have a custom LED color? For example, will Perseus LED customization break 3rd party LED color managers such as: Android Light Manager
8lczXxxN0hYoZrQSVS46n-RJBgrVq1TlmkUAVeEJimznmHuT-45RrKQAB9i1JyLWfA


Thanks in advance,
MKANET
 
Last edited:
  • Like
Reactions: Chris X.

honki24

Senior Member
Oct 8, 2010
290
53
I appreciate your contribution, but I wouldn't go as far as claiming to need to post it in the OP. Voltages are based on Samsung's drivers and only a handful of people since October have reported such issues, if at all. If there is a true need for this then I will simply raise the voltages from the kernel's side and be done with it, but it seems to be a rare exception rather than a common rule. Remind yourself that Perseus and its variants has the single largest user-base around here, people would be reporting such problems more often.
Actually, I've had this problem from time to time but never thought to say anything about it. I'm very glad I came across this tip! No more pixelating NFS for me!


Sent from my SPH-L900 using xda app-developers app
 

RAISSI

Senior Member
Jun 11, 2012
83
9
Anyone having issues with the maps or with Ingress? Am on Wanam, Adam kernel works fine but Perseus causes sticky maps...

Sent from my GT-N7100
 
  • Like
Reactions: Chris X.

trpi

Senior Member
Jan 29, 2013
125
10
how much is led notification light battery hungry? i configured led to most brightest settings all the time(no mather if im in the dark room) i like it nice and blinky

i usually lose 5% overnight 8h, lets say if led notification blinked all that time how much would i lose additional %?
 

qwertyedu

Senior Member
Nov 5, 2010
59
5
LG G8X ThinQ
Realme X2 Pro
How do BB phones blink?
If you remove the tick from the fading option in STweaks and lower the fade-in and fade-out time periods you can speed up the LED blinking
Even I know that .. What I need to know is what values will go exactly.. I tried different combinations, dint work... So be more clear when you intend to give answers

---------- Post added at 03:58 PM ---------- Previous post was at 03:56 PM ----------

how much is led notification light battery hungry? i configured led to most brightest settings all the time(no mather if im in the dark room) i like it nice and blinky

i usually lose 5% overnight 8h, lets say if led notification blinked all that time how much would i lose additional %?
The value can never be given in % because the LED consumes the least power and it will not bring down the battery... You wont find an answer better than this :D
 

killflaker

Senior Member
Apr 6, 2013
57
16
Great kernel, the best for me! Thanks for your job! :good:

Just one question, can you add support for oc to 1.9ghz? It's not for dailyuse, just for fun! :)
 

ravenrocha

Senior Member
Mar 1, 2008
261
42
LED notification

Hi,

i'm very very happy that finaly perseus kernel has LED options like fading, that for me is much much nicer then the default blinking.
Unfortunately, with this last kernel, light flow, even with last version, 3.6.3, dont hand very well this new kernel. When i have for example more then one notification to be seen on LED, for exemple green for email and orange for calendar, it only shows the first one. With previous kernel everything works ok.
 

GonDr

Senior Member
Mar 21, 2011
1,111
128
Egypt, Alexandria
rasoulallah.net
Hi,

i'm very very happy that finaly perseus kernel has LED options like fading, that for me is much much nicer then the default blinking.
Unfortunately, with this last kernel, light flow, even with last version, 3.6.3, dont hand very well this new kernel. When i have for example more then one notification to be seen on LED, for exemple green for email and orange for calendar, it only shows the first one. With previous kernel everything works ok.

I have same problem in led manager and light flow and i guess its related with android logger.

Sent from my GT-N7100 using Tapatalk 2
 

trpi

Senior Member
Jan 29, 2013
125
10
under speaker volume configuration 57-63 for left/right channels, are that values in DB?
 

mkanet

Senior Member
Jul 31, 2010
241
38
I am hoping someone who knows stweaks settings very well can help me....

I looked at CPU utilization more carefully (Using Perfmon 1.1) on my Samsung Note 2 with Pegususq governer preset on Perseus version 35. For some reason only 3 CPU core are utilized at all times; even when 3 CPUs reach 1600mhz with newly full utilization. The only time I've ever seen all four CPU cores be utilized is when playing one of my 3D games. After exiting the game, I am finally able to use all 4 cores in other CPU intensive tasks.

What Stweak setting allows the use of the 4th CPU core more often (when needed)?
 

jujuburi

Senior Member
Sep 10, 2011
1,624
1,504
Flashed the latest version and the LED has stopped working completely, if you keep the LED Fade option checked, the default option! If you uncheck it, okay, but that's not the point I guess.
Oh, I'm on Omega latest.

PS: Nonsense, ignore it.

'Swyped' from my GT-N7100
 
Last edited:

m666p

Senior Member
Aug 21, 2012
386
101
Flashed the latest version and the LED has stopped working completely, if you keep the LED Fade option checked, the default option! If you uncheck it, okay, but that's not the point I guess.
Oh, I'm on Omega latest.

'Swyped' from my GT-N7100

Works for me.....
Also try my led settings looks a little like the bb phones

low light...=255
bright light...=255
fade-in...=1(or 0)
fade-out...=12
enable led fade=yes
slope 1...=4
slope 2...=1
slope 3...=2
slope 4...=3

also using it along with light manager......

Device = Note 2
Rom = Omega 15
(Apex@onyx black,Wallpaper@galaxy pack)
Kernel = Perseus 35
(Cpu 1.7@1175000mV,Gpu 733@1100mV)
 
Last edited:
  • Like
Reactions: jujuburi

ROX77

Member
Feb 2, 2008
47
13
Rome
I am hoping someone who knows stweaks settings very well can help me....

I looked at CPU utilization more carefully (Using Perfmon 1.1) on my Samsung Note 2 with Pegususq governer preset on Perseus version 35. For some reason only 3 CPU core are utilized at all times; even when 3 CPUs reach 1600mhz with newly full utilization. The only time I've ever seen all four CPU cores be utilized is when playing one of my 3D games. After exiting the game, I am finally able to use all 4 cores in other CPU intensive tasks.

What Stweak setting allows the use of the 4th CPU core more often (when needed)?


You have to reduce the runqueue depth from 3 core to online and from 4 core to offline, in the cpu hotplug section. Try to set these values to 300.
 

jujuburi

Senior Member
Sep 10, 2011
1,624
1,504
Ah, damn it, shame on me! Actually I used to see the LED blinking almost instantly after hitting the 'test' option under Light Manager, on Stock or other kernels. This time I had to wait for some 2-3 seconds for the LED to appear, and I don't think I can change that, right? No big deal anyway.
One more thing I might ask, I'm seeing some comments that even on full load all the cores are not activated, is that true? Should I lock all the 4 cores under S Tweaks then?
I don't like slow stuffs, that's all ;)

Btw- Great work Andrei, gotta admit.

'Swyped' from my GT-N7100
 

AllanJH

Senior Member
Mar 2, 2009
152
15
Any chance a "disable dock detection" option could be added? Some Note II ROMs crash when docked, so being able to block that would be amazing.

Unless someone can point me to another way to disable it.
 
Status
Not open for further replies.

Top Liked Posts

  • There are no posts matching your filters.
  • 813
    Welcome to the Perseus kernel! I thought it would be a nice catchname considering the Galaxy/Universe/Pegasus themes.

    This is a direct port of my kernel on the Galaxy S3. I am using the same source base for both devices for the kernel, just with a different configuration file. The kernel images are not interoperable! I will continue development in parallel for both devices, with the Note 2 having maybe some delay due to third party testing.

    I'm trying to be more cutting-edge in terms of development in this kernel. In contrast to other kernels and philosophies of other developers, I don't believe giving the users more choice is a very smart thing to do. As such you won't find a dozen different governors or twenty different settings for this kernel. There is a optimal, or at least, most optimal setting on which the devices operate both in terms of performance and power management. For the average user this kernel will brings lots of benefits to battery life, screen improvement, fluidity and sound enhancements without having to set up any of the configurations.

    The kernel comes with a configuration application called STweaks, and is installed automatically with the kernel. You will find all advanced options in there.

    Don't be scared by the alpha denomination of the kernel, I'm just taking the traditional naming scheme where alpha designates feature development, beta is feature-completeness, and final will actually be when I'll actively stop developing the kernel. The kernel is very stable, and any bugs are fixed in hotfix versions (alpha x.y)

    The kernel is also being maintained and released cross-device for the I9305 (S3 LTE), i9300 (S3) and N7105 (Note 2 LTE) and shares the same base-source. I solely own a I9300 Galaxy S3, but since all the phones derive from the same Midas platform, I merely adapt the differences without having the other devices.


    Features / changelist:

    Perseus alpha36.3 (26/04):
    • Fixed slice lookup issue on ABB: It's recommended you put your slices back to default before flashing if you changed them to borderline stability values. Please upgrade.
    Perseus alpha36 (22/04):
    • Adaptive Body Bias control (ABB). (Experimental feature)

      Body biasing is taking advantage of transistor body effect for binning the chip depending on its quality. In fact, this is used on the latest Samsung SoCs both for reducing power consumption and validating bad chips by adjusting their electrical characteristics.

      The body bias is dictated by the voltage applied to the transistor gate (The usual voltages you're all used to) minus the voltage applied to the transistor body. The resulting bias can change the transistor's electrical characteristics in two possible ways:

      Before reading on: A transistor's voltage and operating frequency is defined/limited mostly on its threshold voltage. Wikipedia has a neat visual representation of this; voltage must raise to a certain point for the transistor to be able to switch and operate. This threshold voltage can be highly dependant on temperature, influenced by the body effect, and defined by the manufacturing process. What we're doing nowdays with undervolting is to get as near as possible to the upper bound of this threshold voltage.

      With that in mind:
      • Forward Body Bias

        A FBB is defined when the bias of the gate voltage minus body voltage is positive, meaning the gate voltage is higher than the body voltage. This has the effect of reducing the threshold voltage. By reducing it, you can achieve lower voltages, or be able to clock the transistor higher. However the side-effect of lowering the threshold voltage is that you are sacrificing power leakage, meaning that the lower the threshold voltage becomes, the higher leakage current in the transistor becomes. This leakage power rises exponentially with a linear lowering of the threshold voltage. This is what is called static transistor leakage.
      • Reverse Body Bias

        A RBB is defined when the bias of gate voltage minus body voltage is negative, meaning the gate voltage is lower than the body voltage. it has the direct opposite effect of FBB, it raises the threshold voltage thus you would need a higher gate voltage for switching, but however you also dramatically decrease static leakage.
      What happens is that you want to use RBB when idling, and a reduced RBB, or even FBB at very high clocks.

      Samsung currently uses this on top of voltage scaling to bin their chips. Here's an excerpt of the stock body biasing on the 4412 Prime chip (I'm using that one as an example as it has better adjusted ABB values over the Rev 1.1 chips).
      ZDOUXP9.png


      To find out your ASV group: You can read out your ASV group in /sys/devices/system/abb/abb_info now.

      I have rewritten the ABB scaling logic/driver for CPU, GPU, MIF and INT voltages.

      In the current implementation, since it would be insane to have paired-up gate-body voltages divides the frequency range in several slices; even Samsung uses only three voltage ranges on the DVFS scale. I divided the frequency ranges as follows:
      • CPU: Divided into four slices, with frequency ranges of 200], 800], 1600] and ]1600 Mhz.
      • GPU: Three slices: 160], 533] and ]533 Mhz.
      • MIF and INT: Both only two slices with the bottom frequencies for each as middle-threshold.

      As mentioned above, controls can be found in /sys/devices/system/abb/ and the entries are self-explanatory. You can also change the frequency slice limits per sysfs, however in STweaks I only included the voltages for each slice only for now.

      Disclaimer
      {
      And that's about it in that regard. I have tried testing things over last couple of weeks, but I haven't come to a solid conclusion yet beyond what's presented by the stock characteristics: It's up to you people to do some advanced testing on the matter. My limited empirical testing in terms of voltages tells me it works as intended, but if a user with advanced measuring equipment would do similar testing to what I did back on the 4210 it would be perfect. }
    • zRAM: Switched over from LZO to Snappy compression algorithm, this provides much faster compression and decompression than the LZO implementation which was in the current kernel. I updated the Snappy libraries to the latest original CSNAPPY implementation, so this is extremely new.
    • Some kernel internal updates to speed up hotplugging and improve I/O latencies.
    • A correctly (Unlike basically every other kernel out there till now) applied load averaging patch regarding fixing a Moiré pattern in the scheduler load calculations which was floating around.
    • Fixed mono and equalizer switches in the sound engine. (Thanks to sorgelig for beating me to it)
    • Fixed led controls to behave correctly with user-space apps.
    • mDNIe digital brightness reduction:

      You can now lower the brightness to basically nothing via this: it uses the mDNIe engine to digitally remove luminance from the RGB channel values, as opposed to reducing brightness via a proper backlight/display driver. The side effect of this is that you lose colour resolution somewhat, but is a practical and working method to reduce the too bright minimum values of our displays.

      You have three configurables:
      • A reduction rate which you want to apply, this is the intensity of the darkening you want to achieve.
      • The take-over point; the backlight driver gets fed brightness values from 0-255 (In reality values below 20 have no effect). The take-over point is the point where the digital brightness reduction starts, on a reverse scale. The reduction is applied linearly from 0, (Full reduction taking place), to the take-over point (Zero reduction). The stock slider doesn't go below 20 in the interface, so practically the full reduction rate is never applied unless you use a third-party brightness controller app, just to keep that in mind, but in practice it doesn't matter.
      • Auto-brightness input-delta: This is needed because the stock framework is retarded in the values it forwards to the kernel, you can adjust this to avoid having brightness reduction when you don't want it on auto-brightness.

        Somebody needs to edit config_autoBrightnessLevels, config_autoBrightnessLcdBacklightValues in framework-res.apk\res\values\arrays.xml to fix this.

        Optionally, if you use a third-party app like Custom Auto Brightness which allows backlight values of down to 0, you can avoid this problem.
      The register hook needs to be enabled to be able to use this function.
    • EA8061 Note 2 owners only: increased the maximum brightness by 50 candela: the manual controls were limited to 250cd as maximum as opposed to 300cd which was only usable during auto-brightness, and unusable for any third-party apps. This doesn't apply to users with S6EVER02 controllers.
    • Unaligned memory access throughout the kernel when applicable.
    • Switched over to GCC 4.7.3 Linaro toolchain for compiling.

    Perseus alpha35 (06/04):
    • Further rewrote the in-kernel audio controls:
      • Threw out the old detection methods for something more robust.
      • This particularly enables non-cellular applications such as Skype, Viber, and so on to be detected correctly. A "calling" state now includes any and all use-cases where the audio is outputted via the phone's earpiece. This fixes microphone levels for such apps to correctly use the calling sensitivity value.
      • Added microphone level for camera use, this state is enabled whenever a camera stream is active. It should give more options into adjusting things to your likings.
      • By now the sound engine has only little similarities to Boeffla, any bugs and feedback now go directly to me.
    • Developers only: MHS: Added a new small tool for tracking media use and reporting it to other in-kernel drivers. Capable of detecting video recording, decoding and camera streams for now. See commit for more info.
    • mDNIe control changes:
      • Removed several controls in STweaks simply because people misunderstood them or misused them, or they simply had no rational use.
      • Video detection, now with the help of MHS, is no longer limited to the stock video player. Any video players using hardware decoding will now be able to make use of edge enhancement, HDR and DNR, this includes any web-based players and the YouTube app.
    • Custom LED controls implemented; Exposed most variable controls for the notification LED via sysfs and STweaks (LED tab). :
      • Control LED brightness. Currently the OS dictates, depending on brightness detected by the light-sensor, wether to run the LED in a low-power mode or in a high-power mode, you can now set brightness for both.
      • Blinking control, this is basically the shape of the wave-pattern that the LED blinks in, you have several controls, best described the data-sheet description:
        aGP3lNe.png


        The fade-in time period is TT1 in the graph, while the fade-out period is TT2.
        Slope (1/2/3/4) detention time represents DT1,2,3,4 in the graph, it controls how "steep" the four different curves are.
      • The LED fading checkbox simply switches between having the detention times controlled by the sliders to having them to 0 (Stock blinking behaviour).
    • The ZRam control is found in the I/O Tab in STweaks. Set it to 0 to turn it off completely, any other value to turn swap on. Changing value takes about ~10-20 seconds depending how loaded the disk is with swap pages so don't piss your pants if it doesn't react immediately.


    Sources:

    https://github.com/AndreiLux/Perseus-S3

    Credit and thanks:

    gokhanmoral, netarchy, and anybody credited in the commits.

    Thanks to sswagonman for the initial testing.

    TL;DR: before flashing aside from known issues in the second post.
    • This isn't an AOSP kernel.
    • Please choose the right version between N7100 (International 3G) and N7105 (International LTE).
      The kernels are labelled for their respective target device. You have no excuse in messing this up.
    140
    Other variants

    Note 2 L900 (Sprint) Download
    Note 2 i605 (Verizon) Download
    Note 2 T889 (T-Mobile) Download
    Note 2 i317 (AT&T) Download


    U.S. Cellular R950 & China Mobile N7108 (这个版本是专为中国移动用户提供的Samsung Galaxy Note II 变体,中国移动版-N7108)

    Kernels for these variations of the devices below.
    71
    Reserved. (Variant downloads moved to post 2)
    47
    Known issues [Updated 10/01]

    • None.

    Older changelogs

    Perseus alpha34 (22/03):
    • Updated sound engine. Based on Boeffla (Andip71)sound but custom fork with rewritten system interface and some other code re-factorings.
      • Should fix all FM Radio issues.
      • Brings us saturation prevention for the equalizer.
      • Privacy mode.
      • Microphone level control
      • You now have control over the speaker equalizer via sysfs, please visit /sys/class/misc/wolfson-control/ the controls are self-explanatory.
      • I removed the equalizer pre-sets from STweaks, if you want, set them manually:

        Bass-extreme: 12 8 3 -1 1
        Bass and Treble: 10 7 0 2 5
        Treble: -5 1 0 4 3
        Classic: 0 0 0 -3 -5
        Pleasant for ears: 4 3 2 3 1
        Eargasm: 12 8 4 2 3
      • I recommend HeadphoneAmpControl (thread - Play Store) for controlling the volume directly on a hardware level; it will overwrite the digital volume of the OS and use the hardware amplifiers only.
    • Enabled ZRam by default with disk size of 200mB and swappiness of 90%.
    • Applied a requested patch which allows PCs to be booted off from the phone storage.

    Perseus alpha33 (26/02):
    • Revamped and hopefully final version of mDNIe controls:
      • The controls work now on two levels: First we have a master sequence that overrides any and all of Samsung's settings; The master sequence is calibrated to sRGB norms on a precision level equalling and even surpassing the iPad3/4 with help of professional equipment (Spectrophotometer) and professional hands. All credit goes to Slimer777 for his incredible job in doing this.

        Calibration data:

        5bg76Ur.png


        Simple report: Download
        Detailed calibration report: Download
        Advanced colour management report: Download

        (Please note that the "before" values represent the raw screen output without use of mDNIe, these values don't represent any of the live profiles)

        The master sequence works as as the calibrated base; for people not wanting to bother further with any more controls, you simply enable this and you're done. Please keep in mind that every screen is slightly different and variations in manufacturing affect image output; this works as a base calibrated as close as possible to sRGB / Rec. 709 specifications.

        Second part is the register hook, it catches effect values and modifies them by applying delta values available as controls in STweaks and in /sys/class/misc/mdnie/hook_control/.

        Leaving both these options will give you Samsung's default values, plus the black crush fix.

        The register hook, while used on Samsung's profiles, is not capable to alter effects which are not integrated in that screen profile's value sequence, the "Movie" profile for example lacks some effects present in the "Dynamic" profile. The same is valid when having different scenarios, the "Camera" scenario will use different effects in its base than the "UI" scenario. To fully explore all possible effects, use the Master profile as it integrates all effect values known.
      • Each control has a master kill-switch which enables or disables the effect. This varies by profile and scenario, so you have control to only "toggle" the switch, whatever its state may be in.
      • Digital noise reduction - Reduces and flattens out grain. Advanced controls are found in the hook_control folder with the dnr_ prefix.
      • High dynamic range - A HDR effect which brings out details in dark and extremely bright scenes.
      • Digital edge enhancement - An edge enhancement effect. What we previously called "sharpening". Divided in controls for radius, amount and threshold. Read the Wikipedia page for more information. More advanced controls found in the sysfs under the de_ prefix.
      • For the above three effects, scenario consideration is taken into account. You can enable/disable them depending when you want it to be applied. Please be aware only the stock applications trigger the scenarios. I will try to enable at least the video scenario depending on when the hardware decoder is active in the future so that they are enabled also in third-party video players.
      • Chroma saturation control - Same as in previous version but with fixed labels.
      • Colour temperature control - By default this is disabled on all profiles, however, if your screen has a tint to it, this is the first control you should try to fix as it alters temperature on all channels.
      • The SCR controls are colour channel filters working on the Red, Green, Blue, Yellow, Cyan, Magenta, White, and Black channels.
        Imagine the controls as manipulating the corners of the RGB cube:
        G1W6fON.png

        (Credit to Wikipedia for the graphic)

        By controlling the RGB coordinates of each corner/channel we can mould the cube into a different shape. At the same time the cube is projected onto a hexagon; the perimeter / angle of the hexagon represents the colour hue, the radius of the hexagon from the middle represents chroma. We can use the chroma saturation controls to "push in" each corner of the cube, while moulding the corner's directions with the RGB controls. The RGB coordinates can be transformed into the HSL space space if needed, however I didn't include this function yet as I don't feel the need for it.

        STweaks has controls for the RGBYCMW channels, the K (Black) channel I left out because it makes no sense in altering it, but can be found in the sysfs folder.
      • Several controls have a "factory setting" switch, this are the burned in-hardware values for some controls, they overwrite the controls themselves.
      • Additionally to the controls exposed to STweaks, there are several other effects and modifiers exposed in the sysfs interfaces. This also includes the gamma curve controls for levels 0-255 in steps of 16.

        There are also some additional unidentified configurables which I wasn't able to properly give a name to or had no effects: Dithering, ABC (Seems to give a gamma brightness boost), SCC, UC, and MCM (Colour temperature) configurables whose exact effect isn't documented.


    Perseus alpha32 (29/01):
    • Charging control implemented. This is my own version.

      Charging currents:
      • Charging currents are dictated by input and charging current limits. The input current is the current flowing into the device through the USB port at 5V. The charging current is the current delivered to the battery at usually 4.35V. The device can have a higher charging current than input current because of the voltage differential, usually a 15% discrepancy. You can also have much higher input currents than charging currents, this can be useful when you are using the device in situations like gaming and charging your battery at the same time, provided your charger actually can provide the power.
      • There are 3 USB charger type categories: DCP / Dedicated Charging Ports which also includes AC chargers, but also special USB plugs; SDP / Standard Downstream Ports which usually includes almost all data enabled USB ports, and CDP / Charging Downstream Ports which includes also data enabled USB ports but which are designed to provide more power, usually on newer laptops where the USB port has a lightning logo next to it. More info here. - Technical explanation here.

      Charging logic:
      • Stable margin removal option. The charger chip is capable of detecting unstable charging sources; it dynamically reduces the input current in 100mA steps until it detects a stable voltage input [We don't have the charger chip datasheet, so the technical explanation is a bit blurry here on how it decides that it's unstable]. It further reduces it by 100mA as a safety margin, you can disable this now.
      • Complete disabling of unstable power detection. This simply ignores unstable power sources and leaves the input current limit at its set up value. This will fix charging problems people have been reporting. However, please use it at your own risk, the S3 chargers which have had these symptoms clearly have some issue in their hardware so you might actually kill them with this option enabled as there is no protection from the phone's side anymore.

        The actual input current limit can be read out in /sys/devices/platform/samsung-battery/power_supply/battery/current_max, so you can see the real limit there, it's the closest thing we have to the actual charging current on stock values since there is no hardware to read out the live currents.

      Voltage control:
      • Hard voltage control: 4.20, 4.35V, and 4.40V charging voltages are available. This is included for anybody running on third-party batteries, whom most of them have a 3.7V battery chemistry as opposed to the 3.8V on the stock battery. These batteries should be charged at 4.2V instead of 4.35V.
      • Soft voltage control: As opposed to the hard voltage control which is the voltage which the charger chip provides to the battery while charging, the soft-voltage is the battery voltage itself. 3.7V batteries have a top-off voltage of 4.2V and 3.8V again 4.35V. The default limit on the stock battery is 4.30V before the charger logic stops and considers the battery as full. This is also merely provided for 3rd party batteries which should be charged at lower voltages. If you overcharge your battery beyond these what are safe considered voltages, such as raising the default 4.30 top-off voltage to the design 4.35V or even higher, you are running into the risk of damaging the battery or even causing it to melt-down. Use at your own discretion.
    • mDNIe sharpness and RGB/YCM chroma saturation control in STweaks:

      I started implementing sharpness control in STweaks and went a bit over-board instead of a simple checkbox; You now have controls over the mDNIe registers as a delta offset value compared to the stock register values. I'm applying the offset to all mDNIe profiles and scenarios which have the specific post-processing effect active in that specific scenario. Meaning, that you start with the default profile; Dynamic / Standard / Natural / Movie and have the delta offset applied on top of that.
      • Sharpness delta. This is what brought most of the quality difference in hardcore's original tweaks. You can now fine-tune it to your own taste, and also take into regard that it produces a different effect for each screen profile while having the same delta - the base values between the profiles are different.
      • DE control - I don't know what this actually does and I couldn't discern much difference between the values, but it used to be disabled in hardcore's tweaks.
      • Chroma saturation control: This is composed of 2 values for each RGB/YCM channel. See the Munsell color system for a visual representation of the values controlled here. The chroma curve control describes the curve weight based on chroma intensity, the chroma gain is the chromatic gain that is being applied on the respective channel. Chromatic saturation weight is again another multiplier for all channels combined. I have not managed to properly identify the chroma grey threshold and its effects.

      Basically this is like an RGB control on steroids, and enables you to tune your screen to your own liking and calibrate it as you wish. Please note that not all scenarios in the profiles have chroma saturation effects, the Movie profile for example has no effect applied to the UI so chromatic control has no effect on it.

      I also want to state that the above are my deductions and theories on the descriptions of these controls, I'm not familiar enough on colour theory to be able to confidently say that these descriptions are correct, and the controls are a work-in-progress for now. Experts are welcome to contribute here.
    • Front buffer early suspend delay option for those who have issues with the CRT animation.
    • Did some refactoring on the Mali drivers and fixed a bug which may have caused less capable undervolting than the stock implementation.

    Perseus alpha31 (09/01):
    • Removed my own security fixes and replaced them with the official Samsung one. I guess it can now be disclosed: exynos-mem was only one of multiple entry-points for the memory exploit. We discovered the s5p-smem exploit ourselves back in December but kept it quiet, I fixed that one back in version 29.2 without mentioning. Nobody was secure from a smart exploiter up until then, SuperCurios or Chainfire's software fixes are also just patching a single hole in what is a Swiss cheese. Kernels >v31 and beyond stock LLA are now the only truly protected ones.
    • Samsung's fix for the sudden death syndrome (SDS) included. It is caused by eMMC failure on phones with VTU00M 16GB internal memory chips with revision 0xF1. You can check your phone with the "eMMC Brickbug Check" in the Play Store (Ignore the message if it says you're not affected, the type and revision is what matters). The patch is a firmware soft-patch that is applied on every boot and MMC resume, it is not a permanent fix. You will need to stay forever on kernels which include the patch, this also includes updated recoveries and their embedded kernels.
    • Some other minor MMC changes extracted from Update 7 sources.

    Perseus alpha30 (06/01):
    • Internal and memory voltage control. This is the first and only working implementation out there. Memory interface voltage is exactly what it the name implies, the voltage on the chip-to-chip interface from the SoC to the memory chip. Internal voltage is the whole SoC voltage excluding CPU, GPU, and the MIF. This includes all auxiliary function blocks such as the ISP/Image signal processor, camera interfaces, I/O interfaces, display controller and the MFC/Multi function codec hardware video de-/en-coder.

      - Internal voltage respectively memory voltage table is found in /sys/devices/cpu/busfreq/ as int_volt_table or mif_volt_table
      - The frequencies are defined as OPP's (Operating performance points), internal frequency and memory frequency (And voltages) together as a pair form an OPP. If you want to change the voltages through the sysfs files, keep in mind how you change them. MIF voltages are stored independently with each OPP step. INT voltages are stored in respect of their frequency key.

      - Default OPP steps are: 440220, 293220, 293176, 176176, 147147, 110110. The first three numbers represent the memory frequency, the other three the internal base frequency. For example 293220 means the memory interface is at 293MHz (586MHz DDR) and the internal frequency is 220MHz.

      - The voltages in STweaks are sorted out through some magic and are frequency unique, I recommend using that for controlling them.
    • Busfreq logic control added into STweaks, this includes all the already available configurables in the stock kernel with added explanations and I supplemented it with a sampling rate parameter.
    • Sensorhub driver and firmware updated.
    • Touchscreen driver and firmware updated.
    • Replaced pegasusq's runqueue detection logic with a new more superiror and precise in-scheduler collection logic, I found that the real runqueues are much less than what was previously reported. This should help a lot with hotplugging.
    • Enabled AFTR by default since we are now running very often in single-core mode. Keep in mind this mode is WFI Idle + LPA + AFTR.
    • Fixed a kernel bug which was eating up randomness entropy. This is related to that whole seeder business - please don't use any of those fixes. I also disabled virtual addresss randomization and at the same time disabled entropy generation from the block layer, which should avoid I/O overheads.
    • I raised the LPA CPU idle target residency, and fixed a bug in the ABB control for voltages for 900 and 1000MHz. I suspect these two to be causes of the sudden reboots for Note 2 users, and may fix them.

    Perseus alpha29 (18/12):
    • I'm doing a quick release because of the security fix, not very feature rich.
    • Fixes the exynos-mem security hole. This is my own fix and will not break camera. Read about it here. You don't need to use Chainfire's or Supercurio's fixes, in fact, you shouldn't use them because of the camera.
      [*]Updated Wifi drivers.
    • Increased max brightness by 50 candela. (Thanks nebkat)
    • Added GPU utilization control to sysfs and STweaks.
    • Changed default GPU thresholds to more relaxed values (75/17)
    • Added block device read-ahead control to STweaks. Additionally set the default read-ahead for internal memory to 256kB and 1mB for SD cards.

      29.1: - Reverted the Wifi drivers back.

    Perseus alpha28 (13/12):
    • 28.1: I reverted the striked out changes due to exFat. I changed my mind due to demand. I apologize for the chaos.
    • On your SD card showing up as damaged: it is not.
      I made a decision in terms of exFat compatibility; either I advance the kernel with newer upstream Linux versions or stay back and keep compatibility with the exFat modules. While I have nothing against proprietary modules or such, not being able to adapt them to the kernel is not optimal. You can format your cards to FAT32 or ext4 without much issue. Please back up your data and format your card accordingly before flashing v28.
      [*]Updated the block system to Linux kernel 3.3.
    • Introduced FIOPSv2, ROWv4, ZEN, BFQv5 as new I/O schedulers;

      FIOPS is the new default scheduler, it's a CFQ like fairness scheduler optimized for solid state storage. ROW should be the actual better performer here as it has superior logic, but I didn't set it as default because of some lags when installing applications. ZEN is just a mix of SIO and Deadline and nothing special. BFQ seems to underperform. I recommend the first two over everything else, and added the latter two just for comparison's sake.
    • Added dynamic Fsync control (Faux123). It disables Fsync only when the screen is on. Enabled by default (Fsync off).
    • Changed some logic on when the adaptive scaling voltages are applied in the kernel init sequence. This fixes GPU voltages not being applied at boot and also fixes the wrong default voltages being displayed in STweaks.
    • STweaks tab for I/O with scheduler selection for each device block and also dynamic Fsync.
    • New script side feature in the uci.sh framework: When inserting an override.profile file into the profile folder (/data/.perseus), the entries in the override profile will supersede the ones in your default profile. You can use to make CWM zips to turn off set at boot flags or to share targeted settings with others. The override is applied once at boot after which the profile deletes itself.

    Perseus alpha27 (02/12):
    • Sources updated with various updates from N8000u1 base. Included are following important changes;
    • Wacom drivers, Sensorhub firmwares, touchscreen updated.
    • Updated wireless drivers.
    • Adds a delay to SD Card host controller power-down, which I assume is to prevent some corruption. There is a specific change to Toshiba 19nm manufactured SD Cards, these are mostly the latest SanDisk 64GB cards. Together this may fix issues users have had.
    • Updates the camera interface, Video4Linux and Jpeg2x drivers and this fixes compatibility with 4.1.2 ROMs. Backwards compatibility is retained.
    • Other updates which are more transparent to the end-user.
    • Removed the sharpness modifications due to demand.
    • LTE devices only: Disabled CPU frequency clock while connected to a cable.
    • New PegasusQ logic:

      - We now have additional conditionals on the hotplug logic which checks the total load across all cores and is able to bias towards a specified core count if the load is low. This is useful because previously we could have had frequency spikes and lots of low-load threads triggering a hotplug-up while in reality it wasn't needed. The core count is more biased on keeping 2 cores online in most cases now unless really needed.

      - The way freq_step is handled has changed. We now take the remainder of load space above the up threshold and dissect it into three slices each having different frequency increase step sizes. The first two slices are each of up threshold differential size, lop-sided towards the lower end of the load scale. We specify the slice size and freq_step delta in regard to the original freq_step.

      - A new fast-down scaling logic; if frequency is beyond a certain threshold, we take a heightened up_threshold value solely on the down scaling logic to scale down more aggressively from the higher frequencies.
    • Audio enhancements (Gokhan Moral's port of Voodoo sound) re-enabled. Call-detection is currently broken (Effects are applied during call while they shouldn't be), but this fixes the effects not being applied otherwise. (Thanks to sjkoon for finally debugging that)
    • STweaks. This is my custom implementation of the kernel side, based on Gokhan Moral's initial implementation.

      - CPU overclocking and voltages interface.
      - Configurables for all CPU governor settings.
      - GPU overclocking and voltage interface.
      - Interface for audio enhancements.

      Just an explanation in regard how uci.sh (Script framework on which STweaks is built) works: The settings displayed in STweaks are the defaults with which the kernel boots the first time and are saved as a profile. The saved profile settings are applied before anything else on boot, including init.d. The values displayed in STweaks do not correspond to live kernel values, but the values saved in the profile. As such if there is another app or script setting something after STweaks, it will not represent those changes. Please be aware of that. I included labels with the default values for almost all values, they are dynamically generated.

      *Note: Currently the labeled default GPU voltages do not correspond the real default ones as the ASV voltages get applied after I'm reading them out for the interface on early boot. I'll fix this later on.

    Perseus alpha26 (14/11):
    • Updated MTP drivers back to the newest version. Fixes some inconsistencies which some people had.
    • Further increased MMC command timeout from Linux default 300ms to 3s in trying to finally squash errors and "unexpectedly removed SD card" after resume.
    • Ported Gokhan Moral's mDNIe interface and also added colour tone modes on top of the scenarios. System interfaces are found in /sys/class/misc/mdnie . Input syntax is the same as the output syntax, or, single register-value pairs as a single line in the output format, except 0xFF which is a terminator value.
    • Increased default sampling rate down to 30ms from 50ms for a bit more fluidity.
    • Updated Sensorhub drivers from latest sources.
    • Updated Wacom and E-pen drivers from latest sources.
    • LTE devices only: Updated some power management functions on the MDM modem from latest sources; this will drastically decrease the amount of wakelocks on mobile data and improve battery life.

      26.1
    • Disabled net_os_rxfilter_add_remove userspace/ROM filter management in the Wifi driver to prevent the operating system of enabling unwanted pass-through multicast and broadcast filters while in standby.
    40
    I'll do that. And I'll be sure you get a pm when I do. Also, you won't have to worry about your device rebooting anymore.

    Have a nice day folks. Sorry for disagreeing with the almighty god
    Get your head out of your ass, it's not about disagreeing or not, it's about the facts/content you disagree on. You're don't have immunity to criticism and neither do I so don't get upset when you are being called out on something.

    Let's do a breakdown:
    Some of these frequencies are set almost -100mv. Processors nowadays are becoming very efficient on power and are absolutely DWARFED by the amount of power your display, radios, and other hw uses. My own personal opinion is to look at other power consumers such as the aforementioned before playing with hw that in the grand scheme of things is not your biggest power consumer culprit, yet is vital to system stability.
    The point of undervolting is that it is a disadvantage free method of gaining power efficiency, and it can bring down the dynamic power usage on the SoC down, from, let's pull it out of my ass, 20% by the best estimates from what I have measured over the last year. If you have instabilities then it is your fault in your methodology because you are undervolting too much. We are merely eliminating a manufacturers safety margin by undervolting.

    I did these measurements last year on the 4210 on the S2 and they represent a almost linear scaling:

    nyKHt.png


    Off = CPU on with top off (Screen turned off and wakelocked system)
    SetCPU = Idling while screen on.
    ST off single = Stress test with single core enabled with top off
    ST off dual = Stress test with both cores enabled with top off

    They are not the same chip and they are not made on the same manufacturing process, but they are the same chip architecture with the same power savings methodologies, power scaling is dictated by physics and transistor dynamic leakage has been dictated by the same Power = Voltage ² x Frequency for the last 30 years.

    You can see in that graph how merely changing the minimum frequency from 200MHz to 500MHz increases the power consumption by 88mW on that chip. Undervolting and dynamic power usage scales and goes down EXACTLY quadratic to the voltage.

    That CPU usage is dwarfed by anything else is absolute MYTH. Let's take the S3 as we have measured data on that: http://displaymate.com/Smartphone_ShootOut_2.htm

    The screen uses 1.3W output maximum on full brightness and white image, the standard usage depending on the coulours is maybe half of that, and a fraction of it if you put a dark interfaced ROM onto your phone or turn down the brightness further.

    The 4412 under medium load from doing nothing to gaming as something from 250mW to 2-3W in the most demanding games, basically double or more of what the screen uses. The device doesn't get hot for nothing.

    SAMPLING RATE: 28000 - just to be clear, the sampling rate is the interval of spacing between CPU being polled for load. Use this as you see fit, the small the interval, the more it checks for pending tasks to be executed. I have found great success and performance (and accuracy and decreased latency) with 20000-15000. Battery will not suffer anything noticeable to the end user.
    No the sampling rate is not when the CPU is polled for load, it's the periods between which the governor does DVFS decisions, load is merely a statistic of the reverse of how much time the CPU is in idle.

    Yes, you are right, making quicker decisions through a scaled down sampling rate does indeed increase responsiveness, that is why I implemented the flexrate stuff (Other kernels lock the CPU to 800MHz and it is a battery drainer), so that whenever you are touching the screen things will accelerate down to 12500µS and up until the flexrate max frequency after which it goes back to the default sampling rate.

    Setting the default sampling rate too low is BAD, it causes too much jitter on very short loads and it scales down the CPU needlessly too high, and on top of that, there is a power and latency penalty to switching frequencies. Having the CPU do that without interactive use is a needless and useless thing.
    honestly, I really don't see the need to mess with this either. More potential instability for a minimal gain in battery when analyzed against your main thieves of your voltage - display, radios.
    Same thing, again, absolute nonsense as with the CPU voltages above. Internal voltage especially can bring power gains, albeit it is much less than the CPU, but it is a free gain.
    dealine and noop will give you the best performance on these devices in real time, data speeds are also increased significantly with these two IO schedulers.
    Deadline is alright, but noop just means that you are turning scheduling off. It doesn't bring you any performance gains at all, you are better off using an IOPS and latency designed scheduler like ROW or FIOPS (I'll bring that back when I have time), again, Deadline is ok, and SIO is a compromise of everything.

    ywGjx.png


    Those are the benchmarks I did with Bonnie++ back when I did the I/O overhaul in version 28. They are very flawed as in they are merely single runs but at least they give you a first impression. I didn't do more because that table already took me half a day to create, and that's only on a 512MB block size and single runs. Deadline and Noop are okey because they do little and no schedeuling at all, the benchmarks just show simple singlethreaded I/O requests, there you will never see any scheduler much in front of the other aside from latencies, but schedulers are meant to schedule concurrent requests and that is why Noop should never truly be used. From all the real schedulers only FIOPS and ROW are able to compete with them. That's why I set up ROW as default until I can bring FIOPS back.

    Also, if i may add this... I would recommend bumping the min frequency to something like 500MHz for the CPU. Reason being is simple - smaller tasks (maintenance, logging, etc) can be handled with ease without causing unnecessary CPU ramping.
    Maintenance, logging???!!! These are tasks that do not even remotely task the CPU even at 200MHz with any significant load, any single process out there running in the background can be done at 200MHz, it is more power efficient and you are not even aware of it.

    Aside from the power aspect which I explained above, there is also other stuff related to the governor scaling logic itself that it bad: If you are running the CPU that high as a minimum threshold, you are : 1) Also breaking the CPUPower driver's setting of migrating tasks on a single CPU at low frequencies so that the other cores can achieve undisturbed and long idle state residencies. 2) Breaking the hotplug logic frequency thresholds as they are not meant to plug in that early and can be uselessly triggered by a single CPU frequency jump up from 500. 3) You are breaking the lower level dedicated logics as freq_for_responsiveness and threshold_at_min_freq which do extremely relaxed scaling logics to deal with minor tasks fast and no do over-scale too much.

    THIS is performance without battery life taking a hit - making your system AGGRESSIVE YET EFFICIENT, not hindering and crippling it to not do what it is programmed to do. Efficiency. "Less is more" as you see thrown around in the Linux world can also be thought of as more is less if you think in terms of more thought, tuning, and logic is less power consumed by your device.
    So you see how that whole last paragraph of yours is just nonsense and that last phrase is really something one might take out of a PR article. Your settings you suggested were not given more thought.

    So with all of that in mind:
    I'll do that. And I'll be sure you get a pm when I do. Also, you won't have to worry about your device rebooting anymore.
    Yes please do deliver your kernel, because I want to see more nonsense delivered with an attitude. We already have a large amount of clueless developers on this site. The problem isn't that they're unskilled or do not know the technical details, everybody was like that including me; It's that they think they are doing some sort of meaningful change without giving the effort of thinking or dwelling into the topic more than 2 minutes. People are suffering from a severe case of the Dunning-Kruger effect (I was so happy when I found out there's a name to that attitude).

    And if you feel the need to be sarcastic and attack me on the reboots because that's just pathetic, it was caused because I did a merge-mistake regarding the lowpower residency times that the Note 2 apparently doesn't like, and I wasn't able to find it until v30 because not a single soul except a few people were able to give me a proper kernel log. Some people forget I don't even own this device.

    There's another developer on this very device who has played with a configuration value a few times over the last few weeks but couldn't do a simple Ctrl-F of that value in the very same file to see what it does and then realize it isn't even used. Or another dev changing voltages and "testing" them out for stability over a period of time, adjusting them, without realizing it those values are never even used and immediately overwritten on boot. New features! Adjusted XX for more performance! New kernel will make your erections bigger!

    What do you want me to say to such people in a nice and civilized manner? People blame me for being arrogant, but then put yourselves in one's shoes for once and think about it.

    Bugger-off is what I say.


    ____


    I will update the kernel here to v31 here too but I'll do that tomorrow or so since I had a lot to do on the S3 regarding the SDS bug and still want to figure some things out regarding the new security fix. Anyway it's not as urgent for Note 2 users. Just be patient.