SEARCH

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

You are not logged in.

#126 2012-01-07 01:37:54

mrpeachy
20% cooler
From: The Everfree Forest
Registered: 2009-11-08
Posts: 3,460

Re: weather in conky (LUA scripts) updated 12/26/13!

Sector11 wrote:

Yup, now I'm convinced that mrpeachy speaks Martian and  here on earth they have disguised the language as LUA.

that is perhaps the biggest barrier to using the lua only method
learning how to write the code to get the info displayed
but i think there are some nice benefits to doing it this way as i mentioned above
ie cpu use and repetition of forecast days based on a single format

once i have the forecast format set up, its as as much code to show 2 days as it is 10 days
all i have to do is specify where each day starts

Offline

Help fund CrunchBang, donate to the project!

#127 2012-01-07 01:45:39

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

Re: weather in conky (LUA scripts) updated 12/26/13!

^ @ mrpeachy

Yes, I realize that but for someone that doesn't know LUA and wants a "custom" layout it'll be a PIG!  I say as I look in a mirror.  lol


·  ↓   ↓   ↓   ↓   ↓   ↓  ·
BunsenLabs Forums now Open for Registration
·  ↑   ↑   ↑   ↑   ↑   ↑  · BL ModSquad

Offline

#128 2012-01-07 01:46:08

BoredOOMM
#! Junkie
From: 36.0718,-119.03519
Registered: 2011-06-19
Posts: 353

Re: weather in conky (LUA scripts) updated 12/26/13!

Sector11 wrote:

Yup, now I'm convinced that mrpeachy speaks Martian and  here on earth they have disguised the language as LUA.


THIS explains the green color preference!!
lol


Congratulations, you've figured out the sound of one hand clapping...

Offline

#129 2012-01-07 02:26:21

mrpeachy
20% cooler
From: The Everfree Forest
Registered: 2009-11-08
Posts: 3,460

Re: weather in conky (LUA scripts) updated 12/26/13!

screenshot5c7192a6c4ad282cc93c1dd7b0f9bc38.png

lua code for the above

