I have been using this in a live-set for about a month. Works pretty well.
I’d really like to get some more device config files, and general cross-platform testing, so I am very open to feedback, and I will help anyone who needs it with setting it up.
Thanks goes to Kieran Foster of Renoise support for his invaluable help with making midi control messages over OSC.
Description:
I wanted to use MIDI keyboards and joysticks to control a specific instrument on a specific track, so I made this device router.
I use it in a live set to allow me to play my devices with pre-made effects racks and instrument settings, along with sequenced and vocal tracks.
You must enable renoise’s OSC server (in settings.) Think of the included yml files as a base for your own devices. They are written in simple YAML, and should be pretty self-explanatory. Included are examples for basic midi keyboards, an XBOX classic controller (hooked to USB) and an XBOX360 guitar-hero controller (also connected to USB.) I have only tested this in Linux, but it should be cross-platform. It requires python YAML and pygame libraries. The devices are searched by the name as they show up in lists of midi input devices and joysticks by pygame. You can see the output if you run the router in a terminal (to get a list of available devices.)
Also, it should be noted that I intend it as a general Renoise OSC trigger, so it can do lots more then just send instrument+track messages. In my setup, it loads songs when you press midi buttons, it sends control messages, and turns joystick events into OSC messages.
hhhhmmmm, Have I done something wrong? ive installed Python Yaml, and Python Pygame, but when I run ./renoise_router.py I get this…
Config files:
.svn
text-base
Traceback (most recent call last):
File “./renoise_router.py”, line 454, in
dev_map, host, port = parse_yaml()
File “./renoise_router.py”, line 442, in parse_yaml
f = open(os.path.join(directory,device_type, fname),“r”)
IOError: [Errno 21] Is a directory: ‘./devices/.svn/text-base’
Ive enable the osc sever in renoise(The Osc.py works by the way).
Looks like you need the newest version. I realized after I put it in SVN that svn uses (hidden) dot directories.
You can grab the updated download here or do an svn update.
After this, in the command-line it will list the available config files, and list the midi/joystick devices you have attached. You can use my yml files as an example, just set “name” field to what shows up in list, and save it as whatever.yml in the right directory (midi/joystick.) Again, I am happy to help people with writing config files if I know what their system calls the device, and even help setup custom actions, like I am using, in python.
Thanks for the work youve been putting into this, and the help!!
sweet, it detects the gamepad, (Microsoft X-Box pad v2 (US)) , and ive managed to enable it, but could you tell me the format for adding the OSC messages?
for instance, if i wanted the Y button (which is being displayed as <Event(10-JoyButtonDown {‘joy’:0, ‘button’:4})>) to set bpm on a “Button Down” how would I add it to the config file?
/renoise/song/bpm(64) would be an example of the osc command id ike to use,(are we supposed to keep the argument in brackets?) not so sure where to put that in the config either…
oh and i was thinking, a threshold limiter(like a deadzone) on the sticks could be a good idea, on some games it helps as the sticks tend to hop around even when im not using them. Dont know if anyone else ever has that problem tho.
cheers:-)
ahh, upon reading through renoise_router.py, it seems it has to be coded into that, and not just dropped in the config file next to the event…not sure im able for that:-(
cheers man, i always wanted to learn python,(did some of the various tutorials and hello worlds) maybe some of this might sink in:-) Il have a go and see what I come up with:-)