 }
 
 void adjust1(float v){
-  if (v < 1){
+  if (v < volRedHigh && v > volRedLow){
     showRed1();
-  }else if (v > 1.01 && v < 2.0) {
+  }else if (v > volGreenLow && v < volGreenHigh) {
     showGreen1();
   } else {
-    turnOff1();
+    turnOff();
   }
 }
 


int ledRed1 = 50;
int ledGreen1 = 52;

int ledRed2 = 22;
int ledGreen2 = 24;

void setup() {                
  Serial.begin(9600);
  
  pinMode(ledRed1, OUTPUT);     
  pinMode(ledGreen1, OUTPUT); 
  
  pinMode(ledRed2, OUTPUT);     
  pinMode(ledGreen2, OUTPUT);  
}

// the loop routine runs over and over again forever:

  }else if (v > 1.01 && v < 2.0) {
    showGreen2();
  } else {
    turnOff();
  }
}

void showRed1(){
  shift.setRegisterPin(green1, LOW);   
  shift.setRegisterPin(red1, HIGH);  
  shift.writeRegisters();
}

void showGreen1(){
  shift.setRegisterPin(green1, HIGH);   
  shift.setRegisterPin(red1, LOW);   
  shift.writeRegisters();
}

void showRed2(){
  shift.setRegisterPin(green2, LOW);   
  shift.setRegisterPin(red2, HIGH);  
  shift.writeRegisters();
}

void showGreen2(){
  shift.setRegisterPin(green2, HIGH);   
  shift.setRegisterPin(red2, LOW);   
  shift.writeRegisters();
}

void turnOff(){
  shift.clearRegisters();
  shift.writeRegisters();  
}

