You are not logged in.

#481 2016-01-03 22:55:31

fvirgola80
Member
From: Italy / Rome
Registered: 2015-10-08
Posts: 262

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

TeoBigusGeekus wrote:

No time for a conky fvirgola80, sorry, why don't you try to create one yourself?

But to be honest with you, I don't see much of a point in a monthly moon phases conky: it'd be the same for a month, you'd only have to update it 12 times a year - not the type of info conky was made for...

Ok now I see with TEO Sector11 for conky help was grnadioso ..... see you tomorrow friend   big_smile  big_smile

Last edited by fvirgola80 (2016-01-03 22:57:33)


Nothing happens by chance

Offline

#482 2016-01-03 22:56:37

fvirgola80
Member
From: Italy / Rome
Registered: 2015-10-08
Posts: 262

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

Sector11 wrote:

^ Create a conky  smile

good job  wink  wink


Nothing happens by chance

Offline

#483 2016-01-04 17:25:30

loutch
Member
Registered: 2015-12-12
Posts: 848

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

Hello guys

I permice me to ad a part from accuweather_images_hourly in my conky and i have two questions .

fisrt for the time :

"tztime Europe/Paris %H" & "tztime GMT-2 %H" & "tztime GMT-3 %H" ect ..

I change GMT by  Europe/Paris -2 %H but it don't work what is the problèm?

second question for the température .,(i search but not found) how can i cut the four five ans six température in the second line in altogether

${color}${goto 10}6°${goto 80}6°${goto 150}6°${goto 220}[four temp]6°${goto 290}[five temp]5°${goto 360}[six temp]5°${goto 430}5°${goto 500}4°${goto 570}4°${goto 650}4°${goto 730}3°${goto 810}4°${goto 890}4°${goto 970}4°${goto 1050}4°${goto 1130}4°

to put them in the conkyrc.i'm sure that is a little thing but it is not in my capacities . Thank for helping me .

the conkyrc

 
background yes
use_xft yes
xftfont URW Chancery L:style=Bold:size=10
xftalpha 1
update_interval 1.0
total_run_times 0
own_window yes
own_window_transparent yes
own_window_argb_visual yes
own_window_type normal
own_window_hints undecorated,below,skip_taskbar,skip_pager
double_buffer yes
minimum_size 220 00
maximum_width 220
text_buffer_size 2048
draw_shades no
draw_outline no
draw_borders no
draw_graph_borders no
default_color ffffff
color0 A9A9A9 #DarkGray
color1 778899 #LightSlateGray
color2 F5F5DC #Beige
color3 87CEFA #LightSkyBlue
color4 48D1CC #MediumTurquoise
color5 FFDEAD #NavajoWhite
color6 00BFFF #DeepSkyBlue
color7 B0E0E6 #PowderBlue
color8 FFD700 #Gold
color9 ff0000 #LightSalmon
default_outline_color black
alignment tl
gap_x 40
gap_y 100
no_buffers yes
uppercase no
cpu_avg_samples 2
override_utf8_locale yes
# Fonctionne uniquement avec les polices Fixes
#use_spacer yes
imlib_cache_size 0 
 uppercase no
 
 lua_load ~/.conky/lua/image.lua
 
TEXT
 
