Skip to content

Commit db5004d

Browse files
authored
Merge pull request #639 from pimoroni/docs/add-links
Update docs and add links
2 parents b3edbc4 + 7a6857b commit db5004d

File tree

4 files changed

+44
-13
lines changed

4 files changed

+44
-13
lines changed

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ We also maintain a C++/CMake boilerplate with GitHub workflows configured for te
8989
## RP2040 Boards
9090

9191
* Plasma 2040 (LED strip driver) - https://shop.pimoroni.com/products/plasma-2040
92-
* Interstate 75 (HUB75 driver) - https://shop.pimoroni.com/products/interstate-75
92+
* Interstate 75 (HUB75 matrix driver) - https://shop.pimoroni.com/products/interstate-75
9393
* Badger 2040 (E Ink badge) - https://shop.pimoroni.com/products/badger-2040
9494
* Servo 2040 (18 Channel Servo Controller) - https://shop.pimoroni.com/products/servo-2040
9595
* Motor 2040 (Quad Motor+Encoder Controller) - https://shop.pimoroni.com/products/motor-2040
@@ -103,6 +103,8 @@ We also maintain a C++/CMake boilerplate with GitHub workflows configured for te
103103
* Automation 2040 W Mini (inputs, outputs and a relay, 6-40V compatible) - https://shop.pimoroni.com/products/automation-2040-w-mini
104104
* Plasma Stick 2040 W (bijou LED strip controller) - https://shop.pimoroni.com/products/plasma-stick-2040-w
105105
* Galactic Unicorn (dazzling 53 x 11 LED matrix) - https://shop.pimoroni.com/products/galactic-unicorn
106+
* Interstate 75 W (HUB75 matrix driver) - https://shop.pimoroni.com/products/interstate-75-w
107+
* Inky Frame 4.0" (7-colour E Ink) - https://shop.pimoroni.com/products/inky-frame-4
106108

107109
## Breakouts
108110

