Bruno Santos
Published © GPL3+

Interactive Winter Wonderland

Imagine a winter wonderland at your fingertips! Snow Globe Touch is an interactive holiday-themed display.

IntermediateFull instructions provided2 hours295
Interactive Winter Wonderland

Things used in this project

Hardware components

Raspberry Pi Zero 2 W
Raspberry Pi Zero 2 W
Probably the first version will also work.
×1
Pimoroni HyperPixel 4.0 Square
Any other touch screen should work
×1

Software apps and online services

Raspbian
Raspberry Pi Raspbian

Hand tools and fabrication machines

3D Printer (generic)
3D Printer (generic)

Story

Read more

Code

findPimoronisTouchDevice

SH
This discovers and returns the touch device for the Hyperpixel 4.0 touch screen
#!/bin/bash

# Define the device name to search for
DEVICE_NAME="11-0048 EP0110M09"

# Read the input file
INPUT_FILE="/proc/bus/input/devices"

# Use awk and extract only the 'eventX' part
awk -v name="$DEVICE_NAME" '
    BEGIN { found = 0 }
    $1 == "N:" && $0 ~ name { found = 1 }   # Match Name line with the device name
    $1 == "H:" && found {
        for (i = 1; i <= NF; i++) {
            if ($i ~ /^event[0-9]+$/) { print $i; break }
        }
        found = 0
    }
' "$INPUT_FILE"

Interactive Winter Wonderland Simulation

This project simulates falling snow on a customizable screen resolution, with interactive background switching via touchscreen. It uses SDL2 for rendering graphics and libevdev for touchscreen input handling. The program is designed to be lightweight, modular, and extensible.

Credits

Bruno Santos
6 projects • 5 followers
Linux and Raspberry PI lover! Systems and Network Administrator, programmer, kind of a Nerd!
Contact

Comments

Please log in or sign up to comment.