Weather by You!
Templates and Projects support => Php templates => Topic started by: martyp on March 08, 2014, 08:11:43 AM
-
Hi all,
Hoping someone has done this and maybe could help please.
I'm using the image from www.dragontail.co.uk with the Maplin weather station with a Raspberry Pi.
I installed apache on the Pi and was able to creae a basic webpage with graphs from the webdata folder which worked fine.
I tried copying the template to the Pi as per the instructions but it's all blank with just the image at the top and date? If I click on 6 hours, 24 hours etc. at the top no table is displayed.
I don't quite know where the files and folders go. The web directory is /var/www/ with a link to the webdata folder in there so the address to the basic web page is /webdata/index.htm
I put the index.php file and other files in the /webdata/ folder.
Can anyone help at all? I have attached a copy of the weather ini file.
-
The weather.log keeps showing:
14:15:12:pywws.weather_station:status {'unknown': 0, 'lost_connection': 0, 'rain_overflow': 0}
Traceback (most recent call last):
File "/usr/lib/python2.7/runpy.py", line 162, in _run_module_as_main
"__main__", fname, loader, pkg_name)
File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
exec code in run_globals
File "/usr/local/lib/python2.7/dist-packages/pywws/Hourly.py", line 108, in <module>
sys.exit(main())
File "/usr/local/lib/python2.7/dist-packages/pywws/Hourly.py", line 105, in main
return Hourly(args[0])
File "/usr/local/lib/python2.7/dist-packages/pywws/Hourly.py", line 78, in Hourly
hourly_data, daily_data, monthly_data).do_tasks():
File "/usr/local/lib/python2.7/dist-packages/pywws/Tasks.py", line 70, in __init__
self.daily_data, self.monthly_data, self.work_dir)
File "/usr/local/lib/python2.7/dist-packages/pywws/Plot.py", line 476, in __init__
os.makedirs(self.work_dir)
File "/usr/lib/python2.7/os.py", line 157, in makedirs
mkdir(name, mode)
OSError: [Errno 2] No such file or directory: ''
-
Hi Marty,
I think that in your Weather.ini file, local_files should
point to your web folder: /var/www/
So try, local_files = /var/www/data/
Regards,
Jacques
-
Many thanks, I think the bit I may be stuck on is where the 'pywws' folder is?
I'm trying to work out where all the data is contained as currently I have the following folders under /home/pi:
webdata - contains the following folders:
data
images
plot text
weather - contains the following folders:
data
plot
temp
templates
text
Going into weather/data folder I see:
calib
daily
hourly
monthly
raw
satuts.ini
weather.ini
Is this weather.ini the one I need to edit?
-
Many thanks, I think the bit I may be stuck on is where the 'pywws' folder is?
I'm trying to work out where all the data is contained as currently I have the following folders under /home/pi:
webdata - contains the following folders:
data
images
plot text
weather - contains the following folders:
data
plot
temp
templates
text
Going into weather/data folder I see:
calib
daily
hourly
monthly
raw
satuts.ini
weather.ini
Is this weather.ini the one I need to edit?
I am also setting up a weather station following dragontail.co.uk instructions - as I was setting up I got an number of error reports and found that some of the directories required re-locating (just copied them from one location to another) that seemed to work and I did get data from the weather station. Having said that I had to use sudo to get it to work properly - still have to figure that one out.
Being a complete novice - even setting up a website has been a struggle so the templates on this site look very attractive. Now I have my rudimentary website up and running but NO DATA - I look at your site and you have data - did you create a new ftp "account" (you can see what a novice I am when I'm not sure if this is called an account ?).Andy (from dragontail.co.uk) did give me some pointers but so far I have failed miserably to get data to flow.
I created an ftp "account" called pieweatherdata and have put that name into the pi weather.ini file together with password.
But then I followed Andy's instructions to copy over my helloworld file (renamed index.html) to the html directory. But found that the ftp account I had created did not have a html directory.
I know that you were asking for help -
If you can tell me the steps you took to get your data onto the web I would be most grateful.
BTW I did find pwss - it was in /usr/local/lib/python2.7/dist-packages/
there were two... pywws and pywss-14.05.dev1208.egg-info
GrahamP