micropython/examples/gfx_pack/README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
- [Wireless Examples](#wireless-examples)
1515
- [Sunrise / Sunset](#sunrise--sunset)
1616
- [Zoo Facts](#zoo-facts)
17+
- [Other Resources](#other-resources)
1718

1819
## About Pico GFX Pack
1920

@@ -122,4 +123,11 @@ Find out more about Zoo Animal API here: https://zoo-animal-api.herokuapp.com/
122123
- D = Show stats
123124
- E = Fetch a different 5 animals
124125

126+
## Other Resources
127+
128+
Here are some GFX Pack community projects and resources that you might find useful! Note that code at the links below has not been tested by us and we're not able to offer support with it.
129+
130+
- :link: [Octopus Energy Monitor](https://github.com/MaverickUK/OctopusEnergyMonitorPicoW)
131+
132+
125133

micropython/examples/pico_explorer/README.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
- [Weather Station (BME68X)](#weather-station-bme68x)
1313
- [Wireless Examples](#wireless-examples)
1414
- [Cheerlights](#cheerlights)
15+
- [Other Resources](#other-resources)
1516

1617
## PicoGraphics
1718

@@ -64,10 +65,17 @@ Plug a [BME680](https://shop.pimoroni.com/products/bme680-breakout) or [BME688](
6465

6566
The wireless examples need `network_manager.py` and `WIFI_CONFIG.py` from the `common` directory to be saved to your Pico W. Open up `WIFI_CONFIG.py` in Thonny to add your wifi details (and save it when you're done).
6667

67-
You'll also need to install the `micropython-urllib.urequest` library using Thonny's 'Tools' > 'Manage Packages'.
68+
You may also need to install the `micropython-urllib.urequest` library using Thonny's 'Tools' > 'Manage Packages'.
6869

6970
### Cheerlights
7071
[cheerlights.py](cheerlights.py)
7172

7273
This Pico W example sets your Pico Explorer's screen (and optionally, a [RGB LED](https://shop.pimoroni.com/products/led-rgb-clear-common-cathode)) to the current #cheerlights colour.
7374

75+
## Other Resources
76+
77+
Here are some Pico Explorer community projects and resources that you might find useful! Note that code at the links below has not been tested by us and we're not able to offer support with it.
78+
79+
- :link: [PicoGraphics Zoomable Mandelbrot](https://github.com/ExperiMentor/PicoGraphics_Zoomable_Mandelbrot)
80+
81+

micropython/modules/picographics/README.md

Lines changed: 24 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ Pico Graphics replaces the individual drivers for displays- if you're been using
66

77
- [Setting up Pico Graphics](#setting-up-pico-graphics)
88
- [Supported Displays](#supported-displays)
9+
- [Interstate75 and Interstate75W Display modes](#interstate75-and-interstate75w-display-modes)
910
- [Supported Graphics Modes (Pen Type)](#supported-graphics-modes-pen-type)
1011
- [Supported Rotations](#supported-rotations)
1112
- [Custom Pins](#custom-pins)
@@ -21,6 +22,7 @@ Pico Graphics replaces the individual drivers for displays- if you're been using
2122
- [Clipping](#clipping)
2223
- [Clear](#clear)
2324
- [Update](#update)
25+
- [Get Bounds](#get-bounds)
2426
- [Text](#text)
2527
- [Changing The Font](#changing-the-font)
2628
- [Drawing Text](#drawing-text)
@@ -61,8 +63,9 @@ Bear in mind that MicroPython has only 192K of RAM available- a 320x240 pixel di
6163
* 240x240 Square SPI LCD Breakout - `DISPLAY_LCD_240X240`
6264
* 160x80 SPI LCD Breakout - `DISPLAY_LCD_160X80`
6365
* 128x128 I2C OLED - `DISPLAY_I2C_OLED_128X128`
64-
* Pico Inky Pack - 296x128 mono e-ink - `DISPLAY_INKY_PACK`
65-
* Inky Frame - 600x447 7-colour e-ink - `DISPLAY_INKY_FRAME`
66+
* Pico Inky Pack - 296x128 mono E ink - `DISPLAY_INKY_PACK`
67+
* Inky Frame 5.7" - 600x448 7-colour E ink - `DISPLAY_INKY_FRAME`
68+
* Inky Frame 4.0" - 640x400 7-colour E ink - `DISPLAY_INKY_FRAME_4`
6669
* Pico GFX Pack - 128x64 mono LCD Matrix - `DISPLAY_GFX_PACK`
6770
* Galactic Unicorn - 53x11 LED Matrix - `DISPLAY_GALACTIC_UNICORN`
6871
* Interstate75 and 75W - HUB75 Matrix driver - `DISPLAY_INTERSTATE75_SIZEOFMATRIX` please read below!
@@ -71,7 +74,7 @@ Bear in mind that MicroPython has only 192K of RAM available- a 320x240 pixel di
7174

7275
Both the Interstate75 and Interstate75W support lots of different sizes of HUB75 matrix displays.
7376

74-
The available display ssettings are listed here:
77+
The available display settings are listed here:
7578

7679
* 32 x 32 Matrix - `DISPLAY_INTERSTATE75_32X32`
7780
* 64 x 32 Matrix - `DISPLAY_INTERSTATE75_64X32`
@@ -267,6 +270,14 @@ If you are using a Galactic Unicorn, then the process for updating the display i
267270
galactic_unicorn.update(display)
268271
```
269272

273+
#### Get Bounds
274+
275+
You can use `get_bounds()` to get the width and height of the display - useful for writing code that's portable across different displays.
276+
277+
```python
278+
WIDTH, HEIGHT = display.get_bounds()
279+
```
280+
270281
### Text
271282

272283
#### Changing The Font
@@ -284,8 +295,8 @@ These are aligned from their top-left corner.
284295
* `bitmap8`
285296
* `bitmap14_outline`
286297

287-
Vector (Hershey) fonts.
288-
These are aligned to their midline.
298+
Vector (Hershey) fonts.
299+
These are aligned horizontally (x) to their left edge, but vertically (y) to their midline excluding descenders [i.e., aligned at top edge of lower case letter m]. At `scale=1`, the top edge of upper case letters is 10 pixels above the specified `y`, text baseline is 10 pixels below the specified `y`, and descenders go down to 20 pixels below the specified `y`.
289300

290301
* `sans`
291302
* `gothic`
@@ -347,7 +358,7 @@ Draws an ampersand in a 16px tall, 2x scaled version of the 'bitmap8' font.
347358

348359
#### Line
349360

350-
To draw a line:
361+
To draw a straight line at any angle between two specified points:
351362

352363
```python
353364
display.line(x1, y1, x2, y2)
@@ -412,12 +423,14 @@ Setting individual pixels is slow, but you can do it with:
412423
display.pixel(x, y)
413424
```
414425

415-
You can set a horiontal span of pixels a little faster with:
426+
You can draw a horizontal span of pixels a little faster with:
416427

417428
```python
418-
pixel_span(x, y, length)
429+
display.pixel_span(x, y, length)
419430
```
420431

432+
(use `display.line()` instead if you want to draw a straight line at any angle)
433+
421434
### Palette Management
422435

423436
Intended for P4 and P8 modes.
@@ -427,7 +440,7 @@ You have a 16-color and 256-color palette respectively.
427440
Set n elements in the palette from a list of RGB tuples:
428441

429442
```python
430-
set_palette([
443+
display.set_palette([
431444
(r, g, b),
432445
(r, g, b),
433446
(r, g, b)
@@ -437,15 +450,15 @@ set_palette([
437450
Update an entry in the P4 or P8 palette with the given colour.
438451

439452
```python
440-
update_pen(index, r, g, b)
453+
display.update_pen(index, r, g, b)
441454
```
442455

443456
This is stored internally as RGB and converted to whatever format your screen requires when displayed.
444457

445458
Reset a pen back to its default value (black, marked unused):
446459

447460
```python
448-
reset_pen(index)
461+
display.reset_pen(index)
449462
```
450463

451464
#### Utility Functions

0 commit comments

Comments
 (0)