I've been playing around with your 32x32 display, and having trouble getting colours properly defined.
based on your library matrix.fillRect(0, 0, 32, 16, matrix.Color333(7, 7, 0)); should fill the display with yellow, but is instead showing only red.
I've found that using (1, 0, 7) gets me a rough mix of colours, but its clear that quite a few of the pixels are not displaying anywhere near as much brightness. Blue seems to work well, red is super strong, and green kind of all over the place. I am also totally unable to display white pixels, as (7, 7, 7) just shows red
Thinking that this might just be a voltage issue, i've also experimented with making small filled rectangles and circles, and getting the same issues.
is this a case of the display being a dud from the manufacturer? or some other issue. If its a manufacturers issue, is there are chance to get the display swapped?
below is a copy of the test code im playing with, and I'd post a photo, but its proving to be really hard to get a photo that actually shows the brightness issues with the panel
Code: Select all
#include <Adafruit_GFX.h> // Core graphics library
#include <RGBmatrixPanel.h> // Hardware-specific library
// If your 32x32 matrix has the SINGLE HEADER input,
// use this pinout:
#define CLK 11 // MUST be on PORTB!
#define OE 9
#define LAT 10
#define A A0
#define B A1
#define C A2
#define D A3
RGBmatrixPanel matrix(A, B, C, D, CLK, LAT, OE, false);
// define some bitmaps
namespace pacman {
const uint16_t Y = matrix.Color333(0, 7, 0);
const uint16_t C = matrix.Color333(0, 0, 7);
const uint16_t chomp[32 * 32] = {
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, Y, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 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 0, C, C, 0, C, C, 0, 0, 0, 0, 0, 0, 0, C, C, 0, 0, 0,
0, 0, 0, 0, C, C, C, 0, 0, C, C, 0, 0, C, 0, 0, 0, 0, C, C, 0, 0, 0, 0, 0, 0, 0, C, C, 0, 0, 0,
0, 0, 0, C, C, C, C, C, 0, 0, C, C, C, 0, 0, 0, 0, 0, 0, C, C, C, C, 0, 0, 0, 0, C, C, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
}
void setup() {
matrix.begin();
matrix.fillScreen(0);
// draw the bitmap
for (uint8_t y = 0; y < 32; ++y) {
for (uint8_t x = 0; x < 32; ++x) {
matrix.drawPixel(x, y, pacman::chomp[y * 32 + x]);
}
}
}
void loop() {
// nothing
}