Skip to content

fbcp driver for SPI based displays for Raspberry Pis via fbcp-ili9341

Notifications You must be signed in to change notification settings

megankde/fbcp

 
 

Repository files navigation

balenablocks/fbcp

Provides fbcp driver for SPI based displays for Raspberry Pis via fbcp-ili9341

Supported Displays

fbcp-ili9341 supports several displays but we have compiled images for

Display Tag Tested Tested On
Adafruit PiTFT - Assembled 480x320 3.5" TFT+Touchscreen for Raspberry Pi adafruit-hx8357d-pitft 3B+
Adafruit 2.8" 320x240 TFT w/ Touch screen for Raspberry Pi adafruit-ili9341-pitft
Adafruit PiTFT 2.2" HAT Mini Kit - 320x240 2.2" TFT - No Touch adafruit-ili9341-pitft
Freeplay CM3 DIY Kit freeplaytech-waveshare32b
Waveshare 3.5" 480x320 (ILI9486) waveshare35b-ili9486
Tontec 3.5" 320x480 LCD Display tontec-mz61581
Waveshare 240x240, 1.3inch IPS LCD display HAT for Raspberry Pi (ST7789VW) waveshare-st7789vw-hat
Waveshare 128x128, 1.44inch LCD display HAT for Raspberry Pi (ST7735S) waveshare-st7735s-hat
KeDei 3.5 inch SPI TFTLCD 480*320 16bit/18bit version 6.3 2018/4/9 kedei-v63-mpi3501

Usage

fbcp is meant to be used alongside other services, so you will need to create a service in your docker-compose.yml file:

The images are build for individual display and are found at balenablocks/fbcp:<tag>. balenablocks/fbcp itself is an image that includes support for all the above display types and the driver to be loaded is selected based on the value of the tag set to the FBCP_DISPLAY environment variable.

If you need support for only one display

version: "2.1"

services:
  fbcp:
    image: balenablocks/fbcp:<tag>
    privileged: true

... other services

So for example, if you are using fbcp with the Adafruit PiTFT - Assembled 480x320 3.5" TFT+Touchscreen along with the dashboard and browser blocks with a Raspberry Pi 3, you would use the following docker-compose.yml file

version: "2.1"

services:
  fbcp:
    image: balenablocks/fbcp:adafruit-hx8357d-pitft
    privileged: true
  dashboard:
    image: balenablocks/dashboard:raspberrypi3
    restart: always
    network_mode: host
    volumes:
      - "dashboard-data:/data"
    ports:
      - "80"
  browser:
    image: balenablocks/browser:raspberrypi3
    network_mode: host
    privileged: true
    environment:
      - "KIOSK=1"

If you need to set the driver at runtime, use

version: "2.1"

services:
  fbcp:
    image: balenablocks/fbcp
    privileged: true

Then set the FBCP_DISPLAY environment variable. e.g FBCP_DISPLAY=adafruit-hx8357d-pitft

Configuring HDMI and TFT display sizes

The following Device Configuration variables might be required for proper scaling and resolutions:

Name Value
BALENA_HOST_CONFIG_hdmi_cvt <width> <height> <framerate> <aspect> <margins> <interlace> <rb> e.g 480 320 60 1 0 0 0
BALENA_HOST_CONFIG_hdmi_force_hotplug 1
BALENA_HOST_CONFIG_hdmi_group 2
BALENA_HOST_CONFIG_hdmi_mode 87

These lines hint native applications about the default display mode, and let them render to the native resolution of the TFT display. This can however prevent the use of the HDMI connector, if the HDMI connected display does not support such a small resolution.

You can read more about these settings in the original fbcp-ili9341 documentation here.

About

fbcp driver for SPI based displays for Raspberry Pis via fbcp-ili9341

Resources

Stars

Watchers

Forks

Packages

 
 
 

Languages

  • Shell 66.1%
  • Dockerfile 33.9%