--write current weather #######################################
--show current conditions title
out({fs=16,x=0,y=20,txt="Current Conditions"})
--show day date and month
out({fs=14,x=0,y=35,txt=now["day_lc"]..", "..now["date"].." "..now["month_lc"]})
--show image
image({x=-20,y=15,w=50,h=50,file=now["weather_icon"]})
--text to right of image
out({x=65,y=55,fs=16,txt=now["conditions_lc"]})
out({x=65,y=72,fs=18,txt=now["temp"].."°F"})
out({x=80,y=88,fs=12,c=0x3ed9e7,txt="feels like: "})
out({x=160,y=88,fs=12,txt=now["feels_like"].."°F"})
--below image
--first column, titles
out({x=0,y=102,c=0x3ed9e7,txt="wind chill: "});
out({x=0,y=114,c=0x3ed9e7,txt="heat index: "});
out({x=0,y=126,c=0x3ed9e7,txt="dew point: "});
out({x=0,y=138,c=0x3ed9e7,txt="humidity: "});
out({x=0,y=150,c=0x3ed9e7,txt="pressure: "});
--second column, data
out({x=80,y=102,txt=now["wind_chill"].."°f"});
out({x=80,y=114,txt=now["heat_index"].."°f"});
out({x=80,y=126,txt=now["dew_point"].."°f"});
out({x=80,y=138,txt=now["humidity"].."%"});
out({x=80,y=150,txt=now["pressure"].."\""});
--third colum, titles
out({x=140,y=102,c=0x3ed9e7,txt="ceiling: "});
out({x=140,y=114,c=0x3ed9e7,txt="visibility: "});
out({x=140,y=126,c=0x3ed9e7,txt="wind: "});
out({x=140,y=138,c=0x3ed9e7,txt="direction: "});
out({x=140,y=150,c=0x3ed9e7,txt="gusts: "});
--fourth column, data
out({x=220,y=102,txt=now["ceiling_lc"]})
out({x=220,y=114,txt=now["visibility"]})
out({x=220,y=126,txt=now["wind_mph"]})
out({x=220,y=138,txt=now["wind_deg"].."° ("..now["wind_nesw"]..")"})
out({x=220,y=150,txt=now["wind_gusts"]})
--write forecast days title
out({fs=16,x=0,y=175,txt="Forecast Days"})
--end of current conditions ###########################################
--write forecast weather and repeat
--these tables hold the top left coordinates for each repeat as set lower, do not edit
top_left_x_coordinate={}
top_left_y_coordinate={}
--enter number of forecast days to show
number_of_days=6
--enter coordinates of top left corner for each day
top_left_x_coordinate[1],top_left_y_coordinate[1]=0,170
top_left_x_coordinate[2],top_left_y_coordinate[2]=260,170
top_left_x_coordinate[3],top_left_y_coordinate[3]=520,170
top_left_x_coordinate[4],top_left_y_coordinate[4]=0,350
top_left_x_coordinate[5],top_left_y_coordinate[5]=260,350
top_left_x_coordinate[6],top_left_y_coordinate[6]=520,350
------------------------
for i=1,number_of_days do--start of day repeat, do not edit
tlx=top_left_x_coordinate[i]--sets top left position for each repeat
tly=top_left_y_coordinate[i]--sets top left position for each repeat
--write day format below, write x and y relative to top left coordinates as in the example
--write i to call day as this will be replaced with the day number for each repeat
--forecast day date and month
out({fs=14,x=tlx+0,y=tly+20,txt=forecast_day_lc[i]..", "..forecast_date[i].." "..forecast_month_lc[i]})
--image
image({x=tlx-20,y=tly+5,w=50,h=50,file=weather_icon[i]})
--text to right of image, conditions, high and low temp
out({x=tlx+65,y=tly+40,fs=16,txt=conditions_lc[i]})
out({x=tlx+80,y=tly+58,fs=18,c=0xf49309,txt=high_temp[i].."°F"})
out({x=tlx+80,y=tly+75,fs=18,c=0x3cb342,txt=low_temp[1].."°F"})
--moon and wind font
out({f="Moon Phases",fs=28,x=tlx+155,y=tly+76,txt=moon_font[i]})
out({f="ConkyWindNESW",fs=32,x=tlx+190,y=tly+75,txt=wind_font[i]})
--info below image
--sun and moon times
--first colum
out({x=tlx+0,y=tly+92,c=0x3ed9e7,txt="sun rise: "});
out({x=tlx+0,y=tly+104,c=0x3ed9e7,txt="moon rise: "});
--second column
out({x=tlx+80,y=tly+92,txt=sun_rise_lc[i]});
out({x=tlx+80,y=tly+104,txt=moon_rise_lc[i]});
--third column
out({x=tlx+140,y=tly+92,c=0x3ed9e7,txt="sun set: "});
out({x=tlx+140,y=tly+104,c=0x3ed9e7,txt="moon set: "});
--fourth column
out({x=tlx+200,y=tly+92,txt=sun_set_lc[i]})
out({x=tlx+200,y=tly+104,txt=moon_set_lc[i]})
--moon phase and moon font
out({x=tlx+0,y=tly+116,c=0x3ed9e7,txt="moon phase: "});
out({x=tlx+80,y=tly+116,txt=moon_phase_lc[i]});
--1st column
out({x=tlx+0,y=tly+128,c=0x3ed9e7,txt="uv index: "});
out({x=tlx+0,y=tly+140,c=0x3ed9e7,txt="humidity: "});
out({x=tlx+0,y=tly+152,c=0x3ed9e7,txt="wind speed: "});
--2nd colum
out({x=tlx+80,y=tly+128,txt=uv_index_num[i].." ("..uv_index_txt[i]..")"})
out({x=tlx+80,y=tly+140,txt=humidity[i].." %"})
out({x=tlx+80,y=tly+152,txt=wind_mph[i].." mph"})
--3rd column
out({x=tlx+140,y=tly+128,c=0x3ed9e7,txt="cloud: "});
out({x=tlx+140,y=tly+140,c=0x3ed9e7,txt="rain: "});
out({x=tlx+140,y=tly+152,c=0x3ed9e7,txt="snow: "});
--4th column
out({x=tlx+200,y=tly+128,txt=cloud_cover[i].." %"});
out({x=tlx+200,y=tly+140,txt=precipitation[i].." %"});
out({x=tlx+200,y=tly+152,txt=snow[i].." %"});
--wind direction and direction font
out({x=tlx+0,y=tly+164,c=0x3ed9e7,txt="wind direction: "})
out({x=tlx+104,y=tly+164,txt=wind_deg[i].."° ("..wind_nesw[i]..")"});
end--of day repeat, do not edit
end--of method 2, do not edit
--############################################################

