Help needed with 52x52 1/13 scan

sudo python3 runtext.py --led-slowdown-gpio=3 --led-cols=64 --led-rows=64 --led-brightness=50 --led-row-addr-type=3 --led-pixel-mapper Rotate:180 --led-multiplexing=1

Hello,
First, I really appreciate your great work!

Second, I recently grabbed a LED Panel from the dumpster which has 52x52 pixels on there. I hooked it up like the HUB75 panels, but the mapping seems not to be right.
I need to skip 3 pixels every 13 horzontal pixels.
The shift register they used has 16outputs, but they left 3 outputs unconnected to have 52pixels in total. (same as in vertical rows, but I could easily change that in the code from 16 to 13)
what lines do I need to add/modify?

class StripeMultiplexMapper : public MultiplexMapperBase {
public:
StripeMultiplexMapper() : MultiplexMapperBase(“Stripe”, 2) {}

void MapSinglePanel(int x, int y, int *matrix_x, int *matrix_y) const {

const bool is_top_stripe = (y % (panel_rows_/2)) < panel_rows_/4;

//x=x+3;
if (x >= 14) { x=x+3; }
if (x >= 30) { x=x+3; }
if (x >= 46) { x=x+3; }

if ( x>63) { x=0 ;}

*matrix_x = is_top_stripe ? x + panel_cols_ : x;

*matrix_y = ((y / (panel_rows_/2)) * (panel_rows_/4)+ y % (panel_rows_/4));

}
};

x 좌표는 성공!! y 실패 x

OMG, that is a very weird size, I didn’t even know those existed.

To be honest, I think you’re going to be on your own for those. I haven’t seen @hzeller in a while, he’s likely busy with work work, but honestly without having the same panels as you have, it’d be a bit time consuming to write drivers remotely.
But it’s a good opportunity for you to learn, good luck :wink:

1 Like

make text-scroller

sudo ./text-scroller -f …/fonts/Medium32.bdf -C0,255,0 -B0,0,0 -O255,255,255 --led-show-refresh
–led-chain=1 --led-slowdown-gpio=3 --led-cols=64 --led-rows=64 --led-multiplexing=1
–led-brightness=100 --led-row-addr-type=3 -s0 -y-0 -x0 “한글출력”

//### 18 new mapper

class Stripe52x52 : public MultiplexMapperBase {
public:
Stripe52x52() : MultiplexMapperBase(“Stripe52x52”, 2) {}

void MapSinglePanel(int x, int y, int *matrix_x, int *matrix_y) const {

const bool is_top_stripe = (y % (panel_rows_/2)) < panel_rows_/4;

if (x >= 14) { x=x+3; }
if (x >= 30) { x=x+3; }
if (x >= 46) { x=x+3; }
if ( x>=63) { x=0 ;}
*matrix_x = is_top_stripe ? x + panel_cols_ : x;

//----------------------------------------------------------------------------------------

*matrix_y = ((y / (panel_rows_/2)) * (panel_rows_/4)+ y % (panel_rows_/4));

//-----------------------------------------------------------------------------------
}
};

// y line ???

새로운 매핑을 만드는 중입니다. y 매핑에 대한 감이 안옵니다.
(Creating a new mapping. I can’t get a feel for the y mapping.)

X line 매핑은 13번 이후에 3씩 추가 했습니다.
(X line mapping was added by 3 after number 13.) : :sweat:

//### 18
class Stripe52x52 : public MultiplexMapperBase {
public:
Stripe52x52() : MultiplexMapperBase(“Stripe52x52”, 2) {}

void MapSinglePanel(int x, int y, int *matrix_x, int *matrix_y) const {

if ( y >= 13) {  y=y+3;}
if ( y >= 29) {  y=y+3;}
if ( y >= 45) {  y=y+3;}

const bool is_top_stripe = (y % (64/2)) < 64/4;

if (x >= 14) { x=x+3; }
if (x >= 30) { x=x+3; }
if (x >= 46) { x=x+3; }
if ( x>=63) { x=0 ;}
*matrix_x = is_top_stripe ? x + panel_cols_ : x;

//----------------------------------------------------------------------------------------
if (y > 63 ) { y = 0;}
*matrix_y = ((y / (64/2)) * (64/4)+ y % (64/4));

//-----------------------------------------------------------------------------------
}
};

I was successful today. :grinning:

1 Like

//## 1Stripe → 18 Stripe52x52 수정

//### 18
class Stripe52x52 : public MultiplexMapperBase {
public:
Stripe52x52() : MultiplexMapperBase(“Stripe52x52”, 2) {}

void MapSinglePanel(int x, int y, int *matrix_x, int *matrix_y) const {

if ( y >= 13) {  y=y+3;}
if ( y >= 29) {  y=y+3;}
if ( y >= 45 ) {  y=y+3;}

const bool is_top_stripe = (y % (panel_rows_/2)) < panel_rows_/4;

if (x >= 14) { x=x+3; }
if (x >= 30) { x=x+3; }
if (x >= 46) { x=x+3; }
if ( x>=63) { x=0 ;}

*matrix_x = is_top_stripe ? x + panel_cols_ : x;

//----------------------------------------------------------------------------------------

if ( y > 63 ) { y = 0; } else {
*matrix_y = ((y / (panel_rows_/2)) * (panel_rows_/4)+ y % (panel_rows_/4)); }
//-----------------------------------------------------------------------------------
}
};