
Simple NVidia Info
Source (link to git-repo or to original if based on someone elses unmodified work):
This plasmoid is just a few "nvidia-setting --bla-bla-bla | grep bla". It displays card model, opengl and driver versions, video memory and cuda cores, and the current temperature.
It is a very simple plasmoid, it has no settings whatsoever and it updates the temperature reading every 10 seconds. All other text is red only once, at the startup.
I started to write this based on the code from this plasmoid: http://kde-look.org/content/show.php/Very+simple+CPU+temperature?content=121205 so thanks to the author.
My free time is limited, so I do not have any future plans for this, but if you have some ideas you can leave them here. Who knows? Maybe one day I will be a python programmer.
And one more thing, I know you can see the fan speed with nvidia-settings, but I have a fanless video card, so unless someone writes a patch to have an option to show/hide fan speed, I will not add it.
Version 1.2.1
- Fixed (hopefully) the last cases when the plasmoid shown no temperature
Version 1.2
- Fixed problem with plasmoid not loading after install on some machines. Please leave a comment if it still happens.
- Added a very basic icon.
Version 1.1.1
- I forgot to update the version number in the previous release so it had to be manually removed before update. Now it is updated and should install without problem if you have any of the previous versions already installed.
Version 1.1
- added "GPUCoreTemp" as main sensor for reading temperature
- the old "thermalsensor" property works as a fallback
- if nothing works "N/A" is printed to avoid users seeing error messages
Version 1.0
- initial release
Ratings & Comments
35 Comments
I just reported this bug: https://bugs.kde.org/show_bug.cgi?id=290470 which I think is due to this plasmoid going into a loop.
Can you give more details (I do not really understand the dump for the link you provided). The plasmoid is so simple that it only does a few grep and sed, nothing else. The only looping code is called by a QT::Timer class. If that is causing the problem, than QT Timer is the problem, or the python bindings... self.timer = QtCore.QTimer(); self.timer.setInterval(10000); self.timer.start(10000); QtCore.QObject.connect(self.timer, QtCore.SIGNAL("timeout()"), self._updatelabel)
I don't have any details beyond what I put in the original ticket. I can't really follow the traceback either, but you can see that when the process was pegged and I killed it this plamoid was in the traceback, so it is very likely that the loop was there. I think that's why they closed the ticket, and claimed that the bug was here. Is it possible that the plasmoid somehow got detached from the timer and then looped immediately instead of after a delay? Perhaps you can e-mail one of the plasma devs to get some help interpreting that trace.
Another thought is that the loop might have happened when the plamoid was asked to redraw itself. It was covered up when akregator was running and was then uncovered.
Auto-looping with timer detached: - this is highly unlikely. As far as I understand the timer's working, if it crashes the plasmoid will stop refreshing. Since the timer is the only element that 'generates a loop' periodically, I can see no way to re-run the code outside of the timer. About contacting plasma devs... Unless I will find out about other people reporting this bug also, I will not take further actions. This may very well be an isolated situation in your case. Plus, if you like this plasmoid, version 2, build on Ruby instead of Python is out, so I recommend using that. I decided not to remove this one for those people which can not install ruby-plasma-engine for various reasons and prefer the python version. Unless there is a reproducible (many times in many places) severe bug, I am not planning to further update this version of the plasmoid.
Just wanted to let you know that the plasmoid now runs, which it didn't before. Just out of curiosity...what was the problem? I just got a C instead of the temperature though so I changed the code a little to make it work... I used this in the temp-detection code instead of yours: sensor=commands.getoutput("nvidia-settings -q [gpu:0]/GPUCoreTemp|grep gpu:0|awk -F'):' '{ print $2 }'"); sensor=sensor.replace(".",unichr(176).encode("latin-1")); sensor+="C"; Of course, that takes it for granted that reading the GPUCoreTemp will always work.
Your solution is like mine, it is working for you but may not work for others. You base your logic on the fact that the GPUCoreTemp is available AND that the temperature is in the second column. I intentionally avoided using awk in my code specifically to not rely on the position of a string. As I commented yesterday, I know what the problem is for some who doesn't have temperature but I am pretty busy in these days and will probably release an update in weekend. For those of you who don't want to wait, use "rfind" instead of "find" when you are searching for the end period (".").
I have Mandriva 2010.2 with kde 4.5.4 instead of the temperature i see a C [dglent@localhost ~]$ nvidia-settings -q all | grep -i temp Attribute 'GPUCoreTemp' (localhost.localdomain:0.0): 51. 'GPUCoreTemp' is an integer attribute. 'GPUCoreTemp' is a read-only attribute. 'GPUCoreTemp' can use the following target types: X Screen, GPU. Attribute 'GPUCoreTemp' (localhost.localdomain:0[gpu:0]): 51. 'GPUCoreTemp' is an integer attribute. 'GPUCoreTemp' is a read-only attribute. 'GPUCoreTemp' can use the following target types: X Screen, GPU. [dglent@localhost ~]$ nvidia-settings -q all | grep -i therm Attributes queryable via localhost.localdomain:0[thermalsensor:0]: Attribute 'ThermalSensorReading' (localhost.localdomain:0[thermalsensor:0]): 51. The valid values for 'ThermalSensorReading' are in the range 0 - 127 'ThermalSensorReading' is a read-only attribute. 'ThermalSensorReading' can use the following target types: Thermal Sensor. Attribute 'ThermalSensorProvider' (localhost.localdomain:0[thermalsensor:0]): 1. 'ThermalSensorProvider' is an integer attribute. 'ThermalSensorProvider' is a read-only attribute. 'ThermalSensorProvider' can use the following target types: Thermal Sensor. Attribute 'ThermalSensorTarget' (localhost.localdomain:0[thermalsensor:0]): 1. 'ThermalSensorTarget' is an integer attribute. 'ThermalSensorTarget' is a read-only attribute. 'ThermalSensorTarget' can use the following target types: Thermal Sensor. [dglent@localhost ~]$
OK, very helpful informations. I see the problem and I'll fix it in the coming days. Stay tuned :D
After the last update 1.2.1 it works fine for me Thanks :)
I'm happy I solved your problem. Sorry for the delay, I was very busy in these last months.
Downloaded the plasmoid, then attempted to add it in the usual manner (from local file.) When I attempt to add the plasmoid I get this error: "This object could not be created for the following reason: Script initialization failed!" I'm running Sabayon (Gentoo based) Linux 5.4 64 bit with KDE 4.5.4. Fairly stock.
Please download the file, open a console, cd into the directory where you saved the file and try to install it from there with: plasmapkg -i ./Simple-NVidia-Info.asmoid Usually console messages are more detailed and I may be able to fix/modify it to solve your problem, too. BTW I am running on Mandriva 2010.2 64bits and also on KDE 4.5.4.
Same problem as the others, 8600M GT, and same output for the commands you asked. But here's a(n obvious) patch that works for me (tm) def _updatelabel(self): - sensor=commands.getoutput("nvidia-settings -q [thermalsensor:0]/ThermalSensorReading | grep thermalsensor"); - sensor=sensor[sensor.find("):")+2:sensor.find(".")+1]; + sensor=commands.getoutput("nvidia-settings -q [gpu:0]/GPUCoreTemp | grep gpu:0"); + sensor=sensor[sensor.find("):")+2:sensor.find(".")]; sensor=sensor.replace(".",unichr(176).encode("latin-1")); sensor+="C";
How can I apply it?
Did you install version 1.1? I modified it to read GPUCoreTemp as in the above patch plus added some fallback logic. Since I have both "GPUCoreTemp" and "thermalsensor" on my system I tested with both scenarios and it works. Just to be sure, uninstall the plasmoid first with this command from a console: plasmapkg -r Simple-NVidia-Info Then simply install it again.
It Works! thakns for the correction! really usseful plasmoid. as suggestions, maybe in the futer you could implement graphical options, f.e. like font size it would be nice to make the plasmoid even more subtle good job!
I am happy it works :) As I said in the description of the plasmoid, I do not have the time to make a settings window and options for this. If there is someone keen to provide a patch I am happy to include it and release it, but I will not invest time into this.
oh I se... well its ok but i have another issue, and maybe you have an idea... I have to rezise the plasmoid so I could see all the info... no problem with that but, when I restart the pc, the size configuration doesn't save and everytime i must resize again do you (or anybody) have an idea to how to solve this? thanks!
Hmm ... sorry ... on my system (Mandriva 2010.2 64 bits, KDE 4.5.<something>) the text is smaller than the plasmoid initial size, but I still resized it to fit the width of the other plasmoids I have on the desktop, and it keeps it's size. Strange it does not for you. Maybe someone else has an idea or somebody can direct me to a tutorial/document on how to fix this.
same here, no temperature this is an awesome plasmoid but the most important function is not working "Error parsing query"
Please someone give me the output of these 2 comments so I can troubleshoot the no temperature problem: nvidia-settings -q all | grep -i temp nvidia-settings -q all | grep -i therm I am getting the temperature from the "thermalsesnor" property of nvidia-settings, maybe some version or card doesn't have this but it has "GPUTemp" property or something similar. Since I have only one and my own video card to test on, all of you don't having the temperature please answer my request, otherwise I can't help you!
sure! here's mine (the second command doesn't pop up with anything) miguel@Kubuntu:~$ nvidia-settings -q all | grep -i temp Attribute 'GPUCoreTemp' (Kubuntu:0.0): 56. 'GPUCoreTemp' is an integer attribute. 'GPUCoreTemp' is a read-only attribute. 'GPUCoreTemp' can use the following target Attribute 'GPUCoreTemp' (Kubuntu:0[gpu:0]): 56. 'GPUCoreTemp' is an integer attribute. 'GPUCoreTemp' is a read-only attribute. 'GPUCoreTemp' can use the following target miguel@Kubuntu:~$ nvidia-settings -q all | grep -i therm miguel@Kubuntu:~$
Saved the file then tried to simply add it via the add widget from local file dialog. Throws up an error: installation of widget failed! Installed manually but then gives "script initialization error" upon adding to desktop. Running 64 Bit Sabayon Linux with KDE 4.5.4 here.
Same here, using 4.6 RC1 (which I thought might have been the problem first).