Rename the MIDI intercept to padcontroller, as a module and as a service.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
00de2595b6
commit
1e09cb3825
9 files changed
+30
-30
No files matched your search
@@ -1,4 +1,4 @@
|
||||
"""Intercept the SMC-PAD's MIDI and smooth its knob CCs so RGBW fades feel less stepped.
|
||||
"""Pad controller: intercept the SMC-PAD's MIDI and smooth its knob CCs so RGBW fades feel less stepped.
|
||||
|
||||
Reads the physical pad (Bluetooth or USB), passes pad notes through
|
||||
immediately, and eases Control Change values toward their targets at
|
||||
@@ -9,10 +9,10 @@ bank 2 in the colours from shows/test.qxw. On Bluetooth it says so and carries o
|
||||
While Play is held, bank 2 notes 52–67 go out as 68–83 (see padeditor/layer.py).
|
||||
|
||||
Point QLC+ MIDI input at that virtual port (midi.qxw does this via
|
||||
patch_smc_pad.py once the intercept is running).
|
||||
patch_smc_pad.py once the pad controller is running).
|
||||
|
||||
Usage:
|
||||
.venv/bin/python -m padeditor.intercept
|
||||
.venv/bin/python -m padeditor.padcontroller
|
||||
# optional: --tau 0.05 (seconds; lower = snappier, higher = silkier)
|
||||
|
||||
padeditor/systemd/install.sh runs it as a systemd user service.
|
||||
@@ -1,14 +1,14 @@
|
||||
#!/usr/bin/env bash
|
||||
# Install the SMC-PAD MIDI intercept as a systemd user service and start it.
|
||||
# Install the SMC-PAD pad controller as a systemd user service and start it.
|
||||
#
|
||||
# padeditor/systemd/install.sh # install, enable, start
|
||||
# padeditor/systemd/install.sh --lock-knobs # pass options to the intercept
|
||||
# padeditor/systemd/install.sh --lock-knobs # pass options to the pad controller
|
||||
# padeditor/systemd/install.sh --uninstall
|
||||
#
|
||||
# Logs: journalctl --user -u smc-pad-intercept -f
|
||||
# Logs: journalctl --user -u padcontroller -f
|
||||
set -euo pipefail
|
||||
|
||||
UNIT=smc-pad-intercept.service
|
||||
UNIT=padcontroller.service
|
||||
HERE="$(cd "$(dirname "$0")" && pwd)"
|
||||
ROOT="$(cd "$HERE/../.." && pwd)"
|
||||
DEST="${XDG_CONFIG_HOME:-$HOME/.config}/systemd/user"
|
||||
|
||||
+4
-4
@@ -1,9 +1,9 @@
|
||||
# SMC-PAD MIDI intercept (padeditor.intercept) as a systemd user service.
|
||||
# SMC-PAD pad controller (padeditor.padcontroller) as a systemd user service.
|
||||
# install.sh fills in @ROOT@, @PYTHON@ and @ARGS@ and copies it to
|
||||
# ~/.config/systemd/user/.
|
||||
|
||||
[Unit]
|
||||
Description=SMC-PAD MIDI intercept (virtual port "SMC-PAD Smooth")
|
||||
Description=SMC-PAD pad controller (virtual port "SMC-PAD Smooth")
|
||||
After=sound.target
|
||||
# Keep retrying while the pad is switched off or not paired yet.
|
||||
StartLimitIntervalSec=0
|
||||
@@ -11,9 +11,9 @@ StartLimitIntervalSec=0
|
||||
[Service]
|
||||
Type=simple
|
||||
WorkingDirectory=@ROOT@
|
||||
ExecStart=@PYTHON@ -m padeditor.intercept @ARGS@
|
||||
ExecStart=@PYTHON@ -m padeditor.padcontroller @ARGS@
|
||||
Environment=PYTHONUNBUFFERED=1
|
||||
# The intercept closes its ports on Ctrl+C.
|
||||
# The pad controller closes its ports on Ctrl+C.
|
||||
KillSignal=SIGINT
|
||||
Restart=always
|
||||
RestartSec=3
|
||||
Reference in new issue
Block a user