OSC on the Mod (or why mod-host doesn't like my midi port)

With some helpful prodding, I’ve finally gotten around to trying to get my osc2midi app to work on the mod. It does! yay. Unfortunately it is useless because as soon as I use jack_connect to make the midi output from osc2midi go into the mod-host the CPU meter in the pedal builder races to 100% and it just doesn’t seem to accept the midi (or at least it won’t midi-learn).


Is the mod-host using an alsa-midi type port where osc2midi is a jack port? Whats going on? If I can get this last step resolved we would have a working osc implementation.

I tried this also connecting to a different midi plugin rather than mod-host but the result is the same. When I connect the midi output to jack_midi_dump then it looks fine. I’m confused.


@Jakob is the guy to answer you :wink:

1 Like

I assume you are talking about this code

You could compare the function in mod-host that handles incoming MIDI events. See here

One idea, what to check, is that there is no type of event getting stuck in the incoming-ringbuffer, because it is neither handled nor discarded.
Before I invest more time into this issue; how do you plan to get OSC messages into the Duo in a live/stage situation?

That is the code.
We’d use Bluetooth to get osc into the duo. I’ve already verified this works in my system.

1 Like

Thank you for this information!

1 Like

the linux audio developer community gave me a hot tip: the mod-host is running as an internal jack client and internal clients don’t like interfacing with external ones. I’m going to add internal client capabilities to osc2midi and see where that gets me. Will report back when done (probably a couple weeks).


I’ve been using OSC Touch on my iphone with Osculator on my mac to control things in Live - it works great - perhaps foolishly I’ve got a Bluetooth dongle and was wondering if that might be a way of getting it working on the Duo with OSC Touch as well… any info on this would be great… thanks

I’ll be sure to update here as thing develop. Unfortunately I’ve hit a brick wall on how to get my app to run properly in the mod as a jack internal client. I need to reach out to get some help.


so TouchOSC won’t work on Mod Duo devices, or?

I’m using it on MODEP (Raspberry Pi 4) and it works great.
Thinking of buying an MOD Dwarf, but if I can’t control it with TouchOSC then not sure what to do…

1 Like

It can as soon as anyone does the implementation required to have it working.

Can you give an overview on how you are using this?

1 Like

I’ve created an template for students and rehabilitators that is easy to understand and control via tablet or smartphone.
So MIDI controllers can’t be used for this. It could, but would make controlling my pedalboards a lot cumbersome and hard.

I enjoy how MODEP works on RPi and PiSound via Patchbox OS, but I’d like to test out Dwarf when it releases, because it has all what I need for my project and if I get working what I need, I’d like to buy more.

1 Like

but I mean, technically, how is this done?
still using OSC2MIDI project right?

I am curious how you connect to the embed system, is it WiFi? Cause otherwise I dont exactly see how it would work with such embed devices.

Oh, sorry :grin:
Ye, via WiFi. Blokas for MODEP use TouchOSC host. Not sure if they use osc2midi tho.

Seems they do - GitHub -> BlokasLabs/osc2midi/blob/master/midi_serialization.h

That is a different project, different implementation. I tried to ask for support on getting my OSC2MIDI program working as a jack internal client so it can play nicely with mod-host but didn’t get any response and dropped the effort. If anyone wants to try it it’s on the jack_internal branch of the repo falkTX linked above. Happy to accept PRs! :slight_smile:

1 Like

since then we added a CLI env var one can use to connect external clients to internal clients, making the internal client sync “slower” (futex becomes public instead of private, which does context-switch) but allows to have this working without much fuss.

the good thing is that we very very soon will have v1.10 which will allow to create any kind of arbitrary UI.
so it is technically possible to have a plugin that does nothing but provide a custom UI to activate and setup something else in the system
I am inclined to do it, if someone shows me a linux or windows desktop tool that can do something similar to TouchOSC (important to be in a compatible way).

somewhat related to this, I am going to investigate using webmidi in a plugin. so we can send midi from the browser to plugins. this allows, for example, to use MIDI devices that are supported in Windows but not on Linux, like wireless MIDI things. but still need to do tests regarding latency

1 Like

we very very soon will have v1.10 which will allow to create any kind of arbitrary UI.

:open_mouth: I must learn more about this, but that’s OT I think.

There are very few people trying to control something from desktop it seems. Most apps are for mobile devices, but you can send OSC messages using oscsend in the liblo-tools package to test. OR you could use GitHub - fps/kontroll: A small app to send the mouse position as midi/OSC controller for something a little more interactive. OR you could use my OSC2MIDI backwards and convert any jack-midi signal to an OSC message which would go to the mod and get converted back to midi. Let me know if you need some more help with that.

1 Like

I guess using the phone is really the way to go…
There is at least one possible relevant tool in fdroid Sensors2OSC | F-Droid - Free and Open Source Android App Repository

I am just confused because it seems to me, please correct me if I am wrong, that you always need to manually create a config file before you can start using osc2midi.
I thought the point of using something like TouchOSC is that it somehow exports/reports its config and the receiver side auto-updates as needed.

1 Like

TouchOSC has the graphical interface more set, but you can use MaxMSP (and probably Pure Data also on Linux…although I’m not sure) to send OSC messages.
“UDP tester” on MaxMSP examples is a pre-made patch that allows you to send OSC.

You simply need to put the host listening the correct IP address and port. Typical UDP implementation.