sonic-pi-net / sonic-pi

Code. Music. Live.
https://sonic-pi.net
Other
10.81k stars 921 forks source link

Support for external controllers (e.g. Monome, Launchpad, etc.)? #1480

Closed tomekr closed 6 years ago

tomekr commented 7 years ago

Hi all, has anyone looked into implementing support for an external controller such as a Monome (http://monome.org/grid/) or launchpad (https://global.novationmusic.com/launch/launchpad)? I'm not quite sure the best way to approach this functionality so I was hoping to maybe get some ideas from the team in case there have already been discussions related to this feature.

llloret commented 7 years ago

Hi,

yes, MIDI support is in the works.

tomekr commented 7 years ago

Great, any idea on how that is going to work at the moment from a high level? Not sure if it'll require plugins in a specific format to be written for devices but either way if you need any help with that or testing I've got a Launchpad and quite a bit of Ruby experience.

I also just stumbled upon this thread from the Google Group (https://groups.google.com/forum/#!searchin/sonic-pi/controller|sort:relevance/sonic-pi/Cy1Ti9fw6os/QUmXSohlEAAJ) which seems to have some independent implementations

samaaron commented 7 years ago

We're going to make it as platform agnostic as possible doing conversion from high level MIDI messages such as: midi :note_on, 70 (a rough example of the kind of syntax it might end up as) using a well-timed Erlang scheduler to forward the messages on to a little C++ binary which will then turn the message to MIDI and ship it to the device.

We'll let you know just as soon as you can play with a working beta. We would love your feedback and assistance with this feature's development.

samaaron commented 6 years ago

Since version v3.0 we've had full support for both MIDI and OSC which will enable you to work with any generic controller such as monomes and launchpads :-)

I'm also working on a GUI grid interface which will support a similar (if not identical) API to monome so people without external hardware can start playing along too :-)

ibz commented 2 years ago

@samaaron is the GUI grid interface something that already exists? How does it work, is it just a separate program that talks OSC to Sonic Pi?

samaaron commented 2 years ago

@ibz - apologies but the grid interface I mentioned 4 years ago never made it into release. I am actually about to look at this kind of stuff again though - but no promises!

samaaron commented 2 years ago

Note, this app already provides an amazing amount of interface opportunities and may be interesting to you: https://hexler.net/touchosc

ibz commented 2 years ago

I was thinking that a more interesting approach would be to somehow expose SuperCollider's GUI toolkit to the Sonic Pi Ruby API, so every live coding session could have its own custom GUI. I wonder what you think about that.

samaaron commented 2 years ago

We don't use SuperCollider language and therefore their GUI toolkit in any way. Adding this would require the integration of a whole new tech stack.

Instead, I'm looking at using web technologies - specifically Elixir LiveView :-)