From ff63873e236ef3c2b7d0a6b53aa60721ceca98c1 Mon Sep 17 00:00:00 2001 From: cbdev Date: Thu, 27 Dec 2018 23:14:54 +0100 Subject: New configuration --- configs/osc-artnet.cfg | 63 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 configs/osc-artnet.cfg (limited to 'configs') diff --git a/configs/osc-artnet.cfg b/configs/osc-artnet.cfg new file mode 100644 index 0000000..3eeba2e --- /dev/null +++ b/configs/osc-artnet.cfg @@ -0,0 +1,63 @@ +; This configuration maps the multifader page of the TouchOSC 'Mix 16' Layout +; to the first 48 ArtNet channels + +[backend artnet] +bind = 0.0.0.0 + +[osc touch] +bind = * 8000 +dest = learn@8001 + +[artnet out] +destination = 255.255.255.255 + +[map] +touch./4/multifader1/1 > out.1 +touch./4/multifader1/2 > out.2 +touch./4/multifader1/3 > out.3 +touch./4/multifader1/4 > out.4 +touch./4/multifader1/5 > out.5 +touch./4/multifader1/6 > out.6 +touch./4/multifader1/7 > out.7 +touch./4/multifader1/8 > out.8 +touch./4/multifader1/9 > out.9 +touch./4/multifader1/10 > out.10 +touch./4/multifader1/11 > out.11 +touch./4/multifader1/12 > out.12 +touch./4/multifader1/13 > out.13 +touch./4/multifader1/14 > out.14 +touch./4/multifader1/15 > out.15 +touch./4/multifader1/16 > out.16 +touch./4/multifader1/17 > out.17 +touch./4/multifader1/18 > out.18 +touch./4/multifader1/19 > out.19 +touch./4/multifader1/20 > out.20 +touch./4/multifader1/21 > out.21 +touch./4/multifader1/22 > out.22 +touch./4/multifader1/23 > out.23 +touch./4/multifader1/24 > out.24 + +touch./4/multifader2/1 > out.25 +touch./4/multifader2/2 > out.26 +touch./4/multifader2/3 > out.27 +touch./4/multifader2/4 > out.28 +touch./4/multifader2/5 > out.29 +touch./4/multifader2/6 > out.30 +touch./4/multifader2/7 > out.31 +touch./4/multifader2/8 > out.32 +touch./4/multifader2/9 > out.33 +touch./4/multifader2/10 > out.34 +touch./4/multifader2/11 > out.35 +touch./4/multifader2/12 > out.36 +touch./4/multifader2/13 > out.37 +touch./4/multifader2/14 > out.38 +touch./4/multifader2/15 > out.39 +touch./4/multifader2/16 > out.40 +touch./4/multifader2/17 > out.41 +touch./4/multifader2/18 > out.42 +touch./4/multifader2/19 > out.43 +touch./4/multifader2/20 > out.44 +touch./4/multifader2/21 > out.45 +touch./4/multifader2/22 > out.46 +touch./4/multifader2/23 > out.47 +touch./4/multifader2/24 > out.48 -- cgit v1.2.3 From a2b0728027dd8961ef84220c8c8eaf8a81154c71 Mon Sep 17 00:00:00 2001 From: cbdev Date: Sat, 30 Mar 2019 14:34:20 +0100 Subject: Fix MIDI mapping syntax --- configs/launchctl-sacn.cfg | 48 ++++---- configs/midi-osc.cfg | 32 ++--- configs/osc-kbd.cfg | 24 ++-- configs/unifest-17.cfg | 288 ++++++++++++++++++++++----------------------- 4 files changed, 196 insertions(+), 196 deletions(-) (limited to 'configs') diff --git a/configs/launchctl-sacn.cfg b/configs/launchctl-sacn.cfg index 164b477..c2dec84 100644 --- a/configs/launchctl-sacn.cfg +++ b/configs/launchctl-sacn.cfg @@ -18,28 +18,28 @@ priority = 100 [map] -lc.cc0.0 > out.1 -lc.cc0.1 > out.2 -lc.cc0.2 > out.3 -lc.cc0.3 > out.4 -lc.cc0.4 > out.5 -lc.cc0.5 > out.6 -lc.cc0.6 > out.7 -lc.cc0.7 > out.8 -lc.cc0.8 > out.9 -lc.cc0.9 > out.10 -lc.cc0.10 > out.11 -lc.cc0.11 > out.12 -lc.cc0.12 > out.13 -lc.cc0.13 > out.14 -lc.cc0.14 > out.15 -lc.cc0.15 > out.16 +lc.ch0.cc0 > out.1 +lc.ch0.cc1 > out.2 +lc.ch0.cc2 > out.3 +lc.ch0.cc3 > out.4 +lc.ch0.cc4 > out.5 +lc.ch0.cc5 > out.6 +lc.ch0.cc6 > out.7 +lc.ch0.cc7 > out.8 +lc.ch0.cc8 > out.9 +lc.ch0.cc9 > out.10 +lc.ch0.cc10 > out.11 +lc.ch0.cc11 > out.12 +lc.ch0.cc12 > out.13 +lc.ch0.cc13 > out.14 +lc.ch0.cc14 > out.15 +lc.ch0.cc15 > out.16 -lc.note0.0 > out.1 -lc.note0.1 > out.2 -lc.note0.2 > out.3 -lc.note0.3 > out.4 -lc.note0.4 > out.5 -lc.note0.5 > out.6 -lc.note0.6 > out.7 -lc.note0.7 > out.8 +lc.ch0.note0 > out.1 +lc.ch0.note1 > out.2 +lc.ch0.note2 > out.3 +lc.ch0.note3 > out.4 +lc.ch0.note4 > out.5 +lc.ch0.note5 > out.6 +lc.ch0.note6 > out.7 +lc.ch0.note7 > out.8 diff --git a/configs/midi-osc.cfg b/configs/midi-osc.cfg index 215daa9..755077c 100644 --- a/configs/midi-osc.cfg +++ b/configs/midi-osc.cfg @@ -33,20 +33,20 @@ write = BCF [map] -bcf.cc0.81 <> touch./fader1 -bcf.cc0.82 <> touch./fader2 -bcf.cc0.83 <> touch./fader3 -bcf.cc0.84 <> touch./fader4 -bcf.cc0.85 <> touch./fader5 -bcf.cc0.86 <> touch./fader6 -bcf.cc0.87 <> touch./fader7 -bcf.cc0.88 <> touch./fader8 +bcf.ch0.cc81 <> touch./fader1 +bcf.ch0.cc82 <> touch./fader2 +bcf.ch0.cc83 <> touch./fader3 +bcf.ch0.cc84 <> touch./fader4 +bcf.ch0.cc85 <> touch./fader5 +bcf.ch0.cc86 <> touch./fader6 +bcf.ch0.cc87 <> touch./fader7 +bcf.ch0.cc88 <> touch./fader8 -bcf.cc0.81 <> touch./multifader1/1 -bcf.cc0.82 <> touch./multifader1/2 -bcf.cc0.83 <> touch./multifader1/3 -bcf.cc0.84 <> touch./multifader1/4 -bcf.cc0.85 <> touch./multifader1/5 -bcf.cc0.86 <> touch./multifader1/6 -bcf.cc0.87 <> touch./multifader1/7 -bcf.cc0.88 <> touch./multifader1/8 +bcf.ch0.cc81 <> touch./multifader1/1 +bcf.ch0.cc82 <> touch./multifader1/2 +bcf.ch0.cc83 <> touch./multifader1/3 +bcf.ch0.cc84 <> touch./multifader1/4 +bcf.ch0.cc85 <> touch./multifader1/5 +bcf.ch0.cc86 <> touch./multifader1/6 +bcf.ch0.cc87 <> touch./multifader1/7 +bcf.ch0.cc88 <> touch./multifader1/8 diff --git a/configs/osc-kbd.cfg b/configs/osc-kbd.cfg index 0abd131..eb80378 100644 --- a/configs/osc-kbd.cfg +++ b/configs/osc-kbd.cfg @@ -11,15 +11,15 @@ bind = * 8000 dest = learn@8001 [map] -pad./1/push1 > out.note0.60 -pad./1/push2 > out.note0.61 -pad./1/push3 > out.note0.62 -pad./1/push4 > out.note0.63 -pad./1/push5 > out.note0.64 -pad./1/push6 > out.note0.65 -pad./1/push7 > out.note0.66 -pad./1/push8 > out.note0.67 -pad./1/push9 > out.note0.68 -pad./1/push10 > out.note0.69 -pad./1/push11 > out.note0.70 -pad./1/push12 > out.note0.71 +pad./1/push1 > out.ch0.note60 +pad./1/push2 > out.ch0.note61 +pad./1/push3 > out.ch0.note62 +pad./1/push4 > out.ch0.note63 +pad./1/push5 > out.ch0.note64 +pad./1/push6 > out.ch0.note65 +pad./1/push7 > out.ch0.note66 +pad./1/push8 > out.ch0.note67 +pad./1/push9 > out.ch0.note68 +pad./1/push10 > out.ch0.note69 +pad./1/push11 > out.ch0.note70 +pad./1/push12 > out.ch0.note71 diff --git a/configs/unifest-17.cfg b/configs/unifest-17.cfg index 1fab484..47e9ec2 100644 --- a/configs/unifest-17.cfg +++ b/configs/unifest-17.cfg @@ -40,156 +40,156 @@ read = 36:1 [map] ; ArtNet -claudius.1 < lc1.cc0.1 -claudius.2 < lc1.cc0.2 -claudius.3 < lc1.cc0.3 -claudius.4 < lc1.cc0.4 -claudius.5 < lc1.cc0.5 -claudius.6 < lc1.cc0.6 -claudius.7 < lc1.cc0.7 -claudius.8 < lc1.cc0.8 -claudius.9 < lc1.cc0.9 -claudius.10 < lc1.cc0.10 -claudius.11 < lc1.cc0.11 -claudius.12 < lc1.cc0.12 -claudius.13 < lc1.cc0.13 -claudius.14 < lc1.cc0.14 -claudius.15 < lc1.cc0.15 -claudius.16 < lc1.cc0.16 +claudius.1 < lc1.ch0.cc1 +claudius.2 < lc1.ch0.cc2 +claudius.3 < lc1.ch0.cc3 +claudius.4 < lc1.ch0.cc4 +claudius.5 < lc1.ch0.cc5 +claudius.6 < lc1.ch0.cc6 +claudius.7 < lc1.ch0.cc7 +claudius.8 < lc1.ch0.cc8 +claudius.9 < lc1.ch0.cc9 +claudius.10 < lc1.ch0.cc10 +claudius.11 < lc1.ch0.cc11 +claudius.12 < lc1.ch0.cc12 +claudius.13 < lc1.ch0.cc13 +claudius.14 < lc1.ch0.cc14 +claudius.15 < lc1.ch0.cc15 +claudius.16 < lc1.ch0.cc16 ; BCF Fader -out.note0.0 < bcf1.cc0.81 -out.note0.1 < bcf1.cc0.82 -out.note0.2 < bcf1.cc0.83 -out.note0.3 < bcf1.cc0.84 -out.note0.4 < bcf1.cc0.85 -out.note0.5 < bcf1.cc0.86 -out.note0.6 < bcf1.cc0.87 -out.note0.7 < bcf1.cc0.88 -out.note0.8 < bcf2.cc0.81 -out.note0.9 < bcf2.cc0.82 -out.note0.10 < bcf2.cc0.83 -out.note0.11 < bcf2.cc0.84 -out.note0.12 < bcf2.cc0.85 -out.note0.13 < bcf2.cc0.86 -out.note0.14 < bcf2.cc0.87 -out.note0.15 < bcf2.cc0.88 +out.ch0.ch0.note< bcf1.ch0.cc81 +out.ch0.note1 < bcf1.ch0.cc82 +out.ch0.note2 < bcf1.ch0.cc83 +out.ch0.note3 < bcf1.ch0.cc84 +out.ch0.note4 < bcf1.ch0.cc85 +out.ch0.note5 < bcf1.ch0.cc86 +out.ch0.note6 < bcf1.ch0.cc87 +out.ch0.note7 < bcf1.ch0.cc88 +out.ch0.note8 < bcf2.ch0.cc81 +out.ch0.note9 < bcf2.ch0.cc82 +out.ch0.note10 < bcf2.ch0.cc83 +out.ch0.note11 < bcf2.ch0.cc84 +out.ch0.note12 < bcf2.ch0.cc85 +out.ch0.note13 < bcf2.ch0.cc86 +out.ch0.note14 < bcf2.ch0.cc87 +out.ch0.note15 < bcf2.ch0.cc88 ; LC Rotary -out.note0.16 < lc1.cc0.1 -out.note0.17 < lc1.cc0.2 -out.note0.18 < lc1.cc0.3 -out.note0.19 < lc1.cc0.4 -out.note0.20 < lc1.cc0.5 -out.note0.21 < lc1.cc0.6 -out.note0.22 < lc1.cc0.7 -out.note0.23 < lc1.cc0.8 -out.note0.24 < lc1.cc0.9 -out.note0.25 < lc1.cc0.10 -out.note0.26 < lc1.cc0.11 -out.note0.27 < lc1.cc0.12 -out.note0.28 < lc1.cc0.13 -out.note0.29 < lc1.cc0.14 -out.note0.30 < lc1.cc0.15 -out.note0.31 < lc1.cc0.16 -out.note0.32 < lc2.cc0.1 -out.note0.33 < lc2.cc0.2 -out.note0.34 < lc2.cc0.3 -out.note0.35 < lc2.cc0.4 -out.note0.36 < lc2.cc0.5 -out.note0.37 < lc2.cc0.6 -out.note0.38 < lc2.cc0.7 -out.note0.39 < lc2.cc0.8 -out.note0.40 < lc2.cc0.9 -out.note0.41 < lc2.cc0.10 -out.note0.42 < lc2.cc0.11 -out.note0.43 < lc2.cc0.12 -out.note0.44 < lc2.cc0.13 -out.note0.45 < lc2.cc0.14 -out.note0.46 < lc2.cc0.15 -out.note0.47 < lc2.cc0.16 +out.ch0.note16 < lc1.ch0.cc1 +out.ch0.note17 < lc1.ch0.cc2 +out.ch0.note18 < lc1.ch0.cc3 +out.ch0.note19 < lc1.ch0.cc4 +out.ch0.note20 < lc1.ch0.cc5 +out.ch0.note21 < lc1.ch0.cc6 +out.ch0.note22 < lc1.ch0.cc7 +out.ch0.note23 < lc1.ch0.cc8 +out.ch0.note24 < lc1.ch0.cc9 +out.ch0.note25 < lc1.ch0.cc10 +out.ch0.note26 < lc1.ch0.cc11 +out.ch0.note27 < lc1.ch0.cc12 +out.ch0.note28 < lc1.ch0.cc13 +out.ch0.note29 < lc1.ch0.cc14 +out.ch0.note30 < lc1.ch0.cc15 +out.ch0.note31 < lc1.ch0.cc16 +out.ch0.note32 < lc2.ch0.cc1 +out.ch0.note33 < lc2.ch0.cc2 +out.ch0.note34 < lc2.ch0.cc3 +out.ch0.note35 < lc2.ch0.cc4 +out.ch0.note36 < lc2.ch0.cc5 +out.ch0.note37 < lc2.ch0.cc6 +out.ch0.note38 < lc2.ch0.cc7 +out.ch0.note39 < lc2.ch0.cc8 +out.ch0.note40 < lc2.ch0.cc9 +out.ch0.note41 < lc2.ch0.cc10 +out.ch0.note42 < lc2.ch0.cc11 +out.ch0.note43 < lc2.ch0.cc12 +out.ch0.note44 < lc2.ch0.cc13 +out.ch0.note45 < lc2.ch0.cc14 +out.ch0.note46 < lc2.ch0.cc15 +out.ch0.note47 < lc2.ch0.cc16 ; LC Button -out.note0.48 < lc1.note0.0 -out.note0.49 < lc1.note0.1 -out.note0.50 < lc1.note0.2 -out.note0.51 < lc1.note0.3 -out.note0.52 < lc1.note0.4 -out.note0.53 < lc1.note0.5 -out.note0.54 < lc1.note0.6 -out.note0.55 < lc1.note0.7 +out.ch0.note48 < lc1.ch0.note0 +out.ch0.note49 < lc1.ch0.note1 +out.ch0.note50 < lc1.ch0.note2 +out.ch0.note51 < lc1.ch0.note3 +out.ch0.note52 < lc1.ch0.note4 +out.ch0.note53 < lc1.ch0.note5 +out.ch0.note54 < lc1.ch0.note6 +out.ch0.note55 < lc1.ch0.note7 -out.note0.56 < lc2.note0.0 -out.note0.57 < lc2.note0.1 -out.note0.58 < lc2.note0.2 -out.note0.59 < lc2.note0.3 -out.note0.60 < lc2.note0.4 -out.note0.61 < lc2.note0.5 -out.note0.62 < lc2.note0.6 -out.note0.63 < lc2.note0.7 +out.ch0.note56 < lc2.ch0.note0 +out.ch0.note57 < lc2.ch0.note1 +out.ch0.note58 < lc2.ch0.note2 +out.ch0.note59 < lc2.ch0.note3 +out.ch0.note60 < lc2.ch0.note4 +out.ch0.note61 < lc2.ch0.note5 +out.ch0.note62 < lc2.ch0.note6 +out.ch0.note63 < lc2.ch0.note7 ; Launchpad -out.note0.64 < pad.note0.0 -out.note0.65 < pad.note0.1 -out.note0.66 < pad.note0.2 -out.note0.67 < pad.note0.3 -out.note0.68 < pad.note0.4 -out.note0.69 < pad.note0.5 -out.note0.70 < pad.note0.6 -out.note0.71 < pad.note0.7 -out.note0.72 < pad.note0.16 -out.note0.73 < pad.note0.17 -out.note0.74 < pad.note0.18 -out.note0.75 < pad.note0.19 -out.note0.76 < pad.note0.20 -out.note0.77 < pad.note0.21 -out.note0.78 < pad.note0.22 -out.note0.79 < pad.note0.23 -out.note0.80 < pad.note0.32 -out.note0.81 < pad.note0.33 -out.note0.82 < pad.note0.34 -out.note0.83 < pad.note0.35 -out.note0.84 < pad.note0.36 -out.note0.85 < pad.note0.37 -out.note0.86 < pad.note0.38 -out.note0.87 < pad.note0.39 -out.note0.88 < pad.note0.48 -out.note0.89 < pad.note0.49 -out.note0.90 < pad.note0.50 -out.note0.91 < pad.note0.51 -out.note0.92 < pad.note0.52 -out.note0.93 < pad.note0.53 -out.note0.94 < pad.note0.54 -out.note0.95 < pad.note0.55 -out.note0.96 < pad.note0.64 -out.note0.97 < pad.note0.65 -out.note0.98 < pad.note0.66 -out.note0.99 < pad.note0.67 -out.note0.100 < pad.note0.68 -out.note0.101 < pad.note0.69 -out.note0.102 < pad.note0.70 -out.note0.103 < pad.note0.71 -out.note0.104 < pad.note0.80 -out.note0.105 < pad.note0.81 -out.note0.106 < pad.note0.82 -out.note0.107 < pad.note0.83 -out.note0.108 < pad.note0.84 -out.note0.109 < pad.note0.85 -out.note0.110 < pad.note0.86 -out.note0.111 < pad.note0.87 -out.note0.112 < pad.note0.96 -out.note0.113 < pad.note0.97 -out.note0.114 < pad.note0.98 -out.note0.115 < pad.note0.99 -out.note0.116 < pad.note0.100 -out.note0.117 < pad.note0.101 -out.note0.118 < pad.note0.102 -out.note0.119 < pad.note0.103 -out.note0.120 < pad.note0.112 -out.note0.121 < pad.note0.113 -out.note0.122 < pad.note0.114 -out.note0.123 < pad.note0.115 -out.note0.124 < pad.note0.116 -out.note0.125 < pad.note0.117 -out.note0.126 < pad.note0.118 -out.note0.127 < pad.note0.119 +out.ch0.note64 < pad.ch0.note0 +out.ch0.note65 < pad.ch0.note1 +out.ch0.note66 < pad.ch0.note2 +out.ch0.note67 < pad.ch0.note3 +out.ch0.note68 < pad.ch0.note4 +out.ch0.note69 < pad.ch0.note5 +out.ch0.note70 < pad.ch0.note6 +out.ch0.note71 < pad.ch0.note7 +out.ch0.note72 < pad.ch0.note16 +out.ch0.note73 < pad.ch0.note17 +out.ch0.note74 < pad.ch0.note18 +out.ch0.note75 < pad.ch0.note19 +out.ch0.note76 < pad.ch0.note20 +out.ch0.note77 < pad.ch0.note21 +out.ch0.note78 < pad.ch0.note22 +out.ch0.note79 < pad.ch0.note23 +out.ch0.note80 < pad.ch0.note32 +out.ch0.note81 < pad.ch0.note33 +out.ch0.note82 < pad.ch0.note34 +out.ch0.note83 < pad.ch0.note35 +out.ch0.note84 < pad.ch0.note36 +out.ch0.note85 < pad.ch0.note37 +out.ch0.note86 < pad.ch0.note38 +out.ch0.note87 < pad.ch0.note39 +out.ch0.note88 < pad.ch0.note48 +out.ch0.note89 < pad.ch0.note49 +out.ch0.note90 < pad.ch0.note50 +out.ch0.note91 < pad.ch0.note51 +out.ch0.note92 < pad.ch0.note52 +out.ch0.note93 < pad.ch0.note53 +out.ch0.note94 < pad.ch0.note54 +out.ch0.note95 < pad.ch0.note55 +out.ch0.note96 < pad.ch0.note64 +out.ch0.note97 < pad.ch0.note65 +out.ch0.note98 < pad.ch0.note66 +out.ch0.note99 < pad.ch0.note67 +out.ch0.note100 < pad.ch0.note68 +out.ch0.note101 < pad.ch0.note69 +out.ch0.note102 < pad.ch0.note70 +out.ch0.note103 < pad.ch0.note71 +out.ch0.note104 < pad.ch0.note80 +out.ch0.note105 < pad.ch0.note81 +out.ch0.note106 < pad.ch0.note82 +out.ch0.note107 < pad.ch0.note83 +out.ch0.note108 < pad.ch0.note84 +out.ch0.note109 < pad.ch0.note85 +out.ch0.note110 < pad.ch0.note86 +out.ch0.note111 < pad.ch0.note87 +out.ch0.note112 < pad.ch0.note96 +out.ch0.note113 < pad.ch0.note97 +out.ch0.note114 < pad.ch0.note98 +out.ch0.note115 < pad.ch0.note99 +out.ch0.note116 < pad.ch0.note100 +out.ch0.note117 < pad.ch0.note101 +out.ch0.note118 < pad.ch0.note102 +out.ch0.note119 < pad.ch0.note103 +out.ch0.note120 < pad.ch0.note112 +out.ch0.note121 < pad.ch0.note113 +out.ch0.note122 < pad.ch0.note114 +out.ch0.note123 < pad.ch0.note115 +out.ch0.note124 < pad.ch0.note116 +out.ch0.note125 < pad.ch0.note117 +out.ch0.note126 < pad.ch0.note118 +out.ch0.note127 < pad.ch0.note119 -- cgit v1.2.3 From b618c4a6b74a52f830ca53029e1cc680d56a2501 Mon Sep 17 00:00:00 2001 From: cbdev Date: Sat, 6 Jul 2019 17:25:12 +0200 Subject: Implement Lua backend --- configs/demo.lua | 21 +++++++++++++++++++++ configs/lua.cfg | 35 +++++++++++++++++++++++++++++++++++ 2 files changed, 56 insertions(+) create mode 100644 configs/demo.lua create mode 100644 configs/lua.cfg (limited to 'configs') diff --git a/configs/demo.lua b/configs/demo.lua new file mode 100644 index 0000000..e816ac4 --- /dev/null +++ b/configs/demo.lua @@ -0,0 +1,21 @@ +-- This example MIDIMonstaer Lua script spreads one input channel onto multiple output +-- channels using a polynomial function evaluated at multiple points. This effect can +-- be visualized e.g. with martrix (https://github.com/cbdevnet/martrix). + +-- This is just a demonstration of global variables +foo = 0 + +-- The polynomial to evaluate +function polynomial(offset, x) + return math.exp(-20 * (x - offset) ^ 2) +end + +-- Handler function for the input channel +function input(value) + foo = foo + 1 + print("input at ", value, foo) + + for chan=0,10 do + output("out" .. chan, polynomial(value, (1 / 10) * chan)) + end +end diff --git a/configs/lua.cfg b/configs/lua.cfg new file mode 100644 index 0000000..9182122 --- /dev/null +++ b/configs/lua.cfg @@ -0,0 +1,35 @@ +; This configuration uses a Lua script to distribute one input channel (from either a mouse +; button or an axis control) onto multiple output channels (on ArtNet). + +[backend artnet] +bind = 0.0.0.0 + +[evdev mouse] +device = /dev/input/by-path/platform-i8042-serio-2-event-mouse + +[evdev xbox] +input = Xbox Wireless +axis.ABS_X = 34300 0 65535 255 4095 + +[lua lua] +script = configs/demo.lua + +[artnet art] +universe = 0 +destination = 255.255.255.255 + +[map] +mouse.EV_KEY.BTN_LEFT > lua.input +xbox.EV_ABS.ABS_X > lua.input + +art.1 < lua.out0 +art.2 < lua.out1 +art.3 < lua.out2 +art.4 < lua.out3 +art.5 < lua.out4 +art.6 < lua.out5 +art.7 < lua.out6 +art.8 < lua.out7 +art.9 < lua.out8 +art.10 < lua.out9 +art.11 < lua.out10 -- cgit v1.2.3 From ee4a46105acecb6a7adc1e7189e8b0a66404b421 Mon Sep 17 00:00:00 2001 From: cbdev Date: Sat, 13 Jul 2019 17:51:11 +0200 Subject: Improved Lua backend with intervals --- configs/demo.lua | 45 +++++++++++++++++++++++++++++++++------------ configs/lua.cfg | 10 +++++++--- 2 files changed, 40 insertions(+), 15 deletions(-) (limited to 'configs') diff --git a/configs/demo.lua b/configs/demo.lua index e816ac4..24a8396 100644 --- a/configs/demo.lua +++ b/configs/demo.lua @@ -1,21 +1,42 @@ --- This example MIDIMonstaer Lua script spreads one input channel onto multiple output +-- This example MIDIMonster Lua script spreads one input channel onto multiple output -- channels using a polynomial function evaluated at multiple points. This effect can -- be visualized e.g. with martrix (https://github.com/cbdevnet/martrix). --- This is just a demonstration of global variables -foo = 0 - -- The polynomial to evaluate -function polynomial(offset, x) - return math.exp(-20 * (x - offset) ^ 2) +function polynomial(x) + return math.exp(-40 * input_value("width") * (x - input_value("offset")) ^ 2) end --- Handler function for the input channel -function input(value) - foo = foo + 1 - print("input at ", value, foo) - +-- Evaluate and set output channels +function evaluate() for chan=0,10 do - output("out" .. chan, polynomial(value, (1 / 10) * chan)) + output("out" .. chan, polynomial((1 / 10) * chan)) + end +end + +-- Handler functions for the input channels +function offset(value) + evaluate() +end + +function width(value) + evaluate() +end + +-- This is an example showing a simple chase running on its own without the need +-- (but the possibility) for external input + +-- Global value for the current step +current_step = 0 + +function step() + if(current_step > 0) then + output("dim", 0.0) + else + output("dim", 1.0) end + + current_step = (current_step + 1) % 2 end + +interval(step, 1000) diff --git a/configs/lua.cfg b/configs/lua.cfg index 9182122..42fd27d 100644 --- a/configs/lua.cfg +++ b/configs/lua.cfg @@ -8,8 +8,9 @@ bind = 0.0.0.0 device = /dev/input/by-path/platform-i8042-serio-2-event-mouse [evdev xbox] -input = Xbox Wireless +device = /dev/input/event17 axis.ABS_X = 34300 0 65535 255 4095 +axis.ABS_Y = 34300 0 65535 255 4095 [lua lua] script = configs/demo.lua @@ -19,8 +20,9 @@ universe = 0 destination = 255.255.255.255 [map] -mouse.EV_KEY.BTN_LEFT > lua.input -xbox.EV_ABS.ABS_X > lua.input +mouse.EV_KEY.BTN_LEFT > lua.click +xbox.EV_ABS.ABS_X > lua.offset +xbox.EV_ABS.ABS_Y > lua.width art.1 < lua.out0 art.2 < lua.out1 @@ -33,3 +35,5 @@ art.8 < lua.out7 art.9 < lua.out8 art.10 < lua.out9 art.11 < lua.out10 + +art.12 < lua.dim -- cgit v1.2.3 From e776e02531aca45f424f7139e5d7304ba3096b45 Mon Sep 17 00:00:00 2001 From: cbdev Date: Sun, 14 Jul 2019 16:49:31 +0200 Subject: Work around missing timerfd on OSX/Windows --- configs/lua.cfg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'configs') diff --git a/configs/lua.cfg b/configs/lua.cfg index 42fd27d..b892e91 100644 --- a/configs/lua.cfg +++ b/configs/lua.cfg @@ -8,7 +8,7 @@ bind = 0.0.0.0 device = /dev/input/by-path/platform-i8042-serio-2-event-mouse [evdev xbox] -device = /dev/input/event17 +;device = /dev/input/event17 axis.ABS_X = 34300 0 65535 255 4095 axis.ABS_Y = 34300 0 65535 255 4095 -- cgit v1.2.3 From 5bd8e81e2821f1378c6773fbc1f06df063dbbd22 Mon Sep 17 00:00:00 2001 From: cbdev Date: Sat, 20 Jul 2019 18:10:56 +0200 Subject: Implement multi-channel mapping syntax --- configs/launchctl-sacn.cfg | 25 +++++-------------------- 1 file changed, 5 insertions(+), 20 deletions(-) (limited to 'configs') diff --git a/configs/launchctl-sacn.cfg b/configs/launchctl-sacn.cfg index c2dec84..02cd152 100644 --- a/configs/launchctl-sacn.cfg +++ b/configs/launchctl-sacn.cfg @@ -6,34 +6,19 @@ [backend midi] name = MIDIMonster -[backend sacn] +[backend artnet] bind = 0.0.0.0 [midi lc] read = Launch Control -[sacn out] -universe = 1 -priority = 100 +[artnet out] +universe = 0 +destination = 255.255.255.255 [map] -lc.ch0.cc0 > out.1 -lc.ch0.cc1 > out.2 -lc.ch0.cc2 > out.3 -lc.ch0.cc3 > out.4 -lc.ch0.cc4 > out.5 -lc.ch0.cc5 > out.6 -lc.ch0.cc6 > out.7 -lc.ch0.cc7 > out.8 -lc.ch0.cc8 > out.9 -lc.ch0.cc9 > out.10 -lc.ch0.cc10 > out.11 -lc.ch0.cc11 > out.12 -lc.ch0.cc12 > out.13 -lc.ch0.cc13 > out.14 -lc.ch0.cc14 > out.15 -lc.ch0.cc15 > out.16 +lc.ch0.cc{0..15} > out.{1..16} lc.ch0.note0 > out.1 lc.ch0.note1 > out.2 -- cgit v1.2.3 From 1f0de6d91c14217ae3893da0e4b6089b799ed026 Mon Sep 17 00:00:00 2001 From: cbdev Date: Wed, 24 Jul 2019 21:30:40 +0200 Subject: Update example configurations to new syntax, add comments --- configs/evdev.cfg | 32 ++++++++ configs/evdev.conf | 31 -------- configs/launchctl-sacn.cfg | 10 +-- configs/lua.cfg | 13 +-- configs/midi-osc.cfg | 25 ++---- configs/osc-artnet.cfg | 51 +----------- configs/osc-kbd.cfg | 16 +--- configs/unifest-17.cfg | 191 +++++++++------------------------------------ 8 files changed, 81 insertions(+), 288 deletions(-) create mode 100644 configs/evdev.cfg delete mode 100644 configs/evdev.conf (limited to 'configs') diff --git a/configs/evdev.cfg b/configs/evdev.cfg new file mode 100644 index 0000000..bb27caf --- /dev/null +++ b/configs/evdev.cfg @@ -0,0 +1,32 @@ +; Map the (admittedly weird) bluetooth profile of an Xbox One +; Gamepad to some ArtNet output channels. Uses both analog joysticks +; and the analog triggers. + +[backend artnet] +bind = 0.0.0.0 6454 +net = 0 + +[evdev xbox] +device = /dev/input/event14 + +[artnet out] +uni = 0 +dest = 255.255.255.255 + +[map] +xbox.EV_ABS.ABS_X > out.1+2 +xbox.EV_ABS.ABS_Y > out.3+4 + +xbox.EV_ABS.ABS_Z > out.16+17 +xbox.EV_ABS.ABS_RZ > out.18+19 + +xbox.EV_ABS.ABS_BRAKE > out.8 +xbox.EV_ABS.ABS_GAS > out.23 + +xbox.EV_KEY.BTN_NORTH > out.5 +xbox.EV_KEY.BTN_EAST > out.6 +xbox.EV_KEY.BTN_SOUTH > out.7 + +xbox.EV_KEY.BTN_NORTH > out.20 +xbox.EV_KEY.BTN_EAST > out.21 +xbox.EV_KEY.BTN_SOUTH > out.22 diff --git a/configs/evdev.conf b/configs/evdev.conf deleted file mode 100644 index 386e154..0000000 --- a/configs/evdev.conf +++ /dev/null @@ -1,31 +0,0 @@ -[backend artnet] -bind = * 6454 -net = 0 - -[evdev xbox] -device = /dev/input/event14 -axis.ABS_X = 34300 0 65535 255 4095 -axis.ABS_RZ = 34300 0 65535 255 4095 -axis.ABS_Y = 34300 0 65535 255 4095 - -[artnet out] -uni = 0 -dest = 129.13.215.127 - -[map] -xbox.EV_ABS.ABS_X > out.1+2 -xbox.EV_ABS.ABS_Y > out.3+4 - -xbox.EV_ABS.ABS_Z > out.16+17 -xbox.EV_ABS.ABS_RZ > out.18+19 - -xbox.EV_ABS.ABS_BRAKE > out.8 -xbox.EV_ABS.ABS_GAS > out.23 - -xbox.EV_KEY.BTN_NORTH > out.5 -xbox.EV_KEY.BTN_EAST > out.6 -xbox.EV_KEY.BTN_SOUTH > out.7 - -xbox.EV_KEY.BTN_NORTH > out.20 -xbox.EV_KEY.BTN_EAST > out.21 -xbox.EV_KEY.BTN_SOUTH > out.22 diff --git a/configs/launchctl-sacn.cfg b/configs/launchctl-sacn.cfg index 02cd152..781ca40 100644 --- a/configs/launchctl-sacn.cfg +++ b/configs/launchctl-sacn.cfg @@ -19,12 +19,4 @@ destination = 255.255.255.255 [map] lc.ch0.cc{0..15} > out.{1..16} - -lc.ch0.note0 > out.1 -lc.ch0.note1 > out.2 -lc.ch0.note2 > out.3 -lc.ch0.note3 > out.4 -lc.ch0.note4 > out.5 -lc.ch0.note5 > out.6 -lc.ch0.note6 > out.7 -lc.ch0.note7 > out.8 +lc.ch0.note{0..7} > out.{1..8} diff --git a/configs/lua.cfg b/configs/lua.cfg index b892e91..af17496 100644 --- a/configs/lua.cfg +++ b/configs/lua.cfg @@ -24,16 +24,5 @@ mouse.EV_KEY.BTN_LEFT > lua.click xbox.EV_ABS.ABS_X > lua.offset xbox.EV_ABS.ABS_Y > lua.width -art.1 < lua.out0 -art.2 < lua.out1 -art.3 < lua.out2 -art.4 < lua.out3 -art.5 < lua.out4 -art.6 < lua.out5 -art.7 < lua.out6 -art.8 < lua.out7 -art.9 < lua.out8 -art.10 < lua.out9 -art.11 < lua.out10 - +art.{1..11} < lua.out{0..10} art.12 < lua.dim diff --git a/configs/midi-osc.cfg b/configs/midi-osc.cfg index 755077c..1b3ccd6 100644 --- a/configs/midi-osc.cfg +++ b/configs/midi-osc.cfg @@ -1,14 +1,18 @@ +; Translate a MIDI fader wing into an OSC fader view and vice versa + [backend midi] name = MIDIMonster [backend artnet] -bind = * 6454 +bind = 0.0.0.0 6454 net = 0 [osc touch] bind = * 8000 dest = learn@8000 root = /4 + +; Pre-declare the fader values so the range mapping is correct /fader1 = f 0.0 1.0 /fader2 = f 0.0 1.0 /fader3 = f 0.0 1.0 @@ -33,20 +37,5 @@ write = BCF [map] -bcf.ch0.cc81 <> touch./fader1 -bcf.ch0.cc82 <> touch./fader2 -bcf.ch0.cc83 <> touch./fader3 -bcf.ch0.cc84 <> touch./fader4 -bcf.ch0.cc85 <> touch./fader5 -bcf.ch0.cc86 <> touch./fader6 -bcf.ch0.cc87 <> touch./fader7 -bcf.ch0.cc88 <> touch./fader8 - -bcf.ch0.cc81 <> touch./multifader1/1 -bcf.ch0.cc82 <> touch./multifader1/2 -bcf.ch0.cc83 <> touch./multifader1/3 -bcf.ch0.cc84 <> touch./multifader1/4 -bcf.ch0.cc85 <> touch./multifader1/5 -bcf.ch0.cc86 <> touch./multifader1/6 -bcf.ch0.cc87 <> touch./multifader1/7 -bcf.ch0.cc88 <> touch./multifader1/8 +bcf.ch0.cc{81..88} <> touch./fader{1..8} +bcf.ch0.cc{81..88} <> touch./multifader1/{1..8} diff --git a/configs/osc-artnet.cfg b/configs/osc-artnet.cfg index 3eeba2e..ab1d767 100644 --- a/configs/osc-artnet.cfg +++ b/configs/osc-artnet.cfg @@ -12,52 +12,5 @@ dest = learn@8001 destination = 255.255.255.255 [map] -touch./4/multifader1/1 > out.1 -touch./4/multifader1/2 > out.2 -touch./4/multifader1/3 > out.3 -touch./4/multifader1/4 > out.4 -touch./4/multifader1/5 > out.5 -touch./4/multifader1/6 > out.6 -touch./4/multifader1/7 > out.7 -touch./4/multifader1/8 > out.8 -touch./4/multifader1/9 > out.9 -touch./4/multifader1/10 > out.10 -touch./4/multifader1/11 > out.11 -touch./4/multifader1/12 > out.12 -touch./4/multifader1/13 > out.13 -touch./4/multifader1/14 > out.14 -touch./4/multifader1/15 > out.15 -touch./4/multifader1/16 > out.16 -touch./4/multifader1/17 > out.17 -touch./4/multifader1/18 > out.18 -touch./4/multifader1/19 > out.19 -touch./4/multifader1/20 > out.20 -touch./4/multifader1/21 > out.21 -touch./4/multifader1/22 > out.22 -touch./4/multifader1/23 > out.23 -touch./4/multifader1/24 > out.24 - -touch./4/multifader2/1 > out.25 -touch./4/multifader2/2 > out.26 -touch./4/multifader2/3 > out.27 -touch./4/multifader2/4 > out.28 -touch./4/multifader2/5 > out.29 -touch./4/multifader2/6 > out.30 -touch./4/multifader2/7 > out.31 -touch./4/multifader2/8 > out.32 -touch./4/multifader2/9 > out.33 -touch./4/multifader2/10 > out.34 -touch./4/multifader2/11 > out.35 -touch./4/multifader2/12 > out.36 -touch./4/multifader2/13 > out.37 -touch./4/multifader2/14 > out.38 -touch./4/multifader2/15 > out.39 -touch./4/multifader2/16 > out.40 -touch./4/multifader2/17 > out.41 -touch./4/multifader2/18 > out.42 -touch./4/multifader2/19 > out.43 -touch./4/multifader2/20 > out.44 -touch./4/multifader2/21 > out.45 -touch./4/multifader2/22 > out.46 -touch./4/multifader2/23 > out.47 -touch./4/multifader2/24 > out.48 +touch./4/multifader1/{1..24} > out.{1..24} +touch./4/multifader2/{1..24} > out.{25..48} diff --git a/configs/osc-kbd.cfg b/configs/osc-kbd.cfg index eb80378..bd2e2c0 100644 --- a/configs/osc-kbd.cfg +++ b/configs/osc-kbd.cfg @@ -1,4 +1,5 @@ -; Maps a TouchOSC simpl keyboard layout to MIDI notes +; Maps a TouchOSC simple keyboard layout to MIDI notes +; and writes them out to a FLUIDSynth instance [backend midi] name = MIDIMonster @@ -11,15 +12,4 @@ bind = * 8000 dest = learn@8001 [map] -pad./1/push1 > out.ch0.note60 -pad./1/push2 > out.ch0.note61 -pad./1/push3 > out.ch0.note62 -pad./1/push4 > out.ch0.note63 -pad./1/push5 > out.ch0.note64 -pad./1/push6 > out.ch0.note65 -pad./1/push7 > out.ch0.note66 -pad./1/push8 > out.ch0.note67 -pad./1/push9 > out.ch0.note68 -pad./1/push10 > out.ch0.note69 -pad./1/push11 > out.ch0.note70 -pad./1/push12 > out.ch0.note71 +pad./1/push{1..12} > out.ch0.note{60..71} diff --git a/configs/unifest-17.cfg b/configs/unifest-17.cfg index 47e9ec2..2504550 100644 --- a/configs/unifest-17.cfg +++ b/configs/unifest-17.cfg @@ -1,27 +1,36 @@ -; Note that this configuration file was originally written with -; an older syntax and thus only contains right-to-left mappings +; This configuration was used as central control translator for the following tasks +; * Translate 2 Fader Wings and 2 Launch Control from MIDI CC to MIDI notes +; to be used as input to the GrandMA (connected to OUT A on Fader 1) +; Since both fader wings have the same name, we need to refer to them by portid +; -> Instances fader1, fader2, lc2, grandma +; * Remap buttons from a LaunchPad as input to the GrandMA +; -> Instances launchpad, grandma +; * Translate the rotaries of one Launch Control to ArtNet for additional effect control +; -> Instances lc1, xlaser +; +; Note that the MIDI port specifications might not be reusable 1:1 [backend midi] name = MIDIMonster [backend artnet] -bind = * 6454 +bind = 0.0.0.0 6454 net = 0 ; XLaser environment -[artnet claudius] -uni = 0 +[artnet xlaser] +universe = 0 ; MIDI input devices -[midi pad] +[midi launchpad] read = Launchpad write = Launchpad -[midi bcf1] +[midi fader1] read = 20:0 write = 20:0 -[midi bcf2] +[midi fader2] read = 36:0 write = 36:0 @@ -34,162 +43,32 @@ read = 32:0 write = 32:0 ; Output MIDI via OUT A on BCF -[midi out] +[midi grandma] write = 36:1 read = 36:1 [map] -; ArtNet -claudius.1 < lc1.ch0.cc1 -claudius.2 < lc1.ch0.cc2 -claudius.3 < lc1.ch0.cc3 -claudius.4 < lc1.ch0.cc4 -claudius.5 < lc1.ch0.cc5 -claudius.6 < lc1.ch0.cc6 -claudius.7 < lc1.ch0.cc7 -claudius.8 < lc1.ch0.cc8 -claudius.9 < lc1.ch0.cc9 -claudius.10 < lc1.ch0.cc10 -claudius.11 < lc1.ch0.cc11 -claudius.12 < lc1.ch0.cc12 -claudius.13 < lc1.ch0.cc13 -claudius.14 < lc1.ch0.cc14 -claudius.15 < lc1.ch0.cc15 -claudius.16 < lc1.ch0.cc16 +; Effect control +xlaser.{1..16} < lc1.ch0.cc{1..16} -; BCF Fader -out.ch0.ch0.note< bcf1.ch0.cc81 -out.ch0.note1 < bcf1.ch0.cc82 -out.ch0.note2 < bcf1.ch0.cc83 -out.ch0.note3 < bcf1.ch0.cc84 -out.ch0.note4 < bcf1.ch0.cc85 -out.ch0.note5 < bcf1.ch0.cc86 -out.ch0.note6 < bcf1.ch0.cc87 -out.ch0.note7 < bcf1.ch0.cc88 -out.ch0.note8 < bcf2.ch0.cc81 -out.ch0.note9 < bcf2.ch0.cc82 -out.ch0.note10 < bcf2.ch0.cc83 -out.ch0.note11 < bcf2.ch0.cc84 -out.ch0.note12 < bcf2.ch0.cc85 -out.ch0.note13 < bcf2.ch0.cc86 -out.ch0.note14 < bcf2.ch0.cc87 -out.ch0.note15 < bcf2.ch0.cc88 +; BCF Faders to GrandMA +grandma.ch0.note{0..7} < fader1.ch0.cc{81..88} +grandma.ch0.note{8..15} < fader2.ch0.cc{81..88} ; LC Rotary -out.ch0.note16 < lc1.ch0.cc1 -out.ch0.note17 < lc1.ch0.cc2 -out.ch0.note18 < lc1.ch0.cc3 -out.ch0.note19 < lc1.ch0.cc4 -out.ch0.note20 < lc1.ch0.cc5 -out.ch0.note21 < lc1.ch0.cc6 -out.ch0.note22 < lc1.ch0.cc7 -out.ch0.note23 < lc1.ch0.cc8 -out.ch0.note24 < lc1.ch0.cc9 -out.ch0.note25 < lc1.ch0.cc10 -out.ch0.note26 < lc1.ch0.cc11 -out.ch0.note27 < lc1.ch0.cc12 -out.ch0.note28 < lc1.ch0.cc13 -out.ch0.note29 < lc1.ch0.cc14 -out.ch0.note30 < lc1.ch0.cc15 -out.ch0.note31 < lc1.ch0.cc16 -out.ch0.note32 < lc2.ch0.cc1 -out.ch0.note33 < lc2.ch0.cc2 -out.ch0.note34 < lc2.ch0.cc3 -out.ch0.note35 < lc2.ch0.cc4 -out.ch0.note36 < lc2.ch0.cc5 -out.ch0.note37 < lc2.ch0.cc6 -out.ch0.note38 < lc2.ch0.cc7 -out.ch0.note39 < lc2.ch0.cc8 -out.ch0.note40 < lc2.ch0.cc9 -out.ch0.note41 < lc2.ch0.cc10 -out.ch0.note42 < lc2.ch0.cc11 -out.ch0.note43 < lc2.ch0.cc12 -out.ch0.note44 < lc2.ch0.cc13 -out.ch0.note45 < lc2.ch0.cc14 -out.ch0.note46 < lc2.ch0.cc15 -out.ch0.note47 < lc2.ch0.cc16 +grandma.ch0.note{16..31} < lc1.ch0.cc{1..16} +grandma.ch0.note{32..47} < lc2.ch0.cc{1..16} ; LC Button -out.ch0.note48 < lc1.ch0.note0 -out.ch0.note49 < lc1.ch0.note1 -out.ch0.note50 < lc1.ch0.note2 -out.ch0.note51 < lc1.ch0.note3 -out.ch0.note52 < lc1.ch0.note4 -out.ch0.note53 < lc1.ch0.note5 -out.ch0.note54 < lc1.ch0.note6 -out.ch0.note55 < lc1.ch0.note7 - -out.ch0.note56 < lc2.ch0.note0 -out.ch0.note57 < lc2.ch0.note1 -out.ch0.note58 < lc2.ch0.note2 -out.ch0.note59 < lc2.ch0.note3 -out.ch0.note60 < lc2.ch0.note4 -out.ch0.note61 < lc2.ch0.note5 -out.ch0.note62 < lc2.ch0.note6 -out.ch0.note63 < lc2.ch0.note7 +grandma.ch0.note{48..55} < lc1.ch0.note{0..7} +grandma.ch0.note{56..63} < lc2.ch0.note{0..7} ; Launchpad -out.ch0.note64 < pad.ch0.note0 -out.ch0.note65 < pad.ch0.note1 -out.ch0.note66 < pad.ch0.note2 -out.ch0.note67 < pad.ch0.note3 -out.ch0.note68 < pad.ch0.note4 -out.ch0.note69 < pad.ch0.note5 -out.ch0.note70 < pad.ch0.note6 -out.ch0.note71 < pad.ch0.note7 -out.ch0.note72 < pad.ch0.note16 -out.ch0.note73 < pad.ch0.note17 -out.ch0.note74 < pad.ch0.note18 -out.ch0.note75 < pad.ch0.note19 -out.ch0.note76 < pad.ch0.note20 -out.ch0.note77 < pad.ch0.note21 -out.ch0.note78 < pad.ch0.note22 -out.ch0.note79 < pad.ch0.note23 -out.ch0.note80 < pad.ch0.note32 -out.ch0.note81 < pad.ch0.note33 -out.ch0.note82 < pad.ch0.note34 -out.ch0.note83 < pad.ch0.note35 -out.ch0.note84 < pad.ch0.note36 -out.ch0.note85 < pad.ch0.note37 -out.ch0.note86 < pad.ch0.note38 -out.ch0.note87 < pad.ch0.note39 -out.ch0.note88 < pad.ch0.note48 -out.ch0.note89 < pad.ch0.note49 -out.ch0.note90 < pad.ch0.note50 -out.ch0.note91 < pad.ch0.note51 -out.ch0.note92 < pad.ch0.note52 -out.ch0.note93 < pad.ch0.note53 -out.ch0.note94 < pad.ch0.note54 -out.ch0.note95 < pad.ch0.note55 -out.ch0.note96 < pad.ch0.note64 -out.ch0.note97 < pad.ch0.note65 -out.ch0.note98 < pad.ch0.note66 -out.ch0.note99 < pad.ch0.note67 -out.ch0.note100 < pad.ch0.note68 -out.ch0.note101 < pad.ch0.note69 -out.ch0.note102 < pad.ch0.note70 -out.ch0.note103 < pad.ch0.note71 -out.ch0.note104 < pad.ch0.note80 -out.ch0.note105 < pad.ch0.note81 -out.ch0.note106 < pad.ch0.note82 -out.ch0.note107 < pad.ch0.note83 -out.ch0.note108 < pad.ch0.note84 -out.ch0.note109 < pad.ch0.note85 -out.ch0.note110 < pad.ch0.note86 -out.ch0.note111 < pad.ch0.note87 -out.ch0.note112 < pad.ch0.note96 -out.ch0.note113 < pad.ch0.note97 -out.ch0.note114 < pad.ch0.note98 -out.ch0.note115 < pad.ch0.note99 -out.ch0.note116 < pad.ch0.note100 -out.ch0.note117 < pad.ch0.note101 -out.ch0.note118 < pad.ch0.note102 -out.ch0.note119 < pad.ch0.note103 -out.ch0.note120 < pad.ch0.note112 -out.ch0.note121 < pad.ch0.note113 -out.ch0.note122 < pad.ch0.note114 -out.ch0.note123 < pad.ch0.note115 -out.ch0.note124 < pad.ch0.note116 -out.ch0.note125 < pad.ch0.note117 -out.ch0.note126 < pad.ch0.note118 -out.ch0.note127 < pad.ch0.note119 +grandma.ch0.note{64..71} < launchpad.ch0.note{0..7} +grandma.ch0.note{72..79} < launchpad.ch0.note{16..23} +grandma.ch0.note{80..87} < launchpad.ch0.note{32..39} +grandma.ch0.note{88..95} < launchpad.ch0.note{48..55} +grandma.ch0.note{96..103} < launchpad.ch0.note{64..71} +grandma.ch0.note{104..111} < launchpad.ch0.note{80..87} +grandma.ch0.note{112..119} < launchpad.ch0.note{96..103} +grandma.ch0.note{120..127} < launchpad.ch0.note{112..119} -- cgit v1.2.3 From 26ee2eacc7d60aa379c9e4b9b9c6b8bcdcd4bc6b Mon Sep 17 00:00:00 2001 From: cbdev Date: Sat, 27 Jul 2019 19:31:21 +0200 Subject: Refactor OSC backend, implement pattern matching --- configs/flying-faders.cfg | 24 ++++++++++++++++++++++++ configs/flying-faders.lua | 10 ++++++++++ configs/osc-xy.cfg | 26 ++++++++++++++++++++++++++ 3 files changed, 60 insertions(+) create mode 100644 configs/flying-faders.cfg create mode 100644 configs/flying-faders.lua create mode 100644 configs/osc-xy.cfg (limited to 'configs') diff --git a/configs/flying-faders.cfg b/configs/flying-faders.cfg new file mode 100644 index 0000000..4197581 --- /dev/null +++ b/configs/flying-faders.cfg @@ -0,0 +1,24 @@ +; Create a 'flying faders' effect using lua and output +; it onto TouchOSC (Layout 'Mix16', Multifader view on page 4) + +[osc touch] +bind = * 8000 +dest = learn@9000 + +; Pre-declare the fader values so the range mapping is correct +/*/fader* = f 0.0 1.0 +/*/toggle* = f 0.0 1.0 +/*/push* = f 0.0 1.0 +/*/multifader*/* = f 0.0 1.0 +/1/xy = ff 0.0 1.0 0.0 1.0 + +[lua generator] +script = configs/flying-faders.lua + +[map] + +generator.wave{1..24} > touch./4/multifader1/{1..24} +;generator.wave{1..24} > touch./4/multifader2/{1..24} + +touch./4/multifader2/1 > generator.magnitude + diff --git a/configs/flying-faders.lua b/configs/flying-faders.lua new file mode 100644 index 0000000..0b0faef --- /dev/null +++ b/configs/flying-faders.lua @@ -0,0 +1,10 @@ +step = 0 + +function wave() + for chan=1,24 do + output("wave" .. chan, (math.sin(math.rad((step + chan * 360 / 24) % 360)) + 1) / 2) + end + step = (step + 5) % 360 +end + +interval(wave, 100) diff --git a/configs/osc-xy.cfg b/configs/osc-xy.cfg new file mode 100644 index 0000000..fc5c5f3 --- /dev/null +++ b/configs/osc-xy.cfg @@ -0,0 +1,26 @@ +; Test for bi-directional OSC with an XY pad (TouchOSC Layout 'Mix16', Page 1) + +[backend osc] +detect = on + +[osc touch] +bind = 0.0.0.0 8000 +dest = learn@9000 + +; Pre-declare the fader values so the range mapping is correct +/*/xy = ff 0.0 1.0 0.0 1.0 + +[evdev xbox] +device = /dev/input/event16 + +[midi launch] + +[map] +xbox.EV_ABS.ABS_X > touch./1/xy:1 +xbox.EV_ABS.ABS_Y > touch./1/xy:0 + +xbox.EV_ABS.ABS_X > launch.ch0.note2 +;xbox.EV_ABS.ABS_Y > launch.ch0.note3 + +launch.ch0.note0 <> touch./1/xy:0 +launch.ch0.note1 <> touch./1/xy:1 -- cgit v1.2.3 From aef72140273b3d98a4d86a42f0f3bcce6d5899ca Mon Sep 17 00:00:00 2001 From: cbdev Date: Sun, 28 Jul 2019 23:19:54 +0200 Subject: Fix Lua timing on non-linux --- configs/midi-osc.cfg | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) (limited to 'configs') diff --git a/configs/midi-osc.cfg b/configs/midi-osc.cfg index 1b3ccd6..7753a24 100644 --- a/configs/midi-osc.cfg +++ b/configs/midi-osc.cfg @@ -13,23 +13,8 @@ dest = learn@8000 root = /4 ; Pre-declare the fader values so the range mapping is correct -/fader1 = f 0.0 1.0 -/fader2 = f 0.0 1.0 -/fader3 = f 0.0 1.0 -/fader4 = f 0.0 1.0 -/fader5 = f 0.0 1.0 -/fader6 = f 0.0 1.0 -/fader7 = f 0.0 1.0 -/fader8 = f 0.0 1.0 - -/multifader1/1 = f 0.0 1.0 -/multifader1/2 = f 0.0 1.0 -/multifader1/3 = f 0.0 1.0 -/multifader1/4 = f 0.0 1.0 -/multifader1/5 = f 0.0 1.0 -/multifader1/6 = f 0.0 1.0 -/multifader1/7 = f 0.0 1.0 -/multifader1/8 = f 0.0 1.0 +/fader* = f 0.0 1.0 +/multifader1/* = f 0.0 1.0 [midi bcf] read = BCF -- cgit v1.2.3 From 33f4e9c7d865ce518b0ffaf49615121db52a6a9e Mon Sep 17 00:00:00 2001 From: cbdev Date: Sat, 17 Aug 2019 01:46:36 +0200 Subject: Add new example config --- configs/midi-mouse.cfg | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 configs/midi-mouse.cfg (limited to 'configs') diff --git a/configs/midi-mouse.cfg b/configs/midi-mouse.cfg new file mode 100644 index 0000000..7e110ff --- /dev/null +++ b/configs/midi-mouse.cfg @@ -0,0 +1,22 @@ +; Use a Launch Control MIDI controller as mouse input +; Running this configuration requires root privileges on most systems, +; as creating additional input devices could potentially be misused for +; nefarious purposes + +[backend midi] +detect = on + +[evdev mouse] +output = MIDI Mouse +relaxis.REL_X = 255 +relaxis.REL_Y = 255 + +[midi launch] +read = Launch + +[map] +launch.ch0.cc0 > mouse.EV_REL.REL_X +launch.ch0.cc1 > mouse.EV_REL.REL_Y + +launch.ch0.note0 > mouse.EV_KEY.BTN_LEFT +launch.ch0.note1 > mouse.EV_KEY.BTN_RIGHT -- cgit v1.2.3 From 62eabb1c1d840cbab26b9ea747b102550199bad3 Mon Sep 17 00:00:00 2001 From: Spacelord09 Date: Thu, 22 Aug 2019 20:02:54 +0200 Subject: Added a config to test the maweb backend. --- configs/maweb-flying faders.cfg | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 configs/maweb-flying faders.cfg (limited to 'configs') diff --git a/configs/maweb-flying faders.cfg b/configs/maweb-flying faders.cfg new file mode 100644 index 0000000..0101f1e --- /dev/null +++ b/configs/maweb-flying faders.cfg @@ -0,0 +1,13 @@ +; Create a 'flying faders' effect using lua and output it onto maweb faders 1..6 + +[maweb ma] +host = 10.23.42.21 80 ; Thats the IP of your console or OnPC. +user = midimonster ; If a Dot2 is used, the username is automatically set to "remote". +password = midimonster + +[lua generator] +script = configs/flying-faders.lua + + +[map] +generator.wave{1..6} > ma.page1.fader{1..6} \ No newline at end of file -- cgit v1.2.3 From 5dcbae830db5289b4e269c1913511b890e3e1d5d Mon Sep 17 00:00:00 2001 From: Spacelord09 Date: Thu, 22 Aug 2019 20:12:21 +0200 Subject: Rename maweb-flying faders.cfg to maweb-flying-faders.cfg --- configs/maweb-flying faders.cfg | 13 ------------- configs/maweb-flying-faders.cfg | 13 +++++++++++++ 2 files changed, 13 insertions(+), 13 deletions(-) delete mode 100644 configs/maweb-flying faders.cfg create mode 100644 configs/maweb-flying-faders.cfg (limited to 'configs') diff --git a/configs/maweb-flying faders.cfg b/configs/maweb-flying faders.cfg deleted file mode 100644 index 0101f1e..0000000 --- a/configs/maweb-flying faders.cfg +++ /dev/null @@ -1,13 +0,0 @@ -; Create a 'flying faders' effect using lua and output it onto maweb faders 1..6 - -[maweb ma] -host = 10.23.42.21 80 ; Thats the IP of your console or OnPC. -user = midimonster ; If a Dot2 is used, the username is automatically set to "remote". -password = midimonster - -[lua generator] -script = configs/flying-faders.lua - - -[map] -generator.wave{1..6} > ma.page1.fader{1..6} \ No newline at end of file diff --git a/configs/maweb-flying-faders.cfg b/configs/maweb-flying-faders.cfg new file mode 100644 index 0000000..85aeada --- /dev/null +++ b/configs/maweb-flying-faders.cfg @@ -0,0 +1,13 @@ +; Create a 'flying faders' effect using lua and output it onto maweb faders 1..6 + +[maweb ma] +host = 10.23.42.21 80 ; Thats the IP of your console or OnPC. +user = midimonster ; If a Dot2 is used, the username is automatically set to "remote". +password = midimonster + +[lua generator] +script = configs/flying-faders.lua + + +[map] +generator.wave{1..6} > ma.page1.fader{1..6} -- cgit v1.2.3 From 90759c9ff4fc4380eec03962656ae4b9ca09bf5a Mon Sep 17 00:00:00 2001 From: Spacelord09 Date: Thu, 22 Aug 2019 20:35:34 +0200 Subject: Added Dot2 B-wing to example config. --- configs/maweb-flying-faders.cfg | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'configs') diff --git a/configs/maweb-flying-faders.cfg b/configs/maweb-flying-faders.cfg index 85aeada..e2fe6c6 100644 --- a/configs/maweb-flying-faders.cfg +++ b/configs/maweb-flying-faders.cfg @@ -10,4 +10,5 @@ script = configs/flying-faders.lua [map] -generator.wave{1..6} > ma.page1.fader{1..6} +generator.wave{1..6} > ma.page1.fader{1..6} ; Fader 1 to 6 +;generator.wave{7..14} > ma.page1.fader{7..14]} ; Fader 7 to 14 (F-wing1 on Dot2) -- cgit v1.2.3 From 88f59354ef22c815ca2731a13ac87677c3571343 Mon Sep 17 00:00:00 2001 From: cbdev Date: Thu, 22 Aug 2019 21:21:59 +0200 Subject: Fix spelling, fix comments Inline-comments are not currently supported --- configs/maweb-flying-faders.cfg | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'configs') diff --git a/configs/maweb-flying-faders.cfg b/configs/maweb-flying-faders.cfg index e2fe6c6..03b0939 100644 --- a/configs/maweb-flying-faders.cfg +++ b/configs/maweb-flying-faders.cfg @@ -1,14 +1,17 @@ ; Create a 'flying faders' effect using lua and output it onto maweb faders 1..6 [maweb ma] -host = 10.23.42.21 80 ; Thats the IP of your console or OnPC. -user = midimonster ; If a Dot2 is used, the username is automatically set to "remote". +; That's the IP of your console or OnPC. +host = 10.23.42.21 80 +; If a Dot2 is used, the username is automatically set to "remote". +user = midimonster password = midimonster [lua generator] script = configs/flying-faders.lua - [map] -generator.wave{1..6} > ma.page1.fader{1..6} ; Fader 1 to 6 -;generator.wave{7..14} > ma.page1.fader{7..14]} ; Fader 7 to 14 (F-wing1 on Dot2) +; Fader 1 to 6 (Core Wing) +generator.wave{1..6} > ma.page1.fader{1..6} +; Fader 7 to 14 (F-wing1 on Dot2) +;generator.wave{7..14} > ma.page1.fader{7..14]} -- cgit v1.2.3 From 350f0d2d2eaff5f0d57b09857102e2df1e96d733 Mon Sep 17 00:00:00 2001 From: cbdev Date: Thu, 7 Nov 2019 18:44:19 +0100 Subject: Makefile install target and packaging instructions (Fixes #28) --- configs/flying-faders.cfg | 2 +- configs/lua.cfg | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'configs') diff --git a/configs/flying-faders.cfg b/configs/flying-faders.cfg index 4197581..d331f38 100644 --- a/configs/flying-faders.cfg +++ b/configs/flying-faders.cfg @@ -13,7 +13,7 @@ dest = learn@9000 /1/xy = ff 0.0 1.0 0.0 1.0 [lua generator] -script = configs/flying-faders.lua +script = flying-faders.lua [map] diff --git a/configs/lua.cfg b/configs/lua.cfg index af17496..098c0f1 100644 --- a/configs/lua.cfg +++ b/configs/lua.cfg @@ -13,7 +13,7 @@ axis.ABS_X = 34300 0 65535 255 4095 axis.ABS_Y = 34300 0 65535 255 4095 [lua lua] -script = configs/demo.lua +script = demo.lua [artnet art] universe = 0 -- cgit v1.2.3 From ddbc61cf653120b513e4e76d893909ba4a77b97f Mon Sep 17 00:00:00 2001 From: cbdev Date: Sat, 9 Nov 2019 14:00:29 +0100 Subject: Fix configurations --- configs/launchctl-sacn.cfg | 7 +++---- configs/maweb-flying-faders.cfg | 2 +- 2 files changed, 4 insertions(+), 5 deletions(-) (limited to 'configs') diff --git a/configs/launchctl-sacn.cfg b/configs/launchctl-sacn.cfg index 781ca40..0f4a19b 100644 --- a/configs/launchctl-sacn.cfg +++ b/configs/launchctl-sacn.cfg @@ -6,15 +6,14 @@ [backend midi] name = MIDIMonster -[backend artnet] +[backend sacn] bind = 0.0.0.0 [midi lc] read = Launch Control -[artnet out] -universe = 0 -destination = 255.255.255.255 +[sacn out] +universe = 1 [map] diff --git a/configs/maweb-flying-faders.cfg b/configs/maweb-flying-faders.cfg index 03b0939..806c4d4 100644 --- a/configs/maweb-flying-faders.cfg +++ b/configs/maweb-flying-faders.cfg @@ -8,7 +8,7 @@ user = midimonster password = midimonster [lua generator] -script = configs/flying-faders.lua +script = flying-faders.lua [map] ; Fader 1 to 6 (Core Wing) -- cgit v1.2.3