Welcome, Guest. Please login or register.
Did you miss your activation email?

Author Topic: [EN] KDE/Plasma desktop -- Live Webcams Slideshow  (Read 1915 times)

Offline dibl

  • siduction community member
  • Global Moderator
  • User
  • *****
  • Posts: 2.364
    • Land of the Buckeye
[EN] KDE/Plasma desktop -- Live Webcams Slideshow
« on: 2024/02/09, 00:31:31 »
For KDE/Plasma desktop users only ....

I really liked the Portalview live wallpaper utility to provide a changing KDE/Plasma desktop background of live webcam photos. Unfortunately, Python 3 was developed to be non-compatible with Python 2 scripts, so that was the end of Portalview.

https://goldnuggetwebs.com/portalview/

As you can see, the author provided a hint for how to use cron and wget to replace the capability of the Python 2 script.

Today I worked on a setup, based on this method. I'm going to share it with the siduction community. I don't claim that anything here is my original idea -- I only put together the information into a working system.

1. I wrote a script named "live-wallpaper.sh" to capture 12 live webcam images from around the world, and save them into a folder on my system named /home/don/IMAGES/live-wallpaper:

Code: [Select]
#live-wallpaper fetcher
#! /bin/bash
wget http://www.jigokudani-yaenkoen.co.jp/livecam/monkey/image.jpg -O /home/don/IMAGES/live-wallpaper/current.jpg > /dev/null
sleep 1
wget http://www.kapstadt.de/webcam.jpg -O /home/don/IMAGES/live-wallpaper/current1.jpg > /dev/null
sleep 1
wget https://stl.seejh.com/tetonvalley/tetonvalley.jpg -O /home/don/IMAGES/live-wallpaper/current2.jpg > /dev/null
sleep 1
wget http://webcam.land-in-sicht.com/feldberg/webcam-seebuck640.jpg -O /home/don/IMAGES/live-wallpaper/current3.jpg > /dev/null
sleep 1
wget https://spu.edu/webcam/pics/bertona.jpg -O /home/don/IMAGES/live-wallpaper/current4.jpg > /dev/null
sleep 1
wget http://www.kilicam.com/cam_image/tuskerpic.jpg -O /home/don/IMAGES/live-wallpaper/current5.jpg > /dev/null
sleep 1
wget http://www.tierradelfuego.org.ar/webcam/ima/2014/06/20140624-021.jpg -O /home/don/IMAGES/live-wallpaper/current6.jpg > /dev/null
sleep 1
wget http://www.annamarialech.at/webcam/webcamannamaria.jpg -O /home/don/IMAGES/live-wallpaper/current7.jpg > /dev/null
sleep 1
wget http://www.hko.gov.hk/wxinfo/aws/hko_mica/cch/latest_CCH.jpg -O /home/don/IMAGES/live-wallpaper/current8.jpg > /dev/null
sleep 1
wget http://live.opatija.net/image2.jpg -O /home/don/IMAGES/live-wallpaper/current9.jpg > /dev/null
sleep 1
wget https://www.feuchtwangen.de/webcam/storch.jpg -O /home/don/IMAGES/live-wallpaper/current10.jpg > /dev/null
sleep 1
wget http://www.prolocobogliasco.it/webcam/current.jpg -O /home/don/IMAGES/live-wallpaper/current11.jpg > /dev/null
sleep 1
wget https://mesonet.agron.iastate.edu/data/camera/stills/KCRG-027.jpg -O /home/don/IMAGES/live-wallpaper/current12.jpg > /dev/null
sleep 1

I named this script "live-wallpaper.sh". The reason for 12 (actually 13) images is, I want to show each one on my Plasma desktop for 5 minutes, and cron does provide a capability to run once per hour, so it will refresh the images every hour.

2. I used systemctl to enable cron and I edited crontab to add the following line:

Code: [Select]
0 * * * * /home/don/live-wallpaper.sh
This line tells cron to run the script once each new hour, refreshing the images.

3. Use systemctl to start cron and verify that the cron service is running.

4. On the Plasma desktop, right-click and choose "Configure Desktop and Wallpaper". Choose "Desktop" for layout, and "Slideshow" and "Scaled and Cropped". Set the Order and Change Time as you wish -- I use "A to Z" and 5 minutes. Use "Random" if there are more than 12 images at 5 minute intervals. Or use a shorter interval if you want.

5. Set the folder to /home/user/yourpictures/live-wallpaper, and "Apply".

Now, you can find webcams that show scenes that you want to see, and edit the script accordingly.

Enjoy that background of changing views!
« Last Edit: 2024/02/10, 10:25:58 by dibl »
System76 Oryx Pro, Intel Core i7-11800H, SSD 970 EVO Plus;  Asus ROG STRIX X299-E, Core i7-7740X, Nvidia GTX-1060, dual monitors, SSD 860 EVO