Tuesday, November 7, 2017

Using RPi3 running raspbian-stretch as a KIOSK browser

Initial setup:

  1. Use Win32DiskImager to burn the 2017-09-07-raspbian-stretch.img file to a micro SD card (it will restart itself after the initial boot and partition resizing)
  2. Open the terminal window and type: sudo raspi-config
  3. Use the configuration tool to
    1. Assign a new password for the user "pi" (default originally set to "raspberry")
    2. Set Localisation Options (set all three to your area)
    3. Enable SSH using Interfacing Options
    4. Enable VNC using Interfacing Options
  4. Restart the Pi

Connect Remotely

Determine the ip address to us with VNC Viewer and PuTTY in a terminal window on the RPi type:ifconfig
Now use the reported IP Address in either PuTTY or VNC Viewer to ensure you have a remote connection. VNC will require the username "pi" along with the password you set during Initial Setup

Set Chromium to auto launch in kiosk mode and disable the screen saver / screen blanking

  1. Launch a terminal window (on the RPi, or using PuTTY).
  2. Edit the startup file to auto launch on boot by typing
    sudo nano /home/pi/.config/lxsession/LXDE-pi/autostart
    to launch the nano text editor against the auto start file.
  3. Add the following lines to the file:
    @xset s off
    @xset -dpms
    @xset noblank
    @chromium-browser --disable-infobars --kiosk http://www.PageToDisplay.com
  4. To disable the crash buble when you power cycle the RPi without closing the chromium session correctly, edit the file etc/rc.local
    sudo nano /etc/rc.local
    Add the following line above "exit 0" [This is one line of code with a single space before the file path]
    sed -i 's/"exit_type":"Crashed"/"exit_type":"none"/' /home/pi/.config/chromium/Default/Preferences

Hide Cursor Visibility

  1. Install unclutter in a terminal window type:
    sudo apt install unclutter

Disable touch capability for the RPi official 7-inch screen

  1. Edit the /boot/config.txt file
    sudo nano /boot/config.txt
    Add the following two lines to the bottom of the file
    # Disable the touch screen
    disable_touchscreen=1