You are not logged in.

#1181 2016-09-22 17:55:39

Doruletz
Member
Registered: 2016-09-21
Posts: 21

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

TeoBigusGeekus wrote:

I've corrected the convert_time function, it should work now.
Please test it and report back loutch, TIA.

Teo, can you do me a favor and post just the time correction part of the code here for me?
For quite some time now, I've been looking for a way to have my sunrise/sunset posted in 24 hr time (here in America, we call it "Military Time").

Offline

#1182 2016-09-22 18:10:44

Doruletz
Member
Registered: 2016-09-21
Posts: 21

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

Another thing I've been trying to achieve for quite some time now:
How to fetch the weather data from AccuWeather and Weather.com in a different language, NOT English.
I'm sure lots of other people here would like that as well.
In my case, that language would be Romanian.
Basically I need at least just the Current Condition Name (Sunny, Fair, Clear, Cloudy, etc) in another language. I can always Hard Code (type in) the rest.
If you go to the sites, both Accuweather and Weather.com have the option to display data in another language, see here:
http://www.accuweather.com/ro/ro/consta … 19?lang=ro
https://weather.com/ro-RO/vreme/astazi/l/35.96,-83.91

*****************************************************************************
EDIT:
Just found a way to do that for Weather.com:
Instead of fetching data from:
http://wxdata.weather.com/wxdata/weathe … =10&unit=m
I add "&locale=RO" at the end, and get this:
http://wxdata.weather.com/wxdata/weathe … &locale=RO
*****************************************************************************

Last edited by Doruletz (2016-09-22 18:24:24)

Offline

#1183 2016-09-22 18:52:12

TeoBigusGeekus
BL DieHard
From: /Deutschland/Frankfurt_am_Main
Registered: 2015-10-04
Posts: 1,486

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

Doruletz wrote:
TeoBigusGeekus wrote:

I've corrected the convert_time function, it should work now.
Please test it and report back loutch, TIA.

Teo, can you do me a favor and post just the time correction part of the code here for me?
For quite some time now, I've been looking for a way to have my sunrise/sunset posted in 24 hr time (here in America, we call it "Military Time").

There you go buddy:

#function: convert_time
	convert_time () 
	{
		hours=$(echo $1|awk -F ":| " '{print $1}')
		minutes=$(echo $1|awk -F ":| " '{print $2}')
		am_or_pm=$(echo $1|awk -F ":| " '{print $3}')
		if [[ $am_or_pm == AM ]]; then
			if (( $hours < 10 )); then
				hours_24=0$hours
			fi
			if (( $hours == 10 || $hours == 11 )); then
				hours_24=$hours
			fi
			if (( $hours == 12 )); then
				hours_24=00
			fi
		elif [[ $am_or_pm == PM ]]; then
			if (( $hours != 12 )); then
				hours_24=$((hours+12))
			fi
			if (( $hours == 12 )); then
				hours_24=12
			fi
		fi
		time_24=$hours_24:$minutes
		echo $time_24
	}

You'd use it like so:

convert_time "2:30 PM"

As for the weather pages in other languages, you answered it yourself.


Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!

Offline

#1184 2016-09-22 21:02:07

TeoBigusGeekus
BL DieHard
From: /Deutschland/Frankfurt_am_Main
Registered: 2015-10-04
Posts: 1,486

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

fvirgola80 wrote:

Just checking the new accuweather and I noticed the wind gauge site like picture .... but you can incorporate that element in your script ? I also verified that the arrow is reversed , I'll explain the wind now blowing from the SE , however, an indication of the image pointing NW .... ??

http://s10.postimg.org/5ra8y7k05/Istantanea_21092016_14_57_08.png

yikes  yikes

I looked at your suggestion fvirgola80, but it seems that there's only one wind icon and it's rotated via webkit functions:
xE4ozcWt.jpg
So, no icons to download there.


Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!

Offline

#1185 2016-09-23 10:02:14

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

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

TeoBigusGeekus wrote:
fvirgola80 wrote:

Just checking the new accuweather and I noticed the wind gauge site like picture .... but you can incorporate that element in your script ? I also verified that the arrow is reversed , I'll explain the wind now blowing from the SE , however, an indication of the image pointing NW .... ??

http://s10.postimg.org/5ra8y7k05/Istantanea_21092016_14_57_08.png

yikes  yikes

I looked at your suggestion fvirgola80, but it seems that there's only one wind icon and it's rotated via webkit functions:
http://i.imgur.com/xE4ozcWt.jpg
So, no icons to download there.

Ok my friend, so you can never get?  8.(


Nothing happens by chance

Offline

#1186 2016-09-23 14:49:36

TeoBigusGeekus
BL DieHard
From: /Deutschland/Frankfurt_am_Main
Registered: 2015-10-04
Posts: 1,486

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

fvirgola80 wrote:

Ok my friend, so you can never get?  8.(

I'm afraid not fvirgola80, sorry.

EDIT: Even if I did download the new wind direction image and rotated it, a problem would be that I don't have the old Accuweather image for wind direction to use with the old icons. And what about the weatherfont users?
Better leave it as it is...

Last edited by TeoBigusGeekus (2016-09-23 14:52:33)


Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!

Offline

#1187 2016-09-23 17:34:16

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

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

@ fvirgola80 and TeoBugusGeekus...

OK, that 'webkit' mucks things up . . . but a good conkystador can do it with images of arrows or even the old conkyForecast images for wind with loutch's idea that starts here, the images are endless.  Just ask Uncle Startpage - because Uncle Google I don't like.  smile

That script is genius  ... we just need to get down and dirty.

Also there are 'arrow' fonts - I even have the OLD: ConkyCompass and ConkyCompassEN the final three came about to indicate various notations and wind speed:

2016_09_23_14_30_46_Scrot11.jpg
ConkyCompassEN could be used with different colours for speeds

Lest we forget:

${if_match "${command_by_Teo_script xyz}" = "NNW"}${font arrows:size=16}G${font}${endif}

Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#1188 2016-09-23 18:07:16

TeoBigusGeekus
BL DieHard
From: /Deutschland/Frankfurt_am_Main
Registered: 2015-10-04
Posts: 1,486

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

S11, do you have an old fashioned wind direction image and background I could use with the 2015 images?

ie. the equivalent of this and that for the 2015 images.


Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!

Offline

#1189 2016-09-23 18:48:31

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

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

Somewhere around there I have something similar -- let me go looking.

Back soon


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#1190 2016-09-23 19:05:17

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

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

Hello guys

I think i have finished my 1_accuweather conky & he done this :

1474657391.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

#1191 2016-09-23 19:37:41

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

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

@ Teo

I can't even find these red pointers anymore, still that the conkyForecast images though ... I did find the same blue arrows loutch uses on occasion though, as seen just below that post.

sad  sad


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#1192 2016-09-23 19:39:25

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:

Hello guys

I think i have finished my 1_accuweather conky & he done this :

Very nice indeed loutch.  I like that.


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#1193 2016-09-23 19:54:04

TeoBigusGeekus
BL DieHard
From: /Deutschland/Frankfurt_am_Main
Registered: 2015-10-04
Posts: 1,486

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

@S11
I don't need all these icons, just a pointer and a background: I'll rotate the pointer according to the wind direction.

@loutch
Awesome job loutch. Could I have this wind direction background as well as the wind pointer please?

Last edited by TeoBigusGeekus (2016-09-23 19:54:15)


Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!

Offline

#1194 2016-09-23 21:06:46

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

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

No problem Théo

Ther is no bacground or any wind pointer. I just coloured in every direction one after the other one .


Here mine icon pack

http://www.mageialinux-online.org/upload/vents_tar.gz

@+


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

#1195 2016-09-23 21:16:52

TeoBigusGeekus
BL DieHard
From: /Deutschland/Frankfurt_am_Main
Registered: 2015-10-04
Posts: 1,486

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

Nah, never mind, it wouldn't work anyway: even if I rotated a wind direction image, how would I pin point it at the center of the compass background?

Thanks anyway.


Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!

Offline

#1196 2016-09-24 14:17:17

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

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

^  I don't have the red pointers - or can't find them BUT, in my mind, I know of a way to rotate an image keeping the centre  I'll try that with what you posted later todat.  Have to run and get photocopies and then to the grocery store for a little old lady that can't do it herself.

I'm such a sucker  O:)  ... back soon.


Debian 12 Beardog, SoxDog and still a Conky 1.9er

Offline

#1197 2016-09-24 15:53:15

TeoBigusGeekus
BL DieHard
From: /Deutschland/Frankfurt_am_Main
Registered: 2015-10-04
Posts: 1,486

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

I'm up to something; stay tuned.


Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!

Offline

#1198 2016-09-24 19:48:16

TeoBigusGeekus
BL DieHard
From: /Deutschland/Frankfurt_am_Main
Registered: 2015-10-04
Posts: 1,486

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

New script and some extra conky configs.

The script now copies an image for the current conditions wind to the forecast_2015 or the forecast_2016 folders (depending on the parameter you pass; for the parameters, see here).
For the 2016 forecast, I used Accuweather's images. For the 2015 one, I used loutch's.
In any case, at the end of the curr_cond file there's a character: it's for the ConkyWindNESW font to find and use, so if you want to use the wind direction with the wind font, put the ConkyWindNESW.otf in your .fonts folder.

All the conkyrcs together
QZcjW26t.jpg
Gsuwrxht.png


...Too much conky; I need a beer. Bye everyone.

Last edited by TeoBigusGeekus (2016-09-25 06:34:48)


Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!

Offline

#1199 2016-09-24 21:04:47

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

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

@TEO .... Great friend of mine, a job number 1 .... magical super TEO my wish has come true ..... now it's up to me and the great Sector11 imagine new conky ....
Congratulations TEO    :8

Luke

May the force be with you

P.S. A short new conky for all      big_smile  wink


Nothing happens by chance

Offline

#1200 2016-09-24 22:41:29

TeoBigusGeekus
BL DieHard
From: /Deutschland/Frankfurt_am_Main
Registered: 2015-10-04
Posts: 1,486

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

I'm glad you like it fvirgola80; after all, you're the reason I integrated the wind icons into the script.


Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!
Please make Autocad Civil 3D and Archicad work on Linux!

Offline

Board footer

Powered by FluxBB