I have written a Bitwig extension and customized a PBF4 module which is working perfectly fine so far.
Now I have added an EN16 module and since the indeces of the LEDs are 0-11 on PBF4 and 0-15 on EN16 when I set i.e the intensity of LED 4 of PBF, the corresponding LED of the EN16 gets addressed as well.
How do I go about handling the LEDs of both modules entirely separately?
Thanks a lot.
Unique LED index with PBF4 + EN16
Replies (6)
You could use the positional index of the modules with the module_position_x() and module_position_y() functions.
For a demo you could take a look at the deafult configuration here: https://docs.intech.studio/wiki/more/dynamic-layout
Thanks. I tried that but I don't see how this would work. I have EN16 at [0,0] and PBF4 below at [0,-1] so I thought an if module:position_y() == -1 could filter the correct module but I cannot extract it from the midi message. And using element_index(), setting the LED of the 1st button on the PBF4 will also set the LED No. 9 on EN16 because self:element_index() == 8 for both of them because this is the physical index. Maybe I'm not seeing the forest for the trees here.
Balint and the other Intech folks could surely describe this better, but having been working on bitwig controller scripting with Grid recently I thought that this might get your wheels turning: you need to design a bidirectional mapping between grid elements and midi messages. By bidirectional I don’t just mean midi feedback from bitwig, I mean that your logic which takes an element index on a module in a particular x y position and turns it into a MIDI CC number on a channel must have corresponding logic which can take a MIDI CC number on a channel, coming from bitwig, and convert it back into the correct module x y and element index.
For me, at first I was doing this with ranges of CCs on a smaller number of MIDI channels, but most recently I changed to assigning a midi channel to each module using its x y coordinates and then simply using element index as the CC and/or note number. That’s for the push encoders (using bin offset CCs) and buttons (using notes.)
To add more layers of control, I have a shift function which communicates across the grid to shift up and down by 16 CCs/notes at a time.
For the linear and rotary pots on the EF44s and PBF4, however, I went with a different mapping: assigning a midi channel to each knob/fader, so that I can use pitch bend messages for them.
This is on a ten-module grid in a 5x2 layout with seven EN16s, two EF44s, and a PBF4, and it has been working nicely and easy to manage once I got over the hurdle of learning the necessary controller scripting and working out my mapping.
I hope this all gives you some ideas!
Thanks, I think it fixed itself after changing the logic a bit and a kind of refactoring. Not sure what the issue was, I guess some user error and double use of IDs. Hopefully this stays true and works out in the end.
I have a bidirectional connection that handles solo states of channels and reflects the bitwig channel colors on EN16 top/PBF4 bottom, being a mixer basically.. I can shift banks with long press, the bwextension recognizes certain EQ/saturation plugins automatically and maps them, which is a nice plus. Lastly I use the utility button to change the page so I can basically just manually map the PBF to syth parameters and stuff. Still WIP but lookin good so far.
And wow, that's some sick elaborate setup you got there. XD
Maybe I was too quick, seems not fixed but only obscured and mitigated. I'll keep on trying...
View on Discord
This post is from the Intech Studio Discord community.