Pure Data to Arduino to Digipot (AD5206)

Hi!
I'm making a hardware interface so i can control effect pedals and circuit bent toys from Pure Data. I'm using a AD5206 digital potentiometer which i'm controlling via the Arduino by serial SPI communication. I have it working for 1 of the 6 digital potentiometers the AD5206 offers by sending a simple integer from PD to the Arduino but when i try sending different values to different pots it doesn't.
I'm pretty new to C and Arduino and specially variable handling though serial, so if anybody had some pointers to where to start to gain more knowledge, 'cause i'm drawing a blank.

My hardware setup on the Arduino looks like this https://dl.dropbox.com/u/77719586/arduino.forum/ad5206.jpg
Here's the sketch i've uploaded to the Arduino https://dl.dropbox.com/u/77719586/arduino.forum/ad5206/ad5206.ino
My PD progam is just for testing purposes and looks like this https://dl.dropbox.com/u/77719586/arduino.forum/pd2ard6x.pd

I've mainly been working of this tutorial http://arduino.cc/en/Tutorial/SPIDigitalPot and this datasheet http://www.analog.com/static/imported-files/data_sheets/AD5204_5206.pdf

Hope you guys and gals can point me in the right direction :slight_smile:

Bjørn

here's the working ones https://dl.dropbox.com/u/77719586/arduino.forum/pd2ard/pd2ard.ino and https://dl.dropbox.com/u/77719586/arduino.forum/pd2ard.pd

no one? :frowning: