SEARCH

Enter your search query in the box above ^, or use the forum search tool.

You are not logged in.

#101 2015-09-02 16:59:44

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: Conky v1.10 Thread

@ arclance

Actually I was re-thinking this after typing that ... your idea is better.

Have the main function match closer to the file name for better identification:
ie:  In chronograph.lua change

function conky_main()

to:

function conky_chrono()

Another example: 4clocks.lua

function conky_4clocks

EDIT:  interrupted by my wife, ragamatrix popped in ahead of me as my reply sat here un-submitted

Last edited by Sector11 (2015-09-02 17:03:01)

Offline

Help fund CrunchBang, donate to the project!

#102 2015-09-03 16:55:05

ragamatrix
#! Junkie
From: Earth
Registered: 2012-12-05
Posts: 286

Re: Conky v1.10 Thread

I tried to change the name function in the lua script (ChronoClear.lua) and calling this with the widget.lua but... That did not work...  ops I probably miss something.

Offline

#103 2015-09-03 17:52:43

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: Conky v1.10 Thread

    --call of the two mains functions in the lua files
        conky_draw_bg()
        conky_new-name()

Offline

#104 2015-09-04 08:13:59

ragamatrix
#! Junkie
From: Earth
Registered: 2012-12-05
Posts: 286

Re: Conky v1.10 Thread

yes that's what I did but it dœsn't works ... I don't know why, thanks for help.

Offline

#105 2015-09-04 12:27:24

arclance
#! Die Hard
Registered: 2012-03-29
Posts: 987

Re: Conky v1.10 Thread

Did you kill and restart the conky after you did that?

Offline

#106 2015-09-06 14:28:10

iami
Member
Registered: 2013-09-06
Posts: 44

Re: Conky v1.10 Thread

Last edited by iami (2015-09-06 14:30:31)

Offline

#107 2015-09-07 16:12:57

ragamatrix
#! Junkie
From: Earth
Registered: 2012-12-05
Posts: 286

Re: Conky v1.10 Thread

Offline

#108 2015-09-07 16:41:06

arclance
#! Die Hard
Registered: 2012-03-29
Posts: 987

Re: Conky v1.10 Thread

^ Okay then post the full text of all three lua scripts and your .conkyrc as they are now so we can see if there is something wrong in the way you changed them.

Offline

#109 2015-09-10 11:46:52

ragamatrix
#! Junkie
From: Earth
Registered: 2012-12-05
Posts: 286

Re: Conky v1.10 Thread

Offline

#110 2015-09-10 11:48:36

ragamatrix
#! Junkie
From: Earth
Registered: 2012-12-05
Posts: 286

Re: Conky v1.10 Thread

Offline

#111 2015-09-10 13:58:44

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: Conky v1.10 Thread

In Sparky do you have "conky all"?

 10 Sep 15 | 10:56:55 ~
    $ ser conky
