Koentje wrote: ⤴Wed Mar 20, 2024 5:33 pm
Logansfury wrote: ⤴Wed Mar 20, 2024 3:18 pm
There seems to be a stray period or comma mark by the graph however. I have checked all the codes but I dont see any stray characters to account for it.
Without you posting the conky config, i have no idea what you did... i gave up mind reading a long time ago!
Glad to oblige. Here is the final conky with working GPU graph:
conkyrc
Code: Select all
conky.config = {
alignment = 'top_left',
gap_x = 56,
gap_y = 156,
xinerama_head = 1,
background = true,
border_width = 1,
cpu_avg_samples = 2,
default_color = 'gray',
default_outline_color = 'black',
default_shade_color = 'white',
color0 = '#ffffff',
color1 = '#ff0000',
double_buffer = true,
draw_borders = false,
draw_graph_borders = true,
draw_outline = true,
draw_shades = false,
extra_newline = false,
font = 'Neon 80s:size=10',
minimum_height = 260,
minimum_width = 356,
net_avg_samples = 2,
no_buffers = true,
out_to_console = false,
out_to_ncurses = false,
out_to_stderr = false,
out_to_x = true,
own_window = true,
own_window_class = 'Conky',
own_window_transparent = true,
own_window_argb_visual = true,
own_window_type = 'desktop',
own_window_hints ='undecorated,sticky,skip_taskbar,skip_pager,below',
show_graph_range = false,
show_graph_scale = false,
stippled_borders = 0,
update_interval = 1.0,
uppercase = false,
use_spacer = 'none',
use_xft = true,
default_graph_height = 40,
default_graph_width = 350
}
conky.text = [[
${color1}GPU» ${hr}
${execpi 5 ./radeontop.sh}
${execgraph "echo $(cat ./radeontop.dump | grep 'gpu' | awk '{print $2}')" ffff00 ff0000}"
]]
Here is the bash script that populates the display:
radeontop.sh
Code: Select all
#!/bin/bash
rm -f ./radeontop.dump
radeontop -l1 -d ./radeontop.dump > /dev/null
wait
sed -i 's/, /\n/g' ./radeontop.dump
gpu=$(cat ./radeontop.dump | grep 'gpu' | awk '{print $2}')
vgt=$(cat ./radeontop.dump | grep 'vgt' | awk '{print $2}')
ta=$(cat ./radeontop.dump | grep 'ta' | awk '{print $2}')
sx=$(cat ./radeontop.dump | grep 'sx' | awk '{print $2}')
sc=$(grep -w 'sc' ./radeontop.dump | awk '{print $2}')
spi=$(cat ./radeontop.dump | grep 'spi' | awk '{print $2}')
pa=$(cat ./radeontop.dump | grep 'pa' | awk '{print $2}')
db=$(cat ./radeontop.dump | grep 'db' | awk '{print $2}')
cb=$(cat ./radeontop.dump | grep 'cb' | awk '{print $2}')
vram=$(cat ./radeontop.dump | grep 'vram' | awk '{print $2" "$3}')
gtt=$(cat ./radeontop.dump | grep 'gtt' | awk '{print $2" "$3}')
mclk=$(cat ./radeontop.dump | grep 'mclk' | awk '{print $2" "$3}')
sclk=$(cat ./radeontop.dump | grep 'sclk' | awk '{print $2" "$3}')
echo "\${color red}GPU brand: \${color white}\${alignr}Advanced Micro Devices, Inc. [AMD/ATI]"
echo "\${color red}GPU model: \${color white}\${alignr}Cape Verde PRO [Radeon HD 7750]"
echo "\${color red}Graphics Pipe: \${color white}\${alignr}$gpu"
echo "\${color red}Vertex Grouper + Tesselator: \${color white}\${alignr}$vgt"
echo "\${color red}Texture Addresser: \${color white}\${alignr}$ta"
echo "\${color red}Shader Export: \${color white}\${alignr}$sx"
echo "\${color red}Shader Interpolator: \${color white}\${alignr}$spi"
echo "\${color red}Scan Converter: \${color white}\${alignr}$sc"
echo "\${color red}Primitive Assembly: \${color white}\${alignr}$pa"
echo "\${color red}Depth Block: \${color white}\${alignr}$db"
echo "\${color red}Color Block: \${color white}\${alignr}$cb"
echo "\${color red}Virtual RAM: \${color white}\${alignr}$vram of 868mb"
echo "\${color red}GTT: \${color white}\${alignr}$gtt of 16005mb"
echo "\${color red}Memory Clock: \${color white}\${alignr}$mclk of 0.80ghz"
echo "\${color red}Shader Clock: \${color white}\${alignr}$sclk of 0.80ghz"