ShizuStore

Device-Watch

jrs8205

1.14.0 · GitHub

Download APK
Miscellaneous Android 8.0+ 4 days ago GPL-3.0
954 ShizuStore
3.4k GitHub
47 Stars
4 MB Size

More about this app

Offline device monitor with widgets, per-app usage insights and a charging screensaver; optional Shizuku access reveals battery statistics, real CPU/GPU load and temperatures.

Device-Watch

Latest release F-Droid Aptoide Downloads Built with Jetpack Compose License: GPL v3

Device-Watch is an Android device monitoring app with Jetpack Glance home screen widgets, per-app usage insights (screen time, data, notifications and more), and an interactive screensaver for charging or docked use.

The app is written in English, Finnish, Simplified Chinese and Arabic. English is the default; in Finnish the app is called Laitevahti. The Simplified Chinese translation is by WOchovy233 (pull request #8).

Screenshots

Home-screen widget Overview tab Screen-time donut Since-charge view

Usage history Most opened and top data Last opened list Charging screensaver

Features

  • Home screen widget for battery, memory, CPU, storage, Wi-Fi, mobile network, data usage, uptime, today's screen time, and last update time
  • Compact 2×2 widget for battery, uptime and mobile/Wi-Fi data, with the counting period shown above each data amount
  • Single figure 1×1 widget: one figure of your choice (battery, battery or processor temperature, data today, uptime, processor load, memory, storage or battery power), picked when the widget is added and changed with a long press
  • Quick Settings tiles, one per figure, added from the panel's edit mode: a wide tile shows the figure's name and value like Android's own tiles, and a small tile, which shows only its icon, draws the figure in its place (switchable in Settings). The tiles show figures and are not switches, so they are drawn in the grey of a tile that is off; a second switch gives a tile that has a reading the colour of a switched-on tile. Android lets no app put widgets in the panel, only tiles
  • Floating figure, off by default: a small dark card with one to three figures of your choice over other apps, including full-screen games and video, where the tiles, widgets and notification are out of sight. Brought up and taken down with the Floating figure tile in Quick Settings; dragged anywhere, its place remembered for portrait and landscape; a tap shows a hide and an open button, a long press hides it. It needs the Display over other apps permission, asked for only when you switch it on
  • Battery power as a ninth figure on the tiles, the single-figure widget, the notification and the floating card: the rate the battery charges or runs down at, in watts, with the direction from the battery's status
  • Live figures in the monitor's notification, off by default: the figures chosen in Settings on two lines among the other notifications, all of them when expanded; a swipe hides it until the screen next comes on, and with none chosen it stays silent at the bottom as before
  • Widget background opacity slider, and a black-background switch for people whose other widgets are black
  • Ways in from Android's own pages, each straight to the matching part of the app's settings: the settings button on Android's screensaver page, a long press on any of the app's Quick Settings tiles, the Additional settings in the app link on Android's notification pages for the app and for each of its channels, and (Android 12+) the launcher's settings button on the Dashboard and Compact widgets
  • The monitor starts again by itself after an update of the app, as it does after a start of the phone
  • Tapping the widget anywhere opens the app
  • Data counters per calendar day or per one-month billing cycle with a configurable start day (month lengths handled automatically); the selection applies to the widget and the in-app data rows
  • Tabbed dashboard UI with swipe navigation between tabs: Home (live battery ring, usage counters, data counters and RAM/CPU/storage meters — full widget parity for people who skip the widget), Apps (usage insights), Device (hardware, SIM and Wi-Fi details), and Settings
  • First-run intro that walks through the widget, screensaver, counters and history, with guided permission setup explaining what each permission unlocks; replayable any time from Settings
  • Pull-to-refresh on every page, and haptic feedback on buttons
  • Apps tab: Digital-Wellbeing-style screen-time donut (top apps + others) with tappable legend, top data consumers today, and a last-opened list (oldest and never-used apps first, reversible) with per-app uninstall; home-screen launchers excluded from usage rankings
  • Per-app detail sheet: screen time, times opened, last opened, data used and notifications today, plus the app's version, install and update dates, where it was installed from, the Android version it targets and needs, and which sensitive permissions it has been allowed (location, camera, microphone and so on), with a shortcut to its system settings
  • Live traffic meter on the Home tab: download and upload right now, with the last minute drawn as a line; it reads the counters only while the page is on screen
  • Camera details on the Device tab: each lens with its megapixels, aperture, 35 mm equivalent focal length and optical stabilisation, the zoom range, RAW and manual-control support and the Camera2 level
  • Audio on the Device tab: connected headphones, Bluetooth and USB audio devices, built-in microphones and spatial audio
  • Usage counters on the Home tab, scoped to the same day/billing-cycle setting as the data counters: total screen time, screen unlocks (API 28+), a filtered notification count (ongoing notifications, group summaries and updates to an existing notification are not counted, so the number stays believable), device restarts and charging sessions
  • The app keeps its own 62-day daily history for these counters (Android has no retroactive API): unlocks and screen time are backfilled from the ~7 days Android remembers, restarts are derived from BOOT_COUNT deltas (immune to Android re-delivering BOOT_COMPLETED after app updates), and notification/charging tallies accumulate from install onward
  • On-device notification log with app name, timestamp, title, and text; 7-day retention; tapping an entry opens the app that posted it (when still installed)
  • History page (opened from the usage card) listing exact daily values for the retained 62 days — screen time, unlocks, notifications, device restarts, and charging sessions; each metric states since when it has been collected, and the page refreshes itself while open
  • Charges on the History page: every charge in the retained 14 days of battery history, with its start and end level, duration, charging rate and peak battery temperature
  • Used storage per day on the History page, with the change from the previous reading, and in the CSV and HTML exports
  • Screen-on time alongside app screen time, collected by the monitor service even when the dashboard stays closed (Android 9+)
  • Battery chart with 14 days of history, charging intervals and visible collection gaps
  • Export usage history and the notification log as CSV, or share a self-contained HTML report with charts, daily and monthly tables, search and date filters
  • Optional charging reminder at a chosen battery level from 50 to 95 %, and mobile-data quota alerts at 80 % and 100 % of the selected day or billing-cycle allowance
  • Optional alerts, all off by default: a hot battery (45 °C), low storage (under 10 % free) and a fast-draining battery (20 % an hour or more); each comes once and again only after things have returned to normal
  • Monthly data usage history on the History page: metered mobile and Wi-Fi totals per calendar month, served straight from Android's own statistics for up to 12 months back (no local storage needed)
  • Since-charge page (opened from the battery card): the period since the battery was last charged full — or since the charger was unplugged, when charging stopped short of full — with elapsed time, battery drop and average drain, unlocks, notifications, Wi-Fi/mobile data, and a per-app screen-time donut over that window (Android does not expose real per-app battery percentages to third-party apps, so without extended access the page shows honest usage numbers instead)
  • Optional extended access through Shizuku (no root needed) or root, off by default, for what Android hides from ordinary apps: Android's own battery statistics on the since-charge page (drain per hour with the screen on and off and how long a full battery would last at that pace, each app's share, and what kept the phone awake, explained in plain words), the real processor load, graphics load, processor/graphics/surface temperatures, and the battery's wear, charge cycles and dates where the phone keeps them
  • ADB permissions, a third extended access switch for a phone with neither Shizuku nor root, off by default: with three permissions granted once from a computer (adb shell pm grant; the switch shows the commands and names any still missing) the app itself reads Android's battery statistics, the privacy log, the processor/graphics/surface temperatures and, from Android 14, the battery's health and its manufacture and first-use dates. The grants last over restarts and updates and no separate app or service has to run. Android gives an app's own user neither the real processor load nor the graphics load whatever it is granted, so those stay with Shizuku and root
  • Kernel page on rooted phones, opened from the Device tab's KERNEL band: each group of processor cores with its speed now, its limit and range, heat throttling in plain words, the graphics processor's speeds, compressed memory (zRAM), the kernel version, SELinux and the storage queue, and every named temperature sensor, all from what this phone's kernel reports, with no phone model assumed
  • Processor profiles on rooted phones: Power saving (the faster cores at most about 60 % of their top speed), Balanced (about 80 %), Stock, or Custom per group of cores. Only speeds the kernel lists, never above what the phone allows; the phone's own limits are saved first and written back on Stock or when root is switched off (if root no longer answers then, they last until the next restart), and a restart returns them by itself unless Apply after restart too is on. When Android's power management raises a limit the monitor sets it again and counts it, and it never lifts a lower limit that heat or Android hold
  • Privacy log with extended access (Shizuku, root or ADB permissions), on the Apps tab's PRIVACY band and its page: Android's own record of which apps used the camera, the microphone and the location, when, for how long, from the background or not, and (on Android 17, which keeps them) which were refused, app by app and moment by moment; the same record the system's Privacy dashboard draws on, shown and never stored. Without extended access the band offers Android's own Privacy dashboard instead
  • System apps page with extended access (Shizuku or root), opened from the Apps tab's SYSTEM APPS band: every app on the system image, with a search, and Remove for the preinstalled ones you do not use. A removal takes the app away from this user only (pm uninstall --user), the system image's copy stays, and Restore brings it back; every removal is asked about first, the apps the phone depends on say what breaks and want that acknowledged, and the ones it cannot do without (Android's core, the home screen, keyboard, phone app and web view in use, Device-Watch itself) cannot be removed from here at all
  • Sleep section on the Kernel page (root): the kernel's own count of sleep attempts and failures with what stopped the last one, the wakeup sources that woke the phone most often, those that held it awake longest, and those holding it right now, in plain words with the kernel's names underneath
  • Today's screen time also appears in the widget footer, refreshed at most once a minute so the 5-second widget loop stays untouched
  • Most-opened-today list on the Apps tab, and last-opened rows show the clock time for apps used today (following the system 12/24-hour setting) with two-tier staleness colors: amber after 1 month unused, red after 3 months (Google's app-hibernation threshold) or never used
  • Special-access buttons show a green/red status dot for granted/missing access
  • Active data-SIM carrier shown next to the mobile network name on dual-SIM devices
  • Interactive Android screensaver with a large clock, date, next alarm, charging status, battery percentage, voltage, temperature, and live charging power in watts
  • Screensaver clock follows the device 12/24-hour setting, with a second-aligned tick
  • Six screensaver styles to choose from in Settings, each with a thumbnail drawn by the screensaver's own code: Glow (the original look, and the default), Minimal, Ring, Gauges, Night and Edge; every style works upright, on its side and flipped upside down
  • Glow: a battery-level-tinted background gradient and a softly pulsing charge indicator
  • Edge: the battery level as a bright line round the screen's edge, running from red to green with the level, its head pulsing while the battery charges; against burn-in the line changes place once a minute and dims after ten minutes without a change
  • Night: the clock, the next alarm and the battery in dim red on black, and an option to switch to it automatically for the night-dim hours
  • Gauges: monospaced figures on named rows, and optionally the next three calendar events (off by default; the calendar permission is asked for only when you switch the rows on, and the titles can be hidden)
  • Switches for what the screensaver shows (device name, seconds, date, next alarm, notification icons, battery details, time to full) and five accent colours for the seconds
  • Optional screensaver dimming: manual, or automatic on a configurable night schedule (default 22:00–07:00)
  • OLED burn-in protection: the screensaver content glides to a new spot within 15 dp once a minute, or, as a setting, only up and down within 20 dp so it stays centred sideways
  • The phone's name (Android's device name, tidied and shortened, e.g. "Pixel 10 Pro") on a small line above the screensaver clock; can be turned off
  • Optional start as soon as charging begins with the screen off, even with Always On Display on: at once through the dream manager with Shizuku or root, otherwise by waking the screen so the lock screen times out into the screensaver; nothing happens while the screen is on, and Android's own screensaver choice and "when to start" are respected
  • Icons of unread notifications under the screensaver clock (one per app, with a count), pulsing when a new one arrives; needs notification access and can be turned off in Settings
  • Own brightness in Settings: a slider sets the screensaver's brightness for every style instead of following the phone's, and the settings page shows the level while the slider moves; it is not in force while the screensaver is dimmed
  • Flip upside down in Settings for a stand that holds the phone upside down; the choice is remembered, and Glow's gradient and Edge's line turn with it
  • Battery full notification while the screensaver is active
  • English default resources with Finnish, Simplified Chinese and Arabic translations. Numbers are written with the digits 0–9 in every language, and in Arabic the app is laid out from the right, with charts, the screensaver's clock and figures such as 5.1 / 7.6 GB kept left to right
  • Runtime permission handling for location, phone state, nearby Wi-Fi devices, and notifications
  • Usage Access shortcut for network and app-usage statistics
  • Release build configured with R8 minification and resource shrinking

Every metric is real data read from Android and kernel sources. When a value is not available with the permissions granted, the UI shows a dash (—) instead of a fabricated value.

Android backup and phone transfer carry user settings only. History, notification texts and delivered-alert flags stay on the device; a new phone can show its own first alerts. Exports leave the app only when you choose to share them.

Download

Get it on F-Droid Download from Aptoide Get it on Obtainium

Device-Watch is available on F-Droid, which also delivers updates automatically, and on Aptoide, which also offers a direct APK download. Obtainium can follow the GitHub releases and install each new version: tap the badge above on your phone, or add https://github.com/jrs8205/Device-Watch in Obtainium. Alternatively, download the latest signed APK from the Releases page, or from its mirror on SourceForge, and open it on your device to install. Releases are built reproducibly and F-Droid verifies each build against the developer-signed APK, so every source ships an APK signed with the same key and later versions install cleanly as an update over an existing one — from any source.

Registered with Google. The package name and signing key are registered in Google's Android Developer Console, so the app keeps installing as usual under Google's new sideloading rules.

Upgrading from v1.3.1 or older: the application ID changed in v1.4.0 from com.example.modernwidget to org.jarsi.devicewatch, so Android treats it as a new app. Install the new version, re-grant its permissions, re-add the widget and re-select the screensaver, then uninstall the old one. Collected usage history starts fresh.

Requires Android 8.0 (API 26) or newer.

Troubleshooting

Common questions — the screensaver not starting, mobile data showing zero, notification counts, history retention — are answered in the FAQ.

Architecture

The app follows an MVVM + repository structure with Hilt dependency injection.

presentation/   DashboardViewModel, AppsViewModel, HistoryViewModel, SinceChargeViewModel
                and LiveTrafficViewModel (StateFlow UI state); CsvExporter,
                HtmlReportBuilder and PeriodComparison behind the History page
presentation/ui Compose-only screen code: SystemDashboardScreen scaffold with a
                Material 3 NavigationBar, Home/Apps/Device/Settings tabs, the
                History and Since-charge pages, the first-run intro, BatteryChart,
                LiveTrafficMeter and shared components (SettingsSectionCard,
                DeviceInfoRow, AppIcon, ScreenTimeDonut, AppDetailSheet, MetricText)
ui/theme/       The two looks (high-contrast and classic) as full Material 3 schemes
data/           SystemStatsRepository + AppUsageRepository (per-app usage, on demand)
                AppSettingsRepository (data-counter mode, cycle start day, alert switches)
                NotificationStats, UsageHistory, BatteryHistory (own tallies: 62-day
                daily history, 14-day battery log, charge sessions)
                SystemStatsParser, DataPeriodCalculator, UsageEventAggregator,
                NotificationCounting, ChargeSessions, AlertLogic, DataQuotaLogic,
                Camera/Audio/AppPackage logic (pure, unit-tested calculations)
                SystemStats / AppUsage / DeviceInfo models (+ UNAVAILABLE_* sentinels)
quick/          QuickMetricFormatter (the eight quick figures as text), QuickStatsSource
                (one shared reading for tiles opened together, today's data from
                midnight), the Quick Settings tiles and the figure drawn as their icon
widget/         Glance DashboardWidget, CompactWidget and SingleMetricWidget (with its
                configuration activity), WidgetStateUpdater (DataStore
                writes), WidgetController (port the ViewModel talks to), receivers,
                actions, and the font cap and the fit to the widget's height
                (WidgetTextScale)
system/         SystemMonitorService (foreground) with the charge-limit, data-quota and
                health-alert notifiers and its own notification in two forms
                (MonitorNotifications, LiveNotificationController), MonitorDreamService (screensaver) with
                DreamNotifications, NotificationCounterService (notification listener)
di/             Hilt modules and entry points
  • SystemStatsRepositoryImpl is the single source of truth. It is a @Singleton, reads system/kernel sources off the main thread on an injected dispatcher, and serializes its CPU-load snapshots with a Mutex.
  • SystemDashboardScreen observes the ViewModels with collectAsStateWithLifecycle() and obtains them via hiltViewModel(). The four tabs are pages of a HorizontalPager whose state is the single source of truth for the selected tab — swiping and the bottom bar both drive it (no navigation library); each page keeps its own scroll position. Permission requests and the foreground-service start stay at screen level.
  • Services and the widget receiver use @AndroidEntryPoint; the Glance ActionCallback reaches the graph through a Hilt EntryPoint.

Tech Stack

  • Kotlin 2.4, AGP 9.2.1, Gradle 9.6
  • compileSdk 36, minSdk 26, targetSdk 35
  • Jetpack Compose (BOM 2026.06.00) + Material 3, Jetpack Glance 1.1.1
  • Hilt 2.60 with KSP 2.3.9
  • AndroidX Lifecycle 2.10, Activity 1.13, DataStore 1.2, WorkManager 2.11
  • Dependencies are managed through the gradle/libs.versions.toml version catalog

Language Behavior

Android selects the UI language from resource qualifiers:

  • English and every device language without a translation use app/src/main/res/values/strings.xml
  • Finnish devices use values-fi, Simplified Chinese ones values-zh-rCN and Arabic ones values-ar
  • From Android 13 the app is on Android's own per-app language page (Settings → System → Languages → App languages), where it can be set to any of its four languages whatever the device language; the languages offered are listed in app/src/main/res/xml/locales_config.xml
  • Numbers are written with the digits 0–9 whatever the language (LatinDigits.kt), unless a numbering system has been chosen for the language in Android's own settings. A phone set to Arabic (Egypt) or Persian would otherwise print some figures with its own digits and others with 0–9 on the same screen
  • A translation must have the shape of the English texts: the same keys, the same format arguments, and the plural forms its language needs (six in Arabic). TranslationsTest checks every values-* folder

Permissions

The app requests only permissions that are used by the current feature set:

  • RECEIVE_BOOT_COMPLETED
  • FOREGROUND_SERVICE
  • FOREGROUND_SERVICE_SPECIAL_USE
  • POST_NOTIFICATIONS
  • ACCESS_NETWORK_STATE
  • ACCESS_WIFI_STATE
  • ACCESS_COARSE_LOCATION
  • ACCESS_FINE_LOCATION
  • NEARBY_WIFI_DEVICES
  • READ_PHONE_STATE
  • PACKAGE_USAGE_STATS
  • DUMP and BATTERY_STATS (development permissions: no dialog on the phone grants them, only adb shell pm grant from a computer, and without that they do nothing. Granted, along with PACKAGE_USAGE_STATS granted the same way, they are what the ADB permissions switch reads with)
  • QUERY_ALL_PACKAGES (resolve names/icons for the per-app data list; the app is distributed outside Google Play)
  • REQUEST_DELETE_PACKAGES (uninstall from the last-opened list via the system dialog)
  • WAKE_LOCK (a normal permission, granted on install; WorkManager declares it for its own jobs, and the app's own code uses it only to wake the screen when charging begins, so the screensaver can start, when Start as soon as charging begins is switched on)
  • USE_BIOMETRIC (a normal permission, granted on install: only to show on the Device tab whether a strong biometric is enrolled — the app never authenticates anyone)
  • READ_CALENDAR (asked for only when you switch on the calendar rows of the screensaver's Gauges style: the next events' times and, unless you hide them, titles are read and drawn on the screensaver — nothing is written to the calendar and nothing is stored)
  • moe.shizuku.manager.permission.API_V23 (declared by the Shizuku library; it does nothing unless you install Shizuku yourself, switch Shizuku on in Settings and approve Device-Watch in Shizuku's own dialog)

Root mode needs no permission: it is off by default, and the app starts su only after you switch it on and your root manager grants it. Through root alone, a processor profile you choose on the Kernel page writes each group of cores' top speed limit; nothing else is written.

Notification counting additionally uses the optional Notification access special permission (a NotificationListenerService); counting starts when access is granted. Do Not Disturb and Bluetooth control permissions are not requested.

Building

Use the Gradle wrapper from the repository root:

.\gradlew.bat :app:compileDebugKotlin
.\gradlew.bat :app:testDebugUnitTest
.\gradlew.bat :app:lintDebug
.\gradlew.bat :app:assembleDebug
.\gradlew.bat :app:assembleRelease

Release builds are minified with R8 and resource shrinking. The release APK is unsigned unless a local keystore.properties and keystore are present.

Testing

1739 JVM unit tests (JUnit 4 + Truth; Robolectric only for the Glance render, notification, backup-rule, settings-store, floating-card window and screensaver screen, settings, calendar, settings-link, language and right-to-left tests) cover the logic behind every screen, service and widget:

.\gradlew.bat :app:testDebugUnitTest
  • Parsing and maths — SystemStatsParserTest, CpuWindowTest, DataPeriodCalculatorTest, UsageEventAggregatorTest, ExtraStatsLogicTest, AppPackageLogicTest, CameraLogicTest, AudioLogicTest, TrafficMeterTest, DefaultDensityTest (when Android's default density can be trusted)
  • Extended access (Shizuku, root and ADB permissions) — ShellSessionTest (the shell conversation, driven through a real sh; on Windows through Git's), PrivilegedShellTest, LocalShellTest (the app's own shell on the adb route: nothing started without the grant, a grant found gone), AdbGrantsTest, ExtendedAccessGateTest (which pages each route opens), AdbAccessRowTest, UsageAccessTest (usage access by the switch or by the permission), BatteryStatsDumpParserTest, PrivilegedDumpParsersTest (parsers written against dumps from real phones), AppOpsHistoryParserTest (Android's privacy record in both the table Android 17 prints and the tree of Android 12–16, against a Pixel 8a and API 34 and 36 emulators), PrivacyLogBuilderTest, ShellPrivacyLogSourceTest, PrivacyPresentationTest, PrivacyViewModelTest, LocationGatedReadsTest (why the app no longer appears in its own log), SystemAppRulesTest (which system apps are blocked or warned about), SystemAppCommandsTest, SystemAppsViewModelTest (the removal question, the acknowledgement, one action at a time)
  • Kernel page and processor profiles (root) — KernelSysfsParserTest (against a full read from a Pixel 8a), KernelSnapshotTest, KernelCommandsTest, RootOnlyShellTest, KernelSnapshotSourceTest, CpuProfilePlannerTest, CpuProfileRulesTest, CpuProfileStoreTest, CpuLimitWriterTest, CpuProfileControllerTest (over FakeSysfsRoot, a pretend cpufreq tree with the kernel's frequency QoS, Android's power HAL, heat and switched-off cores), KernelRootOnlyGuardTest, KernelPresentationTest, KernelViewModelTest, WakeReadTest (the sleep section's command, parser and root gate against a Pixel 8a's wakeup sources), WakePresentationTest, KernelViewModelWakeTest
  • Own history and stores — UsageHistoryLogicTest, UsageHistoryImplTest, NotificationCountingTest, NotificationLogCodecTest, NotificationLogImplTest, BatteryHistoryCodecTest, BatteryHistoryImplTest, ChargeSessionsTest, ChargeAnchorLogicTest, AppSettingsRepositoryImplTest, DeviceLocalFlagsTest, AlertStateBackupTest, BackupRulesTest
  • Alerts and notifications — AlertLogicTest, DataQuotaLogicTest, DataQuotaSettingsChangeTest, ChargeLimitLogicTest, HealthAlertControllerTest, NotificationDeliveryTest, LiveNotificationTest (the two lines, and when the live figures are posted again), LiveNotificationControllerTest (readings and changes of choice take turns), MonitorNotificationsTest (the expanded view, the channels, a blocked channel)
  • Quick figures — QuickMetricTest, QuickMetricFormatterTest (each figure, in Finnish and English), QuickMetricLabelsTest, QuickStatsSourceTest (tiles opened together share one read), QuickTileAppearanceTest, QuickTileIconTest
  • ViewModels and exports — DashboardViewModelTest, AppsViewModelTest, HistoryViewModelTest, SinceChargeViewModelTest, LiveTrafficViewModelTest, PeriodComparisonTest, CsvExporterTest, HtmlReportBuilderTest, ReportPaletteTest (hand-written fakes in Fakes.kt)
  • UI logic — HistoryListLogicTest, SinceChargeNoticesTest, BatteryChartLogicTest, LabelValueRowTest, AppScaleTest, AppPaletteTest (the WCAG AAA contrast of both looks)
  • Widgets — WidgetFormattingTest, WidgetTextScaleTest (sizes in plain dp, the fit to the widget's height), CompactFitTest (text fitting, the floor for names and the ellipsis), CompactUptimeTest, CompactWidgetRenderTest, SingleMetricWidgetRenderTest
  • Screensaver — ClockFitTest, DreamLogicTest (night-dim window, charging watts), DreamNotificationLogicTest (which notifications show, grouping, arrivals, row fit), ActiveNotificationsStoreTest, BurnInShiftTest, DeviceNameTest (tidying, shortening, model codes left out), ChargeStartLogicTest (when charging starts the screensaver, and how), ChargeStartCommandTest (the start command's own check of the screen, through a real sh), DreamStyleTest and DreamOptionsTest (what each style can show, the settings read once, the brightness scale), DreamUiStateTest, DreamScreenTest and DreamStyleFitTest (every style drawn, and fitted at its narrowest), EdgeGeometryTest and EdgePathTest (the Edge line's route, colours, lanes and rest), DreamCalendarTest and DreamCalendarReaderTest (which events are listed), DreamWindowTest (wide colour and brightness reaching the window), ScreensaverSettingsTest (each control writes its key)
  • Ways in from Android's own pages — SystemSettingsLinksTest (what the manifest, the screensaver and the widgets declare, and which part of the settings each start asks for), MainActivitySettingsLinkTest (the request read from a real start, and kept across a recreation of the screen), SettingsSectionScrollTest (the Settings tab bringing a section to the top, and letting go once the user scrolls), WidgetSettingsLinkActivityTest, DashboardWidgetReceiverTest (the broadcasts that start the monitor) and AppLanguagesTest (the language list against the resource folders)
  • Languages — TranslationsTest (every translation against the English texts: keys, format arguments, plural forms, no Arabic-Indic digits), AppNameTest (the name's spelling in the texts, the documents and the store listing), LatinDigitsTest (the digits 0–9 from the application, the two screens, every service that shows text and the screensaver after a rotation), BidiTest and ValueDirectionTest (figures and values kept whole in a language written from the right), LabelValueRowRtlTest, MirroredIconsTest, DurationTextTest, WidgetClockTextTest, DreamClockPatternsTest (12-hour times as the language writes them) and GlowStyleTest

Build Outputs

app/build/outputs/apk/debug/app-debug.apk
app/build/outputs/apk/release/app-release.apk

APK and signing files are intentionally ignored by Git.

Project Structure

app/src/main/java/org/jarsi/devicewatch/
  Bidi.kt       (figures kept left to right in a language written from the right)
  LatinDigits.kt (the digits 0–9 in every language)
  MainActivity.kt
  MonitorApp.kt
  data/
    AdbGrants.kt
    AlertLogic.kt
    AppOpsHistory.kt
    AppOpsHistoryParser.kt
    AppPackageLogic.kt
    AppSettingsRepository.kt
    AppSettingsRepositoryImpl.kt
    AppUsage.kt
    AppUsageRepository.kt
    AppUsageRepositoryImpl.kt
    AppVisibility.kt
    AudioLogic.kt
    BatteryHistory.kt
    BatteryHistoryImpl.kt
    BatteryStatusReader.kt
    BatteryUsage.kt
    CameraLogic.kt
    ChargeAnchor.kt
    ChargeAnchorStoreImpl.kt
    ChargeSessions.kt
    CpuLimitWriter.kt
    CpuProfilePlanner.kt
    CpuProfileRules.kt
    CpuProfileStore.kt
    CpuProfiles.kt
    DataPeriod.kt
    DataQuotaLogic.kt
    DeviceInfo.kt
    DeviceLocalFlags.kt
    DeviceState.kt
    ExtraStatsLogic.kt
    KernelCommands.kt
    KernelSnapshot.kt
    KernelSnapshotSource.kt
    KernelSysfsParser.kt
    LocalShell.kt
    LocationGatedReads.kt
    NotificationCounting.kt
    NotificationLog.kt
    NotificationLogImpl.kt
    NotificationStats.kt
    NotificationStatsImpl.kt
    PrivacyLog.kt
    PrivacyLogSource.kt
    PrivilegedDumpParsers.kt
    PrivilegedShell.kt
    SystemAppCommands.kt
    SystemApps.kt
    SystemAppsRepository.kt
    RootCommandShell.kt
    RootShell.kt
    ShellBatteryUsageSource.kt
    ShellUserService.kt
    ShizukuShell.kt
    SystemStats.kt
    SystemStatsParser.kt
    SystemStatsRepository.kt
    SystemStatsRepositoryImpl.kt
    TrafficMeter.kt
    UsageEventAggregator.kt
    UsageHistory.kt
    UsageHistoryImpl.kt
    WakeSnapshot.kt
  di/
    DispatchersModule.kt
    RepositoryEntryPoint.kt
    RepositoryModule.kt
  presentation/
    AppsViewModel.kt
    CsvExporter.kt
    DashboardViewModel.kt
    HistoryCoverage.kt
    HistoryViewModel.kt
    HtmlReportBuilder.kt
    KernelPresentation.kt
    KernelViewModel.kt
    LiveTrafficViewModel.kt
    PeriodComparison.kt
    PrivacyPresentation.kt
    PrivacyViewModel.kt
    SinceChargeViewModel.kt
    SystemAppsViewModel.kt
    WakePresentation.kt
    ui/
      AppDetailSheet.kt
      AppScale.kt
      AppsTab.kt
      BatteryChart.kt
      BatteryChartLogic.kt
      BatteryUsageCards.kt
      DashboardComponents.kt
      DashboardTabs.kt
      DeviceTab.kt
      Haptics.kt
      HistoryListLogic.kt
      HistoryPage.kt
      KernelBand.kt
      KernelPage.kt
      KernelSleepSection.kt
      LiveTrafficMeter.kt
      MetricText.kt
      OnboardingPage.kt
      OverviewTab.kt
      PrivacyBand.kt
      PrivacyDashboardIntent.kt
      PrivacyPage.kt
      ScreenTimeDonut.kt
      SettingsTab.kt
      SystemAppsBand.kt
      SystemAppsPage.kt
      SinceChargeNotices.kt
      SinceChargePage.kt
  system/
    AlertNotifications.kt
    BatteryFullNotifier.kt
    ChargeLimitLogic.kt
    ChargeLimitNotifier.kt
    DataQuotaNotifier.kt
    DreamNotifications.kt
    DreamPreferences.kt
    HealthAlertController.kt
    HealthAlertNotifier.kt
    MonitorDreamService.kt
    MonitorServiceRelay.kt
    NotificationCounterService.kt
    NotificationDelivery.kt
    SystemMonitorService.kt
  ui/
    theme/
      Color.kt
      Theme.kt
  widget/
    CompactWidget.kt
    DashboardWidget.kt
    DashboardWidgetReceiver.kt
    RefreshStatsAction.kt
    WidgetController.kt
    WidgetStateUpdater.kt
    WidgetTextScale.kt

app/src/test/java/org/jarsi/devicewatch/
  data/
    AlertLogicTest.kt
    AlertStateBackupTest.kt
    AppOpsFixtures.kt
    AppOpsHistoryParserTest.kt
    AppPackageLogicTest.kt
    AppSettingsRepositoryImplTest.kt
    AudioLogicTest.kt
    BackupRulesTest.kt
    BatteryHistoryCodecTest.kt
    BatteryHistoryImplTest.kt
    BatteryStatsDumpParserTest.kt
    CameraLogicTest.kt
    ChargeAnchorLogicTest.kt
    ChargeSessionsTest.kt
    CpuLimitWriterTest.kt
    CpuProfileControllerTest.kt
    CpuProfilePlannerTest.kt
    CpuProfileRulesTest.kt
    CpuProfileStoreTest.kt
    CpuWindowTest.kt
    DataPeriodCalculatorTest.kt
    DataQuotaLogicTest.kt
    DeviceLocalFlagsTest.kt
    ExtraStatsLogicTest.kt
    FakeSysfsRoot.kt
    KernelCommandsTest.kt
    KernelFixtures.kt
    KernelRootOnlyGuardTest.kt
    KernelSnapshotSourceTest.kt
    KernelSnapshotTest.kt
    KernelSysfsParserTest.kt
    LocationGatedReadsTest.kt
    NotificationCountingTest.kt
    NotificationLogCodecTest.kt
    NotificationLogImplTest.kt
    PrivacyLogBuilderTest.kt
    PrivilegedDumpParsersTest.kt
    PrivilegedShellTest.kt
    SystemAppCommandsTest.kt
    SystemAppRulesTest.kt
    RootOnlyShellTest.kt
    ShellPrivacyLogSourceTest.kt
    ShellSessionTest.kt
    SystemStatsParserTest.kt
    TrafficMeterTest.kt
    UsageEventAggregatorTest.kt
    UsageHistoryImplTest.kt
    UsageHistoryLogicTest.kt
    WakeFixtures.kt
    WakeReadTest.kt
  presentation/
    AppsViewModelTest.kt
    CsvExporterTest.kt
    DashboardViewModelTest.kt
    Fakes.kt
    HistoryViewModelTest.kt
    HtmlReportBuilderTest.kt
    KernelPresentationTest.kt
    KernelViewModelTest.kt
    KernelViewModelWakeTest.kt
    LiveTrafficViewModelTest.kt
    PeriodComparisonTest.kt
    PrivacyPresentationTest.kt
    PrivacyViewModelTest.kt
    ReportPaletteTest.kt
    SinceChargeViewModelTest.kt
    SystemAppsViewModelTest.kt
    WakePresentationTest.kt
    ui/
      AppScaleTest.kt
      BatteryChartLogicTest.kt
      HistoryListLogicTest.kt
      LabelValueRowTest.kt
      SinceChargeNoticesTest.kt
  system/
    ActiveNotificationsStoreTest.kt
    ChargeLimitLogicTest.kt
    ClockFitTest.kt
    DataQuotaSettingsChangeTest.kt
    DreamLogicTest.kt
    DreamNotificationLogicTest.kt
    HealthAlertControllerTest.kt
    NotificationDeliveryTest.kt
  ui/
    theme/
      AppPaletteTest.kt
  widget/
    CompactFitTest.kt
    CompactUptimeTest.kt
    CompactWidgetRenderTest.kt
    WidgetFormattingTest.kt
    WidgetTextScaleTest.kt

Support development

If Device-Watch is useful to you, you can support its development:

License

Device-Watch is free software, licensed under the GNU General Public License, version 3 of the License, or (at your option) any later version (SPDX: GPL-3.0-or-later). See LICENSE for the full text.

Close

How Shizuku is used

Can show battery use, privacy history, thermals, battery health, CPU/GPU load, manage system apps and start charging screensaver via `dumpsys`, `pm` and `settings get` through Shizuku.

This is an AI-assisted analysis of Shizuku-related usages in the app's public source code. It is best effort, so it may not catch every single usage.

How this app uses Shizuku

Shizuku provides an optional privileged shell that unlocks readings and actions an ordinary app cannot perform.

  • Battery usage details: shows per app power use and wake activity since last charge using the dumpsys batterystats --charged dump through Shizuku.
  • Privacy access history: shows when apps used location, camera, microphone and other private data using the dumpsys appops --history record through Shizuku.
  • Temperature readings: shows CPU, GPU and skin temperatures from the thermal service dump and thermal zone readings through Shizuku.
  • Battery health info: shows battery health percent, cycle count and first use and manufacturing dates from the battery dump and power supply readings through Shizuku, including Samsung battery figures from the dumpsys battery dump.
  • CPU and GPU load: shows CPU load, frequency pressure and GPU load from processor and graphics driver readings through Shizuku when the app itself is denied access.
  • Developer settings status: shows whether developer options and USB debugging are turned on using system settings reads through Shizuku on versions where the app cannot read them directly.
  • System app management: lists system apps and removes selected ones for the current user or restores them with pm uninstall and pm install-existing commands through Shizuku.
  • Charging screensaver start: starts the charging screensaver right away when charging begins with the screen off by checking screensaver settings and calling the dream manager through Shizuku.

Android APIs or commands used

  • dumpsys batterystats --charged
  • dumpsys appops --history --include-discrete 0
  • dumpsys thermalservice
  • dumpsys battery
  • dumpsys package
  • dumpsys power
  • settings get global development_settings_enabled
  • settings get global adb_enabled
  • settings get secure screensaver_enabled
  • settings get secure screensaver_activate_on_sleep
  • settings get secure screensaver_components
  • service call dreams 1
  • input keyevent KEYCODE_WAKEUP
  • pm uninstall --user
  • pm install-existing --user
  • cat /sys/class/thermal/thermal_zone*/temp
  • cat /sys/class/power_supply/battery/first_usage_date
  • cat /sys/class/power_supply/battery/manufacturing_date
  • cat /sys/class/power_supply/battery/charge_full
  • cat /sys/class/power_supply/battery/charge_full_design
  • cat /sys/class/power_supply/battery/cycle_count
  • cat /proc/stat
  • cat /sys/devices/system/cpu/cpu*/cpufreq/stats/time_in_state
  • cat /sys/devices/system/cpu/cpu*/cpufreq/scaling_cur_freq
  • cat /sys/devices/system/cpu/cpu*/cpufreq/scaling_max_freq
  • cat /sys/class/kgsl/kgsl-3d0/gpu_busy_percentage
  • cat /sys/kernel/gpu/gpu_busy
  • cat /sys/class/misc/mali0/device/utilization

Notable details

Without Shizuku the app tries the same files directly and shows unavailable when denied, so Shizuku only fills in readings that are otherwise hidden. All privileged reads use fixed commands, there is no free form command input. The detailed kernel page and processor speed limit controls need root and are not available through Shizuku. Without privileged access the charging screensaver falls back to briefly waking the screen so the system timeout can start it.

Close

Changelog

What's new for version 1.14.0

What's changed

  • Two new languages: Simplified Chinese and Arabic. The Simplified Chinese translation is by WOchovy233 (#8). In Arabic the app is laid out from right to left, with charts, the screensaver's clock and figures such as 5.1 / 7.6 GB kept left to right. From Android 13 either can be chosen for this app alone on Android's per-app language page.
  • Numbers are written with the digits 0–9 in every language. If a numbering system has been chosen for the language in Android's own settings, the numbers Android formats follow it, so two kinds of digits can then show.
  • ADB permissions: extended access without Shizuku or root. A third extended access switch, off by default. With three permissions granted once from a computer (adb shell pm grant; the switch shows the commands and names any still missing) the app reads Android's battery statistics, the privacy log, the processor, graphics and surface temperatures and, from Android 14, the battery's health and its manufacture and first-use dates. The grants last over restarts and updates, and no separate app or service has to run. Android does not give the real processor load or the graphics load this way, so those stay with Shizuku and root (#10).
  • The Ring screensaver style also shows the time to full charge, the next alarm and the device name. They are on at once if you use Ring; each has its switch under the styles in Settings (#11).
  • Coloured Quick Settings tiles. A new setting, off by default: a tile that has a reading takes the colour of a tile that is switched on. Tapping it still opens the app (#11).
  • The app's name is written Device-Watch everywhere; in Finnish it stays Laitevahti.

More in the FAQ and the privacy policy.

Installing

Updates cleanly over v1.4.x and later. If you are coming from v1.3.1 or older (package com.example.modernwidget), uninstall the old app first — it is a different package and will not update.

APK SHA-256: 1f2464d1b6db1bb83d9e39eff309ee6a5c1ce57a651a5ec513aa2df4753b6981 Signing cert SHA-256: a787d3be1fa4d58751e246dba9b8f1ded5b6a00ab2675367bf49420928e1a51a

Close

Permissions

21 permissions requested

  • android.permission.RECEIVE_BOOT_COMPLETED
  • android.permission.FOREGROUND_SERVICE
  • android.permission.WAKE_LOCK
  • android.permission.FOREGROUND_SERVICE_SPECIAL_USE
  • android.permission.POST_NOTIFICATIONS
  • android.permission.ACCESS_NETWORK_STATE
  • android.permission.ACCESS_WIFI_STATE
  • android.permission.ACCESS_COARSE_LOCATION
  • android.permission.ACCESS_FINE_LOCATION
  • android.permission.NEARBY_WIFI_DEVICES
  • android.permission.READ_PHONE_STATE
  • android.permission.PACKAGE_USAGE_STATS
  • android.permission.DUMP
  • android.permission.BATTERY_STATS
  • android.permission.QUERY_ALL_PACKAGES
  • android.permission.REQUEST_DELETE_PACKAGES
  • android.permission.USE_BIOMETRIC
  • android.permission.SYSTEM_ALERT_WINDOW
  • android.permission.READ_CALENDAR
  • org.jarsi.devicewatch.DYNAMIC_RECEIVER_NOT_EXPORTED_PERMISSION
  • moe.shizuku.manager.permission.API_V23
Close