orblazer / plasma-applet-resources-monitor

Plasmoid for monitoring CPU, memory, network traffic, GPUs and disks IO.
https://www.pling.com/p/2143899/
GNU General Public License v3.0
57 stars 6 forks source link

[BUG] CPU temp = "..." #48

Closed GM-Script-Writer-62850 closed 1 year ago

GM-Script-Writer-62850 commented 1 year ago

Describe the bug CPU temperature is not shown, assuming "..." is place holder text, note that GPU temp works as expected

To Reproduce

Steps to reproduce the behavior:

  1. Enable CPU monitoring
  2. check show temperature.
  3. get "..."

Expected behavior

  1. get 44.4°C (for example)

Screenshots Screenshot_20230513_141247

Versions (please complete the following information): plasma-applet-resources-monitor: v 2.9.1 (latest git version as of commit c077fa1; committed yesterday) Operating System: Kubuntu 22.04 KDE Plasma Version: 5.24.7 KDE Frameworks Version: 5.92.0 Qt Version: 5.15.3 Kernel Version: 5.17.13-051713-generic (64-bit) Graphics Platform: X11 Processors: 12 × AMD Ryzen 5 3600 6-Core Processor Memory: 15.6 GiB of RAM Graphics Processor: AMD Radeon RX 580 Series

Additional context

$ sensors
k10temp-pci-00c3
Adapter: PCI adapter
Tctl:         +60.4°C  
Tccd1:        +39.8°C  

drivetemp-scsi-2-0
Adapter: SCSI adapter
temp1:        +30.0°C  (lowest = +30.0°C, highest = +30.0°C)

nct6795-isa-0a20
Adapter: ISA adapter
Vcore:                        960.00 mV (min =  +0.00 V, max =  +1.74 V)
+5.0V:                          5.04 V  (min =  +0.00 V, max =  +0.00 V)  ALARM
AVCC:                           3.36 V  (min =  +2.98 V, max =  +3.63 V)
+3.3V:                          3.38 V  (min =  +2.98 V, max =  +3.63 V)
+12.0V:                        12.29 V  (min = +11.42 V, max = +12.58 V)
???:                          152.00 mV (min =  +0.00 V, max =  +0.00 V)  ALARM
VIN4:                         704.00 mV (min =  +0.00 V, max =  +0.00 V)  ALARM
3VSB:                           3.36 V  (min =  +2.98 V, max =  +3.63 V)
3BAT:                           3.26 V  (min =  +2.70 V, max =  +3.63 V)
CPU +1.8V:                      1.83 V  (min =  +2.04 V, max =  +2.04 V)  ALARM
???:                            0.00 V  (min =  +0.00 V, max =  +0.00 V)
VIN6:                         648.00 mV (min =  +0.00 V, max =  +0.00 V)  ALARM
SOC:                            1.10 V  (min =  +0.00 V, max =  +0.00 V)  ALARM
DIMM:                           1.36 V  (min =  +0.00 V, max =  +0.00 V)  ALARM
VIN7:                           1.51 V  (min =  +0.00 V, max =  +0.00 V)  ALARM
PUMP 1 Speed (Rear):           556 RPM  (min =    0 RPM)
CPU Fan 1 Speed:               488 RPM  (min =    0 RPM)
Chassis Fan 1 Speed (VRM):       0 RPM  (min =    0 RPM)
Chassis Fan 2 Speed (Bottom):  403 RPM  (min =    0 RPM)
Chassis Fan 3 Speed (Front):   612 RPM  (min =    0 RPM)
Chassis Fan 4 Speed (Front):   605 RPM  (min =    0 RPM)
SYSTIN:                        +37.0°C  (high =  +0.0°C, hyst =  +0.0°C)  ALARM  sensor = CPU diode
CPUTIN:                        +35.0°C  (high = +110.0°C, hyst = +90.0°C)  sensor = thermistor
AUXTIN0:                       +42.5°C  (high = +110.0°C, hyst = +90.0°C)  sensor = thermistor
AUXTIN1:                      -128.0°C    sensor = thermistor
AUXTIN2:                       +46.0°C    sensor = thermistor
AUXTIN3:                        -1.0°C    sensor = thermistor
SMBUSMASTER 0:                 +60.5°C  
PCH_CHIP_CPU_MAX_TEMP:          +0.0°C  
PCH_CHIP_TEMP:                  +0.0°C  
PCH_CPU_TEMP:                   +0.0°C  
intrusion0:                   ALARM
intrusion1:                   ALARM
beep_enable:                  disabled

nvme-pci-0100
Adapter: PCI adapter
Composite:    +59.9°C  (low  = -273.1°C, high = +109.8°C)
                       (crit = +129.8°C)
Sensor 2:     +78.8°C  (low  = -273.1°C, high = -273.1°C)

drivetemp-scsi-3-0
Adapter: SCSI adapter
temp1:        +31.0°C  (low  =  +0.0°C, high = +65.0°C)
                       (crit low = -41.0°C, crit = +85.0°C)
                       (lowest = +22.0°C, highest = +31.0°C)

