Lock option: only show dashboard while locked; Sound Lab only in the desktop apps
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
9203cab4df
commit
f043e1a261
10 files changed
+58
-19
No files matched your search
@@ -17,7 +17,7 @@ pi_writer.py → pi_image.py (cloud-init SD card, installs server.py as a system
|
|||||||
backups. Config is one JSON file (`config.json`, gitignored) – `load()` / `apply_config()` / `save()`.
|
backups. Config is one JSON file (`config.json`, gitignored) – `load()` / `apply_config()` / `save()`.
|
||||||
* **Auth** – 4-digit PIN, PBKDF2 hash in `config.json`, session cookie `dspsess` (30 days), lockout after 5 failures.
|
* **Auth** – 4-digit PIN, PBKDF2 hash in `config.json`, session cookie `dspsess` (30 days), lockout after 5 failures.
|
||||||
The desktop app logs in via `/app-login?t=<one-time token>`; app sessions live in memory only, skip the PIN and may
|
The desktop app logs in via `/app-login?t=<one-time token>`; app sessions live in memory only, skip the PIN and may
|
||||||
toggle remote access (`/api/remote`) and the lock (`/api/lock`, server answers 423 while locked). Remote clients
|
toggle remote access (`/api/remote`) and the lock (`/api/lock`, server answers 423 while locked; with `lock_dash` the window shows only the dashboard). Remote clients
|
||||||
always need the PIN.
|
always need the PIN.
|
||||||
* **`dsp/device.py`** – one `Device` per DSP: connect (TCP or `usbhid.open_stream`), handshake, config dump
|
* **`dsp/device.py`** – one `Device` per DSP: connect (TCP or `usbhid.open_stream`), handshake, config dump
|
||||||
(50-byte chunks), command queue (one request in flight), meter polling (also keepalive), auto-reconnect.
|
(50-byte chunks), command queue (one request in flight), meter polling (also keepalive), auto-reconnect.
|
||||||
@@ -56,7 +56,7 @@ pi_writer.py → pi_image.py (cloud-init SD card, installs server.py as a system
|
|||||||
* **Read-only switch** (`S.guard`, `viewOnly()` in `app.js`) – web UI on phones and touch devices starts read-only, reusing
|
* **Read-only switch** (`S.guard`, `viewOnly()` in `app.js`) – web UI on phones and touch devices starts read-only, reusing
|
||||||
the swallowing of the app lock. A safety catch per browser tab only: not stored, the server doesn't know it. Mute all stays.
|
the swallowing of the app lock. A safety catch per browser tab only: not stored, the server doesn't know it. Mute all stays.
|
||||||
* **Sound Lab / REW** (`static/rew.js`, handbooks in `static/docs.js`, `rew_call` in `server.py`) – the server talks to REW's API on `127.0.0.1:4735`, which only answers on
|
* **Sound Lab / REW** (`static/rew.js`, handbooks in `static/docs.js`, `rew_call` in `server.py`) – the server talks to REW's API on `127.0.0.1:4735`, which only answers on
|
||||||
REW's own computer; filter files work with the app on a Pi. Not offered on phones. Only checked against a fake server built from its OpenAPI spec.
|
REW's own computer; so Sound Lab is only in the desktop apps (`S.isApp`, the server refuses `/api/rew/` otherwise). Only checked against a fake server built from its OpenAPI spec.
|
||||||
* **Network search** – `App.scan_network` probes the local /24 networks on TCP 9761 (handshake + device info),
|
* **Network search** – `App.scan_network` probes the local /24 networks on TCP 9761 (handshake + device info),
|
||||||
skipping DSPs this app is connected to.
|
skipping DSPs this app is connected to.
|
||||||
* **Copy settings / mute all** – `App.copy_settings` (`POST /api/copy`, groups level/filters/eq/dynamics/routing) and
|
* **Copy settings / mute all** – `App.copy_settings` (`POST /api/copy`, groups level/filters/eq/dynamics/routing) and
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ Control both devices at the same time from your phone, tablet or computer – ov
|
|||||||
clickable EQ bands and overlays, channel, limiter, routing, delay, FIR, notes), move them by the title, resize them by
|
clickable EQ bands and overlays, channel, limiter, routing, delay, FIR, notes), move them by the title, resize them by
|
||||||
the arrows, choose their DSP. It only looks and never changes a DSP; the layout is stored in the config
|
the arrows, choose their DSP. It only looks and never changes a DSP; the layout is stored in the config
|
||||||
* **Read-only switch** – on phones and tablets the web UI starts read-only; a small switch at the top allows changes
|
* **Read-only switch** – on phones and tablets the web UI starts read-only; a small switch at the top allows changes
|
||||||
* **Sound Lab** – together with REW (Room EQ Wizard): take the filters of a measurement or a REW filter file onto a channel,
|
* **Sound Lab** (Windows and macOS apps) – together with REW (Room EQ Wizard): take the filters of a measurement or a REW filter file onto a channel,
|
||||||
compare before applying, send a channel's curve or filters back to REW. Handbook with real cases here and in SoundField
|
compare before applying, send a channel's curve or filters back to REW. Handbook with real cases here and in SoundField
|
||||||
* **Mixer** – faders, mute and live meters for all inputs and outputs, limiter LED on every output (status read
|
* **Mixer** – faders, mute and live meters for all inputs and outputs, limiter LED on every output (status read
|
||||||
from the DSP)
|
from the DSP)
|
||||||
|
|||||||
@@ -301,6 +301,7 @@ class App:
|
|||||||
self.remote_writers: set[asyncio.StreamWriter] = set()
|
self.remote_writers: set[asyncio.StreamWriter] = set()
|
||||||
self.remote_error = ""
|
self.remote_error = ""
|
||||||
self.locked = False # desktop app window read-only until unlocked with the PIN
|
self.locked = False # desktop app window read-only until unlocked with the PIN
|
||||||
|
self.lock_dash = False # while locked the app window shows nothing but the dashboard
|
||||||
self.lang = "" # UI language chosen in the desktop app ("" = not chosen yet, English)
|
self.lang = "" # UI language chosen in the desktop app ("" = not chosen yet, English)
|
||||||
# demo mode: the real DSPs are disconnected and a simulated one runs inside the server
|
# demo mode: the real DSPs are disconnected and a simulated one runs inside the server
|
||||||
self.demo = {"enabled": False, "model": "408"}
|
self.demo = {"enabled": False, "model": "408"}
|
||||||
@@ -319,6 +320,7 @@ class App:
|
|||||||
now = time.time()
|
now = time.time()
|
||||||
self.sessions = {k: v for k, v in cfg.get("sessions", {}).items() if v > now}
|
self.sessions = {k: v for k, v in cfg.get("sessions", {}).items() if v > now}
|
||||||
self.locked = bool(cfg.get("locked"))
|
self.locked = bool(cfg.get("locked"))
|
||||||
|
self.lock_dash = bool(cfg.get("lock_dash"))
|
||||||
self.lang = cfg.get("lang") if cfg.get("lang") in ("en", "de") else ""
|
self.lang = cfg.get("lang") if cfg.get("lang") in ("en", "de") else ""
|
||||||
m = cfg.get("mute_all") or {}
|
m = cfg.get("mute_all") or {}
|
||||||
self.mute_all = {"active": bool(m.get("active")), "restore": {
|
self.mute_all = {"active": bool(m.get("active")), "restore": {
|
||||||
@@ -411,7 +413,7 @@ class App:
|
|||||||
def save(self):
|
def save(self):
|
||||||
sessions = {k: v for k, v in self.sessions.items() if k not in self.app_sessions}
|
sessions = {k: v for k, v in self.sessions.items() if k not in self.app_sessions}
|
||||||
cfg = {"devices": [d.config() for d in self.real_devices()], "auth": self.auth,
|
cfg = {"devices": [d.config() for d in self.real_devices()], "auth": self.auth,
|
||||||
"sessions": sessions, "limiter": self.limiter, "remote": self.remote, "locked": self.locked,
|
"sessions": sessions, "limiter": self.limiter, "remote": self.remote, "locked": self.locked, "lock_dash": self.lock_dash,
|
||||||
"soundfield": self.soundfield, "logo": self.logo, "dashboard": self.dashboard,
|
"soundfield": self.soundfield, "logo": self.logo, "dashboard": self.dashboard,
|
||||||
"mute_all": {"active": self.mute_all["active"],
|
"mute_all": {"active": self.mute_all["active"],
|
||||||
"restore": {k: v for k, v in self.mute_all["restore"].items() if k != "demo"}}}
|
"restore": {k: v for k, v in self.mute_all["restore"].items() if k != "demo"}}}
|
||||||
@@ -1105,7 +1107,7 @@ class App:
|
|||||||
is_app = session in self.app_sessions
|
is_app = session in self.app_sessions
|
||||||
if path == "/api/auth":
|
if path == "/api/auth":
|
||||||
await self.respond_json(writer, 200, {"authenticated": bool(session), "app": is_app,
|
await self.respond_json(writer, 200, {"authenticated": bool(session), "app": is_app,
|
||||||
"locked": is_app and self.locked,
|
"locked": is_app and self.locked, "lock_dash": is_app and self.lock_dash,
|
||||||
"lang": self.lang if is_app else ""})
|
"lang": self.lang if is_app else ""})
|
||||||
return
|
return
|
||||||
if path == "/api/login" and method == "POST":
|
if path == "/api/login" and method == "POST":
|
||||||
@@ -1130,6 +1132,18 @@ class App:
|
|||||||
self.save()
|
self.save()
|
||||||
await self.respond_json(writer, 200, {"lang": self.lang})
|
await self.respond_json(writer, 200, {"lang": self.lang})
|
||||||
return
|
return
|
||||||
|
if path.startswith("/api/rew/") and not is_app: # REW runs next to the desktop app
|
||||||
|
await self.respond_json(writer, 403, {"error": "desktop app only"})
|
||||||
|
return
|
||||||
|
if path == "/api/lock-dash" and method == "POST":
|
||||||
|
if not is_app:
|
||||||
|
await self.respond_json(writer, 403, {"error": "desktop app only"})
|
||||||
|
else:
|
||||||
|
self.lock_dash = bool(data.get("enabled"))
|
||||||
|
self.save()
|
||||||
|
self.broadcast({"type": "lockdash", "enabled": self.lock_dash})
|
||||||
|
await self.respond_json(writer, 200, {"enabled": self.lock_dash})
|
||||||
|
return
|
||||||
if path in ("/api/lock", "/api/unlock") and method == "POST":
|
if path in ("/api/lock", "/api/unlock") and method == "POST":
|
||||||
if not is_app:
|
if not is_app:
|
||||||
await self.respond_json(writer, 403, {"error": "desktop app only"})
|
await self.respond_json(writer, 403, {"error": "desktop app only"})
|
||||||
|
|||||||
+24
-3
@@ -626,6 +626,7 @@ function renderTabs() {
|
|||||||
$("#btn-settings").disabled = testLock;
|
$("#btn-settings").disabled = testLock;
|
||||||
document.querySelectorAll("#viewtabs button").forEach(b => {
|
document.querySelectorAll("#viewtabs button").forEach(b => {
|
||||||
if (b.dataset.view === "fir") b.hidden = !(dev() && dev().fir);
|
if (b.dataset.view === "fir") b.hidden = !(dev() && dev().fir);
|
||||||
|
if (b.dataset.view === "lab") b.hidden = !S.isApp;
|
||||||
b.classList.toggle("active", !S.settings && b.dataset.view === S.view);
|
b.classList.toggle("active", !S.settings && b.dataset.view === S.view);
|
||||||
b.disabled = testLock && b.dataset.view !== "test";
|
b.disabled = testLock && b.dataset.view !== "test";
|
||||||
});
|
});
|
||||||
@@ -1359,7 +1360,7 @@ function peqCard(d, kind, idx) {
|
|||||||
const card = h("div", { class: "card wide" + (ch.peq_bypass ? " eq-off" : "") },
|
const card = h("div", { class: "card wide" + (ch.peq_bypass ? " eq-off" : "") },
|
||||||
h("h3", {}, h("span", { class: "grow" }, t("Parametric EQ")), modeSeg,
|
h("h3", {}, h("span", { class: "grow" }, t("Parametric EQ")), modeSeg,
|
||||||
d.fir ? null : toggleBtn("EQ Bypass", kind, idx, "peq_bypass", "small bypass", v => { card.classList.toggle("eq-off", v); renderBand(); redraw(); }),
|
d.fir ? null : toggleBtn("EQ Bypass", kind, idx, "peq_bypass", "small bypass", v => { card.classList.toggle("eq-off", v); renderBand(); redraw(); }),
|
||||||
h("button", { class: "small rewbtn", "data-view-ok": "", title: t("Open this channel in Sound Lab (REW)"), onclick: () => openLab(kind, idx) }, "REW"),
|
S.isApp ? h("button", { class: "small", "data-view-ok": "", title: t("Open this channel in Sound Lab (REW)"), onclick: () => openLab(kind, idx) }, "REW") : null,
|
||||||
h("button", { class: "small", onclick: async () => {
|
h("button", { class: "small", onclick: async () => {
|
||||||
if (!await askConfirm(t("Reset EQ"), t("Set all PEQ bands of this channel to 0 dB and clear bypass?"), t("All flat"))) return;
|
if (!await askConfirm(t("Reset EQ"), t("Set all PEQ bands of this channel to 0 dB and clear bypass?"), t("All flat"))) return;
|
||||||
chans(dev(), kind)[idx].peq.forEach((bb, i) => {
|
chans(dev(), kind)[idx].peq.forEach((bb, i) => {
|
||||||
@@ -2232,6 +2233,16 @@ function backupCard() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Desktop app only: let phones/tablets on the LAN use this PC as server (they need the PIN)
|
// Desktop app only: let phones/tablets on the LAN use this PC as server (they need the PIN)
|
||||||
|
function lockOptionCard() {
|
||||||
|
const box = h("input", { type: "checkbox", checked: !!S.lockDash, onchange: async () => {
|
||||||
|
try { S.lockDash = (await api("POST", "/api/lock-dash", { enabled: box.checked })).enabled; }
|
||||||
|
catch (e) { box.checked = !!S.lockDash; toast(t("Error: ") + trMsg(e.message)); }
|
||||||
|
} });
|
||||||
|
return h("div", { class: "card" }, h("h3", {}, t("Lock")),
|
||||||
|
h("label", { class: "chk" }, box, t("Only show dashboard while locked")),
|
||||||
|
h("p", { class: "info" }, t("With the lock on, this window then shows just your dashboard, until it is unlocked with the PIN.")));
|
||||||
|
}
|
||||||
|
|
||||||
function remoteCard() {
|
function remoteCard() {
|
||||||
const r = S.remote || { enabled: false, port: 8080, urls: [] };
|
const r = S.remote || { enabled: false, port: 8080, urls: [] };
|
||||||
const port = h("input", { type: "number", min: 1, max: 65535, value: r.port, class: "short", "aria-label": "Port" });
|
const port = h("input", { type: "number", min: 1, max: 65535, value: r.port, class: "short", "aria-label": "Port" });
|
||||||
@@ -2397,7 +2408,7 @@ function viewSettings() {
|
|||||||
["devices", t("Devices"), t("Several DSPs can be connected at the same time – pick one at the top. A DSP accepts only one connection: close the Thomann editor first."),
|
["devices", t("Devices"), t("Several DSPs can be connected at the same time – pick one at the top. A DSP accepts only one connection: close the Thomann editor first."),
|
||||||
"wide", [...S.order.filter(id => !S.devices[id].demo).map(id => deviceForm(S.devices[id])), scanCard(), addDeviceCard()]],
|
"wide", [...S.order.filter(id => !S.devices[id].demo).map(id => deviceForm(S.devices[id])), scanCard(), addDeviceCard()]],
|
||||||
["access", S.isApp ? t("Remote access") : t("Security"), S.isApp ? t("Let phones and tablets in your network control this computer – they log in with the PIN.") : t("Who may use this web interface."),
|
["access", S.isApp ? t("Remote access") : t("Security"), S.isApp ? t("Let phones and tablets in your network control this computer – they log in with the PIN.") : t("Who may use this web interface."),
|
||||||
"wide", [S.isApp ? remoteCard() : null, pinCard()]],
|
"wide", [S.isApp ? remoteCard() : null, S.isApp ? lockOptionCard() : null, pinCard()]],
|
||||||
["backup", t("Backup"), t("Save and restore the settings of this app."), "wide", [backupCard()]],
|
["backup", t("Backup"), t("Save and restore the settings of this app."), "wide", [backupCard()]],
|
||||||
];
|
];
|
||||||
const nav = h("nav", { class: "setnav", "aria-label": t("Settings") }, sections.map(([id, title]) =>
|
const nav = h("nav", { class: "setnav", "aria-label": t("Settings") }, sections.map(([id, title]) =>
|
||||||
@@ -2429,6 +2440,11 @@ function render() {
|
|||||||
if (S.busy) { S.dirty = true; return; }
|
if (S.busy) { S.dirty = true; return; }
|
||||||
if ($("#app").hidden) return;
|
if ($("#app").hidden) return;
|
||||||
if (!S.devices[S.cur]) S.cur = S.order[0] || null;
|
if (!S.devices[S.cur]) S.cur = S.order[0] || null;
|
||||||
|
// locked with "only show dashboard": back to where it was after unlocking
|
||||||
|
if (dashOnly() && !testOn(S.devices[S.cur])) {
|
||||||
|
if (S.view !== "dash" || S.settings) { S.beforeLock = S.beforeLock || { view: S.view, settings: S.settings }; S.view = "dash"; S.settings = false; }
|
||||||
|
} else if (S.beforeLock) { S.view = S.beforeLock.view; S.settings = S.beforeLock.settings; S.beforeLock = null; }
|
||||||
|
document.body.classList.toggle("dashonly", dashOnly() && !testOn(S.devices[S.cur]));
|
||||||
if (testOn(S.devices[S.cur])) { S.view = "test"; S.settings = false; } // stays in the audio test until the analog input is back
|
if (testOn(S.devices[S.cur])) { S.view = "test"; S.settings = false; } // stays in the audio test until the analog input is back
|
||||||
// keep focus on a text field (e.g. while typing a device name) – re-rendering would steal it
|
// keep focus on a text field (e.g. while typing a device name) – re-rendering would steal it
|
||||||
const ae = document.activeElement;
|
const ae = document.activeElement;
|
||||||
@@ -2457,7 +2473,7 @@ function render() {
|
|||||||
: d.status === "locked" ? h("div", {}, h("p", {}, t("This DSP is locked with a code.")),
|
: d.status === "locked" ? h("div", {}, h("p", {}, t("This DSP is locked with a code.")),
|
||||||
h("button", { class: "on", onclick: () => unlockDialog(d) }, t("Enter code")))
|
h("button", { class: "on", onclick: () => unlockDialog(d) }, t("Enter code")))
|
||||||
: S.demo.enabled && !d.demo ? t("Disconnected while demo mode is on") : t("Not connected."));
|
: S.demo.enabled && !d.demo ? t("Disconnected while demo mode is on") : t("Not connected."));
|
||||||
else content = ({ mixer: viewMixer, channel: viewChannel, routing: viewRouting, link: viewLink, fir: d.fir ? viewFir : viewMixer, lab: window.innerWidth < 760 ? viewMixer : viewLab, limiter: viewLimiter, test: viewTest }[S.view] || viewMixer)(d);
|
else content = ({ mixer: viewMixer, channel: viewChannel, routing: viewRouting, link: viewLink, fir: d.fir ? viewFir : viewMixer, lab: S.isApp ? viewLab : viewMixer, limiter: viewLimiter, test: viewTest }[S.view] || viewMixer)(d);
|
||||||
main.replaceChildren(...[content].flat().filter(Boolean));
|
main.replaceChildren(...[content].flat().filter(Boolean));
|
||||||
main.querySelectorAll(H_SCROLL).forEach((e, i) => { if (xs[i]) e.scrollLeft = xs[i]; });
|
main.querySelectorAll(H_SCROLL).forEach((e, i) => { if (xs[i]) e.scrollLeft = xs[i]; });
|
||||||
window.scrollTo(0, y);
|
window.scrollTo(0, y);
|
||||||
@@ -2501,6 +2517,7 @@ new ResizeObserver(() => document.documentElement.style.setProperty("--sb", $("#
|
|||||||
// Phones and tablets on the web UI start read-only, so nothing changes by touching it by accident.
|
// Phones and tablets on the web UI start read-only, so nothing changes by touching it by accident.
|
||||||
// Only a safety catch in this browser tab: it is not stored and the server knows nothing about it.
|
// Only a safety catch in this browser tab: it is not stored and the server knows nothing about it.
|
||||||
const viewOnly = () => !!S.locked || !!S.guard;
|
const viewOnly = () => !!S.locked || !!S.guard;
|
||||||
|
const dashOnly = () => !!S.locked && !!S.lockDash;
|
||||||
function showGuard() {
|
function showGuard() {
|
||||||
const b = $("#btn-guard"), used = !S.isApp && S.guardUsed;
|
const b = $("#btn-guard"), used = !S.isApp && S.guardUsed;
|
||||||
b.hidden = !used;
|
b.hidden = !used;
|
||||||
@@ -2640,6 +2657,9 @@ function connectEvents() {
|
|||||||
case "lock":
|
case "lock":
|
||||||
if (S.isApp) { S.locked = ev.locked; showLock(); render(); }
|
if (S.isApp) { S.locked = ev.locked; showLock(); render(); }
|
||||||
break;
|
break;
|
||||||
|
case "lockdash":
|
||||||
|
if (S.isApp) { S.lockDash = ev.enabled; render(); }
|
||||||
|
break;
|
||||||
case "meters":
|
case "meters":
|
||||||
updateMeters(ev); break;
|
updateMeters(ev); break;
|
||||||
case "limiter":
|
case "limiter":
|
||||||
@@ -2729,6 +2749,7 @@ async function startApp() {
|
|||||||
if (store.get("dsp.lang") === a.lang) return location.reload();
|
if (store.get("dsp.lang") === a.lang) return location.reload();
|
||||||
}
|
}
|
||||||
S.locked = !!a.locked;
|
S.locked = !!a.locked;
|
||||||
|
S.lockDash = !!a.lock_dash;
|
||||||
S.guardUsed = !S.isApp && matchMedia("(max-width: 759px), (pointer: coarse)").matches;
|
S.guardUsed = !S.isApp && matchMedia("(max-width: 759px), (pointer: coarse)").matches;
|
||||||
S.guard = S.guardUsed;
|
S.guard = S.guardUsed;
|
||||||
showGuard();
|
showGuard();
|
||||||
|
|||||||
+1
-1
@@ -91,7 +91,7 @@ const DASH_MODULES = {
|
|||||||
const list = dashDevs();
|
const list = dashDevs();
|
||||||
if (!list.length) return offline();
|
if (!list.length) return offline();
|
||||||
return h("div", { class: "dlist" }, list.map(d => h("button", { class: "drow dlink", "data-view-ok": "", title: t("Open in the mixer"),
|
return h("div", { class: "dlist" }, list.map(d => h("button", { class: "drow dlink", "data-view-ok": "", title: t("Open in the mixer"),
|
||||||
onclick: () => { S.cur = d.id; S.view = "mixer"; store.set("dsp.view", "mixer"); render(); window.scrollTo(0, 0); } },
|
onclick: () => { if (dashOnly()) return; S.cur = d.id; S.view = "mixer"; store.set("dsp.view", "mixer"); render(); window.scrollTo(0, 0); } },
|
||||||
h("span", { class: "dot " + d.status }),
|
h("span", { class: "dot " + d.status }),
|
||||||
h("span", { class: "grow dname" }, h("b", {}, d.name), h("small", {}, [MODEL_LABEL[d.detected_model || d.model] || "", d.state ? d.state.preset_name : (STATUS_TEXT[d.status] || d.status)].filter(Boolean).join(" · "))),
|
h("span", { class: "grow dname" }, h("b", {}, d.name), h("small", {}, [MODEL_LABEL[d.detected_model || d.model] || "", d.state ? d.state.preset_name : (STATUS_TEXT[d.status] || d.status)].filter(Boolean).join(" · "))),
|
||||||
d.state && dashChannels(d).some(([k, i]) => chans(d, k)[i].mute) ? h("span", { class: "dtag mute" }, "MUTE") : null)));
|
d.state && dashChannels(d).some(([k, i]) => chans(d, k)[i].mute) ? h("span", { class: "dtag mute" }, "MUTE") : null)));
|
||||||
|
|||||||
+2
-2
@@ -10,7 +10,7 @@ const DOC_LAB = () => ({
|
|||||||
t("Install REW on the computer running this app and connect a measuring microphone."),
|
t("Install REW on the computer running this app and connect a measuring microphone."),
|
||||||
t("In REW: Preferences → API → start the API, and tick that it starts with REW."),
|
t("In REW: Preferences → API → start the API, and tick that it starts with REW."),
|
||||||
t("Open Sound Lab and press “Check”. The dot turns green and shows the REW version."),
|
t("Open Sound Lab and press “Check”. The dot turns green and shows the REW version."),
|
||||||
], p: t("REW's API only answers on its own computer. With the app on a Raspberry Pi, use the filter file instead.") },
|
], p: t("REW's API only answers on its own computer, so Sound Lab is part of the Windows and macOS apps only.") },
|
||||||
{ h: t("Example: correcting a top in a hall"), steps: [
|
{ h: t("Example: correcting a top in a hall"), steps: [
|
||||||
t("Export a preset first (File… → Export), so you can go back."),
|
t("Export a preset first (File… → Export), so you can go back."),
|
||||||
t("Mute everything except the speaker you are measuring and set a low level. Put the microphone at ear height in the audience area."),
|
t("Mute everything except the speaker you are measuring and set a low level. Put the microphone at ear height in the audience area."),
|
||||||
@@ -29,7 +29,7 @@ const DOC_LAB = () => ({
|
|||||||
t("In REW's EQ window change the filters and watch the predicted result. Nothing changes on the DSP."),
|
t("In REW's EQ window change the filters and watch the predicted result. Nothing changes on the DSP."),
|
||||||
t("If you like it, press “Take filters” in Sound Lab, check and apply."),
|
t("If you like it, press “Take filters” in Sound Lab, check and apply."),
|
||||||
] },
|
] },
|
||||||
{ h: t("Without a connection (app on a Raspberry Pi)"), steps: [
|
{ h: t("Without the API"), steps: [
|
||||||
t("In REW's EQ window: File → Export → Filter settings as text."),
|
t("In REW's EQ window: File → Export → Filter settings as text."),
|
||||||
t("In Sound Lab press “Load REW filter file…”, check and apply."),
|
t("In Sound Lab press “Load REW filter file…”, check and apply."),
|
||||||
] },
|
] },
|
||||||
|
|||||||
+4
-2
@@ -630,7 +630,7 @@ const DE = {
|
|||||||
"Install REW on the computer running this app and connect a measuring microphone.": "REW auf dem Computer installieren, auf dem diese App läuft, und ein Messmikrofon anschließen.",
|
"Install REW on the computer running this app and connect a measuring microphone.": "REW auf dem Computer installieren, auf dem diese App läuft, und ein Messmikrofon anschließen.",
|
||||||
"In REW: Preferences → API → start the API, and tick that it starts with REW.": "In REW: Preferences → API → die API starten und anhaken, dass sie mit REW startet.",
|
"In REW: Preferences → API → start the API, and tick that it starts with REW.": "In REW: Preferences → API → die API starten und anhaken, dass sie mit REW startet.",
|
||||||
"Open Sound Lab and press “Check”. The dot turns green and shows the REW version.": "Das Sound Lab öffnen und „Prüfen“ drücken. Der Punkt wird grün und zeigt die REW-Version.",
|
"Open Sound Lab and press “Check”. The dot turns green and shows the REW version.": "Das Sound Lab öffnen und „Prüfen“ drücken. Der Punkt wird grün und zeigt die REW-Version.",
|
||||||
"REW's API only answers on its own computer. With the app on a Raspberry Pi, use the filter file instead.": "Die API von REW antwortet nur auf dem eigenen Computer. Mit der App auf einem Raspberry Pi nimmst du stattdessen die Filterdatei.",
|
"REW's API only answers on its own computer, so Sound Lab is part of the Windows and macOS apps only.": "Die API von REW antwortet nur auf dem eigenen Computer, darum gibt es das Sound Lab nur in den Apps für Windows und macOS.",
|
||||||
"Example: correcting a top in a hall": "Beispiel: ein Top in einer Halle korrigieren",
|
"Example: correcting a top in a hall": "Beispiel: ein Top in einer Halle korrigieren",
|
||||||
"Export a preset first (File… → Export), so you can go back.": "Zuerst ein Preset exportieren (Datei… → Export), damit du zurück kannst.",
|
"Export a preset first (File… → Export), so you can go back.": "Zuerst ein Preset exportieren (Datei… → Export), damit du zurück kannst.",
|
||||||
"Mute everything except the speaker you are measuring and set a low level. Put the microphone at ear height in the audience area.": "Alles außer dem gemessenen Lautsprecher stummschalten und einen niedrigen Pegel einstellen. Das Mikrofon auf Ohrhöhe in den Publikumsbereich stellen.",
|
"Mute everything except the speaker you are measuring and set a low level. Put the microphone at ear height in the audience area.": "Alles außer dem gemessenen Lautsprecher stummschalten und einen niedrigen Pegel einstellen. Das Mikrofon auf Ohrhöhe in den Publikumsbereich stellen.",
|
||||||
@@ -647,7 +647,7 @@ const DE = {
|
|||||||
"Choose a measurement and press “Send filters to the chosen measurement”. This replaces the filters of that measurement in REW.": "Eine Messung wählen und „Filter an die gewählte Messung senden“ drücken. Das ersetzt die Filter dieser Messung in REW.",
|
"Choose a measurement and press “Send filters to the chosen measurement”. This replaces the filters of that measurement in REW.": "Eine Messung wählen und „Filter an die gewählte Messung senden“ drücken. Das ersetzt die Filter dieser Messung in REW.",
|
||||||
"In REW's EQ window change the filters and watch the predicted result. Nothing changes on the DSP.": "Im EQ-Fenster von REW die Filter ändern und die Vorhersage beobachten. Am DSP ändert sich dabei nichts.",
|
"In REW's EQ window change the filters and watch the predicted result. Nothing changes on the DSP.": "Im EQ-Fenster von REW die Filter ändern und die Vorhersage beobachten. Am DSP ändert sich dabei nichts.",
|
||||||
"If you like it, press “Take filters” in Sound Lab, check and apply.": "Wenn es passt, im Sound Lab „Filter holen“ drücken, prüfen und übernehmen.",
|
"If you like it, press “Take filters” in Sound Lab, check and apply.": "Wenn es passt, im Sound Lab „Filter holen“ drücken, prüfen und übernehmen.",
|
||||||
"Without a connection (app on a Raspberry Pi)": "Ohne Verbindung (App auf einem Raspberry Pi)",
|
"Without the API": "Ohne die API",
|
||||||
"In REW's EQ window: File → Export → Filter settings as text.": "Im EQ-Fenster von REW: File → Export → Filter settings as text.",
|
"In REW's EQ window: File → Export → Filter settings as text.": "Im EQ-Fenster von REW: File → Export → Filter settings as text.",
|
||||||
"In Sound Lab press “Load REW filter file…”, check and apply.": "Im Sound Lab „REW-Filterdatei laden…“ drücken, prüfen und übernehmen.",
|
"In Sound Lab press “Load REW filter file…”, check and apply.": "Im Sound Lab „REW-Filterdatei laden…“ drücken, prüfen und übernehmen.",
|
||||||
"SoundField is a top view of the room for planning before you set up: where speakers go, how evenly the room is covered, and which delays they need. It calculates a free field without reflections, so it is a planning aid, not a measurement.": "SoundField ist eine Draufsicht auf den Raum zum Planen vor dem Aufbau: wo die Lautsprecher hinkommen, wie gleichmäßig der Raum abgedeckt ist und welche Delays sie brauchen. Es rechnet im Freifeld ohne Reflexionen, ist also eine Planungshilfe und keine Messung.",
|
"SoundField is a top view of the room for planning before you set up: where speakers go, how evenly the room is covered, and which delays they need. It calculates a free field without reflections, so it is a planning aid, not a measurement.": "SoundField ist eine Draufsicht auf den Raum zum Planen vor dem Aufbau: wo die Lautsprecher hinkommen, wie gleichmäßig der Raum abgedeckt ist und welche Delays sie brauchen. Es rechnet im Freifeld ohne Reflexionen, ist also eine Planungshilfe und keine Messung.",
|
||||||
@@ -672,6 +672,8 @@ const DE = {
|
|||||||
"Select a speaker and tick which DSP outputs feed it.": "Einen Lautsprecher wählen und anhaken, welche DSP-Ausgänge ihn speisen.",
|
"Select a speaker and tick which DSP outputs feed it.": "Einen Lautsprecher wählen und anhaken, welche DSP-Ausgänge ihn speisen.",
|
||||||
"In the “Delays” table press “Apply” for one speaker, or “Apply all”. The column “Now on DSP” shows what is set.": "In der Tabelle „Delays“ für einen Lautsprecher „Übernehmen“ drücken, oder „Alle übernehmen“. Die Spalte „Jetzt im DSP“ zeigt, was gesetzt ist.",
|
"In the “Delays” table press “Apply” for one speaker, or “Apply all”. The column “Now on DSP” shows what is set.": "In der Tabelle „Delays“ für einen Lautsprecher „Übernehmen“ drücken, oder „Alle übernehmen“. Die Spalte „Jetzt im DSP“ zeigt, was gesetzt ist.",
|
||||||
"Check the result by ear or with a measurement: temperature, reflections and real speakers differ from the model.": "Das Ergebnis mit dem Ohr oder per Messung prüfen: Temperatur, Reflexionen und echte Lautsprecher weichen vom Modell ab.",
|
"Check the result by ear or with a measurement: temperature, reflections and real speakers differ from the model.": "Das Ergebnis mit dem Ohr oder per Messung prüfen: Temperatur, Reflexionen und echte Lautsprecher weichen vom Modell ab.",
|
||||||
|
"Only show dashboard while locked": "Während der Sperre nur das Dashboard zeigen",
|
||||||
|
"With the lock on, this window then shows just your dashboard, until it is unlocked with the PIN.": "Bei aktiver Sperre zeigt dieses Fenster dann nur dein Dashboard, bis es mit der PIN entsperrt wird.",
|
||||||
};
|
};
|
||||||
|
|
||||||
const DE_PATTERNS = [
|
const DE_PATTERNS = [
|
||||||
|
|||||||
+1
-1
@@ -42,7 +42,7 @@
|
|||||||
<button data-view="fir" hidden><svg viewBox="0 0 24 24"><path d="M2 12h3l2-7 3 14 3-11 2 6 2-3 1 1h4"/></svg><span>FIR</span></button>
|
<button data-view="fir" hidden><svg viewBox="0 0 24 24"><path d="M2 12h3l2-7 3 14 3-11 2 6 2-3 1 1h4"/></svg><span>FIR</span></button>
|
||||||
<button data-view="limiter"><svg viewBox="0 0 24 24"><path d="M2 7h20" stroke-dasharray="2.5 2.5"/><path d="M2 14c2 0 3-7 5-7h3c2 0 3 11 6 11s3-5 6-5"/></svg><span>Limiter</span></button>
|
<button data-view="limiter"><svg viewBox="0 0 24 24"><path d="M2 7h20" stroke-dasharray="2.5 2.5"/><path d="M2 14c2 0 3-7 5-7h3c2 0 3 11 6 11s3-5 6-5"/></svg><span>Limiter</span></button>
|
||||||
<button data-view="soundfield"><svg viewBox="0 0 24 24"><rect x="3" y="3" width="18" height="18" rx="2"/><path d="M8 7l-2 2 2 2M16 7l2 2-2 2"/><path d="M7 15.5a7 7 0 0 1 10 0" stroke-dasharray="2 2"/><circle cx="12" cy="18" r="1.2" class="f"/></svg><span>SoundField</span><span class="short">Field</span></button>
|
<button data-view="soundfield"><svg viewBox="0 0 24 24"><rect x="3" y="3" width="18" height="18" rx="2"/><path d="M8 7l-2 2 2 2M16 7l2 2-2 2"/><path d="M7 15.5a7 7 0 0 1 10 0" stroke-dasharray="2 2"/><circle cx="12" cy="18" r="1.2" class="f"/></svg><span>SoundField</span><span class="short">Field</span></button>
|
||||||
<button data-view="lab"><svg viewBox="0 0 24 24"><path d="M9.5 3h5M10.5 3v6.5L5 19a1.3 1.3 0 0 0 1.1 2h11.8a1.3 1.3 0 0 0 1.1-2l-5.5-9.5V3"/><path d="M7.5 15h9"/></svg><span>Sound Lab</span><span class="short">Lab</span></button>
|
<button data-view="lab" hidden><svg viewBox="0 0 24 24"><path d="M9.5 3h5M10.5 3v6.5L5 19a1.3 1.3 0 0 0 1.1 2h11.8a1.3 1.3 0 0 0 1.1-2l-5.5-9.5V3"/><path d="M7.5 15h9"/></svg><span>Sound Lab</span><span class="short">Lab</span></button>
|
||||||
<button data-view="test"><svg viewBox="0 0 24 24"><path d="M4 9v6h4l5 4V5L8 9z"/><path d="M16.5 8.5a5 5 0 0 1 0 7M19 6a8.5 8.5 0 0 1 0 12"/></svg><span data-t="Audio test">Audio test</span><span class="short" data-t="Test">Test</span></button>
|
<button data-view="test"><svg viewBox="0 0 24 24"><path d="M4 9v6h4l5 4V5L8 9z"/><path d="M16.5 8.5a5 5 0 0 1 0 7M19 6a8.5 8.5 0 0 1 0 12"/></svg><span data-t="Audio test">Audio test</span><span class="short" data-t="Test">Test</span></button>
|
||||||
</nav>
|
</nav>
|
||||||
<button id="btn-muteall" class="icon" aria-label="Mute all" title="Mute all"></button>
|
<button id="btn-muteall" class="icon" aria-label="Mute all" title="Mute all"></button>
|
||||||
|
|||||||
+2
-3
@@ -1,9 +1,8 @@
|
|||||||
"use strict";
|
"use strict";
|
||||||
|
|
||||||
// Sound Lab: working together with REW (Room EQ Wizard). Take filters from a measurement or a filter file, compare them
|
// Sound Lab: working together with REW (Room EQ Wizard). Take filters from a measurement or a filter file, compare them
|
||||||
// with the channel before applying, send a channel's EQ back. REW's API only answers on the computer it runs on, so the
|
// with the channel before applying, send a channel's EQ back. Desktop apps only: REW's API only answers on the computer
|
||||||
// server of this app talks to it (see rew_call); a filter file also works with the app on a Raspberry Pi.
|
// it runs on, so the server inside the app talks to it (see rew_call).
|
||||||
// Not offered on phones (style.css).
|
|
||||||
|
|
||||||
const REW_IN = { PK: 0, PEAK: 0, LS: 1, LSC: 1, LSQ: 1, HS: 2, HSC: 2, HSQ: 2, HP1: 3, HP: 4, HPQ: 4, LP1: 5, LP: 6, LPQ: 6, AP: 8 };
|
const REW_IN = { PK: 0, PEAK: 0, LS: 1, LSC: 1, LSQ: 1, HS: 2, HSC: 2, HSQ: 2, HP1: 3, HP: 4, HPQ: 4, LP1: 5, LP: 6, LPQ: 6, AP: 8 };
|
||||||
const REW_OUT = ["PK", "LS", "HS", "HP1", "HP", "LP1", "LP", "AP", "AP"];
|
const REW_OUT = ["PK", "LS", "HS", "HP1", "HP", "LP1", "LP", "AP", "AP"];
|
||||||
|
|||||||
+5
-2
@@ -939,5 +939,8 @@ canvas.labcurve { display: block; width: 100%; height: 240px; background: var(--
|
|||||||
.docbody p { margin: 5px 0 0; color: var(--dim); }
|
.docbody p { margin: 5px 0 0; color: var(--dim); }
|
||||||
.docbody ol { margin: 0; padding-left: 20px; }
|
.docbody ol { margin: 0; padding-left: 20px; }
|
||||||
.docbody li { margin: 3px 0; }
|
.docbody li { margin: 3px 0; }
|
||||||
/* Sound Lab is for the computer next to REW, not for phones */
|
/* ---- locked with "only show dashboard" */
|
||||||
@media (max-width: 759px) { #viewtabs button[data-view=lab], .rewbtn { display: none; } }
|
body.dashonly #viewtabs, body.dashonly #devtabs, body.dashonly #btn-settings, body.dashonly #statusbar { display: none; }
|
||||||
|
body.dashonly #main { margin-left: 0; }
|
||||||
|
body.dashonly #btn-muteall { margin-left: auto; }
|
||||||
|
body.dashonly .dlink { cursor: default; }
|
||||||
Reference in new issue
Block a user