From 4c97c8a7161a5250b4619c7c857bc1f0d59e511f Mon Sep 17 00:00:00 2001 From: Phil Date: Sat, 25 Jan 2025 12:34:13 +0000 Subject: [PATCH] bobvgalcd --- README.md | 2 ++ docs/ZxSpectrumPicomputerZx2Lcd.md | 46 ++++++++++++++++++++++++++++++ src/CMakeLists.txt | 13 +++++++++ 3 files changed, 61 insertions(+) create mode 100644 docs/ZxSpectrumPicomputerZx2Lcd.md diff --git a/README.md b/README.md index 3bb495a..97ded59 100644 --- a/README.md +++ b/README.md @@ -85,6 +85,7 @@ Click on the images below for more information ... + @@ -103,6 +104,7 @@ Click on the images below for more information ... | [HDMI breadboard](docs/ZxSpectrumBreadboardHdmiNPinAudio.md) | Some breadboard HDMI options | | [VGA breadboard](docs/ZxSpectrum4PinAudioVga1111Ps2.md) | Some breadboard VGA options | | [PICO ZX48/128](docs/pico_zx48_128.md) | ZX Spectrum 48K replacement board by Bobricius | +| [PICOZX2 LCD](docs/ZxSpectrumPicomputerZx2Lcd.md) | ZX Spectrum with LCD and VGA Mk 2 by Bobricius | | [PICOZX LCD](docs/ZxSpectrumPicomputerZxLcd.md) | ZX Spectrum with LCD and VGA by Bobricius | | [PICOZX](docs/ZxSpectrumPicomputerVga222Zx.md) | ZX Spectrum with VGA by Bobricius | | [RetroVGA](docs/ZxSpectrumPicomputerVga.md) | VGA micro-computer by Bobricius | diff --git a/docs/ZxSpectrumPicomputerZx2Lcd.md b/docs/ZxSpectrumPicomputerZx2Lcd.md new file mode 100644 index 0000000..1434b82 --- /dev/null +++ b/docs/ZxSpectrumPicomputerZx2Lcd.md @@ -0,0 +1,46 @@ +### ZxSpectrumPicomputerZx2Lcd +This is a target written for Bobricius' PICOZX mk 2 with built in LCD + + + +It supports: +* USB keyboard +* Keyboard martix +* USB joysticks +* VGA video (RGB222) +* LCD video (ST7789) +* PWM sound (1 pin) +* SPI SD card + +By default, the board starts up using VGA as its display. +To boot into LCD mode hold down the 'fire' button during reset. +Placing lcd.txt on the SD card in the zxspectrum folder changes the default to LCD. + + +While on the menu... +* SHIFT-Fire = ESC +* RELOAD = Backspace +* SHIFT-RELOAD = Del + +#### Circuit Diagrams +None as yet + +#### Firmware +| LCD | Colour Encoding | Colour Channel | VGA | Sock | Firmware | +| - | - | - | - | - | - | +| ST7789 | BGR | Normal | 640x480x60Hz | Pico2 | [ZxSpectrumPicomputerZxLcd_640x480x60Hz.uf2](/uf2-rp2350-arm-s/ZxSpectrumPicomputerZx2Lcd_640x480x60Hz.uf2) | +| ST7789 | BGR | Normal | 720x576x50Hz | Pico2 | [ZxSpectrumPicomputerZxLcd_720x576x50Hz.uf2](/uf2-rp2350-arm-s/ZxSpectrumPicomputerZx2Lcd_720x576x50Hz.uf2) | + + +#### Build system notes +The make system has some switches to adapt it to different LCD panels: +| Symbol | Description | PICOZX | ILI19341 | +| ------ | ----------- | ------ | -------- | +| LCD_INVERSE | invert the brightness of the RGB color components | undefined | defined | +| LCD_MIRROR_X | Mirror the LCD output horizontally | defined | undefined | +| LCD_RGB | Use RBG order rather than BGR | undefined | defined | + +#### References +[ILI9341 datasheet](https://cdn-shop.adafruit.com/datasheets/ILI9341.pdf)
+ + diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 22a2ce6..9bf0458 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -291,4 +291,17 @@ if (${PICO_BOARD} STREQUAL "pico") message("Relevant target: ZxSpectrumPicomputer") add_dependencies(relevant ZxSpectrumPicomputer) endif() +######################################################################## +# Picomputer 2 II (RP2350 Only) +######################################################################## +add_custom_target (ZxSpectrumPicomputer2) +add_dependencies (ZxSpectrumPicomputer2 + ZxSpectrumPicomputerZx2Lcd_640x480x60Hz + ZxSpectrumPicomputerZx2Lcd_720x576x50Hz +) +if (${PICO_BOARD} STREQUAL "pico2") + message("Relevant target: ZxSpectrumPicomputer2") + add_dependencies(relevant ZxSpectrumPicomputer2) +endif() +