heres the whole script
http://crunchbanglinux.org/pastebin/1423

and in conky, in addition to regular settings

lua_load ~/lua/weatheragain2.lua
lua_draw_hook_pre weather

TEXT

@BoredOOMM
do you still have the intellicast icons?
the pastebin link i have is no longer working

Last edited by mrpeachy (2012-01-07 02:45:13)

Offline

#130 2012-01-07 03:12:57

BoredOOMM
#! Junkie
From: 36.0718,-119.03519
Registered: 2011-06-19
Posts: 353

Re: weather in conky (LUA scripts) updated 12/26/13!

mrpeachy wrote:

@BoredOOMM
do you still have the intellicast icons?
the pastebin link i have is no longer working

Sent PM to you.


Congratulations, you've figured out the sound of one hand clapping...

Offline

#131 2012-01-07 03:26:33

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

Re: weather in conky (LUA scripts) updated 12/26/13!

mrpeachy wrote:

screenshot5c7192a6c4ad282cc93c1dd7b0f9bc38.png

Sweet, now that I will play with... don't know what I'll do but I will try.

Are those the transparent images that look like the conkyForecast images you are looking for?


·  ↓   ↓   ↓   ↓   ↓   ↓  ·
BunsenLabs Forums now Open for Registration
·  ↑   ↑   ↑   ↑   ↑   ↑  · BL ModSquad

Offline

#132 2012-01-07 04:23:10

mrpeachy
20% cooler
From: The Everfree Forest
Registered: 2009-11-08
Posts: 3,460

Re: weather in conky (LUA scripts) updated 12/26/13!

Sector11 wrote:
mrpeachy wrote:

screenshot5c7192a6c4ad282cc93c1dd7b0f9bc38.png

Sweet, now that I will play with... don't know what I'll do but I will try.

Are those the transparent images that look like the conkyForecast images you are looking for?

thanks ands good luck if you try (youll be fine im sure smile )
im far more comfortable in lua code than typing out conkyrc configs, so this method seems only too logical to me

i think there are several scripts out there doing weather the "conkyforecast" way
and version 6 of weather.lua tries to do it that way too

but i think im going to work on the all lua way and see if i cant make it even easier!

i think this is as much weather as i am going to fit on my little eeepc screen
screenshot91cb31c67d70fc426ea409e777c0909d.png

re the icons...im looking for the set of images that the intellicast site uses
like this one
http://images.intellicast.com/App_Image … /wx_97.png

Last edited by mrpeachy (2012-01-07 04:26:52)

Offline

#133 2012-01-07 04:43:22

falldown
#! Samurai
Registered: 2011-09-01
Posts: 1,727

Re: weather in conky (LUA scripts) updated 12/26/13!

@mrpeachy.. I have been reading your scripts here on #! and then came across your blog.. and have to say that your weather set-ups are top notch!!

I came across this and was hoping that you would share the script for the weather??..

4aDwI.png


AWESOME WORK big_smile big_smile big_smile

Offline

#134 2012-01-07 05:22:27

