mirror of
https://github.com/esphome/esphome.git
synced 2025-09-02 19:32:19 +01:00
e131: fix issue 1579: limitation of maximum light count (#1619)
This commit is contained in:
@@ -53,7 +53,8 @@ bool E131AddressableLightEffect::process_(int universe, const E131Packet &packet
|
|||||||
|
|
||||||
int output_offset = (universe - first_universe_) * get_lights_per_universe();
|
int output_offset = (universe - first_universe_) * get_lights_per_universe();
|
||||||
// limit amount of lights per universe and received
|
// limit amount of lights per universe and received
|
||||||
int output_end = std::min(it->size(), std::min(output_offset + get_lights_per_universe(), packet.count - 1));
|
int output_end =
|
||||||
|
std::min(it->size(), std::min(output_offset + get_lights_per_universe(), output_offset + packet.count - 1));
|
||||||
auto input_data = packet.values + 1;
|
auto input_data = packet.values + 1;
|
||||||
|
|
||||||
ESP_LOGV(TAG, "Applying data for '%s' on %d universe, for %d-%d.", get_name().c_str(), universe, output_offset,
|
ESP_LOGV(TAG, "Applying data for '%s' on %d universe, for %d-%d.", get_name().c_str(), universe, output_offset,
|
||||||
|
Reference in New Issue
Block a user