Skip to content

Commit 4d5bc65

Browse files
Update examples - 32x32 and double-buffering no longer fit on Uno
1 parent f43d566 commit 4d5bc65

File tree

8 files changed

+14
-25
lines changed

8 files changed

+14
-25
lines changed

examples/PanelGFXDemo_16x32/PanelGFXDemo_16x32.ino

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,15 @@
99

1010
// Most of the signal pins are configurable, but the CLK pin has some
1111
// special constraints. On 8-bit AVR boards it must be on PORTB...
12-
// Pin 8 works on the Arduino Uno & compatibles (e.g. Adafruit Metro),
1312
// Pin 11 works on the Arduino Mega. On 32-bit SAMD boards it must be
1413
// on the same PORT as the RGB data pins (D2-D7)...
1514
// Pin 8 works on the Adafruit Metro M0 or Arduino Zero,
1615
// Pin A4 works on the Adafruit Metro M4 (if using the Adafruit RGB
1716
// Matrix Shield, cut trace between CLK pads and run a wire to A4).
1817

19-
//#define CLK 8 // USE THIS ON ARDUINO UNO, ADAFRUIT METRO M0, etc.
18+
#define CLK 8 // USE THIS ON ADAFRUIT METRO M0, etc.
2019
//#define CLK A4 // USE THIS ON METRO M4 (not M0)
21-
#define CLK 11 // USE THIS ON ARDUINO MEGA
20+
//#define CLK 11 // USE THIS ON ARDUINO MEGA
2221
#define OE 9
2322
#define LAT 10
2423
#define A A0

examples/colorwheel_32x32/colorwheel_32x32.ino

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
// colorwheel demo for Adafruit RGBmatrixPanel library.
22
// Renders a nice circle of hues on our 32x32 RGB LED matrix:
33
// http://www.adafruit.com/products/607
4+
// 32x32 MATRICES DO NOT WORK WITH ARDUINO UNO or METRO 328.
45

56
// Written by Limor Fried/Ladyada & Phil Burgess/PaintYourDragon
67
// for Adafruit Industries.
@@ -10,14 +11,13 @@
1011

1112
// Most of the signal pins are configurable, but the CLK pin has some
1213
// special constraints. On 8-bit AVR boards it must be on PORTB...
13-
// Pin 8 works on the Arduino Uno & compatibles (e.g. Adafruit Metro),
1414
// Pin 11 works on the Arduino Mega. On 32-bit SAMD boards it must be
1515
// on the same PORT as the RGB data pins (D2-D7)...
1616
// Pin 8 works on the Adafruit Metro M0 or Arduino Zero,
1717
// Pin A4 works on the Adafruit Metro M4 (if using the Adafruit RGB
1818
// Matrix Shield, cut trace between CLK pads and run a wire to A4).
1919

20-
#define CLK 8 // USE THIS ON ARDUINO UNO, ADAFRUIT METRO M0, etc.
20+
#define CLK 8 // USE THIS ON ADAFRUIT METRO M0, etc.
2121
//#define CLK A4 // USE THIS ON METRO M4 (not M0)
2222
//#define CLK 11 // USE THIS ON ARDUINO MEGA
2323
#define OE 9

examples/colorwheel_progmem_32x32/colorwheel_progmem_32x32.ino

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
// colorwheel_progmem demo for Adafruit RGBmatrixPanel library.
22
// Renders a nice circle of hues on our 32x32 RGB LED matrix:
33
// http://www.adafruit.com/products/607
4+
// 32x32 MATRICES DO NOT WORK WITH ARDUINO UNO or METRO 328P.
45

56
// This version uses precomputed image data stored in PROGMEM
67
// rather than calculating each pixel. Nearly instantaneous! Woo!
@@ -12,7 +13,7 @@
1213
#include <RGBmatrixPanel.h>
1314
#include "image.h" // Precomputed colorwheel image is here
1415

15-
#define CLK 8 // USE THIS ON ARDUINO UNO, ADAFRUIT METRO M0, etc.
16+
#define CLK 8 // USE THIS ON ADAFRUIT METRO M0, etc.
1617
//#define CLK A4 // USE THIS ON METRO M4 (not M0)
1718
//#define CLK 11 // USE THIS ON ARDUINO MEGA
1819
#define OE 9

examples/plasma_16x32/plasma_16x32.ino

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
// plasma demo for Adafruit RGBmatrixPanel library.
22
// Demonstrates double-buffered animation our 16x32 RGB LED matrix:
33
// http://www.adafruit.com/products/420
4+
// DOUBLE-BUFFERED ANIMATION DOES NOT WORK WITH ARDUINO UNO or METRO 328.
45

56
// Written by Limor Fried/Ladyada & Phil Burgess/PaintYourDragon
67
// for Adafruit Industries.
@@ -10,14 +11,13 @@
1011

1112
// Most of the signal pins are configurable, but the CLK pin has some
1213
// special constraints. On 8-bit AVR boards it must be on PORTB...
13-
// Pin 8 works on the Arduino Uno & compatibles (e.g. Adafruit Metro),
1414
// Pin 11 works on the Arduino Mega. On 32-bit SAMD boards it must be
1515
// on the same PORT as the RGB data pins (D2-D7)...
1616
// Pin 8 works on the Adafruit Metro M0 or Arduino Zero,
1717
// Pin A4 works on the Adafruit Metro M4 (if using the Adafruit RGB
1818
// Matrix Shield, cut trace between CLK pads and run a wire to A4).
1919

20-
#define CLK 8 // USE THIS ON ARDUINO UNO, ADAFRUIT METRO M0, etc.
20+
#define CLK 8 // USE THIS ON ADAFRUIT METRO M0, etc.
2121
//#define CLK A4 // USE THIS ON METRO M4 (not M0)
2222
//#define CLK 11 // USE THIS ON ARDUINO MEGA
2323
#define OE 9
@@ -30,10 +30,6 @@
3030
// buttery smooth animation. Note that NOTHING WILL SHOW ON THE DISPLAY
3131
// until the first call to swapBuffers(). This is normal.
3232
RGBmatrixPanel matrix(A, B, C, CLK, LAT, OE, true);
33-
// Double-buffered mode consumes nearly all the RAM available on the
34-
// Arduino Uno -- only a handful of free bytes remain. So this code uses
35-
// a bunch of precalculated data in tables to minimize RAM usage and speed
36-
// things up.
3733

3834
static const int8_t PROGMEM sinetab[256] = {
3935
0, 2, 5, 8, 11, 15, 18, 21,

examples/plasma_32x32/plasma_32x32.ino

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
// plasma demo for Adafruit RGBmatrixPanel library.
22
// Demonstrates unbuffered animation on our 32x32 RGB LED matrix:
33
// http://www.adafruit.com/products/607
4+
// 32x32 MATRICES DO NOT WORK WITH ARDUINO UNO or METRO 328.
45

56
// Written by Limor Fried/Ladyada & Phil Burgess/PaintYourDragon
67
// for Adafruit Industries.
@@ -10,14 +11,13 @@
1011

1112
// Most of the signal pins are configurable, but the CLK pin has some
1213
// special constraints. On 8-bit AVR boards it must be on PORTB...
13-
// Pin 8 works on the Arduino Uno & compatibles (e.g. Adafruit Metro),
1414
// Pin 11 works on the Arduino Mega. On 32-bit SAMD boards it must be
1515
// on the same PORT as the RGB data pins (D2-D7)...
1616
// Pin 8 works on the Adafruit Metro M0 or Arduino Zero,
1717
// Pin A4 works on the Adafruit Metro M4 (if using the Adafruit RGB
1818
// Matrix Shield, cut trace between CLK pads and run a wire to A4).
1919

20-
#define CLK 8 // USE THIS ON ARDUINO UNO, ADAFRUIT METRO M0, etc.
20+
#define CLK 8 // USE THIS ON ADAFRUIT METRO M0, etc.
2121
//#define CLK A4 // USE THIS ON METRO M4 (not M0)
2222
//#define CLK 11 // USE THIS ON ARDUINO MEGA
2323
#define OE 9
@@ -28,9 +28,6 @@
2828
#define D A3
2929

3030
RGBmatrixPanel matrix(A, B, C, D, CLK, LAT, OE, false);
31-
// 32x32 matrix consumes nearly all the RAM available on the Arduino Uno --
32-
// only a handful of free bytes remain. So this code uses a bunch of
33-
// precalculated data in tables to minimize RAM usage and speed things up.
3431

3532
static const int8_t PROGMEM sinetab[256] = {
3633
0, 2, 5, 8, 11, 15, 18, 21,

examples/scrolltext_16x32/scrolltext_16x32.ino

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
// scrolltext demo for Adafruit RGBmatrixPanel library.
22
// Demonstrates double-buffered animation on our 16x32 RGB LED matrix:
33
// http://www.adafruit.com/products/420
4+
// DOUBLE-BUFFERED ANIMATION DOES NOT WORK WITH ARDUINO UNO or METRO 328.
45

56
// Written by Limor Fried/Ladyada & Phil Burgess/PaintYourDragon
67
// for Adafruit Industries.
@@ -10,14 +11,13 @@
1011

1112
// Most of the signal pins are configurable, but the CLK pin has some
1213
// special constraints. On 8-bit AVR boards it must be on PORTB...
13-
// Pin 8 works on the Arduino Uno & compatibles (e.g. Adafruit Metro),
1414
// Pin 11 works on the Arduino Mega. On 32-bit SAMD boards it must be
1515
// on the same PORT as the RGB data pins (D2-D7)...
1616
// Pin 8 works on the Adafruit Metro M0 or Arduino Zero,
1717
// Pin A4 works on the Adafruit Metro M4 (if using the Adafruit RGB
1818
// Matrix Shield, cut trace between CLK pads and run a wire to A4).
1919

20-
#define CLK 8 // USE THIS ON ARDUINO UNO, ADAFRUIT METRO M0, etc.
20+
#define CLK 8 // USE THIS ON ADAFRUIT METRO M0, etc.
2121
//#define CLK A4 // USE THIS ON METRO M4 (not M0)
2222
//#define CLK 11 // USE THIS ON ARDUINO MEGA
2323
#define OE 9
@@ -30,9 +30,6 @@
3030
// buttery smooth animation. Note that NOTHING WILL SHOW ON THE DISPLAY
3131
// until the first call to swapBuffers(). This is normal.
3232
RGBmatrixPanel matrix(A, B, C, CLK, LAT, OE, true);
33-
// Double-buffered mode consumes nearly all the RAM available on the
34-
// Arduino Uno -- only a handful of free bytes remain. Even the
35-
// following string needs to go in PROGMEM:
3633

3734
// Similar to F(), but for PROGMEM string pointers rather than literals
3835
#define F2(progmem_ptr) (const __FlashStringHelper *)progmem_ptr

examples/testshapes_32x32/testshapes_32x32.ino

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
// Demonstrates the drawing abilities of the RGBmatrixPanel library.
33
// For 32x32 RGB LED matrix:
44
// http://www.adafruit.com/products/607
5+
// 32x32 MATRICES DO NOT WORK WITH ARDUINO UNO or METRO 328.
56

67
// Written by Limor Fried/Ladyada & Phil Burgess/PaintYourDragon
78
// for Adafruit Industries.
@@ -11,14 +12,13 @@
1112

1213
// Most of the signal pins are configurable, but the CLK pin has some
1314
// special constraints. On 8-bit AVR boards it must be on PORTB...
14-
// Pin 8 works on the Arduino Uno & compatibles (e.g. Adafruit Metro),
1515
// Pin 11 works on the Arduino Mega. On 32-bit SAMD boards it must be
1616
// on the same PORT as the RGB data pins (D2-D7)...
1717
// Pin 8 works on the Adafruit Metro M0 or Arduino Zero,
1818
// Pin A4 works on the Adafruit Metro M4 (if using the Adafruit RGB
1919
// Matrix Shield, cut trace between CLK pads and run a wire to A4).
2020

21-
#define CLK 8 // USE THIS ON ARDUINO UNO, ADAFRUIT METRO M0, etc.
21+
#define CLK 8 // USE THIS ON ADAFRUIT METRO M0, etc.
2222
//#define CLK A4 // USE THIS ON METRO M4 (not M0)
2323
//#define CLK 11 // USE THIS ON ARDUINO MEGA
2424
#define OE 9

examples/testshapes_32x64/testshapes_32x64.ino

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88

99
// Most of the signal pins are configurable, but the CLK pin has some
1010
// special constraints. On 8-bit AVR boards it must be on PORTB...
11-
// Pin 8 works on the Arduino Uno & compatibles (e.g. Adafruit Metro),
1211
// Pin 11 works on the Arduino Mega. On 32-bit SAMD boards it must be
1312
// on the same PORT as the RGB data pins (D2-D7)...
1413
// Pin 8 works on the Adafruit Metro M0 or Arduino Zero,

0 commit comments

Comments
 (0)