Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

P4 LED Panel 1/32 s #540

Open
mjmokhtar opened this issue Dec 15, 2023 · 25 comments
Open

P4 LED Panel 1/32 s #540

mjmokhtar opened this issue Dec 15, 2023 · 25 comments
Labels
weird panel Looks like yet another panel type that isn't 1/16 or 1/32 ABCD addressed.

Comments

@mjmokhtar
Copy link

mjmokhtar commented Dec 15, 2023

32s
that p3 64x32 and have scan 1/32s
I have some problems using this panel

  1. panel cut in middle at panel
  2. color must be RED become green
32s.mp4

here my code
`#include "ESP32-HUB75-MatrixPanel-I2S-DMA.h"

//************************************************************ Display Config Declaration
#define double_buffer

#define PANEL_RES_X 64 // Number of pixels wide of each INDIVIDUAL panel module.
#define PANEL_RES_Y 32 // Number of pixels tall of each INDIVIDUAL panel module.
#define PANEL_CHAIN 2 // Total number of panels chained one to another

MatrixPanel_I2S_DMA* dma_display = nullptr;

#define FONT_SIZE 2.85 // Text will be FONT_SIZE x 8 pixels tall.

int delayBetweeenAnimations = 35; // How fast it scrolls, Smaller == faster
int scrollXMove = -1; //If positive it would scroll right

int textXPosition = PANEL_RES_X * PANEL_CHAIN; // Number of pixels wide of each INDIVIDUAL panel module.
// Will start one pixel off screen
int textYPosition = PANEL_RES_Y / 2 - (FONT_SIZE * 8 / 2); // This will center the text

// For scrolling Text
unsigned long isAnimationDue;

String text ="Restek";

uint16_t myBLACK = dma_display->color565(0, 0, 0);
uint16_t myWHITE = dma_display->color565(255, 255, 255);
uint16_t myRED = dma_display->color565(255, 0, 0);
uint16_t myGREEN = dma_display->color565(0, 255, 0);
uint16_t myBLUE = dma_display->color565(0, 0, 255);

// Will be used in getTextBounds.
int16_t xOne, yOne;
uint16_t w, h;

void setup() {

Serial.begin(115200);
// Configurations for Display
HUB75_I2S_CFG mxconfig(
PANEL_RES_X, // module width
PANEL_RES_Y, // module height
PANEL_CHAIN // Chain length
);

mxconfig.double_buff = true;
mxconfig.gpio.e = 32;
// mxconfig.clkphase = false;
// mxconfig.driver = HUB75_I2S_CFG::FM6124;

// Display Setup
dma_display = new MatrixPanel_I2S_DMA(mxconfig);
dma_display->begin();
dma_display->setBrightness8(255); //0-255
dma_display->fillScreen(myBLACK);
dma_display->setTextSize(FONT_SIZE);
dma_display->setTextWrap(false); // N.B!! Don't wrap at end of line
dma_display->setTextColor(myRED); // Can change the colour here

}

void loop(){
unsigned long now = millis();
if (now > isAnimationDue)
{
// This tells the code to update the second buffer
dma_display->flipDMABuffer();

// This sets the timer for when we should scroll again.
isAnimationDue = now + delayBetweeenAnimations;

textXPosition += scrollXMove;

// Checking if the very right of the text off screen to the left
dma_display->getTextBounds(text, textXPosition, textYPosition, &xOne, &yOne, &w, &h);
if (textXPosition + w <= 0)
{      
  textXPosition = dma_display->width();
}

dma_display->setCursor(textXPosition, textYPosition);

// The display has to do less updating if you only black out the area
// the text is
//dma_display->fillScreen(myBLACK);
dma_display->fillRect(0, textYPosition, dma_display->width(), FONT_SIZE * 8, myBLACK);
dma_display->print(text);

}
}`

as any one have suggest for fix this

@mjmokhtar
Copy link
Author

this panel using DP5125D
please help me mr mrfaptastic

