• sales

    +86-0755-88291180

Raspberry Pi 1.54inch LCD Bookworm-Lite Display and Touch

Step 1】Test Environment
Official image version
2024-03-15-raspios-bookworm-armhf-lite.img And
 2024-03-15-raspios-bookworm-arm64-lite.img

Pi' Version :  Zero(zero not support arm64)、Zero 2W、3B、4B、5B

HAT :  spotpear rpi-1.54inch-lcd


Step 2】Download the necessary software:

Update system】

sudo apt update -y&& sudo apt upgrade -y&& sudo apt full-upgrade -y

Install xorg service】

sudo apt-get install --no-install-recommends xserver-xorg -y

sudo apt-get install --no-install-recommends xinit -y

Install desktop manager】

sudo apt install lightdm -y

Install Raspberry Pi official GUI】

sudo apt install raspberrypi-ui-mods -y

Install browser (optional)】

sudo apt install chromium-browser -y

Step 3】Configure SPI display:

Copy spotpear_240x320_st7789.dtbo to /boot/overlays/ directory

sudo cp spotpear_240x240_st7789_lcd1inch54.dtbo /boot/overlays/

Edit config.txt configuration file】

sudo nano /boot/firmware/config.txt

Disable KMS】

#dtoverlay=vc4-kms-v3d

#max_framebuffers=2

Add the following configuration at the end of the file】

dtparam=spi=on

dtoverlay=spotpear_240x240_st7789_lcd1inch54

hdmi_force_hotplug=1

max_usb_current=1

hdmi_group=2

hdmi_mode=87

hdmi_cvt 480 480 60 6 0 0 0

hdmi_drive=2

display_rotate=0

Set CLI automatic login】

sudo raspi-config nonint do_boot_behaviour B2

Noto: This command has optional parameters

B1 - Boot to console, requiring login

B2 - Boot to console, logging in automatically

B3 - Boot to desktop, requiring login

B4 - Boot to desktop, logging in automatically

Note: Make sure the username of the Raspberry Pi is pi, otherwise it will not log in automatically

Switch to X11】

sudo raspi-config nonint do_wayland W1

Note: This command has optional parameters

W1 - Use the X11 backend

W2 - Use the Wayland backend

Download, compile and install fbcp】

sudo apt update

sudo apt-get install git -y

sudo git clone https://github.com/tasanakorn/rpi-fbcp.git

cd ./rpi-fbcp/

sudo mkdir -m 777 ./build

cd ./build/

sudo apt install libraspberrypi-dev -y

sudo apt-get install cmake -y

sudo cmake ..

sudo make

sudo install fbcp /usr/local/bin/fbcp


Set auto-start startx and fbcp】

sudo nano ~/.bash_profile

Note: If there is no .bash_profile file, create one yourself

Add the following code to the bottom of the .bash_profile file】

if [ "$(cat /proc/device-tree/model | cut -d ' ' -f 3)" = "5" ]; then

# Raspberry Pi 5B configuration

export FRAMEBUFFER=/dev/fb1

startx 2> /tmp/xorg_errors

else

# Non-Raspberry Pi 5B configuration

export FRAMEBUFFER=/dev/fb0

sleep 20

fbcp &

startx 2> /tmp/xorg_errors

fi

The above configuration will take effect after restart】

sudo reboot

Note: After setting ~/.bash_profile configuration, the system will take longer each time it restarts, and SSH will also take a while to enter;

Step 4】Configure Touch:

Install the calibrator software

sudo apt-get install xserver-xorg-input-evdev

sudo cp -rf /usr/share/X11/xorg.conf.d/10-evdev.conf /usr/share/X11/xorg.conf.d/45-evdev.conf

sudo apt-get install xinput-calibrator

Edit the 99-calibration.conf configuration file

sudo nano /usr/share/X11/xorg.conf.d/99-calibration.conf

Section "InputClass"

        Identifier      "calibration"

        MatchProduct    "ADS7846 Touchscreen"

        Option  "Calibration"   "326 3536 3509 256"

        Option  "SwapAxes"      "1"

        Option "EmulateThirdButton" "1"

        Option "EmulateThirdButtonTimeout" "1000"

        Option "EmulateThirdButtonMoveThreshold" "300"

EndSection

The above configuration will take effect after restart】  

sudo reboot


TAG: Luckfox Pico ST7789 Computer Secondary Screen X1202 Raspberry Pi 5 UPS Board Uninterruptible Power Supply For 18650-Li-Battery (NOT includ) 4-Ports ESP32-S3 Development Board 1.47 inch LCD Screen Display 172x320 SD-Port LVGL USB Modbus-Series-BootLoader-Description User Guide JETSON-IO-BASE-A user Guid Industrial Modbus RTU 8 ch Relay Module RS485 Bus Raspberry Pi 0.96inch RGB OLED Zero LCD HAT (A) Raspberry Pi 5 PCIe USB HUB 3.2 Gen1 HAT+ High Speed Pi5 Raspberry Pi Secondary Screen Raspberry Pi Mipi display Raspberry Pi Pico 2 RP2350 1.69 inch LCD TouchScreen Development Board 240x280 1.69inch Display QMI8658 6-Axis Raspberry Pi Pico 2 RP2350B 2.8 inch LCD Development Board RGB Display Round TouchScreen 480x480 LVGL QMI8658 / SD / RTC Raspberry Pi Pico 2 RP2350 Core A Development Board RP2350A ESP32 S3 Development Board 2.8 inch B LCD 2.8inch Display 480x640 TouchScreen QMI8658 Sensor / Battery Port LVGL/HMI For Arduino Raspberry Pi 18.5 inch Type C/HDMI/4K Display Screen 3840×2160 Computer PC Phone Xbox/PS4/Switch 1.54inch OLED Display Multi Protection