outputting to a joypad

hiya,

right, the project i'm doing at the moment is change the hardware in a dancing machine... its an EZ2Dancer machine, very old hardware in it running on windows 98 XD

there are 8 hand sensors and 24 foot pressure sensors

the hand sensors are a simple analog switch, when you break the beam it changes the resistance...

i've managed to get the arduino to pick up the hand sensor which is brilliant, but now i want to output it to a joypad as a digital signal so i can use it like a button press

here's an image of the wiring..
i'll post as a reply

Orange - 5v
Green - Analog pin 0
Resistor - gnd
Blue - gnd on hand sensor
Blue/White - output on hand sensor

here's the code

#define LED 13

int val = 0;

void setup()
{
pinMode(LED, OUTPUT);
Serial.begin(9600);
}

void loop()
{
val = analogRead(0);
if (val >= 1)
{
digitalWrite(LED,HIGH);
}
else
{
digitalWrite(LED,LOW);
}
Serial.println(val);
}

any ideas?? i'm quite stumped on this now XD

i've managed to get the arduino to pick up the hand sensor which is brilliant, but now i want to output it to a joypad as a digital signal so i can use it like a button press

"Output it." What is it?

A joypad? What's a joypad?

any ideas??

I'd suggest that you tell us what the problem is.

To my mind a joypad is like a joystick only it uses push switches. In which case it is a device that outputs signals not something you output to. Do you mean emulate a joypad with the arduino, that is make what ever is connected to it think it has a joy pad attached. If so what are you connecting it to?