Skip to content

Instantly share code, notes, and snippets.

@thomasnorris
Last active October 22, 2023 03:36
Show Gist options
  • Star 44 You must be signed in to star a gist
  • Fork 5 You must be signed in to fork a gist
  • Save thomasnorris/ffccd67a3d29283a05ff79576936cdba to your computer and use it in GitHub Desktop.
Save thomasnorris/ffccd67a3d29283a05ff79576936cdba to your computer and use it in GitHub Desktop.
Instructions for installing a fresh image of Raspbian and turning the Pi into a kiosk (for google slides, google photos, etc)

Raspberry Pi Kiosk Setup

  • Install a fresh image of Raspbian and boot the Pi
  • Go through the prompts to finish initial setup
  • Open a Termial window
    • Type sudo apt-get install unclutter
    • Type sudo raspi-config
      • Select Boot Options with Enter
        • Select Wait for Network at Boot with Enter
        • Select Yes with Enter
        • Press Enter again
      • Press Enter again
      • Press Esc
    • Type sudo nano /home/pi/.config/lxsession/LXDE-pi/autostart
      • In this file:
        • Comment this line by putting a # in front of it to disable the screen saver
          • @xscreensaver -no-splash
        • Disable power saving of the attached monitor
          • @xset s off -dpms
        • Remove the mouse cursor from the screen
          • @unclutter -idle 0
        • Start Chromium in full screen at the desired URL
          • @chromium-browser --kiosk --incognito http://site-to-launch.com
            • The --kiosk flag starts Chromium in full screen
            • The --incognito flag hides any message about Chromium not cleanly exiting/crashing
        • Save the file
          • Press Ctrl+X
          • Press Y
          • Press Enter
    • Type sudo nano /boot/config.txt
      • In this file:
        • Uncomment this line by removing the # in front of it to disable screen overscan
          • disable_overscan=1
        • Add this line to increase GPU memory
          • gpu_mem=128
        • Save the file
          • Press Ctrl+X
          • Press Y
          • Press Enter
    • Type crontab -e
      • Pick Nano as the editor if prompted
      • In this file:
        • Add this line to reboot the Pi every day at 12 am via a Cron
          • 0 0 * * * sudo reboot
        • Save the file
          • Press Ctrl+X
          • Press Y
          • Press Enter
    • Type sudo reboot
      • The Pi will reboot
  • On reboot, Chromium should open the specified URL in full screen mode and the Pi will automatically reboot according to the schedule set above
    • Exit to the Raspbian desktop with Alt+F4
@EtzBetz
Copy link

EtzBetz commented Aug 17, 2018

Nice guide, wish this would've existed earlier, as I had to find everything manually.

Does Incognito hide the message about not cleanly exiting/crashing? If so, I should probably change my setup so that I don't edit the chromium config file but just open incognito.

@thomasnorris
Copy link
Author

@eionsimonelli thanks for the help!

@thomasnorris
Copy link
Author

@derRAV3N Yes, that is what the --incognito flag does. I updated the document to include that.

@eionsimonelli
Copy link

Awesome project dude!

@tailorvj
Copy link

I suggest you check out FullPageOS distro, which does it for you and allows you to set the URL and wifi details in a simple text files on the microSD card.
FullPageOS is also configurable in a way that allows you to create distro variants with your own custom boot commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment