I will use a Raspberry Pi 3+ with a touch screen to display the most important data of my Home Assistant installation. This guide will work for most other sites as well.
The following hardware is used:
Prerequisites:
- Basic Linux knowledge
- How to connect to your Raspberry via SSH
- How to update your System
How to attach the screen to the Raspberry:
Since it is not the original screen I will attach a picture on how to connect the wires to the Raspberry pi +, if the colors don’t match just make sure you connect SDA or SCL to its counterpart on the board.
Installing the OS
- Install Noobs or Raspberry Pi OS on your Raspberry Pi 3+. Noobs is the easiest if you are new to Raspberry Pi.
- Download the Pi Imager for Windows
- Download Noobs latest
- Flash the SDCard with the Pi Imager
- Open the SDCard and create a ssh (empty) file in the root directory (to enable SSH)
- Put the SDCard into your Raspberry, boot it.
- Follow the instructions on screen.
- Or just follow the instructions here: https://www.raspberrypi.org/downloads/ but don’t forget to add the ssh file into your root directory.
Autostart your Browser
Edit the file autostart with “nano /etc/xdg/lxsession/LXDE-pi/autostart” and add the line, on never version you need to use this folder, otherwise, it will destroy your desktop GUI.
nano /etc/xdg/lxsession/LXDE-pi/autostart @chromium-browser –incognito –start-fullscreen –app=http://YourURL
Turning the screen
Before finishing your setup you might need to turn the screen rotation.
This is done in the file boot/config.txt open it with sudo nano /boot/config.txt and add the following line at the end of the file.
In my case, it was lcd_rotate = 2 if you have another orientation look it up in this table. For the Pi +3 and this screen make sure you use lcd_rotate and not display_rotate.
| lcd_rotate | result |
|---|---|
| 0 | no rotation |
| 1 | rotate 90 degrees clockwise |
| 2 | rotate 180 degrees clockwise |
| 3 | rotate 270 degrees clockwise |
Installing an onscreen keyboard:
For emergency reasons, you want to have a virtual keyboard for your touchscreen. In case you have no keyboard at hand, this could be very handy.
sudo apt install matchbox-keyboard
To open the keyboard from the full-screen website just tap and hold any point and leave the full-screen mode. You will find your virtual keyboard under Menu -> Accessories-> Keyboard.
I will use a Raspberry Pi 3+ with a touch screen to display the most important data of my Home Assistant installation. This guide will work for most other sites as well.
The following hardware is used:
Prerequisites:
- Basic Linux knowledge
- How to connect to your Raspberry via SSH
- How to update your System
How to attach the screen to the Raspberry:
Since it is not the original screen I will attach a picture on how to connect the wires to the Raspberry pi +, if the colors don’t match just make sure you connect SDA or SCL to its counterpart on the board.
Installing the OS
- Install Noobs or Raspberry Pi OS on your Raspberry Pi 3+. Noobs is the easiest if you are new to Raspberry Pi.
- Download the Pi Imager for Windows
- Download Noobs latest
- Flash the SDCard with the Pi Imager
- Open the SDCard and create a ssh (empty) file in the root directory (to enable SSH)
- Put the SDCard into your Raspberry, boot it.
- Follow the instructions on screen.
- Or just follow the instructions here: https://www.raspberrypi.org/downloads/ but don’t forget to add the ssh file into your root directory.
Autostart your Browser
Edit the file autostart with “nano /etc/xdg/lxsession/LXDE-pi/autostart” and add the line, on never version you need to use this folder, otherwise, it will destroy your desktop GUI.
nano /etc/xdg/lxsession/LXDE-pi/autostart @chromium-browser –incognito –start-fullscreen –app=http://YourURL
Turning the screen
Before finishing your setup you might need to turn the screen rotation.
This is done in the file boot/config.txt open it with sudo nano /boot/config.txt and add the following line at the end of the file.
In my case, it was lcd_rotate = 2 if you have another orientation look it up in this table. For the Pi +3 and this screen make sure you use lcd_rotate and not display_rotate.
| lcd_rotate | result |
|---|---|
| 0 | no rotation |
| 1 | rotate 90 degrees clockwise |
| 2 | rotate 180 degrees clockwise |
| 3 | rotate 270 degrees clockwise |
Installing an onscreen keyboard:
For emergency reasons, you want to have a virtual keyboard for your touchscreen. In case you have no keyboard at hand, this could be very handy.
sudo apt install matchbox-keyboard
To open the keyboard from the full-screen website just tap and hold any point and leave the full-screen mode. You will find your virtual keyboard under Menu -> Accessories-> Keyboard.