kopia lustrzana https://github.com/peterhinch/micropython-nano-gui
Tested on rp2.
rodzic
16529f2d0b
commit
ce0f47c7eb
|
@ -86,7 +86,9 @@ GUI supports multiple displays attached to a single target, but bear in mind
|
||||||
the RAM requirements for multiple frame buffers. The GUI has been tested on
|
the RAM requirements for multiple frame buffers. The GUI has been tested on
|
||||||
Pyboard 1.1, Pyboard D and on the ESP32 reference board without SPIRAM. Running
|
Pyboard 1.1, Pyboard D and on the ESP32 reference board without SPIRAM. Running
|
||||||
on ESP8266 is possible but frozen bytecode must be used owing to its restricted
|
on ESP8266 is possible but frozen bytecode must be used owing to its restricted
|
||||||
RAM.
|
RAM. As of 14th March 2021 it has been tested on the Raspberry Pi Pico. The
|
||||||
|
`color15` demo fails because the firmware lacks `uos.urandom()` but hopefully
|
||||||
|
it will be fixed soon.
|
||||||
|
|
||||||
It uses synchronous code but is compatible with `uasyncio`. Some demo programs
|
It uses synchronous code but is compatible with `uasyncio`. Some demo programs
|
||||||
illustrate this. Code is standard MicroPython, but some device drivers use the
|
illustrate this. Code is standard MicroPython, but some device drivers use the
|
||||||
|
@ -233,9 +235,8 @@ The `gui/core` directory contains the GUI core and its principal dependencies:
|
||||||
* `fplot.py` The graph plotting module.
|
* `fplot.py` The graph plotting module.
|
||||||
* `colors.py` Color constants.
|
* `colors.py` Color constants.
|
||||||
* `framebuf_utils.mpy` Accelerator for the `CWriter` class. This optional file
|
* `framebuf_utils.mpy` Accelerator for the `CWriter` class. This optional file
|
||||||
is compiled for STM hardware and will be ignored on other ports (with a
|
is compiled for STM hardware. It is specific to Pyboards (1.x and D) and will
|
||||||
harmless warning message) unless recompiled. Instructions and code for
|
be ignored on other ports. Details may be found
|
||||||
compiling for other architectures may be found
|
|
||||||
[here](https://github.com/peterhinch/micropython-font-to-py/blob/master/writer/WRITER.md#224-a-performance-boost).
|
[here](https://github.com/peterhinch/micropython-font-to-py/blob/master/writer/WRITER.md#224-a-performance-boost).
|
||||||
|
|
||||||
###### [Contents](./README.md#contents)
|
###### [Contents](./README.md#contents)
|
||||||
|
|
|
@ -25,9 +25,9 @@ import framebuf
|
||||||
from uctypes import bytearray_at, addressof
|
from uctypes import bytearray_at, addressof
|
||||||
from sys import platform
|
from sys import platform
|
||||||
|
|
||||||
__version__ = (0, 4, 1)
|
__version__ = (0, 4, 2)
|
||||||
|
|
||||||
fast_mode = platform != 'rp2' # framebuf_utils crashes RP2
|
fast_mode = platform == 'pyboard'
|
||||||
if fast_mode:
|
if fast_mode:
|
||||||
try:
|
try:
|
||||||
try:
|
try:
|
||||||
|
@ -40,7 +40,7 @@ if fast_mode:
|
||||||
except ValueError:
|
except ValueError:
|
||||||
fast_mode = False
|
fast_mode = False
|
||||||
if not fast_mode:
|
if not fast_mode:
|
||||||
print('Ignoring framebuf_utils.mpy: compiled for incorrect architecture.')
|
print('Ignoring missing or invalid framebuf_utils.mpy.')
|
||||||
|
|
||||||
|
|
||||||
class DisplayState():
|
class DisplayState():
|
||||||
|
|
Ładowanie…
Reference in New Issue