Fixes for ESP8266
This commit is contained in:
@@ -474,8 +474,11 @@ BusNetwork::BusNetwork(BusConfig &bc, const ColorOrderMap &com) : Bus(bc.type, b
|
||||
break;
|
||||
}
|
||||
_UDPchannels = _rgbw ? 4 : 3;
|
||||
#ifdef ESP32
|
||||
_data = (byte*) heap_caps_calloc_prefer((bc.count * _UDPchannels)+15, sizeof(byte), 3, MALLOC_CAP_DEFAULT, MALLOC_CAP_SPIRAM);
|
||||
|
||||
#else
|
||||
_data = (byte*) calloc((bc.count * _UDPchannels)+15, sizeof(byte));
|
||||
#endif
|
||||
if (_data == nullptr) return;
|
||||
_len = bc.count;
|
||||
_colorOrder = bc.colorOrder;
|
||||
|
||||
Reference in New Issue
Block a user