Community Support

Extended webcam support  

  RSS
Chris
(@zerog981)
Reputable Member 🇩🇪🇦🇹🇨🇭Editor

Hi Pierre 🙂 

I really like the image viewer and timelapse generator (btw the handbook shows "No timelapse for this date." when following the "See in action" button...might be an issue) but since I do not own a Bloomsky station I was wondering if it is feasable to add the live snapshots of any webcam. For instance if I provide the path to a self refreshing image or whatever kind of source Weather Station requires.

Will this be difficult to implement?

Thanks!

Chris

I like the cold weather. It means you get work done.

Quote
Posted : 25/11/2018 1:34 pm
boonrob liked
Pierre Lannoy
(@pierre-lannoy)
Member Admin

Hi Chris!

Thanks for the hint (regarding the "No timelapse for this date."), I had it fixed on a particular date that I found the timelapse really beautiful. And it was a date older (today) than what the timelapse retention time allows  🤣
It's fixed, I set "yesterday" as date...

Regarding you question, first know that the timelapse is an integrated feature offered by the Bloomsky station itself: it is not Weather Station that builds these timelapses. But this is not really difficult to do and if it was possible to collect regular "live" snapshots, it would be quite feasible.
What is more of a problem is the lack of access "standards" for webcams. As a result, this would require to develop one connector per camera brand or model  😱 

This could be possible if I "discover" a standard. I will look at this after the 3.7 release. 

Do you personally already use this type of camera?

If you like Weather Station, please consider to make a review to help make it known. That would be the best way to thank me...

ReplyQuote
Posted : 25/11/2018 4:41 pm
Chris
(@zerog981)
Reputable Member 🇩🇪🇦🇹🇨🇭Editor

Ahhh I see, that's why the BloomSky watermark is there.

I'm currently testing the Hikvision 2CD2385FWD-I and if everything goes according to plan I will buy some more of these. It allows me to both stream the live image over HTTP(S), Multicast and other protocols and to upload images periodically via FTP or SMB. Due to restricted bandwidth I'm currently planning to work with the FTP approach. The camera will upload an image every minute to an FTP server overwriting the previous one.

While being not the most elegant way I think using FTP is kind of a "standard" almost every webcam is capable of. The idea is to let the webcam upload the image to the FTP server and let Weather Station fetch it from there.

Maybe that's something simple to start with and I'm happy to help you with testing 😉 

This post was modified 2 years ago by Chris

I like the cold weather. It means you get work done.

ReplyQuote
Posted : 25/11/2018 7:53 pm
Pierre Lannoy
(@pierre-lannoy)
Member Admin

I moved this post in "idea and suggestions" and... yes, I accept your proposal for tests  😋 

If you like Weather Station, please consider to make a review to help make it known. That would be the best way to thank me...

ReplyQuote
Posted : 25/11/2018 7:57 pm
Chris liked
Erwin Fiten
(@erwin)
Eminent Member

I know most of the IP camera's have a URL, that responds with a basic JPEG image, so if the response is ONLY the JPEG, i think it's not that difficult to collect that image 'somewhere', just let a CRON job browse that URL and save the received image.

 

Erwin

 

ReplyQuote
Posted : 27/12/2018 10:19 am
boonrob liked
david.g
(@david-g)
New Member

Hi Everyone,

I already use this absolut great plug in for weather data. Now I am looking for the same as Chris.
I use two webcams. Each camera upload the image to the server via FTP. Now I am looking for a way to generate timelapse videos of the last day.
Unfortunatly I coudn't find anything regarding this in the changelog.

But I saw it on Chris' site (/ https://wetter.seiersberg-pirka.gv.at/zeitraffer-station-gedersberg-hb1/ ).
@ Chris: Have you used Bloomsky for that or is there a way with regular webcams?

Thanks!
David

ReplyQuote
Posted : 31/12/2019 7:32 pm
Chris
(@zerog981)
Reputable Member 🇩🇪🇦🇹🇨🇭Editor

Hello @ david.g,

I'm glad you like this feature, but I have to disappoint you a little bit, because this was not done using Weather Station. As you already mentioned Weather Station only supports webcams of Bloomsky stations (for now). But if you already upload your images via FTP it's only a minor step towards generating your own timelapse videos. Very similar to our approach you can use the freely available and easy to use ffmpeg software. This software can be integrated in many programming languages and scripts but can also be used directly on the command line. I don't know what platform/server structure you're using, but for generating timelapse videos from a folder of pictures you may find the following command useful:

ffmpeg -i "Temp\%%d.jpg" -r 25 -vcodec libx264 -pix_fmt yuv420p -profile:v baseline -level 3 "output.mp4"

with all images being stored in a folder Temp, using 25 frames per second and some codec settings. The generated timelapse video is saved to output.mp4 and needs to be uploaded to your webserver directory and added to some page.

Of course, I assumed you're already familiar with coding and the command line. If not I probably can help you anyway, even if automating the whole process (from webcam to webpage) is a little bit tricky without prior knowledge 😉 Earlier in our project (before switching all servers to Linux) I created a small batch script for Windows. If you want, I can share the code and help you setting it up. Just give me some more information about the platform and server structure you're using.

Chris

This post was modified 7 months ago 2 times by Chris

I like the cold weather. It means you get work done.

ReplyQuote
Posted : 02/01/2020 7:34 pm
david.g
(@david-g)
New Member

