← or →
Due to Android platform security and SELinux restrictions introduced in Android 8.0+ (Oreo), Total Launcher can no longer read system CPU metrics directly from /proc/stat. This guide details how to query system CPU usage via elevated ADB/Shizuku shell commands in Tasker and push that value into a Total Launcher Text Variable on the home screen.
Prerequisites:
Before setting up the background broadcast, create the graphic text element in Total Launcher that will listen for the value.
%cpu_val%
CPU: 18%). Now create the task that samples current CPU load and sends the broadcast intent to Total Launcher.
Update TL CPUtop -b -n 1 | grep -E "User|CPU" | head -n 1
dumpsys cpuinfo | grep "TOTAL:" | awk '{print $1}'
%cpu_raw
%cpu_raw[0-9]+(?=%) (or [0-9]+ to match the first integer).%cpu_out.%cpu_out1 is empty, set a fallback: Variable > Variable Set > Name %cpu_val To %cpu_out1 (or To 0 if unset).cpu_val%cpu_valcom.ss.launcher.total.action.SET_VARIABLEcom.ss.launcher2var:cpu_valvalue:%cpu_valBroadcast ReceiverUpdate TL CPU.LoopStart5 Seconds (or 10 Seconds).Action Label > Label: LoopStart (Add condition: IF %SCREEN ~ on).
Tip: Add a manual refresh tap action! In Total Launcher, select the CPU text element, open its Tap Action, select Tasker Task, and link it directly to Update TL CPU. Tapping the on-screen text instantly updates the CPU reading on demand.
Following the SELinux restrictions implemented in modern Android versions, Total Launcher cannot query /proc/stat directly for system CPU data. This guide walks through configuring MacroDroid (via ADB Hack or Shizuku) to extract live CPU utilization and update a Total Launcher Text Variable on the home screen.
Prerequisites:
adb shell pm grant com.arlosoft.macrodroid android.permission.DUMP).%cpu_val%
CPU: 24%).cpu_rawcpu_valUpdate TL CPUtop -b -n 1 | grep -E "User|CPU" | head -n 1
dumpsys cpuinfo | grep "TOTAL:" | awk '{print $1}'
cpu_raw
cpu_raw[0-9]+
cpu_valcom.ss.launcher.total.action.SET_VARIABLEcom.ss.launcher2varcpu_valvalue[lv=cpu_val] *(Select via the triple-dot menu or type `[lv=cpu_val]` to pass the local variable)*
Tip: To update CPU readings on demand, open Total Launcher's Edit mode, tap the CPU text object, choose Tap Action > Launch Shortcut > MacroDroid > Run Macro, and link it to Update TL CPU.
For a multi-line diagnostic widget displaying total machine load alongside the top three CPU-consuming processes, execute this command in your Tasker or MacroDroid shell action:
dumpsys cpuinfo | awk '/TOTAL:/ {total=$1} /^[ ]*[0-9]+(\.[0-9]+)?%/ && count < 3 {split($2, p, "/"); split(p[2], name, ":"); apps = apps "\n" $1 " " name[1]; count++} END {print "TOTAL:" total apps}'
This produces a multi-line string formatted like:
TOTAL:10% 19% system_server 10% surfaceflinger 10% net.dinglisch.android.taskerm
Pass this entire multi-line string directly to Total Launcher without regex stripping to show a full diagnostic readout inside a multi-line text object.
Why Individual Process Percentages Don't Add Up to TOTAL:
In Android's Linux shell metrics, individual process percentages are measured against a single core's capacity (100% = 1 core fully saturated; an 8-core CPU tops out at 800%). The TOTAL: line is normalized across the entire chipset (100% = whole device capacity). For example, 39% single-core equivalent spread across eight cores accounts for ~4.87% of total SoC power. Added to background kernel workers and I/O wait, the true machine-wide load lands at 10%.