${texeci 600 bash $HOME/1b1_accuweather_images/1b1}
Température : ${voffset -20}${goto 120}${color7}${font URW Chancery L:style=Bold:size=30}${execi 90 sed -n '29p' $HOME/1b1_accuweather_images/curr_cond}°${color}${font}
Conditions : ${execi 90 sed -n '1p' $HOME/1b1_accuweather_images/messages-fr}
Humiditée : ${execi 90 sed -n '32p' $HOME/1b1_accuweather_images/curr_cond}
Vent : ${execi 90 sed -n '31p' $HOME/1b1_accuweather_images/curr_cond} à ${execi 90 sed -n '38p' $HOME/1b1_accuweather_images/curr_cond}
Lev. Sol. ${execi 90 sed -n '39p' $HOME/1b1_accuweather_images/curr_cond}\
${goto 120}Cou. Sol. ${execi 90 sed -n '40p' $HOME/1b1_accuweather_images/curr_cond}
${alignc}Prévisions des six prochaines heures
${texeci 600 bash $HOME/1c_accuweather_images_hourly/1c}
${voffset -15}${tztime Europe/Paris %H} h\
${goto 73}${tztime GMT-2 %H} h\
${goto 145}${tztime GMT-3 %H} h
${execpi 600 sed -n '2p' $HOME/1c_accuweather_images_hourly/altogether}
${tztime GMT-4 %H} h\
${goto 73}${tztime GMT-5 %H} h\
${goto 145}${tztime GMT-6 %H} h
${execpi 600 sed -n '2p' $HOME/1c_accuweather_images_hourly/altogether}
${alignc}Prévisions des six prochains jours
${execi 3600 echo `date --date="1 day" | awk '{print $1" "$3" "$2}'`}\
${goto 75}${execi 3600 echo `date --date="2 day" | awk '{print $1" "$3" "$2}'`}\
${goto 145}${execi 3600 echo `date --date="3 day" | awk '{print $1" "$3" "$2}'`}
${color9}${execi 90 sed -n '8p' $HOME/1b1_accuweather_images/first_days}°${color}\
${goto 75}${color9}${execi 90 sed -n '13p' $HOME/1b1_accuweather_images/first_days}°\
${goto 145}${execi 90 sed -n '18p' $HOME/1b1_accuweather_images/first_days}°${color}
${color7}${execi 90 sed -n '9p' $HOME/1b1_accuweather_images/first_days}°${color}\
${goto 75}${color7}${execi 90 sed -n '14p' $HOME/1b1_accuweather_images/first_days}°${color}\
${goto 145}${color7}${execi 90 sed -n '19p' $HOME/1b1_accuweather_images/first_days}°${color}
${execi 3600 echo `date --date="4 day" | awk '{print $1" "$3" "$2}'`}\
${goto 75}${execi 3600 echo `date --date="5 day" | awk '{print $1" "$3" "$2}'`}\
${goto 145}${execi 3600 echo `date --date="6 day" | awk '{print $1" "$3" "$2}'`}
${color9}${execi 90 sed -n '23p' $HOME/1b1_accuweather_images/first_days}°${color}\
${goto 75}${color9}${execi 90 sed -n '4p' $HOME/1b1_accuweather_images/last_days}°\
${goto 145}${execi 90 sed -n '9p' $HOME/1b1_accuweather_images/last_days}°${color}
${color7}${execi 90 sed -n '24p' $HOME/1b1_accuweather_images/first_days}°${color}\
${goto 75}${execi 90 sed -n '5p' $HOME/1b1_accuweather_images/last_days}°\
${goto 145}${execi 90 sed -n '10p' $HOME/1b1_accuweather_images/last_days}°${color}
${texeci 600 bash $HOME/4_Moon/moon_MoonGiant}
${voffset -15}${goto 15}${execpi 600 sed -n '7p' $HOME/4_Moon/raw | awk '{print $1}'}\
${alignc -30}${execpi 600 sed -n '35p' $HOME/4_Moon/raw | awk '{print $1}'}\
${alignc -100}${execpi 600 sed -n '43p' $HOME/4_Moon/raw | awk '{print $1}'}              
${goto 10}${execpi 600 sed -n '7p' $HOME/4_Moon/raw | awk '{print $2}'}\
${alignc -50}${execpi 600 sed -n '35p' $HOME/4_Moon/raw | awk '{print $2}'}\
${alignc -100}${execpi 600 sed -n '43p' $HOME/4_Moon/raw | awk '{print $2}'}              
${voffset 00}${goto 25}${execpi 600 sed -n '1p' $HOME/4_Moon/raw}\
${alignc -12}${execpi 600 sed -n '29p' $HOME/4_Moon/raw}\
${alignc -80}${execpi 600 sed -n '37p' $HOME/4_Moon/raw}
${voffset 34}${alignc 05}Détails 
${alignc}Distance : ${execpi 600 sed -n '4p' $HOME/4_Moon/raw | cut -c1-5} Mkms
${alignc}Age : ${execpi 600 sed -n '5p' $HOME/4_Moon/raw} jours$font            
#### icones conditions actuelles ####
${lua fDrawImage $HOME/1b1_accuweather_images/cc.png 145 40 100 65 0}\
#### icones 3 prochaines heures ####
${lua fDrawImage $HOME/1c_accuweather_images_hourly/20.png  20 160 50 30 0}\
${lua fDrawImage $HOME/1c_accuweather_images_hourly/23.png 90 160 50 30 0}\
${lua fDrawImage $HOME/1c_accuweather_images_hourly/26.png 163 160 50 30 0}\
#### icones 3 heures suivantes ####
${lua fDrawImage $HOME/1c_accuweather_images_hourly/29.png 20 195 50 30 0}\
${lua fDrawImage $HOME/1c_accuweather_images_hourly/32.png 90 195 50 30 0}\
${lua fDrawImage $HOME/1c_accuweather_images_hourly/35.png 163 195 50 30 0}
#### icones 3 premiers jours ####
${lua fDrawImage $HOME/1b1_accuweather_images/6.png 20 270 50 30 0}\
${lua fDrawImage $HOME/1b1_accuweather_images/11.png  90 270 50 30 0}\
${lua fDrawImage $HOME/1b1_accuweather_images/16.png 163 270 50 30 0}\
#### icones 3 jours suivants ####
${lua fDrawImage $HOME/1b1_accuweather_images/21.png 20 325 50 30 0}\
${lua fDrawImage $HOME/1b1_accuweather_images/last_2.png 90 325 50 30 0}\
${lua fDrawImage $HOME/1b1_accuweather_images/last_7.png 163 325 50 30 0}\
#### icone lune ####
${lua fDrawImage  $HOME/4_Moon/0.png  15 415 35 35 0}
${lua fDrawImage  $HOME/4_Moon/1.png  95 415 35 35 0}
${lua fDrawImage  $HOME/4_Moon/2.png 175 415 35 35 0}

