GC9A01 Display
The gc9a01 is a chip that drives a 240x240 round display that is connected to a microcontroller by an SPI display.
The current gc9a01 drivers are not compatable with the current release of framebuf in
the standard MicroPython runtime. Therefore the standard framebuf functions
such as ellipse()
and poly()
functions do not work. This limits the portability
of many of or clock and watch example.
The good news is that you can do some drawing operations faster and your code
does not have to run the show()
command. Functions such as line()
will draw directly to the display.
To connect we need to either use a firmware version or load the driver into the /lib directory and we can then use the following code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 |
|
Rotation
The driver supports 8 different types of rotations:
- 0 - PORTRAIT
- 1 - LANDSCAPE
- 2 - INVERTED PORTRAIT
- 3 - INVERTED LANDSCAPE
- 4 - PORTRAIT MIRRORED
- 5 - LANDSCAPE MIRRORED
- 6 - INVERTED PORTRAIT MIRRORED
- 7 - INVERTED LANDSCAPE MIRRORED
In our labs we have the connector at the bottom so we use the Portrait rotation of 0 which is the default rotation.
References
- Russ Hughes - Russ provides firmware images that you can use for both the Pico and Pico W.