I am having an issue with sending midi on multiple channels. When set to all everything sends on channel 1. Can anyone else confirm?

Also – when setting up, I choose my device and then my interface. At that point I always have to change the device away and then back to what I want in order to start passing midi.

Also also – any way to add a command to refresh the midi devices? If I change anything they don’t show up in the list, even if I map them under the main norns midi devices page. In order to update I have to restart the script.

Sorry for the hassle, thanks for the great utility!

Also – when setting up, I choose my device and then my interface. At that point I always have to change the device away and then back to what I want in order to start passing midi.

Yep - i get this too, had looked briefly into it but haven’t yet been able to get it working as it should. Will have another look.

Will investigate the all issue too and see I can add refreshing to midi devices on connection.

There an update devices function which can get hit in the params callback. I’ll see if i can find a reference here shortly

Pretty sure I have seen something like that around… hard to remember in which script I last spotted it tho so if you do come across a reference, would be v handy!

Ok so I’m doing this in my Torii script when setting up the params for changing grid devices:

midi.update_devices() should help for either/both your midi_device and midi_interface params?

Also - looking at Passthrough.device_event(data) I’m not seeing anything obvious that would send to all channels. Wouldn’t that need a loop? I don’t think there’s any kind of “Omni” channel in the core midi library.

Yup - looks like it! To be honest i hadn’t tested that functionality as i’d lifted that chunk from elsewhere mostly… my bad! Maybe i should remove it… or add a loop in. An omni channel would be a good addition to the core midi lib

1 Like

looking at the core midi lib, I don’t think there’s an easy way to do this since the midi spec doesn’t really include a separate channel for all/omni. (investigating further). For now I think it’d need to be done at the app layer with a loop to send to all channels.

I’ve made an update this evening - this fixes the issue of the devices and interfaces events not targeting the right functions. So this should work as expected on script launch now. Thanks for the prompt to fix that.

As for the other issues. I haven’t yet a solution for refreshing the available midi devices. I’ll keep trying but I couldn’t get the params options to update when devices are added/removed. If you can find an example where this works well, let me know! And I removed all as a channel option for now. It would be great to support it properly, but for now I wanted to ensure that the core was behaving as it should and keep ‘work in progress’ features far from causing people issues!

1 Like

I updated and this still doesn’t seem to be working for me – still have to switch away and back to get data sending through. Just a minor thing, really.

Makes sense to me – this is a great utility (seems like it would be a great add to main norns under midi devices @tehn?) just hope that all becomes workable as it’s my primary use case right now :sweat_smile:

Weird - did you update it inside the scripts that you’re using it in? Or are you trying with the example script in the Passthrough repo? Just tried with my setup and it’s working here.

I’ll keep looking into all :slight_smile:

I wasn’t certain whether to suggest rolling it into Norns core midi although it could be nice. I haven’t really checked or tested Passthrough with scripts that use MIDI input/output in parallel since it wasn’t particularly relevant for me, and I wonder if having it in could create some hiccups for folks. I even was doubtful whether to add the repo to the community catalogue since the example script does nothing else :smiley:

Yes – I only have it in MLR right now, so overwrite the existing lib passthrough.lua with the new one. Confirmed it’s new because all is no longer there. Do I need to update anything inside the code?

I tried with both my Midi Fighter Twister and Qunexus sending to Digitone.

Good point about possible interactions with midi scripts. That could get very confusing, or requiring those scripts to assume control of the system somehow.

Alright i’ll try to reproduce …

I just tried it with MLR and it works instantly.

Can you show me your implementation in MLR?
Mine is this:
L24: local Passthrough = include("lib/passthrough")
L362: Passthrough.init()

and can you double check that you’re using the same contents in lib/passthrough.lua as what is on master on github? Feel free to send me the entire copy you’re using either here or on PM and I can take a peek.
Sorry for the trouble!

No trouble at all. It works now. :slight_smile:

Deleted and reinstalled MLR, then added the lib and code back in. I had L24 same as you, but had what you note as L362 at L370 under init = function(). Put it as you note and voila. Thanks!

Glad it’s working for you now :slight_smile:

1 Like

i’m wondering if there’s sufficient validation for some sort of UI to “load additional lib” or something.

my gut feeling is that unless it’s very well designed and considered there will inevitably be difficult code conflicts to resolve.

i do think the MIDI devices section could have a couple util functions added, such as port redirection (like this lib does). it’d also be nice to have a little midi monitor built-in to the menu.

5 Likes

@Frederickk has made a great update to Passthrough, which allows for user event callbacks to be defined in your scripts, alongside a couple of nice bits of polish. This allows you to hook into the MIDI event stream in Passthrough, and define your own behaviours.

Update in Github repo linked in the top post or install using Maiden catalogue.

2 Likes

does anyone know what the best method to pass midi through my norns (fates) and back into my octatrack would be? i have octa midi going through a digitone and then model cycles which send midi thru to the norns which goes into the octatrack. I also have a nanokontrol running midi into the norns. I would like to be able to pass the midi from the octatrack back into itself through the norns and have the ability to control my octatrack with the nanokontrol through the norns as well.

i have tried unsuccessfully to use this script. Cant figure out how to add the code to another script without getting a run error. but i dont really need it to be attached to any particular script if that isnt necessary. is there a way to pass midi from either device port straight through the norns without any particular script running? or is there a way to do that with this script?

Passthrough was initially built to pass MIDI into an Octatrack I was using. If I’m following correctly, I think you are looking for multiple devices (Nanokontrol + model cycles) to be supported with an interface (Octatrack). Passthrough doesn’t currently support this, although its a good feature request that I’ll try to get round to implementing. I believe there was talk of creating this kind of routing as part of the core Norns MIDI feature set, but I haven’t really followed so unsure of the status there.

Am interested what are the run errors you are getting, there are instructions for implementing it in scripts.

thanks so much for this @nattog! was able to get a Midi Fighter Twister hooked up to a Zoia no problem, and was able to do what I was hoping would work out of the box - using the same cc to control norns and zoia params. (I’m still new to MIDI; this is probably an obvious use-case)

1 Like