Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[GPU] Add missing sensors for mac mini m1 #20

Merged
merged 1 commit into from
Sep 28, 2023

Conversation

enen92
Copy link
Contributor

@enen92 enen92 commented Sep 21, 2023

Hey @narugit,

Hope you're doing well. Unfortunately while doing xbmc/xbmc#23770 I found out the gpu temperature tests are failing on our CI. The CI runs on mac minis (M1 CPU).
Runtime testing it (smctemp -l) I figure out those must be the two sensors reported by TGPro for the GPU (they are even the only ones starting with Tg). Interesting stuff - the OS only seems to report data to those sensors when the GPU is under load (otherwise it reports 0.0). TGPro, when the GPU doesn't have any load reports a static 30.0ºC which also matches the average temperature of the machine (the overall sensors the app has combined). So this pretty much indicates they are also using the same strategy smctemp is doing but simply use a fallback temperature when there's no data.
When the GPU is under load the temperature match the one reported by TGPro pretty close!

@narugit
Copy link
Owner

narugit commented Sep 23, 2023

@enen92
I think the modification itself is good.
However, I am sure there are other sensors that start with Tg, but I would like to know how you were able to determine that these two sensors are needed as a know-how to find effective sensors in the future.

  • Tg4b
  • Tg1b

@enen92
Copy link
Contributor Author

enen92 commented Sep 27, 2023

@enen92 I think the modification itself is good. However, I am sure there are other sensors that start with Tg, but I would like to know how you were able to determine that these two sensors are needed as a know-how to find effective sensors in the future.

  • Tg4b
  • Tg1b

In this specific machine only those 2 sensors are available and start with Tg. The metodology was quite easy: checking against TgPro. By default those sensors have a 0.0ºC temperature while TgPro shows a constant value of 30ºC (which also matches the average machine temperature the app displays). Once you put some load on the GPU (by using gpu benchmark from the app store or simply running https://www.matthew-x83.com/online/gpu-test.php) the values on those two sensors (as well as tgpro) start to increase and having similar values. Since we don't really know the polling time (and it's not easy to keep both in sync) you'll have to watch smctemp for a while. Stopping the test makes the temperatures go down until 0.0 again (and 30 on tgpro)

@narugit
Copy link
Owner

narugit commented Sep 28, 2023

@enen92
Thank you for the clear explanation. The steps you provided are excellent know-how to identify the sensors.

Copy link
Owner

@narugit narugit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@narugit narugit merged commit 0472f16 into narugit:main Sep 28, 2023
2 checks passed
@enen92
Copy link
Contributor Author

enen92 commented Sep 28, 2023

Thanks for the merge @narugit. If not asking for too much mins tagging a new version?
Reason is the Mac mini is precisely the Mac version mostly used for media center applications :)

@narugit
Copy link
Owner

narugit commented Sep 28, 2023

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