diff --git a/README.md b/README.md index 48713cc..a2880a6 100644 --- a/README.md +++ b/README.md @@ -18,6 +18,22 @@ firmware by yourself. ESP8266, ESP32, and STM32 ports are supported for now. +Connecting to the Raspberry Pi Pico +---------------------------------- +This repository is a fork of +[https://github.com/devbis/st7789_mpy/](https://github.com/devbis/st7789_mpy/) +focused on the [Raspberry Pi Pico](https://www.raspberrypi.org/products/raspberry-pi-pico/). + +Here is a firmware for the rp2040 with the st7789 module: +[rp2-st7789-20210412.uf2](https://github.com/udifuchs/st7789_mpy/releases/download/rp2-20210412/rp2-st7789-20210412.uf2). It is based on the github version of MicroPython from 2021-04-12. + +Here is a sample wiring for connecting the [Adafruit 1.3 LCD display](https://learn.adafruit.com/adafruit-1-3-and-1-54-240-x-240-wide-angle-tft-lcd-displays) to the Raspberry PI Pico: +

+ adafruit 1.3 inch display +

+(the source [fritzing]() file is [here](adafruit-1.3-display.fzz).) +The "Lite" pin is not connected to make it fit on a mini breadboard. + Building instruction --------------------- @@ -111,6 +127,19 @@ Also, the driver was tested on STM32 board: display = st7789.ST7789(spi, 135, 240, reset=machine.Pin('B3', machine.Pin.OUT), dc=machine.Pin('B6', machine.Pin.OUT)) display.init() +For the rp2040 with the wiring shown above use: + + import machine + import st7789 + + spi = machine.SPI(1, baudrate=500_000_000, polarity=1) + display = st7789.ST7789( + spi, 240, 240, + reset=machine.Pin(15, machine.Pin.OUT), + dc=machine.Pin(14, machine.Pin.OUT), + cs=machine.Pin(13, machine.Pin.OUT), + ) + display.init() Methods ------------- diff --git a/adafruit-1.3-display.fzz b/adafruit-1.3-display.fzz new file mode 100644 index 0000000..6f127b1 Binary files /dev/null and b/adafruit-1.3-display.fzz differ diff --git a/adafruit-1.3-display_bb.png b/adafruit-1.3-display_bb.png new file mode 100644 index 0000000..ff9992b Binary files /dev/null and b/adafruit-1.3-display_bb.png differ