Skip to content

params: detect sensor availability for "full" overlay preset#1837

Open
matte-schwartz wants to merge 2 commits into
flightlessmango:masterfrom
matte-schwartz:matts/z2e
Open

params: detect sensor availability for "full" overlay preset#1837
matte-schwartz wants to merge 2 commits into
flightlessmango:masterfrom
matte-schwartz:matts/z2e

Conversation

@matte-schwartz

Copy link
Copy Markdown
Contributor

gets rid of the extra unused fields for the Z2E (Strix/890m) similar to the other Z-series chips and Vangogh when using the "full" layout

Before:

image

After:

image

@flightlessmango

Copy link
Copy Markdown
Owner

I wonder if we can figure this out programmatically instead.
If these fields aren't available they should report 0xffff like we check here [src/amdgpu.cpp:L21](https://github.com/flightlessmango/MangoHud/blob/5399bf1a184ce41ff55125e4a24b978392025d24/src/amdgpu.cpp#L73C1-L73C61)

@matte-schwartz

Copy link
Copy Markdown
Contributor Author

that does sound smarter, I think all of them except for gpu_voltage report as 0xffff (gpu_voltage reports as 0). I can try implementing something based off your idea instead.

@flightlessmango

Copy link
Copy Markdown
Owner

Seems safe to assume 0 for voltage also means unavailable

@matte-schwartz

Copy link
Copy Markdown
Contributor Author

sorry, haven't forgotten this. will work on it this week.

Replace the hardcoded handheld device-id list in preset 4 with a per-GPU
check of which sensors are actually reported, so on handhelds information
is only shown when it is actually available on the device. AMD and Intel
report availability via hwmon (a missing node hides the field); AMD voltage
is special-cased since its node exists but reads 0, so it is probed at init.

Also drops the redundant gpu_efficiency=0, already set for all of preset 4.
ram_temp is read from an spd5118 hwmon sensor. With no such sensor, like
on handhelds, mem_temp stays 0 and the "full" layout shows a bogus "0 C".

Track whether a sensor was found and only draw ram_temp when one is, so
a real 0 C reading still shows.
@matte-schwartz

Copy link
Copy Markdown
Contributor Author

reworked this to make it programmatic as suggested, but review would definitely be appreciated here. I've tested this on a few handhelds now (Deck, Go S, Go 2, MSI Claw w/ Lunar Lake) and they seems to work as expected. also found #2070 while working on this, thinking it was my own regression.

@matte-schwartz matte-schwartz changed the title params: add Z2E to known handheld GPUs params: detect sensor availability for "full" overlay preset Jun 8, 2026
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.

2 participants