Skip to content

Experiment with the RP2040 based board with a round 240x240 pixel display.

Notifications You must be signed in to change notification settings

DeShrike/pico-waveshare

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Waveshare RP2040 Round Touch LCD 1.28"

Experiment with the RP2040 based board with a round 240x240 pixel display.

https://www.waveshare.com/rp2040-touch-lcd-1.28.htm

RP2040-Touch-LCD-1.28

SKU: 24580

  • Linux (tested on Ubuntu 18.04.1)
  • C / C++
  • Command line
  • Pico SDK
  • Docker (optional)
  • LVGL

Installation

cd <your projects folder>
git clone https://www.github.com/deshrike/pico-waveshare
cd pico-waveshare
git submudule update --init

Pico SDK

You can compile the Pico programs locally, or using Docker.

To compile locally, install the Pico SDK.

To use a Docker image, follow these steps:

cd <your projects folder>
mkdir pico-waveshare
docker run -d -it --name pc1 --mount type=bind,source=${PWD},target=/home/dev lukstep/raspberry-pi-pico-sdk:latest

After a reboot, you will need to restart the container:

docker start pc1

Connect to the Docker container:

docker exec -it pc1 /bin/sh

Inside the Docker container:

cd /home/dev/pico-waveshare

Compiling

cd /home/dev/pico-waveshare  (if using Docker)
cd <your projects folder>/pico-waveshare (if you have installed the Pico SDK locally)

cd cdjwatch
mkdir build
cd build
cmake ..
make

The build folder should now contain a file called cdjwatch.uf2. Copy this file to the device.

Follow the same steps for the other examples: blink, canvastest and lvgltest.

Examples

blink

Pico example to blink the on-board LED (Backlight).

lvgltest

Example from Waveshare. LVGL, Touch, LCD, Sensors.

cdjwatch

Simple LVGL test showing some text and a logo.

canvastest

My own easy framework to write to the screen and read touch input.

Drawing primitives: rectangle, circles, lines, ascii font, ...