@mrcodetastic
Copy link
Owner

Can you test with another library as well? Like PxMatrix library.

If you have same issues then you have defective panel.

You can easily workaround the red/green issue by just swapping the pins around in the config.

@mjmokhtar
Copy link
Author

actually, when I use 64x64 px, the panel can display not cutting like my video.
I've using PxMatrix and it's same
and I've read documentation of PxMatrix, that's library just for one panel

so i've don't know what I should I do for this think

@mjmokhtar
Copy link
Author

#516

its same like this

@board707
Copy link
Contributor

If the label "32scan" is not a mistake, it is something completely new among the HUB75 panels.
All the panels I had to deal with had a scan factor of no more than half the height. That is, for a 64x32 matrix, the scan should be 16 or less.
Your matrix is some new type and I don’t know any libraries that support such panels.

@mjmokhtar
Copy link
Author

for your information mr
my panel have led driver IC DP5125D

i tried to find datasheet but I didn't found it

once again when I use 64x64 px, the panel can display not cutting like my video
#516

its same like this

@mjmokhtar
Copy link
Author

when i change panel Y from 32 to 64
display not cutting but it will be cutting when I define Panel Y become 32

@mrcodetastic mrcodetastic added the weird panel Looks like yet another panel type that isn't 1/16 or 1/32 ABCD addressed. label Jan 9, 2024
@mjmokhtar
Copy link
Author

i've try scan cordinate using this code

`#include "ESP32-HUB75-MatrixPanel-I2S-DMA.h"

//************************************************************ Display Config Declaration
#define double_buffer

#define PANEL_RES_X 64 // Number of pixels wide of each INDIVIDUAL panel module.
#define PANEL_RES_Y 32 // Number of pixels tall of each INDIVIDUAL panel module.
#define PANEL_CHAIN 1 // Total number of panels chained one to another

MatrixPanel_I2S_DMA* dma_display = nullptr;

uint16_t myBLACK;
uint16_t myWHITE;
uint16_t myRED;
uint16_t myGREEN;
uint16_t myBLUE;

void setup() {
Serial.begin(115200);

// Configurations for Display
HUB75_I2S_CFG mxconfig(
PANEL_RES_X, // module width
PANEL_RES_Y, // module height
PANEL_CHAIN // Chain length
);

mxconfig.double_buff = true;
mxconfig.gpio.e = 32;
mxconfig.clkphase = false;

// Display Setup
dma_display = new MatrixPanel_I2S_DMA(mxconfig);
dma_display->begin();
dma_display->setBrightness8(255); //0-255

// Define colors
myBLACK = dma_display->color565(0, 0, 0);
myWHITE = dma_display->color565(255, 255, 255);
myRED = dma_display->color565(255, 0, 0);
myGREEN = dma_display->color565(0, 255, 0);
myBLUE = dma_display->color565(0, 0, 255);

// Print dot at each coordinate
for (int y = 0; y < PANEL_RES_Y; y++) {
for (int x = 0; x < PANEL_RES_X * PANEL_CHAIN; x++) {
dma_display->drawPixel(x, y, myRED);
// Print coordinates
Serial.print("(");
Serial.print(x);
Serial.print(",");
Serial.print(y);
Serial.print(") ");
delay(100); // Delay 500ms before printing the next dot
}
Serial.println(); // Move to the next line after each row
}
}

void loop() {
// Nothing here, just printing dots in setup()
}
`
here's debug image

Gambar WhatsApp 2024-03-27 pukul 16 39 38_636c51c2

here's in visual led matrix

for red color I can fix it but for coordinate i need help
thanks

@mjmokhtar
Copy link
Author

is sombody can help me
i still stuck

@board707
Copy link
Contributor

I am in doubt that anybody can help without having the panel for tests.
How many such panels do you have? Perhaps buying a different model could be a solution?

@mjmokhtar
Copy link
Author

@board707 actualy i just wonder how to fix this code by my self but I still stuck , i can't buying for solution because it new feature led but still no code cant explain this what this happen