drivetemp-scsi-1-0
Adapter: SCSI adapter
temp1:        +35.0°C  (low  =  +0.0°C, high = +60.0°C)
                       (crit low = -41.0°C, crit = +85.0°C)
                       (lowest = +23.0°C, highest = +35.0°C)

amdgpu-pci-2700
Adapter: PCI adapter
vddgfx:      950.00 mV 
fan1:             N/A  (min =    0 RPM, max = 3700 RPM)
edge:         +35.0°C  (crit = +85.0°C, hyst = -273.1°C)
slowPPT:      24.04 W  (cap = 145.00 W)
orblazer commented 1 year ago

Hello, Could you create an new page in System Monitor app ans adding this sensors "CPU > [Group] CPU > [Group] Temperature", and share the page file (stored in ~/.local/share/plasma-systemmonitor) ?

That is for know what the name of sensors you have for temperature.

GM-Script-Writer-62850 commented 1 year ago

sorry for the late reply, seems my email client was glitches and did not notify me of over 50 emails...

relevant part:

[Face-94410266684256][Sensors]
totalSensors=["cpu/all/usage","cpu/cpu\\\\d+/temperature"]

entire file:

[Face-93831649033184][Appearance]
chartFace=org.kde.ksysguard.piechart
title=Swap

[Face-93831649033184][SensorColors]
memory/swap/used=161,61,233
memory/swap/usedPercent=61,233,149

[Face-93831649033184][Sensors]
highPrioritySensorIds=["memory/swap/used"]
totalSensors=["memory/swap/used","memory/swap/total"]

[Face-93831649033184][org.kde.ksysguard.piechart][General]
showLegend=false

[Face-93831748113728][Appearance]
chartFace=org.kde.ksysguard.barchart
title=Disk I/O

[Face-93831748113728][FaceGrid][Appearance]
chartFace=org.kde.ksysguard.linechart
showTitle=false

[Face-93831748113728][FaceGrid][SensorColors]
disk/all/read=233,211,61
disk/all/write=61,108,233

[Face-93831748113728][FaceGrid][Sensors]
highPrioritySensorIds=["disk/all/read"]

[Face-93831748113728][SensorColors]
disk/all/read=233,211,61
disk/all/write=61,108,233

[Face-93831748113728][Sensors]
highPrioritySensorIds=["disk/all/write","disk/all/read"]
totalSensors=["disk/all/read","disk/all/write"]

[Face-93831748113728][org.kde.ksysguard.barchart][General]
rangeAuto=false
rangeFromUnit=200
rangeTo=600
rangeToMultiplier=1048576
rangeToUnit=202
showLegend=false

[Face-93831748113728][org.kde.ksysguard.piechart][General]
rangeAuto=false
rangeTo=600
rangeToMultiplier=1048576
rangeToUnit=202
showLegend=false
smoothEnds=false

[Face-94410222150464][SensorColors]
memory/physical/used=61,174,233

[Face-94410238879984][SensorColors]
network/enp36s0/ipv4address=61,174,233
network/enp36s0/ipv6address=233,120,61

[Face-94410261307168][SensorColors]
disk/all/used=61,174,233

[Face-94410266684256][SensorColors]
cpu/all/usage=61,174,233

[Face-94410266684256][Sensors]
totalSensors=["cpu/all/usage","cpu/cpu\\\\d+/temperature"]

[Face-94410278989264][SensorColors]
os/plasma/kfVersion=233,223,61
os/plasma/plasmaVersion=233,61,105
os/plasma/qtVersion=61,233,86
os/system/hostname=61,174,233
os/system/prettyName=154,61,233

[Face-94410280144624][SensorColors]
network/enp36s0/download=61,174,233
network/enp36s0/upload=233,120,61

[page]
actionsFace=

[page][row-0][column-0][section-1]
face=Face-93831649033184
isSeparator=false
name=section-1

[page][row-0][column-1][section-1]
face=Face-93831748113728
isSeparator=false
name=section-1
orblazer commented 1 year ago

That look weird sensor, could you try with only CPU 1 and theoretically the sensor should be cpu/cpu0/temperature and if is that i need to dig deeper in the issue because that make no sense to why this doesn't work and i can't reproduce the issue.

GM-Script-Writer-62850 commented 1 year ago

Maybe this attachment will have something useful, this is probably a modern amd vs intel subsystem layout thing

$ cat /sys/class/hwmon/hwmon6/temp{1,3}_{label,input}
Tctl
48000
Tccd1
40250

tree command outputs.zip

also this

[Face-94410266684256][Sensors]
totalSensors=["cpu/all/usage","cpu/cpu0/temperature"]
orblazer commented 1 year ago

The values appear right in System Monitor ? And the hwom things is "useless" for me.

IF not : this is an libksysguard issue. IF yes : this is my widget have some issue.