Hi Chris

Thanks for your answer.
I am more the embedded guy. So I'm not an expert in the whole desktop and wep stuff.
But I took a quick look at the ffmpeg tool and I was able to render a short video with your comand line on windows. 😍
It's a very cool tool.
I will play around with it in the next few days and then report whether it works.

David

 

ReplyQuote
Posted : 02/01/2020 9:13 pm
Chris
(@zerog981)
Reputable Member 🇩🇪🇦🇹🇨🇭Editor

Hi David,

that's good news. Feel free to ask if you have any further questions 😉 

Chris

I like the cold weather. It means you get work done.

ReplyQuote
Posted : 03/01/2020 3:22 pm
david.g liked
CKayaks
(@ckayaks)
New Member
Posted by: @zerog981

While being not the most elegant way I think using FTP is kind of a "standard" almost every webcam is capable of. The idea is to let the webcam upload the image to the FTP server and let Weather Station fetch it from there.

Maybe that's something simple to start with and I'm happy to help you with testing 😉 

Hello Pierre and Chris,

Second the request if that matters. 🙂 I came across Weather Station while searching for something very much like this.

Background:
I have an Ecowitt weather station and a Reolink IP camera. I feed weather data out through an Ecowitt GW1000 to WU, Ecowitt weather (similar to Ambient.net), PWS Weather. I can easily get snapshots and time series video out of the webcam by using IPTimelapse software. It also integrates weather data into the image or video. There is an option to put the images into a date folder structure. Uploads of the images can be scheduled via FTP from IPTimelapse. IPTimelapse is a commonly used for IP cameras but the approach is similar in other software I looked at in my searching. Weather Display, for example, may be another route. I just glanced at the software last night and it looks like they also can capture image and video and do the FTP uploads. Have to verify that though.  

Use case:
My thinking was along the lines of Chris': FTP the images into a designated folder on the WP site and then read them into the plug-in. That would save you (Pierre) the burden of developing for every crazy camera out there. Let IPTimelapse, Weather Display, etc. do the lifting on that end. Ideally, be able to read in a date-stamped folder and have a widget that allows the user to scroll through the images in sequence. Have that range be dynamic: current day, last 24-hours, last week, last month, etc. While the plug-in could have the capability to create a time-sequence video, the feeding software could easily just supply that instead. 

Have thought about trying to write a script to do something like this but would prefer a plug-in. My wife is the household WP expert. I barely plug away at the minimalist site I have right now. Have some time on my hands for the moment so am looking at adding to the site, the weather data and webcam being the first target. I do have some programming experience with Python, R, C, Java but not WP, PHP, Javascript, or HTML. May be time to learn these as well. Groan! 🙂

Thank you for the consideration. I plan on trying out the plug-in over the next few days. 

"The cure for anything is salt water: sweat, tears, or the sea." Isak Dinesen

ReplyQuote
Posted : 27/02/2020 4:53 pm
Chris
(@zerog981)
Reputable Member 🇩🇪🇦🇹🇨🇭Editor

Hello and welcome @ckayaks,

I hope you find Weather Station as useful as I do. Feel free to post any questions you have.

As for the webcam I can give you some further insight in how I've implemented this at the moment: The best example is one of our remote stations with limited internet access. The setup is as follows:

Webcam <------ HTTP ------ On site Linux machine + Storage + Timelapse processing <------ SFTP for timelapse videos, HTTPS for live image ------ Linux Server (Webserver, Timelapse 2nd processing)

The on site Linux machine regularly fetches an image from the webcam, blurs out sensitive areas and adds some text to the image. The images are then stored locally on a hard drive. Since internet access is very limited especially in terms of data usage it is not possible to directly transfer the individual high quality images and create the timelapse sequence on the server. Instead, the local machine preprocesses all images during nighttime using ffmpeg into a timelapse video encoded with the highly efficient H.265 codec. This process takes some time (1 hour approx.). The video is then fetched by the server via SFTP, processed again with webpage optimization in mind and displayed on the webpage using PHP. To store the high quality raw images I copy them twice a year when I'm inspecting the remote location.

Of course, one could also use the built in FTP server most webcams have, as you suggested. I assume, Pierre, the developer of this plugin, is rather busy at the moment, so we have to wait a little longer to see if and how he wants to implement this. In the meantime I'm happy to support you and share my experience if you have further questions.

Chris

By the way: Nice image! 😀 

This post was modified 6 months ago by Chris

I like the cold weather. It means you get work done.

ReplyQuote
Posted : 29/02/2020 11:22 am
CKayaks
(@ckayaks)
New Member

Hi Chris,

Thanks for the reply. The webcam is right outside my home office window. That is my view most days. 🙂 We sit on ten acres in western Montana. 

The process you outlined is indeed what I had in mind. Started my PHP studies and looking at code samples to sort this out with my setup.  I will ping you if I hit any snags. The image overlay and FTP is not a problem. The IPTimelapse software covers that. I can get sets of snapshots and daily videos FTP'd to the host site from the software. It is loading a set of images up a WP page within a date range (e.g. "show the last five days of snapshots or daily videos") that is the challenge. The files are structured into date folders. Will need to loop through the appropriate folder and then load to the page.   

"The cure for anything is salt water: sweat, tears, or the sea." Isak Dinesen

ReplyQuote
Posted : 02/03/2020 9:50 pm

To participate, please connect first!