Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions wled00/FX_fcn.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2005,6 +2005,10 @@ bool WS2812FX::deserializeMap(unsigned n) {

d_free(customMappingTable);
customMappingTable = static_cast<uint16_t*>(d_malloc(sizeof(uint16_t)*getLengthTotal())); // prefer DRAM for speed
// fill with empty in case we don't fill the entire matrix
unsigned matrixSize = Segment::maxWidth * Segment::maxHeight;
for (unsigned i = 0; i<matrixSize; i++) customMappingTable[i] = 0xFFFFU;
for (unsigned i = matrixSize; i<getLengthTotal(); i++) customMappingTable[i] = i; // trailing LEDs for ledmap (after matrix) if it exist

Comment thread
coderabbitai[bot] marked this conversation as resolved.
if (customMappingTable) {
DEBUG_PRINTF_P(PSTR("ledmap allocated: %uB\n"), sizeof(uint16_t)*getLengthTotal());
Expand Down