Skip to content

feat(gui): add System temperature to Dashboard monitor - #252

Open
ryann-g wants to merge 1 commit into
PXDiv:mainfrom
ryann-g:feat/system-temperature-monitor
Open

feat(gui): add System temperature to Dashboard monitor#252
ryann-g wants to merge 1 commit into
PXDiv:mainfrom
ryann-g:feat/system-temperature-monitor

Conversation

@ryann-g

@ryann-g ryann-g commented Aug 23, 2026

Copy link
Copy Markdown

Summary

Adds a third System temperature reading (EC / board sensor) to the Dashboard's Temperature Monitor, alongside the existing CPU and GPU readings.

The linuwu_sense driver already registers an acer hwmon device exposing three temperature channels (src/linuwu_sense.c, acer_wmi_temp_channel_to_sensor_id[]):

Channel Sensor Currently shown by DAMX
temp1_input ACER_WMID_SENSOR_CPU_TEMPERATURE
temp2_input ACER_WMID_SENSOR_GPU_TEMPERATURE
temp3_input ACER_WMID_SENSOR_EXTERNAL_TEMPERATURE_2 ❌ (new)

This PR surfaces that third, independent EC-reported sensor in the GUI. It is not derived from CPU/GPU values and requires no driver or daemon changes.

Motivation

Users currently have no visibility into chassis/board temperature. The EC already reports it; the GUI simply never displayed it.

Changes

  • Dashboard.axaml.cs
    • New FindSystemTempPath() — locates the acer hwmon device by scanning /sys/class/hwmon/*/name and reading temp3_input. Discovery is name-based rather than index-based, since hwmon numbering varies between boots/kernels.
    • Fallback chain: acer temp3_input → first non-CPU/GPU ACPI thermal zone → sensors acpitz regex (mirrors existing fallback style).
    • New GetSystemTemperature() following the same error-handling pattern as GetCpuTemperature().
    • Third LineSeries ("System Temperature", orange) on the Temperature Monitor chart + history buffer capped at MAX_HISTORY_POINTS.
    • MetricsData.SystemTemp wired through the existing refresh pipeline.
  • Dashboard.axaml
    • Live CPU: x°C · GPU: x°C · System: x°C readout row inside the Temperature Monitor card.

Testing

Tested on Acer Nitro ANV15-41 (AMD Ryzen 5 7535HS + RTX 2050), Zorin OS 18.1, kernel 7.0.0-30-generic:

  • dotnet build -c Release: 0 errors; no new functional warnings (the single added CS8618 matches the file's existing nullable-field pattern for _cpuTempHistory etc.)
  • ✅ Discovery log at runtime:
    Found System Temperature at /sys/class/hwmon/hwmon4/temp3_input
    
  • ✅ GUI readout matched sysfs live (temp3_input = 52000 m°C → displayed 52 °C), tracked across refresh cycles
  • ✅ Chart renders three series; readout row renders above it
  • ✅ Verified alongside the installed production DAMX instance running simultaneously — no interference (GUI-only change, read-only /sys access)

Screenshots

Sandbox build (left) vs installed release (right):

Sandbox build (with this PR) Installed release (before)
Temperature Monitor shows CPU · GPU · System readout row and third chart series Original two-sensor layout

Checklist

  • Build passes (Release)
  • Tested on real hardware (ANV15-41)
  • No changes to driver, daemon, or installer
  • Follows existing code style (discovery caching in _systemInfoPaths, Console.WriteLine logging, RunCommand fallback)
  • Tested on Intel-based Nitro/Predator models (would appreciate maintainer/maintainer-community verification)

Surface the third EC thermal sensor (ACER_WMID_SENSOR_EXTERNAL_TEMPERATURE_2)
that linuwu_sense already exposes via its hwmon interface, which the GUI
previously ignored.

- Discover the acer hwmon device by scanning /sys/class/hwmon/*/name
  instead of hardcoding indices, then read temp3_input
- Fall back to a non-CPU/GPU ACPI thermal zone when the sensor is absent,
  then to lm-sensors acpitz parsing
- Add a third "System Temperature" series to the Temperature Monitor chart
- Add a live CPU / GPU / System readout row above the chart

No daemon or driver changes are required.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant