Hello guys!,
I'm considering buy a webcam for my weather station but I have absolutely no idea where to begin my search from and what specifications to look for.
I'd prefer something that would offer good images both day and night (in a cityscape, preferably not IR at night but color vision). My budget is around 100€. I have read that Foscam FI9900P is quite popular among weather enthousiasts and I'm seriously considering it, but does anyone have any other suggestions?
Thanks in advance!
Webcam suggestion
- dmgould
- Forecaster
- Posts: 173
- Joined: Sat Aug 26, 2017 2:43 am
- Location: Divide, Colorado, USA
- Station model: Davis Pro 2 Plus Wireless
- Software: Meteobridge
- Contact:
Re: Webcam suggestion
I am using 3 Foscam cameras. The newest is the model you mentioned. They have worked well for me. Here is one thing you should know about the current model. It will ftp using a filename that includes the date and time, and you are not able to control that naming. As a result it places a new image file on your server on whatever schedule you set in the camera, and so that directory quickly fills with files. My solution, with Jachym's help, was to write a simple php file that renames the most recent image file in the directory, and then it deletes any other files. Then the webcam block and plugin use that image to load it into their database. You can also control whether or not you want the IR lights to come on or not after dark.
Dave G
-
- Observer
- Posts: 15
- Joined: Sun Oct 01, 2017 4:41 pm
- Location: Gent,Belgium
- Station model: Davis Vantage Pro 2
- Software: WU
- Contact:
Re: Webcam suggestion
Thank you for the suggestion! I have indeed chosen for the 9900P Foscam, and I just got to install it yesterday when I came back home for the Easter holiday.
I am now really clueless on how to proceed with it (and I also didn't have much time to do the research). I connected it with the app on my phone but that's pretty much all I could do. Would you mind sharing with me how you managed to get yours online (and eventually the script you mentioned above)?
I am now really clueless on how to proceed with it (and I also didn't have much time to do the research). I connected it with the app on my phone but that's pretty much all I could do. Would you mind sharing with me how you managed to get yours online (and eventually the script you mentioned above)?
- dmgould
- Forecaster
- Posts: 173
- Joined: Sat Aug 26, 2017 2:43 am
- Location: Divide, Colorado, USA
- Station model: Davis Pro 2 Plus Wireless
- Software: Meteobridge
- Contact:
Re: Webcam suggestion
I FTP the image to my website using the camera's built in FTP function. It's in the camera menu when you access it via the camera's IP in your browser. While setting this up you probably do not want to FTP on a schedule yet as the server directory will quickly fill up with image files. After you get everything working you can setup the upload schedule.
In the exact directory that my camera uploads the image files, I placed the following php script. In my case I named it sortname.php. I used Notepad++ which correctly creates php files. Script is as follows:
<?php
if ($images = glob("Schedule_*.jpg") ) {
rsort($images);
$img = $images[0];
$newfile = 'image.jpg';
copy($img, $newfile);
}
if ($images = glob("Schedule_*.jpg") ) {
foreach($images as $img){
unlink($img);
}
}
?>
This finds the most recent image upload, renames it image.jpg, and then deletes all other image files in that directory. Eventually you will need to trigger this script using a cron job of some sort or http request. In the meantime you can test it by just entering the correct URL to the script in your browser. Each time you do this it executes the script leaving just the image file image.jpg. Once you have it working you can setup a cron job (or in my case an http request in my Meteobridge) to trigger the script on a schedule. Now you can enter an upload schedule that is also in the camera menu.
At this point you have setup the most recent image file from your camera on your server and can then follow the instructions in the webcam block and plugin to get the image into MT.
In the exact directory that my camera uploads the image files, I placed the following php script. In my case I named it sortname.php. I used Notepad++ which correctly creates php files. Script is as follows:
<?php
if ($images = glob("Schedule_*.jpg") ) {
rsort($images);
$img = $images[0];
$newfile = 'image.jpg';
copy($img, $newfile);
}
if ($images = glob("Schedule_*.jpg") ) {
foreach($images as $img){
unlink($img);
}
}
?>
This finds the most recent image upload, renames it image.jpg, and then deletes all other image files in that directory. Eventually you will need to trigger this script using a cron job of some sort or http request. In the meantime you can test it by just entering the correct URL to the script in your browser. Each time you do this it executes the script leaving just the image file image.jpg. Once you have it working you can setup a cron job (or in my case an http request in my Meteobridge) to trigger the script on a schedule. Now you can enter an upload schedule that is also in the camera menu.
At this point you have setup the most recent image file from your camera on your server and can then follow the instructions in the webcam block and plugin to get the image into MT.
Dave G
-
- Forecaster
- Posts: 190
- Joined: Sat Mar 17, 2018 2:01 am
- Location: Illinois
- Station model: Davis Pro2 Plus
- Software: Meteobridge
Re: Webcam suggestion
Been thinking about getting one myself. I am rural with a 350gig data a month. If you are able to figure it out, what kind of bandwidth is your cam using a month? Uploading like you are. Curious if it's feasible for me. We have been using around 40 gigs a month now.
mchd17
mchd17
- aznetcowboy
- Advisor
- Posts: 50
- Joined: Wed Apr 04, 2018 6:21 pm
- Location: Tucson, AZ
- Station model: Davis Vantage Pro2
- Software: Cumulus
- Contact:
Re: Webcam suggestion
I have been wanting to add a weather camera to my site also, but my needs are I can get power to it, but to run a cable from the camera to the computer is not an option which means it must be Bluetooth or wi-fi. Wireless is the only option I must have. What are the suggestions now. Oh yes, it must also survive summer temperatures is excess of 100 degrees on a regular basis. And when the monsoon finally kicks in, high winds and very severe weather.
Tom Wills
Kingston Knolls Terrace, Tucson, AZ 85710
El Gheko Neighborhood Weather Station: http://www.elgheko.us
El Gheko meteoTemplate Weather Station: http://www.elgheko.us/mtp/
El Gheko Neighborhood Association: http://na.elgheko.us
Certified Skywarn Trained Observer #1569
Kingston Knolls Terrace, Tucson, AZ 85710
El Gheko Neighborhood Weather Station: http://www.elgheko.us
El Gheko meteoTemplate Weather Station: http://www.elgheko.us/mtp/
El Gheko Neighborhood Association: http://na.elgheko.us
Certified Skywarn Trained Observer #1569
-
- Newbie
- Posts: 9
- Joined: Mon Nov 11, 2019 12:26 pm
- Station model: BYOWS with RPi 3b
- Software: weewx with skin Belcherto
Re: Webcam suggestion
hello dmgoud,
I tested your script to rename "images" but it doesn't work.
do you have modify your script ?
thanks
Patrick
I tested your script to rename "images" but it doesn't work.
do you have modify your script ?
thanks
Patrick