[PD] usb iobox comming - testers needed !

Christian Klippel ck at mamalala.de
Tue Feb 10 08:33:13 CET 2004

hello all,

first, sorry for cross-posting .....

second, sorry for the long posting ;-)

after a (way too) long time, i finally got the basic usb implementation of my 
multi-iobox working. that box will be the follow-up of the 88-port ad-module 
for the pc-perport i have done a long time ago.

wit the new usb version everybody should be able to use it, on any computer 
providing usb and a usb-hid (Human Interface Device) driver. that means, 
linux, os-x, windows .....

the box is not completely finished yet, but will be in about 1-2 months.
in fact, the usb implementation on the microcontoller took the most time ...
just put a look at the usb specs chapter9, plus the hid definition plus the 
hut (Hid Usage Tables) stuff ..... and you will get a impression ....

what's needed now are testers, that will try out the current usb-firmware of 
the microcontroller connected to different machines. to help me out with that 
you will currently need :

0.) a cimputer with usb and hid drivers (that means: if your comp can use a 
mouse/keyboard/joystick... on usb)

1.) a programmer that is cappable of burning the microchip pic 16c765 

2.) of course one if that microcontrollers, hard to get in germany, sorry.
be sure to get the -jw version, which is uv-erasable. otp-chips are a waste at 
the current state of my development.... remember, its just a test 

3.) the current test-firmware from http://mamalala.de/iobox-test.zip

4.) a small prototype board, a usb-b connector, a cable from usb-b to usb-a 
(to you computer) and led's (with 1k resistors), buttons and faders as 
needed. take look at the microcontrollers datasheet 
we need a 6 mhz xtal, portb is used to display led's, portd is used for 8 
buttons, an0-an7 as analogue inputs plus the two pwm outputs on rc1 and 

5.) pd or jmax with a event-device object (on jmax i made ev_dev, i think h.c. 
steiner has made a similar object for pd on linux)

after burning and assembling, the thing does the following :
on connecting to the computer, it enumarates to the host as hid device.
it sets up 64 led outputs, 64 single key inputs, 88 adc inputs, 64 dac outputs 
and a 3-byte in-/output. the adc out's are declared (by the device) as 
absolute events, the buttons and led's as what they are, respectively.
the dac is accessed as led, just with a 16 bit value range instead of the 
usual 1-bit on/off state .... the 3-byte in/out is done as one 3-byte wide 
button and a 3-byte wide led.

currently used by the chip (as this are the built-in capabilities) are 8 adc, 
2 dac (done by using the pwm outputs of the chip) , 8 buttons and 8 led's.
(see http://mamalala.de/iobox-test.jph how that looks in jmax)

that makes up the following events :

inputs: (from device to computer)
a:	type 1 (key) 
	code 256 - 263 (would be 256 - 319 in full version)
	range 0/1 (on/off)
b:	type 3 (abs. movement)
	code 6-13 (would be 6-92 in full version)
	range 0-255 (would be 0-255|1023|4095 in full version, depending on used adc)

outputs (all are type 17:led) 
a:	0-7 (would be 0-63 in full version)
	range 0/1 (on/off)
b:	64-65 (would be 64-127 in full version)
	range 0-256 (would be 0-255|1023|4095 in full version, depending on used dac)

the rawbyte in/out's do nothing yet, but will be used for thing like buffered 
midi in/out, serial in/out, rotary encoders, small lcd displays, [put your 
ideas here]....

now comes the point where i need your assistance :

please test if the device connects to your computer without error.

if you are on linux, test it's in/output. to send to the device in a propper 
way, you need a recent linux-usb driver. older ones (for example 2.4.18) dont 
include the report-id to the device, but we need that ;-) newer drivers do 
(as in linux 2.4.24 and up....)
all the i/o should be do-able by the standard linux event input device 
interface (evdev) and the linux usb-hid driver compiled to use that 

more important to me is, if you are on mac/windows/.... :
i cant supply objects for pd/jmax/... on these platforms.
but, from what i expect they should be easy to write. just access the hid 
interface of the host, it will give/take the reports as needed.....
for example, a usb-hid conform "driver" in source-form for a mouse, keyboard, 
joystick, tablet.... should provide a good basis for that.....
if you plug it into window, it already announces itself as unknown hid device.

please help, provide some objects for that thing !
all the linux stuff i will do myself, ev_dev is already there. what i will do 
next is a alsa-driver that wraps the device into a midi stream, for use wit 
other sequencer/synth apps. such a thing would be nice on other platforms 
too. imagine all midi-conform apps could use that thins faderbox, for 

ok, thats all for now. if you want to try that and help me out on that part,
drop me a note and "just do it". report back your experience....

thnaks a lot,


More information about the Pd-list mailing list