dmx_htm_fixes (#1070)
* Update cdata.js * Update html_settings.h * Update settings.htm * Update settings_dmx.htm * Add %DMXMENU% to cdata.js * Fix single % being treated as template in settings.htm Co-authored-by: cschwinne <dev.aircoookie@gmail.com>
This commit is contained in:
parent
42397a01bf
commit
47f24ac151
2
package-lock.json
generated
2
package-lock.json
generated
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "wled",
|
"name": "wled",
|
||||||
"version": "0.10.0",
|
"version": "0.10.1",
|
||||||
"lockfileVersion": 1,
|
"lockfileVersion": 1,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
@ -202,6 +202,10 @@ writeChunks(
|
|||||||
append: ")=====",
|
append: ")=====",
|
||||||
method: "plaintext",
|
method: "plaintext",
|
||||||
filter: "html-minify",
|
filter: "html-minify",
|
||||||
|
mangle: (str) =>
|
||||||
|
str
|
||||||
|
.replace("%", "%%")
|
||||||
|
.replace(/User Interface\<\/button\>\<\/form\>/gms, "User Interface\<\/button\>\<\/form\>%DMXMENU%"),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
file: "settings_wifi.htm",
|
file: "settings_wifi.htm",
|
||||||
|
@ -31,6 +31,9 @@ function mMap(){
|
|||||||
function S(){GCH(15);GetV();mMap();}function H(){window.open("https://github.com/Aircoookie/WLED/wiki/DMX");}function B(){window.history.back();}
|
function S(){GCH(15);GetV();mMap();}function H(){window.open("https://github.com/Aircoookie/WLED/wiki/DMX");}function B(){window.history.back();}
|
||||||
function GetV(){}
|
function GetV(){}
|
||||||
</script>
|
</script>
|
||||||
|
<style>
|
||||||
|
@import url("style.css");
|
||||||
|
</style>
|
||||||
</head>
|
</head>
|
||||||
<body onload="S()">
|
<body onload="S()">
|
||||||
<form id="form_s" name="Sf" method="post">
|
<form id="form_s" name="Sf" method="post">
|
||||||
@ -48,7 +51,7 @@ Spacing between start channels: <input type="number" min="1" max="512" name="CG"
|
|||||||
<div id="gapwarning" style="color: orange; display: none;">WARNING: Channel gap is lower than channels per fixture.<br />This will cause overlap.</div>
|
<div id="gapwarning" style="color: orange; display: none;">WARNING: Channel gap is lower than channels per fixture.<br />This will cause overlap.</div>
|
||||||
<button type="button" onclick="location.href='/dmxmap';">DMX Map</button><br>
|
<button type="button" onclick="location.href='/dmxmap';">DMX Map</button><br>
|
||||||
DMX fixtures start LED: <input type="number" min="0" max="1500" name="SL">
|
DMX fixtures start LED: <input type="number" min="0" max="1500" name="SL">
|
||||||
<h3>channel functions</h3>
|
<h3>Channel functions</h3>
|
||||||
<div id="dmxchannels"></div>
|
<div id="dmxchannels"></div>
|
||||||
<hr><button type="button" onclick="B()">Back</button><button type="submit">Save</button>
|
<hr><button type="button" onclick="B()">Back</button><button type="submit">Save</button>
|
||||||
</form>
|
</form>
|
||||||
|
@ -62,6 +62,10 @@ void initDMX() {
|
|||||||
dmx.init(512); // initialize with bus length
|
dmx.init(512); // initialize with bus length
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if (LEDPIN == 2)
|
||||||
|
#pragma message "Pin conflict compiling with DMX and LEDs on pin 2. Please set a different LEDPIN."
|
||||||
|
#endif
|
||||||
|
|
||||||
#else
|
#else
|
||||||
void handleDMX() {}
|
void handleDMX() {}
|
||||||
void initDMX() {}
|
void initDMX() {}
|
||||||
|
@ -12,14 +12,14 @@ const char PAGE_settingsCss[] PROGMEM = R"=====(<style>body{font-family:Verdana,
|
|||||||
// Autogenerated from wled00/data/settings.htm, do not edit!!
|
// Autogenerated from wled00/data/settings.htm, do not edit!!
|
||||||
const char PAGE_settings[] PROGMEM = R"=====(<!DOCTYPE html><html><head><meta http-equiv="Content-Type"
|
const char PAGE_settings[] PROGMEM = R"=====(<!DOCTYPE html><html><head><meta http-equiv="Content-Type"
|
||||||
content="text/html; charset=windows-1252"><title>WLED Settings</title><style>
|
content="text/html; charset=windows-1252"><title>WLED Settings</title><style>
|
||||||
body{text-align:center;background:#222;height:100;margin:0}html{--h:11.55vh}button{background:#333;color:#fff;font-family:Verdana,Helvetica,sans-serif;border:.3ch solid #333;display:inline-block;font-size:8vmin;height:var(--h);width:95%;margin-top:2.4vh}
|
body{text-align:center;background:#222;height:100;margin:0}html{--h:11.55vh}button{background:#333;color:#fff;font-family:Verdana,Helvetica,sans-serif;border:.3ch solid #333;display:inline-block;font-size:8vmin;height:var(--h);width:95%%;margin-top:2.4vh}
|
||||||
</style><script>
|
</style><script>
|
||||||
function BB(){window.frameElement&&(document.getElementById("b").style.display="none",document.documentElement.style.setProperty("--h","13.86vh"))}
|
function BB(){window.frameElement&&(document.getElementById("b").style.display="none",document.documentElement.style.setProperty("--h","13.86vh"))}
|
||||||
</script></head><body onload="BB()"><form action="/"><button type="submit"
|
</script></head><body onload="BB()"><form action="/"><button type="submit"
|
||||||
id="b">Back</button></form><form action="/settings/wifi"><button type="submit">
|
id="b">Back</button></form><form action="/settings/wifi"><button type="submit">
|
||||||
WiFi Setup</button></form><form action="/settings/leds"><button type="submit">
|
WiFi Setup</button></form><form action="/settings/leds"><button type="submit">
|
||||||
LED Preferences</button></form><form action="/settings/ui"><button
|
LED Preferences</button></form><form action="/settings/ui"><button
|
||||||
type="submit">User Interface</button></form><form action="/settings/sync">
|
type="submit">User Interface</button></form>%DMXMENU%<form action="/settings/sync">
|
||||||
<button type="submit">Sync Interfaces</button></form><form
|
<button type="submit">Sync Interfaces</button></form><form
|
||||||
action="/settings/time"><button type="submit">Time & Macros</button></form><form
|
action="/settings/time"><button type="submit">Time & Macros</button></form><form
|
||||||
action="/settings/sec"><button type="submit">Security & Updates</button></form>
|
action="/settings/sec"><button type="submit">Security & Updates</button></form>
|
||||||
@ -136,14 +136,14 @@ onclick="B()">Back</button><button type="submit">Save</button></form></body>
|
|||||||
const char PAGE_settings_dmx[] PROGMEM = R"=====(<!DOCTYPE html><html><head><meta name="viewport" content="width=500"><meta
|
const char PAGE_settings_dmx[] PROGMEM = R"=====(<!DOCTYPE html><html><head><meta name="viewport" content="width=500"><meta
|
||||||
charset="utf-8"><title>DMX Settings</title><script>
|
charset="utf-8"><title>DMX Settings</title><script>
|
||||||
function GCH(n){for(d=document,d.getElementById("dmxchannels").innerHTML+="",i=0;i<n;i++)d.getElementById("dmxchannels").innerHTML+="<span id=CH"+(i+1)+"s >Channel "+(i+1)+": <select name=CH"+(i+1)+' id="CH'+(i+1)+'"><option value=0>Set to 0</option><option value=1>Red</option><option value=2>Green</option><option value=3>Blue</option><option value=4>White</option><option value=5>Shutter (Brightness)</option><option value=6>Set to 255</option></select></span><br />\n'}function mMap(){for(d=document,numCh=document.Sf.CN.value,numGap=document.Sf.CG.value,parseInt(numCh)>parseInt(numGap)?d.getElementById("gapwarning").style.display="block":d.getElementById("gapwarning").style.display="none",i=0;i<15;i++)i>=numCh?(d.getElementById("CH"+(i+1)+"s").style.opacity="0.5",d.getElementById("CH"+(i+1)).disabled=!0):(d.getElementById("CH"+(i+1)+"s").style.opacity="1",d.getElementById("CH"+(i+1)).disabled=!1)}function S(){GCH(15),GetV(),mMap()}function H(){window.open("https://github.com/Aircoookie/WLED/wiki/DMX")}function B(){window.history.back()}function GetV() {var d=document;
|
function GCH(n){for(d=document,d.getElementById("dmxchannels").innerHTML+="",i=0;i<n;i++)d.getElementById("dmxchannels").innerHTML+="<span id=CH"+(i+1)+"s >Channel "+(i+1)+": <select name=CH"+(i+1)+' id="CH'+(i+1)+'"><option value=0>Set to 0</option><option value=1>Red</option><option value=2>Green</option><option value=3>Blue</option><option value=4>White</option><option value=5>Shutter (Brightness)</option><option value=6>Set to 255</option></select></span><br />\n'}function mMap(){for(d=document,numCh=document.Sf.CN.value,numGap=document.Sf.CG.value,parseInt(numCh)>parseInt(numGap)?d.getElementById("gapwarning").style.display="block":d.getElementById("gapwarning").style.display="none",i=0;i<15;i++)i>=numCh?(d.getElementById("CH"+(i+1)+"s").style.opacity="0.5",d.getElementById("CH"+(i+1)).disabled=!0):(d.getElementById("CH"+(i+1)+"s").style.opacity="1",d.getElementById("CH"+(i+1)).disabled=!1)}function S(){GCH(15),GetV(),mMap()}function H(){window.open("https://github.com/Aircoookie/WLED/wiki/DMX")}function B(){window.history.back()}function GetV() {var d=document;
|
||||||
</head><body onload="S()"><form id="form_s" name="Sf" method="post">
|
%CSS%%SCSS%</head><body onload="S()"><form
|
||||||
<div class="helpB"><button type="button" onclick="H()">?</button></div><button
|
id="form_s" name="Sf" method="post"><div class="helpB"><button type="button"
|
||||||
type="button" onclick="B()">Back</button><button type="submit">Save</button><hr>
|
onclick="H()">?</button></div><button type="button" onclick="B()">Back</button>
|
||||||
<h2>Imma firin ma lazer (if it has DMX support)</h2>Proxy Universe <input
|
<button type="submit">Save</button><hr><h2>
|
||||||
name="PU" type="number" min="0" max="63999" required>
|
Imma firin ma lazer (if it has DMX support)</h2>Proxy Universe <input name="PU"
|
||||||
from E1.31 to DMX (0=disabled)<br><i>
|
type="number" min="0" max="63999" required> from E1.31 to DMX (0=disabled)<br>
|
||||||
This will disable the LED data output to DMX configurable below</i><br><br><i>
|
<i>This will disable the LED data output to DMX configurable below</i><br><br>
|
||||||
Number of fixtures is taken from LED config page</i><br>
|
<i>Number of fixtures is taken from LED config page</i><br>
|
||||||
Channels per fixture (15 max): <input type="number" min="1" max="15" name="CN"
|
Channels per fixture (15 max): <input type="number" min="1" max="15" name="CN"
|
||||||
maxlength="2" onchange="mMap()"><br>Start channel: <input type="number" min="1"
|
maxlength="2" onchange="mMap()"><br>Start channel: <input type="number" min="1"
|
||||||
max="512" name="CS" maxlength="2"><br>Spacing between start channels: <input
|
max="512" name="CS" maxlength="2"><br>Spacing between start channels: <input
|
||||||
@ -153,7 +153,7 @@ info</a> ]<br><div id="gapwarning" style="color:orange;display:none">
|
|||||||
WARNING: Channel gap is lower than channels per fixture.<br>
|
WARNING: Channel gap is lower than channels per fixture.<br>
|
||||||
This will cause overlap.</div><button type="button"
|
This will cause overlap.</div><button type="button"
|
||||||
onclick='location.href="/dmxmap"'>DMX Map</button><br>DMX fixtures start LED:
|
onclick='location.href="/dmxmap"'>DMX Map</button><br>DMX fixtures start LED:
|
||||||
<input type="number" min="0" max="1500" name="SL"><h3>channel functions</h3><div
|
<input type="number" min="0" max="1500" name="SL"><h3>Channel functions</h3><div
|
||||||
id="dmxchannels"></div><hr><button type="button" onclick="B()">Back</button>
|
id="dmxchannels"></div><hr><button type="button" onclick="B()">Back</button>
|
||||||
<button type="submit">Save</button></form></body></html>)=====";
|
<button type="submit">Save</button></form></body></html>)=====";
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user