i need help Mr @board707

if you don't mine i will send my email to you, and we can solve it together if you don't mind

@board707
Copy link
Contributor

Unfortunately, I do not use ESP32 with HUB75 RGB matrices.
If you don’t have to use ESP32, we can try your panel with boards based on Pico RP2040 or STM32 controllers.

@mjmokhtar
Copy link
Author

Video.WhatsApp.2024-03-28.pukul.15.41.20_cee1bccc.mp4

i found another condition
my HUB75 have pin a,b,c,d and pin E
in another hub75 they don't have pin E

so I tried to measure the voltage in pin E there is no signal, different from the another pin a,b,c, and d have voltage 1.12v a data

I hope this data can we figure it out together

@board707
Copy link
Contributor

board707 commented Mar 28, 2024

my HUB75 have pin a,b,c,d and pin E
in another hub75 they don't have pin E

There is no magic in it. It depends only on number of scan lines. Panels with 16 scans and less doesn't need a E line. Panels with 8scans and less doesn't need a D and E lines... and so on

@mjmokhtar
Copy link
Author

mjmokhtar commented Mar 28, 2024

i have told you before my hub is different and
i know but my p4 led panel matrix needs pin e, cause it has 32 scans
you can say that not magic

I really need help for this, what I would do for this

@board707
Copy link
Contributor

board707 commented Mar 28, 2024

my p4 led panel

"P4" says nothing about panel type, please be more specific and use informative labels - for example "64x32 s32 panel". And "p4" is completely unnecessary for it :)

my hub is different

There is no difference in the fact that your HUB has E pin. This is common to all 32s panels

what I would do for this

Did you try to configure the library as for 64x64 panel ?

@mjmokhtar
Copy link
Author

yes i have it
this panel will full #516 same like this

#516

its same like this

@board707
Copy link
Contributor

So the panel works? What is your problem?

@mjmokhtar
Copy link
Author

mjmokhtar commented Mar 28, 2024

not work for 64x32
it cut my content display when it parallel that why I ask how can be to solve this for multi panel

@board707
Copy link
Contributor

not work for 64x32

Please understand that technically your panel is not a 64x32, it is a half of 64x64 panel. So you have to setup and use it as 64x64. Do not try to setup it as 64x32 - nothing will come of this.
If you need a several panels, chained horizontally, you can setup it as chain of 64x64 panels - it should work. If you need a several horizontal rows of panels - the setup is slightly different. You need to connect R0 G0 B0 lines to corresponding pins of upper row of panels, and R1 G1 B1 lines to R0 G0 B0 pins of lower row

@mjmokhtar
Copy link
Author

yes that why i ask how to try it 64x32 because when I want to print something that cut even I use 64x64 and been chain panel it cause set 64x64 my panel thing is one panel not chain panel

you said about R0G0B0
can you tell me how to set up that ?

@board707
Copy link
Contributor

that why i ask how to try it 64x32

as 64x32 no way. use it as 64x64

even I use 64x64 and been chain panel it cause set 64x64 my panel thing is one panel not chain panel

I don't understand... Do you use a google translate?

@mjmokhtar
Copy link
Author

yes i use translator app
i know its not helping but I just share my problem
I still want use 64x32 code and I try figure it out to found it

event you said 64x64 code, I think there is way to use 64x32 panel without problem and that solution is change library code
that's why I ask

thank you

@board707
Copy link
Contributor

I think there is way to use 64x32 panel without problem and that solution is change library code
that's why I ask

Do you expect that somebody will redesign the library for you? - as I said before, for this one at least need to have such a panel.
More realistic if you would try to edit the code yourself and then offer a PR with your changes.

@board707
Copy link
Contributor

However, the simplest thing is to use the panel as 64x64, as I described above. This does not require editing the library

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
weird panel Looks like yet another panel type that isn't 1/16 or 1/32 ABCD addressed.
Projects
None yet
Development

No branches or pull requests

3 participants