1451928205.png


Linuxmint 22.1 Xia xfce & mageia 9 XFCE on ssd hp pavilion g7
Xubuntu 18.04 lts & 24.04 lts on ASUS Rog STRIX

Offline

#484 2016-01-04 17:53:54

unklar
Back to the roots 1.9
From: #! BL
Registered: 2015-10-31
Posts: 2,645

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

Examples of the time:

date "+%a %d. %b %H:%M:%S"
Mo 04. Jan 18:52:33
Battle Lake: ${alignr 15}${execpi 1 TZ=America/North_Dakota/Center date "+%a %d. %b %H:%M:%S"}
Lochranza: ${alignr 15}${execpi 1 TZ=Europe/London date "+%a %d. %b %H:%M:%S"}
Frohnleiten: ${alignr 15}${execpi 1 TZ=Europe/Berlin date "+%a %d. %b %H:%M:%S"}
Dhiffushi: ${alignr 15}${execpi 1 TZ=Indian/Maldives date "+%a %d. %b %H:%M:%S"}

  wink

Offline

#485 2016-01-04 19:09:15

Sector11
Mod Squid Tpyo Knig
From: Upstairs
Registered: 2015-08-20
Posts: 8,010

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

@ unklar - interesting.  I have never used "date" like that before - must research.  But it is using an "execpi" - chewing up CPU resources when conky has ${time} and ${tztime} and will save a few cycles.  big_smile

So you can change things:

Lochranza: ${execpi 1 TZ=Europe/London date "+%a %d. %b %H:%M:%S"}
to
Lochranza: ${tztime Europe/London %a %d. %b %T}

${time} and ${tztime} use the same the same "format" optons as "Date"


@ loutch - ${time} and ${tztime} have limitations in conky, they don't have the full scope of options that unklar is hinting at and I'm not sure you can "add or subtract hours/day/minutes from "locations" like Europe/Paris.  Or at least I should say: I don't know how.

Your best bet is to use the GMT offset needed:

${tztime GMT-5 %D %T}

This is interesting:

Local time Hour   ${time %H}
Local time Hour+2 ${execi 3600 echo `date --date="2 hour" | awk '{print $4}'` | cut -c-2}
Local time Hour-3 ${execi 3600 echo `date --date="-3 hour" | awk '{print $4}'` | cut -c-2}

I'll leave this here, my time cheatsheet

I use "faketime" to test different times in conky.


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#486 2016-01-04 19:24:41

Sector11
Mod Squid Tpyo Knig
From: Upstairs
Registered: 2015-08-20
Posts: 8,010

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

loutch wrote:

second question for the température .,(i search but not found) how can i cut the four five ans six température in the second line in altogether

${color}${goto 10}6°${goto 80}6°${goto 150}6°${goto 220}[four temp]6°${goto 290}[five temp]5°${goto 360}[six temp]5°${goto 430}5°${goto 500}4°${goto 570}4°${goto 650}4°${goto 730}3°${goto 810}4°${goto 890}4°${goto 970}4°${goto 1050}4°${goto 1130}4°

to put them in the conkyrc.i'm sure that is a little thing but it is not in my capacities . Thank for helping me .

Where are you getting that line from?


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#487 2016-01-05 00:02:00

Sector11
Mod Squid Tpyo Knig
From: Upstairs
Registered: 2015-08-20
Posts: 8,010

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

Teo posted a "Monthly Moon Calendar" script here ... so I mean like ... it's a red flag in front of a bull, and I am a Taurus ... I had to charge in.

