Author |
Topic: Map PC to CC as a toggle (Read 4277 times) |
|
nick_robinson
New Member

 MIDI-OX Rules!
Posts: 4
|
 |
Map PC to CC as a toggle
« on: Aug 3rd, 2016, 12:54pm » |
Quote Modify
|
I'm using midiox to map program change messages to CC, with the aim of toggling ableton effects on & off. It will switch it on or off... however, I can't seem to persuade it to toggle. Any clues?
|
|
IP Logged |
|
|
|
Breath
Administrator
    

Gender: 
Posts: 1035
|
 |
Re: Map PC to CC as a toggle
« Reply #1 on: Aug 3rd, 2016, 10:21pm » |
Quote Modify
|
Hi Nick By toggling I am assuming you are sending the same PC message twice to 'flip' the switch. Once to turn it ON then again to turn it OFF. If this is the case MidiOx would need to remember if the switch was On or Off so it could change it to the opposite state. There is no way a single map can know the state of the switch BUT you can do it in a tricky way and use 2 Data maps and the Patch Map. An example.. using PC 100 on channel 1 as the trigger to turn things off and on For Abelton .... CC20 value 0 is OFF CC20 value 10 is ON We will use patch change (PC) 100 on channel 16 to load the Toggle OFF data map file and PC 101 channel 16 to load the Toggle ON file. Create a Data Map with 2 lines 1 PC 100 100 (clone the original message) 1 CC 20 20 0 0 1 PC 100 100 16 PC 101 101 Save as ToggleOff.oxm Change this Data Map - CC20 should now be 10 and PC should be 100 1 PC 100 100 (clone the original message) 1 CC 20 20 10 10 1 PC 100 100 ****** there was a correction to this line 16 PC 100 100 Save as ToggleOn.oxm and turn on the Data Map (to the left of the OK button) Go to the Options/Patch Mapping, clear all channels then select just 16. Scroll down to 100 and select the file ToggleOff.oxm Then at 101 select ToggleOn.oxm and switch on the Map (to the left of the OK button) Now on the Port Routing window route your input to Abelton (eg MidiYoke2). When you send the PC 100 on channel 1 MidiOx will change it to CC20 10 turning ON Abelton and MidiOx will also send a patch change message (PC) 101 on channel 16 which will load ToggleOff.oxm Now when you send the PC 100 again MidiOx will change it to CC20 0 turning OFF Abelton and it will also send a patch change message (PC) 100 on channel 16 which will load ToggleOn.oxm If the PC message does things you don't want it to, you can use a different Channel for the PC (make sure the PC Map has that channel ticked) If you need to filter out the PC message, connect input -> MidiYoke1 -> Abelton. On the MidiYoke1 -> Abelton connection click the little box in the middle of the line and load in a new DataMap (oxm) that filters out the PC message. The other alternative is to program MidiOx's Script function (have a look at the help manual as well as the examples). All the best Royce
|
« Last Edit: Nov 11th, 2018, 8:07pm by Breath » |
IP Logged |
|
|
|
Astraios
Member
 
 MIDI-OX Rules!
Gender: 
Posts: 16
|
 |
Re: Map PC to CC as a toggle
« Reply #2 on: Nov 10th, 2018, 9:39am » |
Quote Modify
|
Hi Royce After years working with OX I try to create my first Patch-Map following this instruction but I don't understand: [/b]"1 PC 2 2 100 100"[/b] what is this PC 2 2 for? Best wishes from Berlin
|
|
IP Logged |
|
|
|
Breath
Administrator
    

Gender: 
Posts: 1035
|
 |
Re: Map PC to CC as a toggle
« Reply #3 on: Nov 10th, 2018, 7:34pm » |
Quote Modify
|
Hi oops I really goofed in my rush - I know I should have checked it. Change this Data Map - CC20 should now be 10 and PC should be 100 1 PC 100 100 (clone the original message) 1 CC 20 20 10 10 1 PC 100 100 ****** there was a correction to this line 16 PC 100 100 Save as ToggleOn.oxm and turn on the Data Map (to the left of the OK button) Thanks for the correction. I hope Nick Robertson sorted it out. ToggleOn.oxm Toggleoff.oxm Patchmap http://www.bwalk.com.au/Public/MidiOxToggle.zip Here is a zip file of the Data Maps and the Patch Map. Unzip them to .... MidiOx/Maps All the best Royce
|
« Last Edit: Nov 11th, 2018, 8:37pm by Breath » |
IP Logged |
|
|
|
Astraios
Member
 
 MIDI-OX Rules!
Gender: 
Posts: 16
|
 |
Re: Map PC to CC as a toggle
« Reply #4 on: Nov 12th, 2018, 3:56am » |
Quote Modify
|
Thank you for this : that is exactly what I found out after hours of rack my brain. Sure, now it is clear: every command in the first row has to be pc 100 100 (because that represents the push of the one button) Nice regards Uwe
|
|
IP Logged |
|
|
|
Astraios
Member
 
 MIDI-OX Rules!
Gender: 
Posts: 16
|
 |
Re: Map PC to CC as a toggle
« Reply #5 on: Nov 12th, 2018, 4:58am » |
Quote Modify
|
Hello Royce just want to add, from my opinion and realization no chance to get it to work right without activating channel 1 too… but maybe I'm wrong. Also, I haven't 'send patch through new map' on. But it works perfect in my OX setup Greetings
|
|
IP Logged |
|
|
|
Breath
Administrator
    

Gender: 
Posts: 1035
|
 |
Re: Map PC to CC as a toggle
« Reply #6 on: Nov 15th, 2018, 9:21pm » |
Quote Modify
|
I'll have to try it out. Glad you got it working. Royce
|
|
IP Logged |
|
|
|
|