BoredOOMM
#! Junkie
From: 36.0718,-119.03519
Registered: 2011-06-19
Posts: 353

Re: weather in conky (LUA scripts) updated 12/26/13!

mrpeachy wrote:

re the icons...im looking for the set of images that the intellicast site uses
like this one
http://images.intellicast.com/App_Image … /wx_97.png

dropbox link I sent you?????


Congratulations, you've figured out the sound of one hand clapping...

Offline

#135 2012-01-07 05:34:41

BoredOOMM
#! Junkie
From: 36.0718,-119.03519
Registered: 2011-06-19
Posts: 353

Re: weather in conky (LUA scripts) updated 12/26/13!

falldown wrote:

@mrpeachy.. I have been reading your scripts here on #! and then came across your blog.. and have to say that your weather set-ups are top notch!!

I came across this and was hoping that you would share the script for the weather??..

AWESOME WORK big_smile big_smile big_smile

that scrot shows the bottom...

Here is weather introducted with no scripts... http://crunchbanglinux.org/forums/post/122396/#p122396


Congratulations, you've figured out the sound of one hand clapping...

Offline

#136 2012-01-07 06:36:59

mrpeachy
20% cooler
From: The Everfree Forest
Registered: 2009-11-08
Posts: 3,460

Re: weather in conky (LUA scripts) updated 12/26/13!

falldown wrote:

@mrpeachy.. I have been reading your scripts here on #! and then came across your blog.. and have to say that your weather set-ups are top notch!!

I came across this and was hoping that you would share the script for the weather??..

AWESOME WORK big_smile big_smile big_smile

thanks falldown
i would have to dig around to find that one in particular
and if i remember correctly i was using conkyforecast for the info!

if i cant find it, im sure i could recreate it with my current weather script... with a couple of additions here and there

@BoredOOMM...still not getting those intellicast icons...only conkyforecast ones, dont worry about it if you dont have them, just a thought smile

Offline

#137 2012-01-07 06:58:01

BoredOOMM
#! Junkie
From: 36.0718,-119.03519
Registered: 2011-06-19
Posts: 353

Re: weather in conky (LUA scripts) updated 12/26/13!

mrpeachy wrote:

[

@BoredOOMM...still not getting those intellicast icons...only conkyforecast ones, dont worry about it if you dont have them, just a thought smile

I sent the wrong archive.

Here are the i-weathericons

http://www.savefile.com/dl/2FPTH38G


Congratulations, you've figured out the sound of one hand clapping...

Offline

#138 2012-01-07 07:56:41

mrpeachy
20% cooler
From: The Everfree Forest
Registered: 2009-11-08
Posts: 3,460

Re: weather in conky (LUA scripts) updated 12/26/13!

BoredOOMM wrote:
mrpeachy wrote:

[

@BoredOOMM...still not getting those intellicast icons...only conkyforecast ones, dont worry about it if you dont have them, just a thought smile

I sent the wrong archive.

Here are the i-weathericons

http://www.savefile.com/dl/2FPTH38G

those are the ones! thank you very much BoredOOMM

Offline

#139 2012-01-07 16:04:54

falldown
#! Samurai
Registered: 2011-09-01
Posts: 1,727

Re: weather in conky (LUA scripts) updated 12/26/13!

mrpeachy wrote:

thanks falldown
i would have to dig around to find that one in particular
and if i remember correctly i was using conkyforecast for the info!

if i cant find it, im sure i could recreate it with my current weather script... with a couple of additions here and there

RIP ConkyForecast. That would be great If you feel inspired at some point to recreate the round weather script with your current masterpiece of a Lua script.  smile

Offline

#140 2012-01-07 16:11:42

falldown
#! Samurai
Registered: 2011-09-01
Posts: 1,727

Re: weather in conky (LUA scripts) updated 12/26/13!

BoredOOMM wrote:

that scrot shows the bottom...

Here is weather introducted with no scripts... http://crunchbanglinux.org/forums/post/122396/#p122396

Thank you Sir!! Another thread that is  full of knowledge big_smile Cummunity #! is IMO the best cummunity around!!

Offline

#141 2012-01-07 20:36:41

ackernan
#! Junkie
Registered: 2011-01-10
Posts: 403

Re: weather in conky (LUA scripts) updated 12/26/13!

mrpeachy wrote:

screenshot5c7192a6c4ad282cc93c1dd7b0f9bc38.png

lua code for the above

--write current weather #######################################
--show current conditions title
out({fs=16,x=0,y=20,txt="Current Conditions"})
--show day date and month
out({fs=14,x=0,y=35,txt=now["day_lc"]..", "..now["date"].." "..now["month_lc"]})
--show image
image({x=-20,y=15,w=50,h=50,file=now["weather_icon"]})
--text to right of image
out({x=65,y=55,fs=16,txt=now["conditions_lc"]})
out({x=65,y=72,fs=18,txt=now["temp"].."°F"})
out({x=80,y=88,fs=12,c=0x3ed9e7,txt="feels like: "})
out({x=160,y=88,fs=12,txt=now["feels_like"].."°F"})
--below image
--first column, titles
out({x=0,y=102,c=0x3ed9e7,txt="wind chill: "});
out({x=0,y=114,c=0x3ed9e7,txt="heat index: "});
out({x=0,y=126,c=0x3ed9e7,txt="dew point: "});
out({x=0,y=138,c=0x3ed9e7,txt="humidity: "});
out({x=0,y=150,c=0x3ed9e7,txt="pressure: "});
--second column, data
out({x=80,y=102,txt=now["wind_chill"].."°f"});
out({x=80,y=114,txt=now["heat_index"].."°f"});
out({x=80,y=126,txt=now["dew_point"].."°f"});
out({x=80,y=138,txt=now["humidity"].."%"});
out({x=80,y=150,txt=now["pressure"].."\""});
--third colum, titles
out({x=140,y=102,c=0x3ed9e7,txt="ceiling: "});
out({x=140,y=114,c=0x3ed9e7,txt="visibility: "});
out({x=140,y=126,c=0x3ed9e7,txt="wind: "});
out({x=140,y=138,c=0x3ed9e7,txt="direction: "});
out({x=140,y=150,c=0x3ed9e7,txt="gusts: "});
--fourth column, data
out({x=220,y=102,txt=now["ceiling_lc"]})
out({x=220,y=114,txt=now["visibility"]})
out({x=220,y=126,txt=now["wind_mph"]})
out({x=220,y=138,txt=now["wind_deg"].."° ("..now["wind_nesw"]..")"})
out({x=220,y=150,txt=now["wind_gusts"]})
--write forecast days title
out({fs=16,x=0,y=175,txt="Forecast Days"})
--end of current conditions ###########################################
--write forecast weather and repeat
--these tables hold the top left coordinates for each repeat as set lower, do not edit
top_left_x_coordinate={}
top_left_y_coordinate={}
--enter number of forecast days to show
number_of_days=6
--enter coordinates of top left corner for each day
top_left_x_coordinate[1],top_left_y_coordinate[1]=0,170
top_left_x_coordinate[2],top_left_y_coordinate[2]=260,170
top_left_x_coordinate[3],top_left_y_coordinate[3]=520,170
top_left_x_coordinate[4],top_left_y_coordinate[4]=0,350
top_left_x_coordinate[5],top_left_y_coordinate[5]=260,350
top_left_x_coordinate[6],top_left_y_coordinate[6]=520,350
------------------------
for i=1,number_of_days do--start of day repeat, do not edit
tlx=top_left_x_coordinate[i]--sets top left position for each repeat
tly=top_left_y_coordinate[i]--sets top left position for each repeat
--write day format below, write x and y relative to top left coordinates as in the example
--write i to call day as this will be replaced with the day number for each repeat
--forecast day date and month
out({fs=14,x=tlx+0,y=tly+20,txt=forecast_day_lc[i]..", "..forecast_date[i].." "..forecast_month_lc[i]})
--image
image({x=tlx-20,y=tly+5,w=50,h=50,file=weather_icon[i]})
--text to right of image, conditions, high and low temp
out({x=tlx+65,y=tly+40,fs=16,txt=conditions_lc[i]})
out({x=tlx+80,y=tly+58,fs=18,c=0xf49309,txt=high_temp[i].."°F"})
out({x=tlx+80,y=tly+75,fs=18,c=0x3cb342,txt=low_temp[1].."°F"})
--moon and wind font
out({f="Moon Phases",fs=28,x=tlx+155,y=tly+76,txt=moon_font[i]})
out({f="ConkyWindNESW",fs=32,x=tlx+190,y=tly+75,txt=wind_font[i]})
--info below image
--sun and moon times
--first colum
out({x=tlx+0,y=tly+92,c=0x3ed9e7,txt="sun rise: "});
out({x=tlx+0,y=tly+104,c=0x3ed9e7,txt="moon rise: "});
--second column
out({x=tlx+80,y=tly+92,txt=sun_rise_lc[i]});
out({x=tlx+80,y=tly+104,txt=moon_rise_lc[i]});
--third column
out({x=tlx+140,y=tly+92,c=0x3ed9e7,txt="sun set: "});
out({x=tlx+140,y=tly+104,c=0x3ed9e7,txt="moon set: "});
--fourth column
out({x=tlx+200,y=tly+92,txt=sun_set_lc[i]})
out({x=tlx+200,y=tly+104,txt=moon_set_lc[i]})
--moon phase and moon font
out({x=tlx+0,y=tly+116,c=0x3ed9e7,txt="moon phase: "});
out({x=tlx+80,y=tly+116,txt=moon_phase_lc[i]});
--1st column
out({x=tlx+0,y=tly+128,c=0x3ed9e7,txt="uv index: "});
out({x=tlx+0,y=tly+140,c=0x3ed9e7,txt="humidity: "});
out({x=tlx+0,y=tly+152,c=0x3ed9e7,txt="wind speed: "});
--2nd colum
out({x=tlx+80,y=tly+128,txt=uv_index_num[i].." ("..uv_index_txt[i]..")"})
out({x=tlx+80,y=tly+140,txt=humidity[i].." %"})
out({x=tlx+80,y=tly+152,txt=wind_mph[i].." mph"})
--3rd column
out({x=tlx+140,y=tly+128,c=0x3ed9e7,txt="cloud: "});
out({x=tlx+140,y=tly+140,c=0x3ed9e7,txt="rain: "});
out({x=tlx+140,y=tly+152,c=0x3ed9e7,txt="snow: "});
--4th column
out({x=tlx+200,y=tly+128,txt=cloud_cover[i].." %"});
out({x=tlx+200,y=tly+140,txt=precipitation[i].." %"});
out({x=tlx+200,y=tly+152,txt=snow[i].." %"});
--wind direction and direction font
out({x=tlx+0,y=tly+164,c=0x3ed9e7,txt="wind direction: "})
out({x=tlx+104,y=tly+164,txt=wind_deg[i].."° ("..wind_nesw[i]..")"});
end--of day repeat, do not edit
end--of method 2, do not edit
--############################################################

heres the whole script
http://crunchbanglinux.org/pastebin/1423

and in conky, in addition to regular settings

lua_load ~/lua/weatheragain2.lua
lua_draw_hook_pre weather

TEXT

@MrPeachy - I have a problem using the v9000 lua script.   I use the v7 lua script with no problem.  I've tried v9000 with a template and get this error..

Conky: llua_do_call: function conky_weather execution failed: /home/tony/.conky/weather-9000.lua:273: bad argument #1 to '?' (string expected, got nil)

I copied the above v9000 lua script that you use and get a different error..

Conky: llua_do_call: function conky_weather execution failed: /home/tony/.conky/weatheragain.lua:524: attempt to concatenate field '?' (a nil value)

I'm at a loss.  Why is it working for you but not me?  I've killed & restarted all conkys and rebooted.

Offline

#142 2012-01-07 20:38:05

mrpeachy
20% cooler
From: The Everfree Forest
Registered: 2009-11-08
Posts: 3,460

Re: weather in conky (LUA scripts) updated 12/26/13!

here is a pretty close recreation
screenshot086bad643ea8b313666bd02cc250013b.png

code weathercircle.lua
http://crunchbanglinux.org/pastebin/1424

in conkyrc

lua_load ~/lua/weathercircle.lua
lua_draw_hook_pre weather

TEXT

Offline

#143 2012-01-07 20:49:38

mrpeachy
20% cooler
From: The Everfree Forest
Registered: 2009-11-08
Posts: 3,460

Re: weather in conky (LUA scripts) updated 12/26/13!

ackernan wrote:

@MrPeachy - I have a problem using the v9000 lua script.   I use the v7 lua script with no problem.  I've tried v9000 with a template and get this error..

Conky: llua_do_call: function conky_weather execution failed: /home/tony/.conky/weather-9000.lua:273: bad argument #1 to '?' (string expected, got nil)

I copied the above v9000 lua script that you use and get a different error..

Conky: llua_do_call: function conky_weather execution failed: /home/tony/.conky/weatheragain.lua:524: attempt to concatenate field '?' (a nil value)

I'm at a loss.  Why is it working for you but not me?  I've killed & restarted all conkys and rebooted.

did both curl commands activate correctly?
should see something like

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 68344  100 68344    0     0  10795      0  0:00:06  0:00:06 --:--:-- 56576
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 68344  100 68344    0     0  34272      0  0:00:01  0:00:01 --:--:-- 38159

update your lua to this one
http://crunchbanglinux.org/pastebin/1425

it has better curl management
this version only takes direct lua input
what is in there starts at line 467

see if that does it for you!

note,
im going to make myself a memory use recording function and test out the lua script for memory leaks

Last edited by mrpeachy (2012-01-07 20:52:11)

Offline

#144 2012-01-07 21:10:48

falldown
#! Samurai
Registered: 2011-09-01
Posts: 1,727

Re: weather in conky (LUA scripts) updated 12/26/13!

mrpeachy wrote:

code weathercircle.lua
http://crunchbanglinux.org/pastebin/1424

in conkyrc

lua_load ~/lua/weathercircle.lua
lua_draw_hook_pre weather

TEXT

OH WOW MrPeachy!! You my fellow #!r are AWESOME!! It works perfectly (just need the weather icons) I am incorporating it into my current set-up and will have a screenshot of it for you if you like.
and again thank you for taking the time.

Offline

#145 2012-01-07 21:26:08

mrpeachy
20% cooler
From: The Everfree Forest
Registered: 2009-11-08
Posts: 3,460

Re: weather in conky (LUA scripts) updated 12/26/13!

here are the icons if you havnt already got them
http://ompldr.org/vYzRpcw

Offline

#146 2012-01-07 21:48:17

ackernan
#! Junkie
Registered: 2011-01-10
Posts: 403

Re: weather in conky (LUA scripts) updated 12/26/13!

mrpeachy wrote:

did both curl commands activate correctly?
should see something like

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 68344  100 68344    0     0  10795      0  0:00:06  0:00:06 --:--:-- 56576
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 68344  100 68344    0     0  34272      0  0:00:01  0:00:01 --:--:-- 38159

update your lua to this one
http://crunchbanglinux.org/pastebin/1425

I used the lua script from this post, still errored.  The curl seems to be working fine.  Here's the output from conky and the corresponding script lines..

Conky: drawing to double buffer
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 83105  100 83105    0     0   213k      0 --:--:-- --:--:-- --:--:--  346k
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 83105  100 83105    0     0   199k      0 --:--:-- --:--:-- --:--:--  299k
Conky: llua_do_call: function conky_weather execution failed: /home/tony/.conky/weatheragain.lua:406: bad argument #1 to '?' (string expected, got nil)
Conky: llua_do_call: function conky_weather execution failed: /home/tony/.conky/weatheragain.lua:476: attempt to concatenate field '?' (a nil value)
line 406 - now["conditions_caps"]=string.upper(t)
line 476 - out({x=65,y=72,fs=18,txt=now["temp"].."°F"})

Offline

#147 2012-01-07 22:21:09

Dodge ram
#! CrunchBanger
Registered: 2011-04-26
Posts: 140

Re: weather in conky (LUA scripts) updated 12/26/13!

I am trying to chase down a problem I am having. When I call up the weather This is what I get.
Screenshot_2.jpg

When I close the terminal I get this
Screenshot_3.jpg

As far as I can tell all of my links are good. What does this error message mean?

Offline

#148 2012-01-07 22:31:48

ackernan
#! Junkie
Registered: 2011-01-10
Posts: 403

Re: weather in conky (LUA scripts) updated 12/26/13!

ackernan wrote:

I used the lua script from this post, still errored.  The curl seems to be working fine.  Here's the output from conky and the corresponding script lines..

Conky: drawing to double buffer
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 83105  100 83105    0     0   213k      0 --:--:-- --:--:-- --:--:--  346k
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 83105  100 83105    0     0   199k      0 --:--:-- --:--:-- --:--:--  299k
Conky: llua_do_call: function conky_weather execution failed: /home/tony/.conky/weatheragain.lua:406: bad argument #1 to '?' (string expected, got nil)
Conky: llua_do_call: function conky_weather execution failed: /home/tony/.conky/weatheragain.lua:476: attempt to concatenate field '?' (a nil value)
line 406 - now["conditions_caps"]=string.upper(t)
line 476 - out({x=65,y=72,fs=18,txt=now["temp"].."°F"})

Now it's working w/o errors.  Very strange, I didn't change anything.  Strange indeed! hmm
{scratch head}

All I get is Current Conditions.  I added minimum_size 1500 500 to my config, that made no difference.

Upper left corner of screenshot
Screenshot_at_2012_01_07_17_36_18.jpg

Last edited by ackernan (2012-01-07 22:39:08)

Offline

#149 2012-01-07 22:32:22

falldown
#! Samurai
Registered: 2011-09-01
Posts: 1,727

Re: weather in conky (LUA scripts) updated 12/26/13!

Same here guys.. only it is stable for 5-10 minutes.

Conky: llua_do_call: function conky_weather execution failed: /home/falldown/.conky/weathercircle.lua:406: bad argument #1 to '?' (string expected, got nil)
Conky: llua_do_call: function conky_weather execution failed: /home/falldown/.conky/weathercircle.lua:506: attempt to concatenate field '?' (a nil value)
 

Offline

Help fund CrunchBang, donate to the project!

#150 2012-01-07 22:35:49

Dodge ram
#! CrunchBanger
Registered: 2011-04-26
Posts: 140

Re: weather in conky (LUA scripts) updated 12/26/13!

Dodge ram wrote:

I am trying to chase down a problem I am having. When I call up the weather This is what I get.
Screenshot_2.jpg

When I close the terminal I get this
Screenshot_3.jpg

As far as I can tell all of my links are good. What does this error message mean?

If it is saying that I have a error in forecast_VW.lua, this is the line

file:write(datastringnow.."<>"..datastringday1.."<>"..datastringday2.."<>"..datastringday3.."<>"..datastringday4.."<>:"..datastringday5.."<>"..datastringday6.."<>"..datastringday7.."<>"..datastringday8.."<>"..datastringday9.."<>"..datastringday10.."<>"..datastringfont.."<>"..datastringimage.."<>"..datastringwindfont.."<>"..datastringwindicon.."<>"..datastringmoonfont.."<>"..datastringmoonicon)

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: acrobat

Debian Logo