It's not finished yet ... but:
1. it gets the month name automatically from a template:
- template1  ${execi 86400 echo `date | awk '{print $2}'`}
2. it checks to see if the images 29, 30 or 31.jpg exist
- if they do it add the data see on the bottom line
- if not - well, ${endif} takes care of errors.
3. the conky updates every second but ${execpi 86400 --} (24 hours) means the conky draws hardly 0 CPU cycles.
- there are 13 conkys running on my system at the time of the scrot
- check the CPU usage on the right.
4. Uses MobileDiesel's horizontal/vertical multilingual calendar (bash script)
- English Horizontal (default) on to and three sample languages on the bottom
- there are 40 languages in the support conkycal.lang file.
- the calendar ALWAYS displays 31 days - next month if current has less than 31

There are more things to do.
Sneak Peak
2016_01_04_20_44_28_Scrot11.jpg
I doubt it will be finished.


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#488 2016-01-05 08:38:15

loutch
Member
Registered: 2015-12-12
Posts: 848

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

Hello

Sector11 wrote:

@ loutch - ${time} and ${tztime} have limitations in conky, they don't have the full scope of options that unklar is hinting at and I'm not sure you can "add or subtract hours/day/minutes from "locations" like Europe/Paris.  Or at least I should say: I don't know how.

OK

Sector11 wrote:

Your best bet is to use the GMT offset needed:
${tztime GMT-5 %D %T}

I would content myself with that

Sector11 wrote:

Where are you getting that line from?

i'm geeting the line from the altogether file created in 1c_accuweather_images_hourly

here the completly file generated this morning

${color ffe595}${goto 10}${hr 1}
${color}${goto 10}4°${goto 80}4°${goto 150}5°${goto 220}5°${goto 290}6°${goto 360}6°${goto 430}7°${goto 500}6°${goto 570}6°${goto 650}6°${goto 730}6°${goto 810}6°${goto 890}6°${goto 970}6°${goto 1050}6°${goto 1130}5°
${color ffe595}${goto 100}${hr 1}
REel.(°C)${color}${goto 100}-1°${goto 160}1°${goto 220}0°${goto 280}2°${goto 340}2°${goto 400}2°${goto 460}2°${goto 520}0°${goto 580}2°${goto 640}0°${goto 700}2°${goto 760}0°${goto 820}0°${goto 880}1°${goto 940}1°${goto 1000}1°
${color ffe595}${goto 100}${hr 1}
HUMIDITEE${color}${goto 100}92%${goto 160}93%${goto 220}97%${goto 280}93%${goto 340}90%${goto 400}88%${goto 460}84%${goto 520}85%${goto 580}86%${goto 640}90%${goto 700}91%${goto 760}91%${goto 820}90%${goto 880}89%${goto 940}90%${goto 1000}89%
${color ffe595}${goto 100}${hr 1}
PLUIE${color}${goto 100}58%${goto 160}44%${goto 220}52%${goto 280}48%${goto 340}34%${goto 400}34%${goto 460}40%${goto 520}60%${goto 580}49%${goto 640}60%${goto 700}49%${goto 760}56%${goto 820}56%${goto 880}40%${goto 940}34%${goto 1000}37%
${color ffe595}${goto 100}${hr 1}
NEIGE${color}${goto 100}0%${goto 160}0%${goto 220}0%${goto 280}0%${goto 340}0%${goto 400}0%${goto 460}0%${goto 520}0%${goto 580}0%${goto 640}0%${goto 700}0%${goto 760}0%${goto 820}0%${goto 880}0%${goto 940}0%${goto 1000}0%
${color ffe595}${goto 100}${hr 1}
GIVRE${color}${goto 100}0%${goto 160}0%${goto 220}0%${goto 280}0%${goto 340}0%${goto 400}0%${goto 460}0%${goto 520}0%${goto 580}0%${goto 640}0%${goto 700}0%${goto 760}0%${goto 820}0%${goto 880}0%${goto 940}0%${goto 1000}0%
${color ffe595}${goto 100}${hr 1}
VENT(km/h)${color}${goto 100}11 WSW${goto 160}13 WSW${goto 220}15 WSW${goto 280}17 WSW${goto 340}17 WSW${goto 400}17 SW${goto 460}18 SSW${goto 520}18 SSW${goto 580}17 SSW${goto 640}17 SSW${goto 700}18 SSW${goto 760}17 SSW${goto 820}17 SSW${goto 880}18 SW${goto 940}18 SW${goto 1000}18 SW
${color ffe595}${goto 100}${hr 1}
UV INDEX${color}${goto 100}0${goto 160}0${goto 220}0${goto 280}0${goto 340}0${goto 400}0${goto 460}0${goto 520}0${goto 580}0${goto 640}0${goto 700}0${goto 760}0${goto 820}0${goto 880}0${goto 940}0${goto 1000}0
${color ffe595}${goto 100}${hr 1}
COUV NUAGE.${color}${goto 100}99%${goto 160}95%${goto 220}89%${goto 280}90%${goto 340}86%${goto 400}90%${goto 460}90%${goto 520}90%${goto 580}90%${goto 640}90%${goto 700}100%${goto 760}98%${goto 820}97%${goto 880}96%${goto 940}97%${goto 1000}98%
${color ffe595}${goto 100}${hr 1}
DEW P.(°C)${color}${goto 100}3°${goto 160}3°${goto 220}4°${goto 280}4°${goto 340}4°${goto 400}4°${goto 460}4°${goto 520}4°${goto 580}4°${goto 640}4°${goto 700}5°${goto 760}4°${goto 820}5°${goto 880}4°${goto 940}4°${goto 1000}4°

