4

Edit: I'm trying a different tack at the problem, by using /dev/midi with C.

Hello all! I recently got a Akai MPD24 MIDI controller, as part of a piece of software I'm writing. I'm looking to use the dials on it to control the view of an OpenGL window. I've already got the OpenGL part working with GTK+ sliders, so the only problem is getting the MIDI device set up.

I found the OSS MIDI libraries, and it appears that they are working correctly, but for some reason it can't probe it correctly.

dmesg output:

...
usb 3-1: USB disconnect, address 2
usb 3-1: new full speed USB device using uhci_hcd and address 3
usb 3-1: configuration #1 chosen from 1 choice
Reinsert of an audioctl device 1/0 - USB sound device
oss_usb: probe of 3-1:1.1 failed with error -5
...

Has anyone been able to use a MIDI device through Linux, or have any idea as to what the mysterious "error -5" is?

2
  • Because it looks like your problem is USB related: I read about a USB stick which did not work on Ubuntu, because udevinfo was missing or the wrong version. Sorry, if this is totally of the track. Commented Jul 16, 2009 at 8:52
  • Hmm... I'll have to look into that. Anything you can think of is greatly appreciated!
    – user1607
    Commented Jul 17, 2009 at 17:58

2 Answers 2

1

-5 is EIO - an IO error (in ANSI C anyway; lets hope Linux is using standard error codes)

I'll include some URLs I found when researching this:

http://manuals.opensound.com/sources/usb_wrapper.inc.2.html http://ubuntuforums.org/showthread.php?t=955243 http://www-numi.fnal.gov/offline_software/srt_public_context/WebDocs/Errors/unix_system_errors.html

So, the mystery is gone but the problem remains. Sorry if this isn't more helpful. -Paul

0

Check out the program xev to see if you're getting any input. You may not need it to be a MIDI device, but just to map the keys (xbindkeys) to other function buttons etc.

Useful Commands

xev -name GetKeys - Display a little box that monitors all input. Good for finding your mouses button numbers.

xbindkeys -k - Display a little box which you can highlight and press a key in to find out what it's called. Works for your keyboard.

xmodmap [file name] - modify or create keys. I'll get to this later

xbindkeys -f [file name] - pass a file into xbindkeys, and bind the keys to commands

xdotool - simulate a key press, you'll want this with your mouse

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .