DS-MAP

Make your own Shift-Box

Warlord

  • *
  • 11
    • Talon TSI AWD
    • 1990
    • Head: 1G (large ports)
    • Motor: 4G63 2.0L
    • Turbo: T3/T4OE
Re: Make your own Shift-Box
« Reply #15 on: April 27, 2017, 11:33:43 PM »
I know this topic is old but incase anyone wants somewhere to start with making an Arduino controlled shift box or paddle shifters I wrote some simple code. You could also use this for any other vehicle thats an auto and uses solenoids to shift. I haven't tested the code and there might be errors but it'll point someone in the right direction that is to overwhelmed with attempting to learn Arudino programming.  Its all just assigning pins for being an input or output and basic "if" statements.  8;)

Arduino Code:

void setup() {
    int PaddleUp (2); //pin 2 shift up button
    int PaddleDown(3); //pin 3 shift down button
    int SolOne(4); //pin 4 shift solenoid output
    int SolTwo (5); //pin 5 shift solenoid output
   
}

void loop() {
    //define inputs and outputs
    pinMode(2, INPUT); //assigning pin 2 as an input
    pinMode(3, INPUT); //assigning pin 3 as an input
    pinMode(4, OUTPUT); //assigning pin 4 as an output
    pinMode(5, OUTPUT); //assigning pin 5 as an output
   
    //Low is off, High is on

    //Low,Low = 1st gear
    //High,Low = 2nd gear
    //High,High = 3rd gear
    //Low,High = 4th gear
   
    //Shift up sequences
    if (PaddleUp) == HIGH && SolOne == LOW && SolTwo == LOW {
        digitalout SolOne(HIGH)
        digitalout SolTwo(LOW)
    }
   
  if (PaddleUp) == HIGH && SolOne == HIGH && SolTwo == LOW {
        digitalout SolOne(HIGH)
        digitalout SolTwo(HIGH)
    }
   
  if (PaddleUp) == HIGH && SolOne == HIGH && SolTwo == HIGH {
        digitalout SolOne(LOW)
        digitalout SolTwo(HIGH)
    }
    //Shift down sequences
    if (PaddleDown) == HIGH && SolOne == LOW && SolTwo == HIGH {
        digitalout SolOne(HIGH)
        digitalout SolTwo(HIGH)
    }
if (PaddleDown) == HIGH && SolOne == HIGH && SolTwo == HIGH {
        digitalout SolOne(HIGH)
        digitalout SolTwo(LOW)
    }
if (PaddleDown) == HIGH && SolOne == HIGH && SolTwo == HIGH {
        digitalout SolOne(LOW)
        digitalout SolTwo(LOW)
    }
}
Retired 1990 snowcross rally car. Gutted, caged, fuel cell, Winebro 255, 660cc Denso, Garret T3/T4OE, AEM AFR, open DP, solid motor mounts, 4 bolt LSD, Bride seats, 4-point GForce harnesses, Custom M/T gear indicator, Hydro E-brake.