@+


Linuxmint 22.1 Xia xfce & mageia 9 XFCE on ssd hp pavilion g7
Xubuntu 18.04 lts & 24.04 lts on ASUS Rog STRIX

Offline

#489 2016-01-05 12:48:51

Sector11
Mod Squid Tpyo Knig
From: Upstairs
Registered: 2015-08-20
Posts: 8,010

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

loutch wrote:

i'm geeting the line from the altogether file created in 1c_accuweather_images_hourly

here the completly file generated this morning

@+

@loutch

Why not use the conky.companion for 1c)Accuweather Hourly Forecast - it will tell you exactly what command (-xxp) you can use rather than chopping that line.  To do what you are asking would require a re-write of the script that created that data file - or some really fancy sed-fu that is beyond my scope of knowledge.  smile

- or -

If you are concerned about daylight Savings Time changes then ${tztime } may not me the way to go.
That's where "date" will help but it needs ${exec(p)i }
2016_01_05_09_45_06_Scrot11.jpg

Local Time with "date"
| cut -c-8 is the same as no cut:
Hour-4 = ${execi 30 echo `date --date="-4 hour" | awk '{print $4}'`}
Hour-3 = ${execi 30 echo `date --date="-3 hour" | awk '{print $4}'` | cut -c-8}
Hour-2 = ${execi 30 echo `date --date="-2 hour" | awk '{print $4}'` | cut -c-5}
Hour-1 = ${execi 30 echo `date --date="-1 hour" | awk '{print $4}'` | cut -c-2}
Hour   = ${time %T}
Hour+1 = ${execi 30 echo `date --date="1 hour" | awk '{print $4}'` | cut -c-2}
Hour+2 = ${execi 30 echo `date --date="2 hour" | awk '{print $4}'` | cut -c-5}
Hour+3 = ${execi 30 echo `date --date="3 hour" | awk '{print $4}'` | cut -c-8}
Hour+4 = ${execi 30 echo `date --date="4 hour" | awk '{print $4}'`}

Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#490 2016-01-05 15:13:54

loutch
Member
Registered: 2015-12-12
Posts: 848

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

to Sector11


Conky companion is a PPA ?

I'm using Mageia with RPM

@+

Last edited by loutch (2016-01-05 15:15:46)


Linuxmint 22.1 Xia xfce & mageia 9 XFCE on ssd hp pavilion g7
Xubuntu 18.04 lts & 24.04 lts on ASUS Rog STRIX

Offline

#491 2016-01-05 16:06:36

Sector11
Mod Squid Tpyo Knig
From: Upstairs
Registered: 2015-08-20
Posts: 8,010

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

loutch wrote:

to Sector11

Conky companion is a PPA ?

@+

Yes, the Conky Companion your are thinking about is a PPA app.  Not recommended for distros outside of the Ubuntu world IMHO.

I'm sorry, I meant the 1c_companion.conky created to support that particular script by Teo. It's a conky too!
2015_11_16_18_48_08_Scrot11.jpg

There are a few, as seen in the first post - The first post has the links

1a) Accuweather_ConkyWeather_Font - 1a_12-2-14
- - Companion to the script: 1a_12-2-14_Companion

1b1) Accuweather - Images - 1b1_29-10-15
- - Companion to the script: 1b1_29-10-15_Companion

1b2) Accuweather - ConkyWeather font - 1b2_29-10-15
- - Companion to the script: 1b2_29-10-15_Companion

1c) Accuweather Hourly Forecast - 1c_12-2-14
- - Companion to the script: 1c_12-2-14_Companion

2b) WUnderground API - All users - 2b_21-12-15
- - Companion to the script: 2b_21-12-15_Companion

