You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
High-performance DMA-based driver for HUB75 RGB LED matrix panels, supporting ESP32, ESP32-S2, ESP32-S3, ESP32-C6, and ESP32-P4.
4
7
5
8
## Features
@@ -24,7 +27,19 @@ High-performance DMA-based driver for HUB75 RGB LED matrix panels, supporting ES
24
27
25
28
## Installation
26
29
27
-
Add to your project via Component Manager (`idf_component.yml`):
30
+
### ESP-IDF Component Manager
31
+
32
+
Add to your project's `idf_component.yml`:
33
+
34
+
```yaml
35
+
dependencies:
36
+
hub75:
37
+
version: "^0.1.0"
38
+
```
39
+
40
+
Browse on the [ESP Component Registry](https://components.espressif.com/components/stuartparmenter/esp-hub75).
41
+
42
+
Or install from git:
28
43
29
44
```yaml
30
45
dependencies:
@@ -33,13 +48,57 @@ dependencies:
33
48
path: components/hub75 # Important: point to the component subdirectory!
34
49
```
35
50
51
+
### PlatformIO
52
+
53
+
Add to `platformio.ini`:
54
+
55
+
```ini
56
+
lib_deps =
57
+
stuartparmenter/esp-hub75@^0.1.0
58
+
```
59
+
60
+
Browse on the [PlatformIO Registry](https://registry.platformio.org/libraries/stuartparmenter/esp-hub75).
61
+
62
+
### Manual Installation
63
+
36
64
See [Component Documentation](components/hub75/README.md) for manual installation options.
37
65
38
66
## Quick Start
39
67
40
-
Configure your panel hardware, set GPIO pins, call `begin()`, and start drawing pixels. The driver handles continuous DMA refresh automatically - no CPU intervention needed after initialization. Supports single pixels (`set_pixel`), bulk writes (`draw_pixels`), and double buffering for tear-free animation.
driver.set_pixel(10, 10, 255, 0, 0); // Red pixel at (10,10)
90
+
}
91
+
```
92
+
93
+
See [examples/01_basic/simple_colors](examples/01_basic/simple_colors) for complete working example and [examples/common/](examples/common/) for board-specific pin configurations.
94
+
95
+
## Getting Started Paths
41
96
42
-
See [examples/](examples/) for working code and [Component Documentation](components/hub75/README.md) for complete API reference.
97
+
- **First time with HUB75 panels?** → See [Quick Start](#quick-start) above, then try [examples/01_basic/](examples/)
98
+
- **Setting up multiple panels?** → See [Multi-Panel Guide](docs/MULTI_PANEL.md)
99
+
- **Display not working?** → See [Troubleshooting Guide](docs/TROUBLESHOOTING.md)
100
+
- **Want to understand the internals?** → See [Architecture Overview](docs/ARCHITECTURE.md)
101
+
- **Need complete API reference?** → See [Component Documentation](components/hub75/README.md)
-**Serpentine**: Alternate rows are physically mounted upside down (saves cable length)
214
-
-**Zigzag**: All panels mounted upright, cables route back between rows (longer cables)
215
-
216
-
**Row-Major Chaining:** Panels chain HORIZONTALLY across rows (not vertically down columns). This matches the ESP32-HUB75-MatrixPanel-DMA reference library.
config.layout_cols = 2; // Two panels horizontally
176
+
config.layout = PanelLayout::HORIZONTAL;
177
+
// Virtual display: 128×64
237
178
```
238
179
239
-
**Clock Speed Options:**
240
-
-`HZ_8M` - 8 MHz (most compatible)
241
-
-`HZ_10M` - 10 MHz
242
-
-`HZ_16M` - 16 MHz
243
-
-`HZ_20M` - 20 MHz (default, works with most panels)
244
-
245
-
Higher speeds may cause signal integrity issues with long cables or poor-quality panels.
246
-
247
-
**Bit Depth:**
248
-
- 6-bit: Fast refresh, basic color depth
249
-
- 8-bit: Good balance (default)
250
-
- 10-bit: Better gradients, recommended for smooth animations
251
-
- 12-bit: Best quality, slower refresh
252
-
253
-
Higher bit depth = more descriptors + slower refresh rate.
254
-
255
-
### Pin Configuration
256
-
180
+
**Higher quality display:**
257
181
```cpp
258
-
// GPIO pin assignments (example for ESP32-S3)
259
-
config.pins.r1 = 25; // Red data (top half)
260
-
config.pins.g1 = 26; // Green data (top half)
261
-
config.pins.b1 = 27; // Blue data (top half)
262
-
config.pins.r2 = 14; // Red data (bottom half)
263
-
config.pins.g2 = 12; // Green data (bottom half)
264
-
config.pins.b2 = 13; // Blue data (bottom half)
265
-
config.pins.a = 23; // Row address bit A
266
-
config.pins.b = 19; // Row address bit B
267
-
config.pins.c = 5; // Row address bit C
268
-
config.pins.d = 17; // Row address bit D
269
-
config.pins.e = -1; // Row address bit E (-1 if unused)
270
-
config.pins.lat = 4; // Latch
271
-
config.pins.oe = 15; // Output enable
272
-
config.pins.clk = 16; // Clock
182
+
config.bit_depth = 10; // Better gradients
183
+
config.double_buffer = true; // Tear-free updates
184
+
config.min_refresh_rate = 90; // Smoother for cameras
273
185
```
274
186
275
-
**GPIO Restrictions:**
276
-
- Avoid strapping pins (GPIO0, GPIO46, etc.)
277
-
- ESP32-S3: GPIO19/20 unavailable if USB CDC enabled
278
-
- Check ESP32 variant datasheets for input-only pins
279
-
- Some platforms have restrictions on which peripherals can use which pins
280
-
281
-
**Pre-configured Examples:** See repository [examples/common/pins_example.h](https://github.com/stuartparmenter/esp-hub75/blob/main/examples/common/pins_example.h) for tested pin configurations for different boards.
187
+
**For complete configuration reference** (all scan patterns, layouts, clock speeds, bit depth options, pin configuration, etc.), see **[MENUCONFIG.md](../../docs/MENUCONFIG.md)**.
282
188
283
189
## Multi-Panel Layouts
284
190
285
-
Chain multiple panels for larger displays. Panels connect **horizontally across rows** (row-major traversal).
-**ESP32-C6** (PARLIO): Planned, same as P4 but no clock gating
317
214
318
-
**For detailed platform comparison**, implementation specifics, memory calculations, and when to choose each platform, see **[Platform Details](../../docs/PLATFORMS.md)** and **[Memory Usage](../../docs/MEMORY_USAGE.md)**.
215
+
**For detailed platform comparison, memory calculations, and implementation specifics**, see **[Platform Details](../../docs/PLATFORMS.md)**.
319
216
320
217
## Troubleshooting
321
218
322
-
### Common Issues
323
-
324
-
**Black Screen:**
325
-
- Try `shift_driver = ShiftDriver::FM6126A` (most modern panels)
326
-
- Verify power supply adequate (3-5A per 64×64 panel)
0 commit comments