GM-Script-Writer-62850 commented 1 year ago

looks right or close enough to trick me 2023-05-14 21-05-43.zip (screencapture)

GM-Script-Writer-62850 commented 1 year ago

is there a priority list that will use a different underlying system if it is available? i think i installed a second system monitor for something or another some time back when, maybe it is using what is now some legacy version not the correct version that you intend to EOL for v3.0

orblazer commented 1 year ago

Ok, so that is definitely an issue with my widget.

Could you check if you have some errors in log with journalctl /usr/bin/plasmashell -e OR by running in isolated environment with plasmawindowed org.kde.resourcesMonitor-fork ? If no error could you add the code below above this next line, and check if some log appear. https://github.com/orblazer/plasma-applet-resources-monitor/blob/081636330d0f23f96bdd9e3dd27a45e6442dae9d/package/contents/ui/components/graph/CpuGraph.qml#L54

if (index == 2) {
    console.log(JSON.stringify(data, null, 2))
}

is there a priority list that will use a different underlying system if it is available? i think i installed a second system monitor for something or another some time back when, maybe it is using what is now some legacy version not the correct version that you intend to EOL for v3.0

This normally change nothing, because i only use libksysguard and you have that packages installed because none of my widget or System Monitor could work without it. Finally for the EOL is i go to drop support of KDE framework/plasma 5.x, but i don't have ETA for that version because i don't have info of the next major update from KDE.

GM-Script-Writer-62850 commented 1 year ago

not getting any debug data from that code...

You monster how could you forget the semicolon on line of that

that function is only getting called with a index of 0

tested this line below line 50: console.log("hello world",index,JSON.stringify(data));

cleaned up using

        if (index > 0){
            console.log("hello world",index,JSON.stringify(data));
        }
madeddy commented 1 year ago

Got this problem also. I patched my v2.9.1 install with your changes in #5d41c02. Frequency for CPU is now working but temp is still missing with .... Found this in the journal regarding the widget: Mai 15 14:35:46 blue krunner[53874]: file:///home/olli/.local/share/plasma/plasmoids/org.kde.resourcesMonitor-fork/contents/ui/components/graph/CpuGraph.qml:59:9: Unable to assign [undefined] to QString

orblazer commented 1 year ago

You monster how could you forget the semicolon on line of that

@GM-Script-Writer-62850 That is because is not required in JavaScript :sweat_smile:

Found this in the journal regarding the widget: Mai 15 14:35:46 blue krunner[53874]: file:///home/olli/.local/share/plasma/plasmoids/org.kde.resourcesMonitor-fork/contents/ui/components/graph/CpuGraph.qml:59:9: Unable to assign [undefined] to QString

@madeddy I think that is because you haven't restart the widget :shrug:

I have found an way to reproduce the issue ! That is because i use "cpu/all/" + plasmoid.configuration.clockAgregator + "Frequency" (so sensor like cpu/all/averageFrequency) and due to this doesn't exist before plasma 5.25 the sensor for temperature is not queried.

GM-Script-Writer-62850 commented 1 year ago

patch works

could you check for a better icon for cpu clock speed? the icon is a egg timer...

madeddy commented 1 year ago

I think that is because you haven't restart the widget

You are right, i did not. Because i don't know how and couldn't find in the net any trace how to do it. If you know any way please tell. However... i did a kquitapp5 plasmashell && kstart5 plasmashell after patching and the frequency worked then like written above. 😜 The temp not.

Ok. I patched again with https://github.com/orblazer/plasma-applet-resources-monitor/commit/9596e9a160d164e35cef1eaf5bd1d9f7a2b564f1, restarted plasma and... it works. Great job! Thanks.

could you check for a better icon for cpu clock speed? the icon is a egg timer...

I agree. Egg's and KDE are sooo cringe! 💩

orblazer commented 1 year ago

could you check for a better icon for cpu clock speed? the icon is a egg timer...

I think i can use 🕑 instead of that look more great, but i think i go to remove it because is look weird to have "emoji" right to text and nowhere else.

GM-Script-Writer-62850 commented 1 year ago

it probably makes more sense as is on your icon theme, this is what i have... (breeze-dark icon theme) Screenshot_20230516_214452

orblazer commented 1 year ago

@GM-Script-Writer-62850 @madeddy I have fix it by removing icons with c8b56152845c4144c2e12fcd294217df82e56e73.

madeddy commented 1 year ago

Hey, don't remove them because of my comment. It was more of a joke. 😅

If you want to use some icons i think some simple ones do it good enough. e.g.: https://www.onlinewebfonts.com/icon/free_Temperature https://www.onlinewebfonts.com/icon/search?q=clock&p=3

Ultimately it's naturally your call.

Greets

orblazer commented 1 year ago

@madeddy that is tricky for now to have custom icons in label because i same text element for value and label. And as the unicods icons are not everywhere for me is more logic to have icons everywhere OR nowhere ^^ That triggered me every times i develop the widget to see only icons at some place ^^