How to Configure and Use ElementalX Kernel on your M8 for the Best Results

Pin It

Today we are going to dive deeper into the world of kernels and explore command lines, kernel log files and various other functions. Our kernel of choice? The ElementalX Kernel for the HTC One M8. However before we dive right into this, we need to have the Kernel installed on our device. If you want to read more about that head on over to this article.



ElementalX Configuration File
Your choices in the Aroma installer are used to build a configuration file. The config file is located at /etc/elementalx.conf. You can edit this file to change kernel settings. Whatever is set in this file will take effect when the device is booted (unless other scripts or apps interfere!)

If settings are not sticking:

  • Make sure you have busybox installed correctly and updated to the latest version
  • Make sure the file permissions for /etc/init.d/99elementalx are set to execute.
  • Check to see if any /etc/init.d scripts or apps (such as Kernel Tuner or TricksterMod) are interfering with your settings.

ElementalX Log File
Every boot, a log file is created at /data/local/tmp/elementalx-kernel.log. This file shows the date and time and all settings that have been applied. Use this to verify and troubleshoot configuration options.

Customisation Options


Overclocking is optional. The installer lets you choose the maximum frequency. Whatever frequencies you chose in the installer will be set at boot for each CPU. Not all devices can handle overclocking. I don’t recommend overclocking, this device is fast enough. If you overclock, the CPU frequency will likely be throttled due to heat. I recommend the stock frequencies, as this device is plenty fast.

CPU voltages
The installer allows you to choose from several undervolting options: stock, -15mV, -30mV, or -45mV. This only undervolts the lowest frequency, which happens to be the frequency used the most, and this is safer. Be careful, lowering voltages can cause instability.

gboost enhances gaming performance by giving a slight boost to cpu frequencies when the graphics load is high (e.g. while gaming). It should have no effect on battery life during regular usage, so it’s safe to leave it enabled all the time.

fsync can be disabled if you’re looking for the last ounce of performance. I recommend leaving it enabled as there is a slight risk of data loss if your phone shuts off unexpectedly before filesystems are synced.

Installing a new ROM
If you install a new ROM, it will probably replace this with the stock kernel and will definitely overwrite /etc/init.d/99elementalx and /etc/elementalx.conf so you will lose your settings and certain features. So always reinstall the kernel after installing a ROM.

Sweep2sleep allows you to put your device to sleep by swiping right to left across the bottom of the screen where the back, home, recent buttons are. I find this useful since the stock motion gestures do not provide a good way to turn off the screen.


  • 0= disabled
  • 1= sweep2sleep right enabled
  • 2= sweep2sleep left enabled
  • 3= sweep2sleep left and right enabled

USB fastcharge
USB fastcharge is optional. This will allow you to charge at a faster rate when connected to a USB port. The default limit for USB ports is 500ma, this increases it to 1100ma. Be sure that the computer/laptop/whatever you are plugged into can handle it. Some will automatically cap it at 500ma. Please note that this does not force AC charge mode like previous implementations of force fastcharge. Your battery setting will still say USB mode. You can edit /etc/elementalx.conf to change the setting on boot.

Wake Gestures

There are three modes

  • Mode 1: Stock Motion Launch Gestures
    For stock motion launch gestures, /sys/android_touch/wake_gestures, /sys/android_touch/sweep2wake and /sys/android_touch/doubletap2wake must all be set to 0. Enabling any of these overrides the stock gestures. Obviously Motion Launch Gestures must be enabled in the system settings.
  • Mode 2: Remove motion requirement
    For this, you must set /sys/android_touch/wake_gestures to 1 and enable at least one gesture in /sys/android_touch/sweep2wake or /sys/android_touch/doubletap2wake and Motion Launch Gestures must be enabled in system settings. In this mode, when you sweep or doubletap, the appropriate input events are generated and acted upon the EasyAccessService (i.e., the system app that handles gesture actions).
  • Mode 3: Traditional S2W/DT2W
    In this mode, wake gestures and actions are handled entirely by the kernel. The gestures will turn on the screen and that’s it. For this, you must set /sys/android_touch/wake_gestures to 0 and enable at least one gesture in /sys/android_touch/sweep2wake or /sys/android_touch/doubletap2wake. It doesn’t matter if Motion Launch Gestures is enabled or disabled in system settings, the gestures don’t interact with it in this mode.


For modes 2 and 3, there are several options.


  • Sweep right=  1
  • Sweep left=    2
  • Sweep up=     4
  • Sweep down=8

Add up the values for each gesture you want to enable and put the total in /sys/android_touch/sweep2wake. For example, to enable all gestures, the value is 15 (1+2+4+8). To enable sweep right, sweep left and sweep up, the value is 7 (1+2+4)

  • DoubleTap2wakeSet /sys/android_touch/doubletap2wake to 1 to enable DT2W, and set to 0 to disable it.
  • Pocket DetectionSet /sys/android_touch/pocket_detect to 1 to enable pocket detection, and set to 0 to disable it. Pocket detection is experimental right now, I’d say it’s about 90% functional, but there is an occasional bug where it either doesn’t work or works too well.
  • Vibration StrengthHaptic feedback can be enabled for the wake gestures in /sys/android_touch/vib_strength. This setting takes a number between 0 and 60. Default is 20, which is the same vibration as the stock gestures. Setting this to 0 disables haptic feedback.

Source: XDA Thread.

Subscribe To Get Latest Rooting Guides

Subscribe us to get all latest rooting guides and custom ROMs directly in your inbox.

Android VPN


  1. Pephias says

    I just installed elementalx on my htc one device but am now experiencing several startups and its failing to re-boot. I have tried to reset my device but its just the same. So what can I do next to have my phone back to its nomal state?

Leave a Reply

Your email address will not be published. Required fields are marked *

CommentLuv badge