Closed retrixe closed 1 year ago
This code is fully complete now, tested locally (GPU goes to sleep perfectly fine!) and ready to be merged :tada:
I have tested it good progress. There are 2 issues.
Issue1: Showing warning sign when gpu is sleep. You have already mentioned about the issue. But if you have already figure out a way to display 0degC. Option1 would be to display text instead "OFF". Option2 would be to use if(ExtensionUtils.getSettings().get_string('unit') === 'fahrenheit') adjust the value to compute to 0 instead of -32C
Issue 2: When the extension is installed and enabled for the first time, if the dgpu is in sleep state. There is no nvidia gpu is displayed and there is no way to enable it, to display on the panel menu. I had to manually get the dgpu out of sleep state by running the command nvidia-smi to get the gpu temp displayed on the menu. If you could do something like if nvidia toggle is enabled prevent dgpu from sleeping for 2 minutes or sometime, giving user change to enable it in panel. pretty tricky thoug.
All in all good progress, though. Thanks.
@maniacx thanks for the feedback! I looked into this a bit more, and it turned out to actually be very easy to show N/A
in the menu by setting the temperature to null
.
This should fix both issues that you mention :tada: I think the user experience is perfect now, although testing is still appreciated.
Closes #250
Optional: Show 0° or a previously cached value instead of a warning logo if the GPU was selected? (I don't think this is a good idea to be honest and will require some work in case you opt forShow N/A when an NVIDIA GPU is sleeping.-1
or0
since Fahrenheit <-> Celsius conversion will interfere with it).