Skip to content

Commit

Permalink
Support HotCue clear with Pad.
Browse files Browse the repository at this point in the history
push "Pad" in "CUES" mode, activate hotcue, and
push "Pad" holding "PAD MODE" in "CUES" mode, clear hotcue.
  • Loading branch information
doteya committed Aug 30, 2022
1 parent c9d9581 commit 328093b
Show file tree
Hide file tree
Showing 2 changed files with 152 additions and 1 deletion.
144 changes: 144 additions & 0 deletions res/controllers/Numark_DJ2GO2_Touch.midi.xml
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,78 @@
<script-binding/>
</options>
</control>
<control>
<group>[Channel1]</group>
<key>DJ2GO2Touch.leftDeck.hotcueButtons[1].input</key>
<status>0x84</status>
<midino>0x09</midino>
<options>
<script-binding/>
</options>
</control>
<control>
<group>[Channel1]</group>
<key>DJ2GO2Touch.leftDeck.hotcueButtons[1].input</key>
<status>0x94</status>
<midino>0x09</midino>
<options>
<script-binding/>
</options>
</control>
<control>
<group>[Channel1]</group>
<key>DJ2GO2Touch.leftDeck.hotcueButtons[2].input</key>
<status>0x84</status>
<midino>0x0A</midino>
<options>
<script-binding/>
</options>
</control>
<control>
<group>[Channel1]</group>
<key>DJ2GO2Touch.leftDeck.hotcueButtons[2].input</key>
<status>0x94</status>
<midino>0x0A</midino>
<options>
<script-binding/>
</options>
</control>
<control>
<group>[Channel1]</group>
<key>DJ2GO2Touch.leftDeck.hotcueButtons[3].input</key>
<status>0x84</status>
<midino>0x0B</midino>
<options>
<script-binding/>
</options>
</control>
<control>
<group>[Channel1]</group>
<key>DJ2GO2Touch.leftDeck.hotcueButtons[3].input</key>
<status>0x94</status>
<midino>0x0B</midino>
<options>
<script-binding/>
</options>
</control>
<control>
<group>[Channel1]</group>
<key>DJ2GO2Touch.leftDeck.hotcueButtons[4].input</key>
<status>0x84</status>
<midino>0x0C</midino>
<options>
<script-binding/>
</options>
</control>
<control>
<group>[Channel1]</group>
<key>DJ2GO2Touch.leftDeck.hotcueButtons[4].input</key>
<status>0x94</status>
<midino>0x0C</midino>
<options>
<script-binding/>
</options>
</control>
<control>
<group>[Channel1]</group>
<key>DJ2GO2Touch.leftDeck.loopIn.input</key>
Expand Down Expand Up @@ -572,6 +644,78 @@
<script-binding/>
</options>
</control>
<control>
<group>[Channel2]</group>
<key>DJ2GO2Touch.rightDeck.hotcueButtons[1].input</key>
<status>0x85</status>
<midino>0x09</midino>
<options>
<script-binding/>
</options>
</control>
<control>
<group>[Channel2]</group>
<key>DJ2GO2Touch.rightDeck.hotcueButtons[1].input</key>
<status>0x95</status>
<midino>0x09</midino>
<options>
<script-binding/>
</options>
</control>
<control>
<group>[Channel2]</group>
<key>DJ2GO2Touch.rightDeck.hotcueButtons[2].input</key>
<status>0x85</status>
<midino>0x0A</midino>
<options>
<script-binding/>
</options>
</control>
<control>
<group>[Channel2]</group>
<key>DJ2GO2Touch.rightDeck.hotcueButtons[2].input</key>
<status>0x95</status>
<midino>0x0A</midino>
<options>
<script-binding/>
</options>
</control>
<control>
<group>[Channel2]</group>
<key>DJ2GO2Touch.rightDeck.hotcueButtons[3].input</key>
<status>0x85</status>
<midino>0x0B</midino>
<options>
<script-binding/>
</options>
</control>
<control>
<group>[Channel2]</group>
<key>DJ2GO2Touch.rightDeck.hotcueButtons[3].input</key>
<status>0x95</status>
<midino>0x0B</midino>
<options>
<script-binding/>
</options>
</control>
<control>
<group>[Channel2]</group>
<key>DJ2GO2Touch.rightDeck.hotcueButtons[4].input</key>
<status>0x85</status>
<midino>0x0C</midino>
<options>
<script-binding/>
</options>
</control>
<control>
<group>[Channel2]</group>
<key>DJ2GO2Touch.rightDeck.hotcueButtons[4].input</key>
<status>0x95</status>
<midino>0x0C</midino>
<options>
<script-binding/>
</options>
</control>
<control>
<group>[Channel2]</group>
<key>DJ2GO2Touch.rightDeck.loopIn.input</key>
Expand Down
9 changes: 8 additions & 1 deletion res/controllers/Numark_DJ2GO2_Touch_scripts.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,14 @@ DJ2GO2Touch.Deck = function(deckNumbers, midiChannel) {
this.hotcueButtons[i] = new components.HotcueButton({
group: "[Channel" + script.deckFromGroup(this.currentDeck) + "]",
midi: [0x94 + midiChannel, 0x00 + i],
number: i
number: i,
input: function(channel, control, value, status, _group) {
if (control <= 8) {
engine.setValue(this.group, "hotcue_" + this.number + "_activate", value);
} else {
engine.setValue(this.group, "hotcue_" + this.number + "_clear", value);
}
},
});
var sampler = i + (midiChannel * DJ2GO2Touch.padsPerDeck);
this.samplerButtons[i] = new components.SamplerButton({
Expand Down

0 comments on commit 328093b

Please sign in to comment.