
Reads pixel data from QSPI flash using a DTR read. Displays on VGA.
Timing and latency are very configurable, hopefully allowing full resolution images at up to 720p and 1024x768 resolutions.
The image format is RGB332, which can be either truncated or dithered to the RGB222 format required by the Tiny VGA PMOD.
There are two config shift registers that control the design. The first controls the VGA timing parameters, plus a trigger count of how many cycles before the active display region the QSPI read should be started. The second sets the address of the QSPI read, whether to use full res mode, and whether to dither.
The active config register is selected by in7. This should allow quick changing of the address without affecting VGA configuration.
Flash an RGB332 image to the QSPI flash (e.g. using the Tiny Tapeout flasher), set the config registers, and enable.
The image address can be set to any multiple of 128kB, allowing multiple images to be stored and switched between by changing the config register. This should allow short animations to be displayed with a simple script on the RP2.
You can create RGB332 images using the make_img_bin.py script in the repo.
The photo.py script in the upy directory gives an example of how to configure the design.
By default, images should be half the resolution of the configured timing mode. For full resolution images you must double the clock rate, double all the horizontal timing parameters, and set the full res bit in the QSPI config register.
QSPI PMOD, Tiny VGA PMOD
| # | Input | Output | Bidirectional |
|---|---|---|---|
| 0 | Config clk | R[1] | CS |
| 1 | Config data | G[1] | SD0 / SCK |
| 2 | Display enable | B[1] | SD1 / SD0 |
| 3 | Select QSPI pinout | vsync | SCK / SD1 |
| 4 | QSPI latency 0 | R[0] | SD2 |
| 5 | QSPI latency 1 | G[0] | SD3 |
| 6 | QSPI latency 2 | B[0] | Unused CS |
| 7 | Config register selection | hsync | Unused CS |