alias ser = aptitude search
i   bunsen-conky                                    - Conky configuration files and related scripts for BunsenLa
p   conky                                           - highly configurable system monitor (transitional package) 
i   conky-all                                       - highly configurable system monitor (all features enabled) 
p   conky-all-dbg                                   - highly configurable system monitor (all features enabled -
p   conky-cli                                       - highly configurable system monitor (basic version)        
p   conky-cli-dbg                                   - highly configurable system monitor (basic version - debug)
p   conky-std                                       - highly configurable system monitor (default version)      
p   conky-std-dbg                                   - highly configurable system monitor (default version - debu
i   conkyemail                                      - Email inbox count script with ssl capabilities, for use in
i   conkymisc                                       - Misc python scripts for use in Conky                      
 
 10 Sep 15 | 10:57:01 ~
    $ 

Offline

#112 2015-09-10 14:02:48

ragamatrix
#! Junkie
From: Earth
Registered: 2012-12-05
Posts: 286

Re: Conky v1.10 Thread

Hi Sector11
Yes conky-all is installed.
Here's the conky conf:

conky.config = {
-- work in background (disabled for testing)
background = false,

-- better fonts
use_xft = true,
--xftalpha = 1,

-- update interval
update_interval = 60.0,
total_run_times = 0,

-- window settings
own_window = true,
own_window_transparent = true,
own_window_type = 'override',
own_window_hints = 'undecorated, below, sticky, skip_taskbar, skip_pager',
--own_window_argb_visual = true,
--own_window_argb_value = 0,

-- anti-flickering
double_buffer = true,

-- size
minimum_width = 260,
minimum_height = 80,
maximum_width = 260,

 -- shadows
draw_shades = true,
default_shade_color = 'black',

--borders
draw_outline = false,
default_outline_color = 'red',
draw_graph_borders = true,

-- frame
draw_borders = false,

-- color
default_color = 'white',

-- position
alignment = 'top_right',
gap_x = 130,
gap_y = 105,

-- misc
no_buffers = true,
uppercase = false,
cpu_avg_samples = 2,
if_up_strictness = 'address',

show_graph_range = false,
show_graph_scale = false,
--default_bar_height = 6,
--default_bar_width = 200,
text_buffer_size = 1000,
override_utf8_locale = true,

font = 'Liberation Sans:bold:size=9', --important for shades
template0 = 'Liberation Sans:bold:size=9',
template1 = 'Liberation Mono:bold:size=7',
lua_load = '/home/raphix/.conky/ConkyChronoClear/draw_bg.lua',
}

conky.text = [[
${lua conky_draw_bg 10 0 0 0 0 0x000000 0.50} \
${font NeogreyMedium:size=55}$alignc${color D4D4D4}${time %H:%M}${color}
]]

Last edited by ragamatrix (2015-09-10 14:42:30)

Offline

#113 2015-09-16 14:15:23

ragamatrix
#! Junkie
From: Earth
Registered: 2012-12-05
Posts: 286

Re: Conky v1.10 Thread

hi!
Still problem with the draw_bg.lua script.
I got this error:

conky: llua_do_call: function conky_main execution failed:~/.conky/ConkyChronoClear/draw_bg.lua:32: attempt to perform arithmetic on local 'colour' (a nil value)

I don't know what's wrong with the rgba ? around line 32 ?
draw_bg.lua:

--[[Background originally by londonali1010 (2009)
    ability to set any size for background mrpeachy 2011
    ability to set variables for bg in conkyrc dk75

  the change is that if you set width and/or height to 0
  then it assumes the width and/or height of the conky window

so:

lua_load ~/Conky/LUA/draw_bg.lua
TEXT
${lua conky_draw_bg 20 0 0 0 0 0x000000 0.4}


${lua conky_draw_bg corner_radius x_position y_position width height color alpha}

covers the whole window and will change if you change the minimum_size setting

20             corner_radius
 0             x_position
 0             y_position
 0             width
 0             height
 0x000000      color
 0.4           alpha

]]

require 'cairo'
local    cs, cr = nil
function rgb_to_r_g_b(colour,alpha)
return ((colour / 0x10000) % 0x100) / 255., ((colour / 0x100) % 0x100) / 255., (colour % 0x100) / 255., alpha
end
function conky_draw_bg(r,x,y,w,h,color,alpha)
if conky_window == nil then return end
if cs == nil then cairo_surface_destroy(cs) end
if cr == nil then cairo_destroy(cr) end
local cs = cairo_xlib_surface_create(conky_window.display, conky_window.drawable, conky_window.visual, conky_window.width, conky_window.height)
local cr = cairo_create(cs)
w=w
h=h
if w=="0" then w=tonumber(conky_window.width) end
if h=="0" then h=tonumber(conky_window.height) end
cairo_set_source_rgba (cr,rgb_to_r_g_b(color,alpha))
--top left mid circle
local xtl=x+r
local ytl=y+r
--top right mid circle
local xtr=(x+r)+((w)-(2*r))
local ytr=y+r
--bottom right mid circle
local xbr=(x+r)+((w)-(2*r))
local ybr=(y+r)+((h)-(2*r))
--bottom right mid circle
local xbl=(x+r)
local ybl=(y+r)+((h)-(2*r))
-----------------------------
cairo_move_to (cr,xtl,ytl-r)
cairo_line_to (cr,xtr,ytr-r)
cairo_arc(cr,xtr,ytr,r,((2*math.pi/4)*3),((2*math.pi/4)*4))
cairo_line_to (cr,xbr+r,ybr)
cairo_arc(cr,xbr,ybr,r,((2*math.pi/4)*4),((2*math.pi/4)*1))
cairo_line_to (cr,xbl,ybl+r)
cairo_arc(cr,xbl,ybl,r,((2*math.pi/4)*1),((2*math.pi/4)*2))
cairo_line_to (cr,xtl-r,ytl)
cairo_arc(cr,xtl,ytl,r,((2*math.pi/4)*2),((2*math.pi/4)*3))
cairo_close_path(cr)
cairo_fill (cr)
------------------------------------------------------------
cairo_surface_destroy(cs)
cairo_destroy(cr)
return ""
end

Offline

#114 2015-09-17 09:12:15

mzsade
#! Junkie
Registered: 2009-09-27
Posts: 276

Re: Conky v1.10 Thread

:~$ whereis conky
conky: /usr/bin/conky /usr/lib/conky /etc/conky /usr/share/man/man1/conky.1.gz
:~$ ls /usr/bin/conky
/usr/bin/conky
:~$ ls /usr/lib/conky
libcairo_imlib2_helper.so  libcairo.so  libimlib2.so  librsvg.so
:~$ ls /etc/conky
conky.conf  conky_no_x11.conf

Last edited by mzsade (2015-09-18 06:39:36)

Offline

#115 2015-09-17 22:41:43

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: Conky v1.10 Thread

Offline

#116 2015-09-18 06:29:35

mzsade
#! Junkie
Registered: 2009-09-27
Posts: 276

Re: Conky v1.10 Thread

Offline

#117 2015-09-18 10:16:02

ragamatrix
#! Junkie
From: Earth
Registered: 2012-12-05
Posts: 286

Re: Conky v1.10 Thread

Offline

#118 2015-09-18 12:45:13

mzsade
#! Junkie
Registered: 2009-09-27
Posts: 276

Re: Conky v1.10 Thread

${color green}CPU Temperature: ${color red} ${acpitemp}

Last edited by mzsade (2015-09-18 15:15:43)

Offline

#119 2015-09-18 15:27:52

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: Conky v1.10 Thread

 18 Sep 15 | 12:25:28 ~
    $ sensors
acpitz-virtual-0
Adapter: Virtual device
temp1:        +30.0°C  (crit = +110.0°C)

f71862fg-isa-0a00
Adapter: ISA adapter
+3.3V:        +3.50 V  
in1:          +1.35 V  
in2:          +1.50 V  
in3:          +0.86 V  
in4:          +0.00 V  
in5:          +0.00 V  
in6:          +0.00 V  
3VSB:         +3.39 V  
Vbat:         +2.99 V  
fan1:        2235 RPM
fan2:           0 RPM  ALARM
fan3:           0 RPM  ALARM
temp1:        +40.0°C  (high = +85.0°C, hyst = +81.0°C)
                       (crit = +255.0°C, hyst = +251.0°C)  sensor = transistor
temp2:        +40.0°C  (high = +85.0°C, hyst = +81.0°C)
                       (crit = +100.0°C, hyst = +96.0°C)  sensor = thermistor
temp3:       +127.0°C  (high = +70.0°C, hyst = +68.0°C)  ALARM (CRIT)
                       (crit = +85.0°C, hyst = +83.0°C)  sensor = transistor

k10temp-pci-00c3
Adapter: PCI adapter
temp1:        +30.5°C  (high = +70.0°C)

Offline

#120 2015-09-18 17:20:22

mzsade
#! Junkie
Registered: 2009-09-27
Posts: 276

Re: Conky v1.10 Thread

Thank you so much, both for your advice and your patience. I installed inxi and ran sensors.

:~$ sensors
acpitz-virtual-0
Adapter: Virtual device
temp1:        +60.0°C  (crit = +104.0°C) # This is the value the variable {acpitemp} shows in conky

asus-isa-0000
Adapter: ISA adapter
cpu_fan:     2600 RPM
temp1:       +6280.0°C  

coretemp-isa-0000
Adapter: ISA adapter
Core 0:       +52.0°C  (high = +105.0°C, crit = +105.0°C)
Core 1:       +52.0°C  (high = +105.0°C, crit = +105.0°C)
Core 2:       +55.0°C  (high = +105.0°C, crit = +105.0°C)
Core 3:       +55.0°C  (high = +105.0°C, crit = +105.0°C)

I am not happy with the thought of running sensors-detect and letting lm-sensors create directories and stuff in my system for every aspect of my H/W. So how is it that gkrellm is able to accurately display to a degree the same core temp. values i got after running "sensors" without my having to do any of that? And isn't it possible to make conky do that similarly? Needless to say, prudent counsel will prevail in the end but i am just hoping..

Offline

#121 2015-09-18 17:31:46

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: Conky v1.10 Thread

Core 0 ${execpi 5 sensors -f | awk '/Core0/ {gsub(/\+/,"",$3); gsub(/\..+/,"",$3); print $3}'}
Core 1 ${execpi 5 sensors -f | awk '/Core1/ {gsub(/\+/,"",$3); gsub(/\..+/,"",$3); print $3}'}
Core 2 ${execpi 5 sensors -f | awk '/Core2/ {gsub(/\+/,"",$3); gsub(/\..+/,"",$3); print $3}'}
Core 3 ${execpi 5 sensors -f | awk '/Core3/ {gsub(/\+/,"",$3); gsub(/\..+/,"",$3); print $3}'}

Offline

#122 2015-09-18 19:47:23

mzsade
#! Junkie
Registered: 2009-09-27
Posts: 276

Re: Conky v1.10 Thread

Chose method 3, ran sudo sensors-detect and bent over, all it did after that was write "#Chip Driver coretemp" in /etc/modules. Ran '/etc/init.d/kmod start' and added

${color white}CPU Temperature: ${color red} ${platform coretemp temp 1}

And this is what i get in return; sad

:~$ conky
...
conky: can't open '/sys/bus/platform/devices/coretemp/temp1_input': No such file or directory
please check your device or remove this var from conky
conky: forked to background, pid is 1757

.
But thanks anyway, those links were very informative, never had reason to look up sed, awk or aur before.
Still hoping i've missed something that'd be obvious to others;

ls /sys/devices/platform
80860F41:00  efivars.0         INTL9C60:01  PNP0C0E:00            snd-soc-dummy
alarmtimer   Fixed MDIO bus.0  microcode    PNP0C14:00            uevent
asus-nb-wmi  i8042             pcspkr       power
ATK4001:00   INT3396:00        PNP0103:00   regulatory.0
clk-lpt      INT33BD:00        PNP0C0C:00   serial8250
coretemp.0   INT33FC:00        PNP0C0D:00   simple-framebuffer.0
:~$ ls /sys/bus/platform/devices
80860F41:00  Fixed MDIO bus.0  microcode   PNP0C14:00
ACPI0003:00  i8042             pcspkr      regulatory.0
alarmtimer   INT0800:00        PNP0103:00  rtsx_pci_ms.0
asus-nb-wmi  INT3396:00        PNP0C09:00  rtsx_pci_sdmmc.0
ATK4001:00   INT33BD:00        PNP0C0A:00  serial8250
clk-lpt      INT33FC:00        PNP0C0C:00  simple-framebuffer.0
coretemp.0   INTL9C60:01       PNP0C0D:00  snd-soc-dummy
efivars.0    iTCO_wdt.0.auto   PNP0C0E:00
:~$ ls /sys/bus/platform/devices/coretemp.0
driver  driver_override  hwmon  modalias  power  subsystem  uevent
i:~$ ls /sys/bus/platform/devices/coretemp.0/hwmon
hwmon1
:~$ ls /sys/bus/platform/devices/coretemp.0/hwmon/hwmon1
device            temp2_label       temp4_crit        temp5_input
name              temp2_max         temp4_crit_alarm  temp5_label
power             temp3_crit        temp4_input       temp5_max
subsystem         temp3_crit_alarm  temp4_label       uevent
temp2_crit        temp3_input       temp4_max
temp2_crit_alarm  temp3_label       temp5_crit
temp2_input       temp3_max         temp5_crit_alarm

Tried ${platform coretemp.0 temp2_input}

onky: get_sysfs_info(): read from '  failed
conky: can't open '': No such file or directory

Last edited by mzsade (2015-09-18 20:55:13)

Offline

#123 2015-09-19 06:36:02

mzsade
#! Junkie
Registered: 2009-09-27
Posts: 276

Re: Conky v1.10 Thread

${hwmon 1 temp 2}
${hwmon 1 temp 3}
${hwmon 1 temp 4}
${hwmon 1 temp 5}

Last edited by mzsade (2015-09-19 09:36:16)

Offline

#124 2015-09-19 11:43:48

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: Conky v1.10 Thread

Offline

Be excellent to each other!

#125 2015-09-19 14:37:20

mzsade
#! Junkie
Registered: 2009-09-27
Posts: 276

Re: Conky v1.10 Thread

Thank you, that's a considerable body of work and it'll take me an age to just assimilate a tiny fraction of it. I had no idea you were such a huge deal! I kid you not, i am more than a little starstruck now.

Last edited by mzsade (2015-09-19 14:37:37)

Offline

Board footer

Powered by FluxBB

Copyright © 2012 CrunchBang Linux.
Proudly powered by Debian. Hosted by Linode.
Debian is a registered trademark of Software in the Public Interest, Inc.
Server: bleh

Debian Logo