summaryrefslogtreecommitdiff
path: root/Midi_Interface
diff options
context:
space:
mode:
Diffstat (limited to 'Midi_Interface')
-rw-r--r--Midi_Interface/RHMixxx-scripts.js12
1 files changed, 6 insertions, 6 deletions
diff --git a/Midi_Interface/RHMixxx-scripts.js b/Midi_Interface/RHMixxx-scripts.js
index 4e4aff3..0d7114f 100644
--- a/Midi_Interface/RHMixxx-scripts.js
+++ b/Midi_Interface/RHMixxx-scripts.js
@@ -7,9 +7,6 @@
function RHMixxx() {}
-RHMixxx.num_decks = 2;
-RHMixxx.num_sampler = 12;
-
RHMixxx.groupNotes = {
"[Channel1]": { play: 0x01, stop: 0x00 },
"[Channel2]": { play: 0x03, stop: 0x02 },
@@ -30,14 +27,17 @@ RHMixxx.groupNotes = {
// *********** Init/De-Init ***********
RHMixxx.init = function (id, debug) {
+ var num_decks = engine.getValue("[Master]", "num_decks");
+ var num_sampler = engine.getValue("[Master]", "num_samplers");
+
if(debug)
print("RHMixxx initializing for controller '" + id +
- "' (" + RHMixxx.num_decks + " Decks, " + RHMixxx.num_sampler + " Sampler)");
+ "' (" + num_decks + " Decks, " + num_sampler + " Sampler)");
var i;
- for (i = 1; i <= RHMixxx.num_decks; i++)
+ for (i = 1; i <= num_decks; i++)
RHMixxx.initDeck(i, debug);
- for (i = 1; i <= RHMixxx.num_sampler; i++)
+ for (i = 1; i <= num_sampler; i++)
RHMixxx.initSampler(i, debug);
midi.sendShortMsg(0x80, 0x1F, 0x00);