I still need to make them for:
1d) Accuweather RSS - 1d_12-2-14
2a) WUnderground ICAL - International users - 2a_12-2-14
3) NWS XML - USA users - 3_22-7-15
4) Moon phases' script - 4_2-6-15
and maybe the new, if that's what it becomes:  smile
5) Moon Phase Monthly Calendar


Some may think that a few are too simple to really need one, but think of people new to Linux and new to conky.

Question and a Request:

Q:  What does @+ mean?  smile
R:  Would you please post the code for:  ~/.conky/lua/image.lua your use.  ]:D


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#492 2016-01-05 17:10:57

loutch
Member
Registered: 2015-12-12
Posts: 848

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

@+

in more
see you later
bye
not sure at 100%

I edit the post 472 page 19 and ad  the image.lua .

here is it too

--créer par  Didier-T




require 'cairo'
home = os.getenv ('HOME')

--Fonction d'affichage
function conky_fDrawImage(path,x,y,w,h,arc)

	path = string.gsub(path, "~", home)
	path = string.gsub(path, "$HOME", home)

	local cs = cairo_xlib_surface_create(conky_window.display, conky_window.drawable, conky_window.visual, conky_window.width, conky_window.height)
	
	local function fDrawImage(path,x,y,w,h,arc)
		x=x+(w/2)
		y=y+(h/2)
		local img =  cairo_image_surface_create_from_png(path)
		local w_img, h_img = cairo_image_surface_get_width (img), cairo_image_surface_get_height (img)

		local cr = cairo_create (cs)
		cairo_translate (cr, x, y)

		if arc then
			cairo_rotate (cr, arc)
		end

		cairo_scale (cr, w/w_img, h/h_img)
		cairo_set_source_surface (cr, img, -w_img/2, -h_img/2)
		cairo_paint (cr)
		cairo_destroy(cr)
		cairo_surface_destroy (img)
	end
	fDrawImage(path,x,y,w,h,arc)
	cairo_surface_destroy(cs)
	return ""
end

Tank's

I change my conky with hourly_raw1 and it's perfect here the  conkyrc

