Rudder pedals

I want to build myself a pair of rudder pedals, but it looks like a daunting task with the arduino uno. Is there an arduino product that can communicate with the computer as a joystick by default?

If there is not an arduino that has this functionality out of the box, is there a simple tutorial for turning an arduino into a joystick with linux?

A quick look on google and this hit looks promising.

Am I misunderstandng something or does that permanently modify the Arduino IDE install?

flyingfisch: Am I misunderstandng something or does that permanently modify the Arduino IDE install?

A quick look and yes it does modify the IDE install but it appears it is only adding the Joystick HID to the existing Mouse & Keyboard HID's. If your unsure of this then download and extract the ZIP version of the IDE (Assuming Windows user), place it in a different location and add the modifications to that copy only. You will then have two separated versions of the IDE you can run. I do a similar thing where I have a vanilla IDE and one with Tiny cores & modified boards.txt to remove hardware I don't have.

Ok, will try that, I am a linux user though. ;)

I want to build myself a pair of rudder pedals, but it looks like a daunting task with the arduino uno. Is there an arduino product that can communicate with the computer as a joystick by default?

Make your rudder peddles using pots or joysticks like below.

http://www.ebay.com/itm/10x-B10K-Ohm-Linear-Taper-Rotary-Potentiometer-Panel-Pot-15mm-Shaft-Nuts-Washers-/291010300828?pt=LH_DefaultDomain_0&hash=item43c190cb9c

http://www.ebay.com/itm/3D-Analog-Joystick-Thumbstick-Module-Replacement-Part-For-PS2-Controller-/261239908711?pt=US_Video_Gaming_Replacement_Parts_Tools&hash=item3cd31ca967

zoomkat:

I want to build myself a pair of rudder pedals, but it looks like a daunting task with the arduino uno. Is there an arduino product that can communicate with the computer as a joystick by default?

Make your rudder peddles using pots or joysticks like below.

http://www.ebay.com/itm/10x-B10K-Ohm-Linear-Taper-Rotary-Potentiometer-Panel-Pot-15mm-Shaft-Nuts-Washers-/291010300828?pt=LH_DefaultDomain_0&hash=item43c190cb9c

http://www.ebay.com/itm/3D-Analog-Joystick-Thumbstick-Module-Replacement-Part-For-PS2-Controller-/261239908711?pt=US_Video_Gaming_Replacement_Parts_Tools&hash=item3cd31ca967

How would I make the computer recognize it as a rudder pedal though?

flyingfisch: How would I make the computer recognize it as a rudder pedal though?

I think the simple way is to use a Leonardo and follow the tutorial in the link supplied but if you get a dfu-programmer then you can re-program the USB to UART converter chip on an UNO so it looks like a Joystick instead of a serial port and use this

How would I make the computer recognize it as a rudder pedal though?

If you want to make rudder peddles for a pc, then skip the arduino and just modify a gamepad like below.

http://www.ebay.com/itm/Black-USB-Dual-Shock-PC-Computer-Wired-Gamepad-Game-Controller-Joystick-Joypad-/291035524239?pt=US_Video_Game_Controllers&hash=item43c311ac8f

OK, so that reply did not work, but what did work was this: http://forum.freetronics.com/viewtopic.php?f=27&t=734&start=10#p10806

What should I edit in HID.cpp to add a rudder axis (to make the whole thing plug-and-play)?

EDIT:

figured it out.

HID.cpp USBAPI.h

Sketch:

int x = 0;
int y = 0;
int z = 0;
int xrot = 0;
int yrot = 0;
int zrot = 0;
int throttle = 0;
int rudder = 0;
int buttons = 0;
int hatSw1 = 0;
int hatSw2 = 0;

void setup() {

}

void loop() {
    x = random(1,255);
    Joystick.move(x, y, z, xrot, yrot, zrot, throttle, rudder, buttons, hatSw1, hatSw2);
}

Sketch for rudder pedals, input at A0:

int x = 0;
int y = 0;
int z = 0;
int xrot = 0;
int yrot = 0;
int zrot = 0;
int throttle = 0;
int rudder = 0;
int buttons = 0;
int hatSw1 = 0;
int hatSw2 = 0;

void setup() {

}

void loop() {
    int rudder = analogRead(A0);
    rudder = map(rudder, 0, 1023, 0, 255);

    Joystick.move(x, y, z, xrot, yrot, zrot, throttle, rudder, buttons, hatSw1, hatSw2);
    delay(50);
}