Halloween Video Kiosk

Use a rasberryPi as a full screen video kiosk
Tagged: funFriday, October 13, 2017

Raspberry Pi Full Screen Halloween Projector

This Halloween I wanted to make a projector that would play scary videos for the holidays. I wanted something that would automatically turn on, play videos at random but have some built in manual controls. I decided to go with a raspberry-Pi that would connect to the projector and a wireless keyboard. As I wanted this to work offline, so I wouldn't have to worry about network connections, I installed apache and set it up so the kiosk would load a page from http://localhost. Then I would use javascript to add keyboard controls to manually activate jump scares or controls for next/prev videos.

Rasberry Pi Setup

I followed the normal getting started instructions and installed the NOOBS version and booted to the desktop.

Then I updated the Pi

sudo apt-get update && sudo apt-get upgrade -y

Installed the software packages needed

sudo apt-get install chromium x11-xserver-utils unclutter apache2

Next we're going to modify the auto start script so everything will fire up automatically

sudo nano .config/lxsession/LXDE-pi
/```


Delete this line to de-activate the screen saver
```javascript
@xscreensaver -no-splash

Next add these lines

@endxset off
@xset -dpms
@xset s noblank
@unclutter -idle 0.1 -root

Now we will configure the chrome browser to launch in kiosk mode and load up the localhost

@chromium-browser --kiosk --incognito localhost

Load apache with your video player webpage

Next you will need to load up the webpage that will play all the videos. By default you should be able to visit http://localhost/ and see the default webpage apache/rasberryPi gives you.

Grab the Code

Just use this github repo https://github.com/NickStees/halloween-video-kiosk and adjust the index.html to match all your videos you want to play in the /videos folder. Be sure to optimize the videos so they play well on the RasberryPi. By default the index.html in that project will make the videos cover the entire screen so you don't have any black bars. But playing videos via a web browser is a little more work for a RasberryPi. After you modified the index.html to match all the videos you added, put those files on a thumb drive, and insert it into the rasberryPi.

Launch explorer as root so you can copy the files to var/www/html/ run the following command so you can copy the files from the thumb drive.

sudo pcmanfm

At this point you should be able to visit http://localhost on the rasberryPi and see your videos start.

Reboot and Test

Next give your pi a reboot and see if the browser launches correctly in kiosk mode. If it doesn't make sure http://localhost is working, and verify the LXDE-pi was the correct one you need to modify.

Notes/Tips

I ran into a few issues with this project so I figured I would give you some tips to maybe help out others who try this out.

  • A lot of RasberryPi setup guides have little bits of outdated steps, so you may have to combine a few together to get things accomplished.
  • The videos may need to be down-sampled or re-encoded if your rasberryPi can't handle the workload. I have an adobe subscription so I used their media encoder to reduce the 1080p videos to 1024x768 which was my projectors native resolution.