PSla Blog

Blog Piotra Ślatały | Peter Slatala's Blog

Raspberry Pi Photo Frame – 2025 Edition – LABWC

This article looked promising, but 1) compiling picframe took forever, 2) and it failed. Also, I was looking for something less “pythony” and more “I want a lightweight, wayland, window manager” and go from there

Out of scope:

  • Preparing raspberry pi. Out of scope. Simply flash your SD card.
  • Configuring wifi and/or VPN
  • Configuring SSH for remote access

Requirements

  1. I am assuming that your pictures are available locally (not via samba). You may use rsync periodically to push new pictures to your device.
    • The proposed solution will refresh the folder periodically to include new files.
  2. Show images in random order
  3. Hide mouse cursor
  4. Compositor is not supposed to load its own wallpaper, taskbar, filesystem, upgraders, or anything that typically comes with X11/Xorg/Wayland compositors.
  5. Do not use lightdm / or any other desktop manager for that matter.
  6. Configuration must happen completely over SSH, without attaching mouse & keyboard to the raspberry pi

Non goals: transition between images.

Summary

I will use labwc and systemd directly. feh will be used for slide show. lightdm will be disabled, labwc autostart configuration will be simplified to remove unnecessary stuff.

Disable lightdm

Login (via SSH) to your raspberry pi

sudo systemctl stop lightdm
sudo systemctl disable lightdm

Install & enable dependencies

(You likely already have labwc, but not feh)

sudo apt install -y labwc feh seatd policykit-1

Prepare your folder with images

I uploaded all images to /home/psla/wallpapers.

Create and download config

mkdir -p ~/.config/labwc
wget https://raw.githubusercontent.com/labwc/labwc/master/docs/environment -O ~/.config/labwc/environment
wget https://raw.githubusercontent.com/labwc/labwc/master/docs/autostart -O ~/.config/labwc/autostart
wget https://raw.githubusercontent.com/labwc/labwc/master/docs/menu.xml -O ~/.config/labwc/menu.xml
wget https://raw.githubusercontent.com/labwc/labwc/master/docs/rc.xml -O ~/.config/labwc/rc.xml

I then simplified /home/psla/.config/labwc/menu.xml to be:

<?xml version="1.0" encoding="UTF-8"?>

<openbox_menu>
</openbox_menu>

And /home/psla/.config/labwc/autostart is practically empty:

/usr/bin/feh -F -R 3600 --hide-pointer --randomize --slideshow-delay 30 /home/psla/wallpapers/ 2>&1 >> /home/psla/feh.log &
  • –slideshow-delay – how often to change slides
  • -R 3600 – how often to refresh directory list
  • –randomize – to show images in random order
  • -F – full screen

Configure systemd

Create /etc/systemd/system/labwc.service. Replace psla with your username!

sudo nano /etc/systemd/system/labwc.service

[Unit]
Description=Labwc Wayland Window Manager
After=graphical.target systemd-user-sessions.service
[email protected]

[Service]
Type=simple
User=psla
WorkingDirectory=/home/psla
PAMName=login
eset=yes
TTYVHangup=yes
TTYVTDisallocate=yes
StandardOutput=journal
ExecStart=/usr/bin/labwc-pi -C /home/psla/.config/labwc/

StandardOutput=file:/var/log/labwc.out
StandardError=file:/var/log/labwc.err

[Install]
WantedBy=graphical.target

Save the file, then

sudo systemctl deamon-reload
sudo systemctl enable labwc
sudo systemctl start labwc

To check the status, run:

root@# systemctl status labwc
● labwc.service - Labwc Wayland Window Manager
     Loaded: loaded (/etc/systemd/system/labwc.service; enabled; preset: enabled)
     Active: active (running) since Sat 2025-04-26 14:50:04 PDT; 42min ago
   Main PID: 5205 (labwc)
      Tasks: 0 (limit: 374)
        CPU: 107ms
     CGroup: /system.slice/labwc.service
             ‣ 5205 /usr/bin/labwc -m -C /home/psla/.config/labwc/

Apr 26 14:50:04 rpiphoto systemd[1]: Stopped labwc.service - Labwc Wayland Window Manager.
Apr 26 14:50:04 rpiphoto systemd[1]: Started labwc.service - Labwc Wayland Window Manager.
Apr 26 14:50:05 rpiphoto (labwc-pi)[5205]: pam_unix(login:session): session opened for user psla(uid=1000) by (uid=0)

Leave a Reply

Your email address will not be published. Required fields are marked *