Skip 1st fix, save LED count, removed reverse.
This commit is contained in:
parent
77dee439e6
commit
d60506a75d
@ -140,13 +140,13 @@ class BusDigital : public Bus {
|
||||
|
||||
void setPixelColor(uint16_t pix, uint32_t c) {
|
||||
if (reversed) pix = _len - pix -1;
|
||||
pix += _skip;
|
||||
else pix += _skip;
|
||||
PolyBus::setPixelColor(_busPtr, _iType, pix, c, _colorOrder);
|
||||
}
|
||||
|
||||
uint32_t getPixelColor(uint16_t pix) {
|
||||
if (reversed) pix = _len - pix -1;
|
||||
pix += _skip;
|
||||
else pix += _skip;
|
||||
return PolyBus::getPixelColor(_busPtr, _iType, pix, _colorOrder);
|
||||
}
|
||||
|
||||
|
@ -350,7 +350,6 @@
|
||||
<option value="2">Linear (never wrap)</option>
|
||||
<option value="3">None (not recommended)</option>
|
||||
</select><br>
|
||||
Reverse LED order (rotate 180): <input type="checkbox" name="RV"><br>
|
||||
Skip first LED: <input type="checkbox" name="SL"><br>
|
||||
<span class="wc">
|
||||
Auto-calculate white channel from RGB:<br>
|
||||
|
@ -134,9 +134,8 @@ required><br>Mode: <select name="TW"><option value="0">Wait and set</option>
|
||||
value="3">Sunrise</option></select><h3>Advanced</h3>Palette blending: <select
|
||||
name="PB"><option value="0">Linear (wrap if moving)</option><option value="1">
|
||||
Linear (always wrap)</option><option value="2">Linear (never wrap)</option>
|
||||
<option value="3">None (not recommended)</option></select><br>
|
||||
Reverse LED order (rotate 180): <input type="checkbox" name="RV"><br>
|
||||
Skip first LED: <input type="checkbox" name="SL"><br><span class="wc">
|
||||
<option value="3">None (not recommended)</option></select><br>Skip first LED:
|
||||
<input type="checkbox" name="SL"><br><span class="wc">
|
||||
Auto-calculate white channel from RGB:<br><select name="AW"><option value="0">
|
||||
None</option><option value="1">Brighter</option><option value="2">Accurate
|
||||
</option><option value="3">Dual</option><option value="4">Legacy</option>
|
||||
|
@ -126,14 +126,14 @@ void handleSettingsSet(AsyncWebServerRequest *request, byte subPage)
|
||||
}
|
||||
colorOrder = request->arg(co).toInt();
|
||||
start = (request->hasArg(ls)) ? request->arg(ls).toInt() : 0;
|
||||
ledCount += length;
|
||||
// ledCount += length;
|
||||
|
||||
// actual finalization is done in loop()
|
||||
if (busConfigs[s] != nullptr) delete busConfigs[s];
|
||||
busConfigs[s] = new BusConfig(type, pins, start, length, colorOrder, request->hasArg(cv), skipFirstLed);
|
||||
}
|
||||
|
||||
// ledCount = request->arg(F("LC")).toInt();
|
||||
ledCount = request->arg(F("LC")).toInt();
|
||||
// if (t > 0 && t <= MAX_LEDS) ledCount = t;
|
||||
//DMA method uses too much ram, TODO: limit!
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user