${texeci 600 bash $HOME/1b1_accuweather_images/1b1}
Température : ${voffset -20}${goto 120}${color7}${font URW Chancery L:style=Bold:size=30}${execi 90 sed -n '29p' $HOME/1b1_accuweather_images/curr_cond}°${color}${font}
Conditions : ${execi 90 sed -n '1p' $HOME/1b1_accuweather_images/messages-fr}
Humiditée : ${execi 90 sed -n '32p' $HOME/1b1_accuweather_images/curr_cond}
Vent : ${execi 90 sed -n '31p' $HOME/1b1_accuweather_images/curr_cond} à ${execi 90 sed -n '38p' $HOME/1b1_accuweather_images/curr_cond}
Lev. Sol. ${execi 90 sed -n '39p' $HOME/1b1_accuweather_images/curr_cond}\
${goto 120}Cou. Sol. ${execi 90 sed -n '40p' $HOME/1b1_accuweather_images/curr_cond}
${alignc}Prévisions des six prochaines heures
${texeci 600 bash $HOME/1c_accuweather_images_hourly/1c}
${voffset -15}${time %H} h\
${goto 73}${tztime GMT-2 %H} h\
${goto 145}${tztime GMT-3 %H} h
${goto 10}${execpi 90 sed -n '52p' $HOME/1c_accuweather_images_hourly/hourly_raw1}\
${goto 80}${execpi 90 sed -n '53p' $HOME/1c_accuweather_images_hourly/hourly_raw1}\
${goto 150}${execpi 90 sed -n '54p' $HOME/1c_accuweather_images_hourly/hourly_raw1}
${tztime GMT-4 %H} h\
${goto 73}${tztime GMT-5 %H} h\
${goto 145}${tztime GMT-6 %H} h
${goto 10}${execpi 90 sed -n '55p' $HOME/1c_accuweather_images_hourly/hourly_raw1}\
${goto 80}${execpi 90 sed -n '56p' $HOME/1c_accuweather_images_hourly/hourly_raw1}\
${goto 150}${execpi 90 sed -n '57p' $HOME/1c_accuweather_images_hourly/hourly_raw1}
${alignc}Prévisions des six prochains jours
${execi 3600 echo `date --date="1 day" | awk '{print $1" "$3" "$2}'`}\
${goto 75}${execi 3600 echo `date --date="2 day" | awk '{print $1" "$3" "$2}'`}\
${goto 145}${execi 3600 echo `date --date="3 day" | awk '{print $1" "$3" "$2}'`}
${color9}${execi 90 sed -n '8p' $HOME/1b1_accuweather_images/first_days}°${color}\
${goto 75}${color9}${execi 90 sed -n '13p' $HOME/1b1_accuweather_images/first_days}°\
${goto 145}${execi 90 sed -n '18p' $HOME/1b1_accuweather_images/first_days}°${color}
${color7}${execi 90 sed -n '9p' $HOME/1b1_accuweather_images/first_days}°${color}\
${goto 75}${color7}${execi 90 sed -n '14p' $HOME/1b1_accuweather_images/first_days}°${color}\
${goto 145}${color7}${execi 90 sed -n '19p' $HOME/1b1_accuweather_images/first_days}°${color}
${execi 3600 echo `date --date="4 day" | awk '{print $1" "$3" "$2}'`}\
${goto 75}${execi 3600 echo `date --date="5 day" | awk '{print $1" "$3" "$2}'`}\
${goto 145}${execi 3600 echo `date --date="6 day" | awk '{print $1" "$3" "$2}'`}
${color9}${execi 90 sed -n '23p' $HOME/1b1_accuweather_images/first_days}°${color}\
${goto 75}${color9}${execi 90 sed -n '4p' $HOME/1b1_accuweather_images/last_days}°\
${goto 145}${execi 90 sed -n '9p' $HOME/1b1_accuweather_images/last_days}°${color}
${color7}${execi 90 sed -n '24p' $HOME/1b1_accuweather_images/first_days}°${color}\
${goto 75}${execi 90 sed -n '5p' $HOME/1b1_accuweather_images/last_days}°\
${goto 145}${execi 90 sed -n '10p' $HOME/1b1_accuweather_images/last_days}°${color}     
${texeci 500 bash $HOME/4_Moon/moon_MoonGiant}
${goto 15}${execpi 600 sed -n '7p' $HOME/4_Moon/raw | awk '{print $1}'}\
${alignc -30}${execpi 600 sed -n '35p' $HOME/4_Moon/raw | awk '{print $1}'}\
${alignc -100}${execpi 600 sed -n '43p' $HOME/4_Moon/raw | awk '{print $1}'}              
${goto 10}${execpi 600 sed -n '7p' $HOME/4_Moon/raw | awk '{print $2}'}\
${alignc -50}${execpi 600 sed -n '35p' $HOME/4_Moon/raw | awk '{print $2}'}\
${alignc -100}${execpi 600 sed -n '43p' $HOME/4_Moon/raw | awk '{print $2}'}              
${voffset 00}${goto 25}${execpi 600 sed -n '1p' $HOME/4_Moon/raw}\
${alignc -12}${execpi 600 sed -n '29p' $HOME/4_Moon/raw}\
${alignc -80}${execpi 600 sed -n '37p' $HOME/4_Moon/raw}
${voffset 34}${alignc 05}Détails 
${alignc}Distance : ${execpi 600 sed -n '4p' $HOME/4_Moon/raw | cut -c1-5} Mkms
${alignc}Age : ${execpi 600 sed -n '5p' $HOME/4_Moon/raw} jours$font            

#### icones conditions actuelles ####
${lua fDrawImage $HOME/1b1_accuweather_images/cc.png 145 40 100 65 0}\
#### icones 3 prochaines heures ####
${lua fDrawImage $HOME/1c_accuweather_images_hourly/20.png  20 160 50 30 0}\
${lua fDrawImage $HOME/1c_accuweather_images_hourly/23.png 90 160 50 30 0}\
${lua fDrawImage $HOME/1c_accuweather_images_hourly/26.png 163 160 50 30 0}\
#### icones 3 heures suivantes ####
${lua fDrawImage $HOME/1c_accuweather_images_hourly/29.png 20 195 50 30 0}\
${lua fDrawImage $HOME/1c_accuweather_images_hourly/32.png 90 195 50 30 0}\
${lua fDrawImage $HOME/1c_accuweather_images_hourly/35.png 163 195 50 30 0}
#### icones 3 premiers jours ####
${lua fDrawImage $HOME/1b1_accuweather_images/6.png 20 270 50 30 0}\
${lua fDrawImage $HOME/1b1_accuweather_images/11.png  90 270 50 30 0}\
${lua fDrawImage $HOME/1b1_accuweather_images/16.png 163 270 50 30 0}\
#### icones 3 jours suivants ####
${lua fDrawImage $HOME/1b1_accuweather_images/21.png 20 325 50 30 0}\
${lua fDrawImage $HOME/1b1_accuweather_images/last_2.png 90 325 50 30 0}\
${lua fDrawImage $HOME/1b1_accuweather_images/last_7.png 163 325 50 30 0}\
#### icone lune ####
${lua fDrawImage  $HOME/4_Moon/0.png  15 425 35 35 0}
${lua fDrawImage  $HOME/4_Moon/1.png  95 425 35 35 0}
${lua fDrawImage  $HOME/4_Moon/2.png 175 425 35 35 0}

