Searchable presets.
Inline sin_gap(). Prevent live timeout.
This commit is contained in:
parent
06fe7323eb
commit
841a9f8082
@ -670,9 +670,13 @@ class WS2812FX {
|
||||
setPixelSegment(uint8_t n),
|
||||
gamma8(uint8_t),
|
||||
gamma8_cal(uint8_t, float),
|
||||
sin_gap(uint16_t),
|
||||
get_random_wheel_index(uint8_t);
|
||||
|
||||
inline uint8_t sin_gap(uint16_t in) {
|
||||
if (in & 0x100) return 0;
|
||||
return sin8(in + 192); //correct phase shift of sine so that it starts and stops at 0
|
||||
}
|
||||
|
||||
int8_t
|
||||
tristate_square8(uint8_t x, uint8_t pulsewidth, uint8_t attdec);
|
||||
|
||||
|
@ -931,12 +931,6 @@ uint16_t IRAM_ATTR WS2812FX::triwave16(uint16_t in)
|
||||
return 0xFFFF - (in - 0x8000)*2;
|
||||
}
|
||||
|
||||
uint8_t IRAM_ATTR WS2812FX::sin_gap(uint16_t in) {
|
||||
if (in & 0x100) return 0;
|
||||
//if (in > 255) return 0;
|
||||
return sin8(in + 192); //correct phase shift of sine so that it starts and stops at 0
|
||||
}
|
||||
|
||||
/*
|
||||
* Generates a tristate square wave w/ attac & decay
|
||||
* @param x input value 0-255
|
||||
|
@ -139,19 +139,21 @@ button {
|
||||
}
|
||||
|
||||
.segt TD {
|
||||
padding: 2px !important;
|
||||
text-align: center;
|
||||
/*text-transform: uppercase;*/
|
||||
}
|
||||
.segt TD, .plentry TD {
|
||||
font-size: 14px;
|
||||
font-size: 13px;
|
||||
padding: 0;
|
||||
vertical-align: middle;
|
||||
}
|
||||
/*
|
||||
.segt TD.h, .plentry TD.h {
|
||||
font-size: 13px;
|
||||
padding: 2px 0 0;
|
||||
}
|
||||
|
||||
*/
|
||||
.keytd {
|
||||
text-align: left;
|
||||
}
|
||||
@ -317,6 +319,20 @@ button {
|
||||
margin: 10px 0;
|
||||
}
|
||||
|
||||
#pcont {
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
#putil {
|
||||
padding: 0 0 10px;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
#putil .btn-n, #putil .btn-s {
|
||||
/*box-shadow: 0 0 0 5px var(--c-1);*/
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.smooth { transition: transform calc(var(--f, 1)*.5s) ease-out }
|
||||
|
||||
.tab-label {
|
||||
@ -386,7 +402,7 @@ button {
|
||||
color: var(--c-f);
|
||||
text-align: center;
|
||||
border-radius: 5px;
|
||||
padding: 16px;
|
||||
padding: 22px;
|
||||
position: fixed;
|
||||
z-index: 5;
|
||||
left: 50%;
|
||||
@ -655,8 +671,8 @@ input[type=range]::-moz-range-thumb {
|
||||
transform:translate3d(0,0,0);
|
||||
overflow: clip;
|
||||
text-overflow: clip;
|
||||
border: 1px solid var(--c-2);
|
||||
background-color: var(--c-2);
|
||||
border: 1px solid var(--c-3);
|
||||
background-color: var(--c-3);
|
||||
}
|
||||
.btn:hover {
|
||||
border: 1px solid var(--c-5);
|
||||
@ -680,12 +696,16 @@ input[type=range]::-moz-range-thumb {
|
||||
margin: 5px 0;
|
||||
}
|
||||
.btn-xs, .btn-pl-del, .btn-pl-add {
|
||||
width: 42px;
|
||||
height: 42px;
|
||||
width: 42px !important;
|
||||
height: 42px !important;
|
||||
}
|
||||
.btn-xs {
|
||||
margin: 2px 0 0 0;
|
||||
}
|
||||
#putil .btn-xs {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.btn-pl-del, .btn-pl-add {
|
||||
margin: 0;
|
||||
white-space: nowrap;
|
||||
@ -762,11 +782,10 @@ input[type=number], input[type=text] {
|
||||
border: 0px solid var(--c-2);
|
||||
border-radius: 5px;
|
||||
padding: 8px;
|
||||
margin: 6px 6px 6px 0;
|
||||
/*margin: 6px 6px 6px 0;*/
|
||||
font-size: 19px;
|
||||
transition: background-color 0.2s;
|
||||
outline: none;
|
||||
width: 50px;
|
||||
-webkit-appearance: textfield;
|
||||
-moz-appearance: textfield;
|
||||
appearance: textfield;
|
||||
@ -774,12 +793,13 @@ input[type=number], input[type=text] {
|
||||
|
||||
input[type=number] {
|
||||
text-align: right;
|
||||
width: 50px;
|
||||
}
|
||||
|
||||
textarea {
|
||||
background: var(--c-2);
|
||||
color: var(--c-f);
|
||||
width: 250px; /* +padding=260px */
|
||||
width: calc(100% - 14px); /* +padding=260px */
|
||||
height: 90px;
|
||||
border-radius: 5px;
|
||||
border: 2px solid var(--c-5);
|
||||
@ -789,17 +809,21 @@ textarea {
|
||||
padding: 5px;
|
||||
}
|
||||
|
||||
.apitxt {
|
||||
height: 7em;
|
||||
}
|
||||
|
||||
::selection {
|
||||
background: var(--c-b);
|
||||
}
|
||||
|
||||
input[type=text] {
|
||||
width: 100px;
|
||||
width: calc(100% - 24px);
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.ptxt {
|
||||
width: 240px !important;
|
||||
/*width: 236px !important;*/
|
||||
margin: 0 4px 4px !important;
|
||||
}
|
||||
|
||||
@ -836,9 +860,9 @@ input[type=number]::-webkit-outer-spin-button {
|
||||
|
||||
.pid {
|
||||
position: absolute;
|
||||
top: 2px;
|
||||
left: 0px;
|
||||
padding: 12px 0px 0px 12px;
|
||||
top: 8px;
|
||||
left: 12px;
|
||||
/*padding: 10px 0 0 12px;*/
|
||||
font-size: 16px;
|
||||
text-align: center;
|
||||
color: var(--c-b);
|
||||
@ -1044,9 +1068,7 @@ input[type=number]::-webkit-outer-spin-button {
|
||||
}
|
||||
|
||||
#segcont .seg:hover:not([class*="expanded"]),
|
||||
#pcont .pres:hover:not([class*="expanded"]),
|
||||
#pcont .selected:hover:not([class*="expanded"]),
|
||||
.lstI:hover {
|
||||
.lstI:hover:not([class*="expanded"]) {
|
||||
background: var(--c-5);
|
||||
}
|
||||
|
||||
@ -1065,6 +1087,11 @@ input[type=number]::-webkit-outer-spin-button {
|
||||
.lstI.sticky, .lstI.selected {
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
#pcont .selected {
|
||||
bottom: 114px;
|
||||
top: 40px;
|
||||
}
|
||||
/* calculated in index.js
|
||||
#fxlist .lstI.selected {
|
||||
top: 142px;
|
||||
@ -1085,8 +1112,8 @@ input[type=number]::-webkit-outer-spin-button {
|
||||
|
||||
.lstIcontent {
|
||||
/*width: 100%;
|
||||
vertical-align: middle;
|
||||
padding: 0 20px 0 5px;
|
||||
vertical-align: middle;*/
|
||||
padding: 0; /*20px 0 5px;
|
||||
text-align: left;
|
||||
display: inline-block;*/
|
||||
position: relative;
|
||||
@ -1110,6 +1137,8 @@ input[type=number]::-webkit-outer-spin-button {
|
||||
.fnd {
|
||||
width: 280px;
|
||||
margin: 0 auto;
|
||||
/*border-radius: 25px;
|
||||
box-shadow: 0 0 0 5px var(--c-1);*/
|
||||
}
|
||||
|
||||
input[type="text"].fnd {
|
||||
@ -1133,22 +1162,29 @@ input[type="text"].fnd:hover {
|
||||
}
|
||||
|
||||
.segin {
|
||||
padding: 8px;
|
||||
display: none;
|
||||
padding: 8px 8px 0;
|
||||
}
|
||||
.presin {
|
||||
padding: 8px 0 0;
|
||||
}
|
||||
|
||||
.modal .btn, .segin .btn {
|
||||
border: 1px solid var(--c-3);
|
||||
background-color: var(--c-3);
|
||||
.btn-s, .btn-n {
|
||||
border: 1px solid var(--c-2);
|
||||
background-color: var(--c-2);
|
||||
}
|
||||
.modal .btn:hover, .segin .btn:hover {
|
||||
border: 1px solid var(--c-5);
|
||||
background-color: var(--c-5);
|
||||
}
|
||||
|
||||
/* must be after .expanded */
|
||||
.pres .lstIcontent, .segin {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.check input:checked ~ .checkmark:after, .radio input:checked ~ .radiomark:after,
|
||||
.expanded, .expanded .segin {
|
||||
display: block;
|
||||
.expanded {
|
||||
display: block !important;
|
||||
}
|
||||
|
||||
.c {
|
||||
|
@ -182,50 +182,52 @@
|
||||
</div>
|
||||
|
||||
<div id="Effects" class="tabcontent">
|
||||
<p class="labels" id="sliderLabel0">Effect speed</p>
|
||||
<div class="staytop" id="slider0">
|
||||
<i class="icons slider-icon" style="cursor: pointer;" onclick="tglFreeze()"></i>
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderSpeed" class="noslide" onchange="setSpeed()" oninput="updateTrail(this)" max="255" min="0" type="range" value="128" />
|
||||
<div class="sliderdisplay"></div>
|
||||
<div id="sliders">
|
||||
<p class="labels" id="sliderLabel0">Effect speed</p>
|
||||
<div class="staytop" id="slider0">
|
||||
<i class="icons slider-icon" style="cursor: pointer;" onclick="tglFreeze()"></i>
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderSpeed" class="noslide" onchange="setSpeed()" oninput="updateTrail(this)" max="255" min="0" type="range" value="128" />
|
||||
<div class="sliderdisplay"></div>
|
||||
</div>
|
||||
<output class="sliderbubble"></output>
|
||||
</div>
|
||||
<output class="sliderbubble"></output>
|
||||
</div>
|
||||
<p class="labels" id="sliderLabel1">Effect intensity</p>
|
||||
<div class="staytop" id="slider1">
|
||||
<i class="icons slider-icon" style="cursor: pointer;" onclick="tglLabels()"></i>
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderIntensity" class="noslide" onchange="setIntensity()" oninput="updateTrail(this)" max="255" min="0" type="range" value="128" />
|
||||
<div class="sliderdisplay"></div>
|
||||
<p class="labels" id="sliderLabel1">Effect intensity</p>
|
||||
<div class="staytop" id="slider1">
|
||||
<i class="icons slider-icon" style="cursor: pointer;" onclick="tglLabels()"></i>
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderIntensity" class="noslide" onchange="setIntensity()" oninput="updateTrail(this)" max="255" min="0" type="range" value="128" />
|
||||
<div class="sliderdisplay"></div>
|
||||
</div>
|
||||
<output class="sliderbubble"></output>
|
||||
</div>
|
||||
<output class="sliderbubble"></output>
|
||||
</div>
|
||||
<p class="labels" id="sliderLabel2">Custom 1</p>
|
||||
<div class="staytop" id="slider2">
|
||||
<i class="icons slider-icon"></i>
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderC1" class="noslide" onchange="setFFT1()" oninput="updateTrail(this)" max="255" min="0" type="range" value="6" />
|
||||
<div class="sliderdisplay"></div>
|
||||
<p class="labels" id="sliderLabel2">Custom 1</p>
|
||||
<div class="staytop" id="slider2">
|
||||
<i class="icons slider-icon"></i>
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderC1" class="noslide" onchange="setFFT1()" oninput="updateTrail(this)" max="255" min="0" type="range" value="6" />
|
||||
<div class="sliderdisplay"></div>
|
||||
</div>
|
||||
<output class="sliderbubble"></output>
|
||||
</div>
|
||||
<output class="sliderbubble"></output>
|
||||
</div>
|
||||
<p class="labels" id="sliderLabel3">Custom 2</p>
|
||||
<div class="staytop" id="slider3">
|
||||
<i class="icons slider-icon"></i>
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderC2" class="noslide" onchange="setFFT2()" oninput="updateTrail(this)" max="255" min="0" type="range" value="6" />
|
||||
<div class="sliderdisplay"></div>
|
||||
<p class="labels" id="sliderLabel3">Custom 2</p>
|
||||
<div class="staytop" id="slider3">
|
||||
<i class="icons slider-icon"></i>
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderC2" class="noslide" onchange="setFFT2()" oninput="updateTrail(this)" max="255" min="0" type="range" value="6" />
|
||||
<div class="sliderdisplay"></div>
|
||||
</div>
|
||||
<output class="sliderbubble"></output>
|
||||
</div>
|
||||
<output class="sliderbubble"></output>
|
||||
</div>
|
||||
<p class="labels" id="sliderLabel4">Custom 3</p>
|
||||
<div class="staytop" id="slider4">
|
||||
<i class="icons slider-icon"></i>
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderC3" class="noslide" onchange="setFFT3()" oninput="updateTrail(this)" max="255" min="0" type="range" value="6" />
|
||||
<div class="sliderdisplay"></div>
|
||||
<p class="labels" id="sliderLabel4">Custom 3</p>
|
||||
<div class="staytop" id="slider4">
|
||||
<i class="icons slider-icon"></i>
|
||||
<div class="sliderwrap il">
|
||||
<input id="sliderC3" class="noslide" onchange="setFFT3()" oninput="updateTrail(this)" max="255" min="0" type="range" value="6" />
|
||||
<div class="sliderdisplay"></div>
|
||||
</div>
|
||||
<output class="sliderbubble"></output>
|
||||
</div>
|
||||
<output class="sliderbubble"></output>
|
||||
</div>
|
||||
<div class="il">
|
||||
<p class="labels hd" id="modeLabel">Effect mode</p>
|
||||
@ -235,7 +237,15 @@
|
||||
<i class="icons search-icon"></i>
|
||||
</div>
|
||||
<div id="fxlist" class="list">
|
||||
Loading...
|
||||
<div class="lstI">
|
||||
<label class="radio schkl" onclick="loadFX()">
|
||||
<div class="lstIcontent">
|
||||
<span class="lstIname">
|
||||
Loading...
|
||||
</span>
|
||||
</div>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -253,13 +263,19 @@
|
||||
</div>
|
||||
|
||||
<div id="Presets" class="tabcontent">
|
||||
<div id="putil" class="staytop">
|
||||
</div>
|
||||
<div id="pql">
|
||||
</div>
|
||||
<div id="pcont">
|
||||
<p class="labels hd">Presets</p>
|
||||
<div class="staytop fnd" id="psFind">
|
||||
<input type="text" class="fnd" placeholder="Search" oninput="search(this,'pcont')" onfocus="search(this,'pcont')" />
|
||||
<i class="icons clear-icon" onclick="clean(this);"></i>
|
||||
<i class="icons search-icon"></i>
|
||||
</div>
|
||||
<div id="pcont" class="list">
|
||||
<span onclick="loadPresets()">Loading...</span>
|
||||
</div>
|
||||
<div id="putil" class="staybot">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -271,7 +287,7 @@
|
||||
</div>
|
||||
|
||||
<div id="connind"></div>
|
||||
<div id="toast"></div>
|
||||
<div id="toast" onclick="clearErrorToast(100);"></div>
|
||||
<div id="namelabel" onclick="toggleNodes()"></div>
|
||||
<div id="info" class="modal">
|
||||
<div id="imgw">
|
||||
|
4958
wled00/data/index.js
4958
wled00/data/index.js
File diff suppressed because it is too large
Load Diff
3314
wled00/html_ui.h
3314
wled00/html_ui.h
File diff suppressed because it is too large
Load Diff
@ -148,8 +148,10 @@ void realtimeLock(uint32_t timeoutMs, byte md)
|
||||
}
|
||||
}
|
||||
|
||||
realtimeTimeout = millis() + timeoutMs;
|
||||
if (timeoutMs == 255001 || timeoutMs == 65000) realtimeTimeout = UINT32_MAX;
|
||||
if (realtimeTimeout != UINT32_MAX) {
|
||||
realtimeTimeout = millis() + timeoutMs;
|
||||
if (timeoutMs == 255001 || timeoutMs == 65000) realtimeTimeout = UINT32_MAX;
|
||||
}
|
||||
// if strip is off (bri==0) and not already in RTM
|
||||
if (bri == 0 && !realtimeMode) {
|
||||
strip.setBrightness(scaledBri(briLast));
|
||||
|
@ -8,7 +8,7 @@
|
||||
*/
|
||||
|
||||
// version code in format yymmddb (b = daily build)
|
||||
#define VERSION 2203091
|
||||
#define VERSION 2203101
|
||||
|
||||
//uncomment this if you have a "my_config.h" file you'd like to use
|
||||
//#define WLED_USE_MY_CONFIG
|
||||
|
Loading…
Reference in New Issue
Block a user