Ok, almost have it working, in my previous, 1 dimensional code this:
int XLit = abs(AcX) / (25000/(NUM_LEDS/2));
if(XLit > (NUM_LEDS/2)) {
XLit = NUM_LEDS/2;
}
fill_solid(Xleds,NUM_LEDS,CRGB::Black);
if(AcX < 0) {
for(int xi = 1; xi <= XLit; xi++) {
Xleds[(NUM_LEDS/2)-xi] = CRGB::Green;
}
} else {
for(int xi = 0; xi < XLit; xi++) {
Xleds[(NUM_LEDS/2)+xi] = CRGB::Yellow;
}
}
worked perfectly for having all the positive values on one half of the strip and the negatives on the other half. Heres what i have now:
fill_solid(leds,NUM_LEDS,CRGB::Black);
for( uint8_t x = 0; x < kMatrixWidth; x++) {
for( uint8_t y = 0; y < kMatrixHeight; y++) {
leds[ XY( AcX/4000, AcY/4000) ] = CRGB::White;
}
}
LEDS.show();
}
as is it is, it only shows 1/4 of the data because i think it’s only displaying the positives, how would i implement the other code to get everything to be displayed from the center of my matrix out?