@+

Last edited by loutch (2016-01-05 17:12:16)


Linuxmint 22.1 Xia xfce & mageia 9 XFCE on ssd hp pavilion g7
Xubuntu 18.04 lts & 24.04 lts on ASUS Rog STRIX

Offline

#493 2016-01-05 18:30:49

Inodoro Pereyra
Member
Registered: 2015-11-04
Posts: 123

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

Ok, got a problem:

Over the last few days, I noticed the weather station I was using (on the wunderground API) does not provide some information, like wind speed and direction.
For that reason, I decided to change station again, to the official weather station at Jorge Newbery Airport (station code is SABE). So, following S11's indications from a few days ago, I changed the address line on the 2b script to:

address="http://api.wunderground.com/api/APICODE/conditions/forecast10day/astronomy/hourly/satellite/q/pws:SABE.json"

But now the script is not loading anything... sad

What am I doing wrong, this time? sad

Thanks in advance. smile


Imagination is intelligence having fun. (Albert Einstein)
The thing about the Internet is you can create a phrase, and make up its author, and everybody will fall for it. (Aristotle)

Offline

#494 2016-01-05 19:19:49

Sector11
Mod Squid Tpyo Knig
From: Upstairs
Registered: 2015-08-20
Posts: 8,010

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

^ Don't think it is you IP ... None of my wunderground scripts are working, not even the companion scripts.

mad   8.(  mad


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#495 2016-01-05 19:23:06

Sector11
Mod Squid Tpyo Knig
From: Upstairs
Registered: 2015-08-20
Posts: 8,010

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

loutch wrote:

@+

in more
see you later
bye
not sure at 100%

I edit the post 472 page 19 and ad  the image.lua .

here is it too

Perfect thank you.  Glad I can help.


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#496 2016-01-05 19:31:50

Inodoro Pereyra
Member
Registered: 2015-11-04
Posts: 123

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

Sector11 wrote:

^ Don't think it is you IP ... None of my wunderground scripts are working, not even the companion scripts.

mad   8.(  mad

But mine does work... Just not with that station... sad


Imagination is intelligence having fun. (Albert Einstein)
The thing about the Internet is you can create a phrase, and make up its author, and everybody will fall for it. (Aristotle)

Offline

#497 2016-01-05 19:41:22

Inodoro Pereyra
Member
Registered: 2015-11-04
Posts: 123

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

GOT IT!!!
Just changed the address line to:

address="http://api.wunderground.com/api/APICODE/conditions/forecast10day/astronomy/hourly/satellite/q/Argentina/Jorge_Newbery_Aeroparque.json"

...and everything started working again. big_smile

Thank you S11, for trying.  big_smile


Imagination is intelligence having fun. (Albert Einstein)
The thing about the Internet is you can create a phrase, and make up its author, and everybody will fall for it. (Aristotle)

Offline

#498 2016-01-05 20:28:13

Sector11
Mod Squid Tpyo Knig
From: Upstairs
Registered: 2015-08-20
Posts: 8,010

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

I'll have to try that. so strange ... all wunderground sites for Buenos Aires are "pws" (Personal Weather Stations)

I'll have to try the JNA address.  Thanks.

EDIT:  ^ Yea, that works  Thank you.


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#499 2016-01-05 21:57:40

Inodoro Pereyra
Member
Registered: 2015-11-04
Posts: 123

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

Sector11 wrote:

I'll have to try the JNA address.  Thanks.

EDIT:  ^ Yea, that works  Thank you.

You're welcome. big_smile


Imagination is intelligence having fun. (Albert Einstein)
The thing about the Internet is you can create a phrase, and make up its author, and everybody will fall for it. (Aristotle)

Offline

#500 2016-01-06 11:00:57

unklar
Back to the roots 1.9
From: #! BL
Registered: 2015-10-31
Posts: 2,645

Re: Conky weather+moon scripts (Accuw/WUndergr/NWS/MoonGiant)

Inodoro Pereyra wrote:
address="http://api.wunderground.com/api/APICODE/conditions/forecast10day/astronomy/hourly/satellite/q/pws:SABE.json"

The ICAO code the Airport is not equal to PWS!
That's why

..../q/SABE.json"

  wink

Last edited by unklar (2016-01-06 11:53:38)

Offline

Board footer

Powered by FluxBB