hi,
just to close this thread. everything is working. i got two sensors detecting different directions. each sensor causes a different midi signal (and a different soundfile to be played in the end). a little annoying is the fact that every soundfile is triggered 3 times each sensor detection. for i use very atmospheric sounds with a pretty long attack and release time it does not really matters.
here comes the code:
//this bases on the code for midi drumkit
// copyleft 2006 Tod E. Kurt <tod@todbot.com http://todbot.com/
// put together and rearranged by miksen for marcia at art academy duesseldorf 2008
//VARS
#define midichannel 1 //defines the channel we use for midi note on and off
#define note_box1 35 //define the midi note for first soundfile
#define note_box2 38 //defines the midi note for second soundfile
int calibrationTime = 30; //the time we give the sensor to calibrate (10-60sec)
long unsigned int lowln; //the time when the sensor outputs a low impulse
long unsigned int pause = 5000; //the amount of milliseconds has to be low before we assume no more motion is present
int pirsensorAPin = 7;
int pirsensorBPin = 8;
int ledPin = 13;
void setup() {
Serial.begin(31250); //MIDI baud rate
pinMode(pirsensorAPin, INPUT); //Sensor 1
pinMode(pirsensorBPin, INPUT); //Sensor 2
pinMode(ledPin, OUTPUT); //blinking LED indicates that midi data is send
digitalWrite(pirsensorAPin, LOW); //both sensors set to LOW
digitalWrite(pirsensorBPin, LOW); //no motion state
for(int i = 0; i < calibrationTime; i++){
delay(1000);
delay(50);
}
}
void loop() {
if(digitalRead(pirsensorAPin) ==HIGH){ //motion is detected
noteOn(midichannel, note_box1, 100); //midi note on is send
delay(500);
}
if(digitalRead(pirsensorAPin) == LOW ){ //no more motion
noteOff (midichannel, note_box1, 0); //midi note off is send
delay(500);
}
if(digitalRead(pirsensorBPin) ==HIGH){ // same for the second sensor
noteOn(midichannel, note_box2, 100);
delay(1000);
}
if(digitalRead(pirsensorBPin) == LOW ){ //same as above
noteOff (midichannel, note_box2, 0);
}
}
// Send a MIDI note-on message
void noteOn(byte channel, byte note, byte velocity){
midiMsg( (0x80 | (channel<<4)), note, velocity);
}
// Send a MIDI note-off message. Like releasing a piano key
void noteOff(byte channel, byte note, byte velocity) {
midiMsg( (0x80 | (channel<<4)), note, velocity);
}
// Send a general MIDI message
void midiMsg(byte cmd, byte data1, byte data2) {
digitalWrite(ledPin,HIGH); // indicate we’re sending MIDI data
Serial.print(cmd, BYTE);
Serial.print(data1, BYTE);
Serial.print(data2, BYTE);
digitalWrite(ledPin,LOW);
}
improvements are welcome…
thanks everybody who helped me out with this 
miksen