 #include <avr/io.h>
 #include <SoftwareSerial.h>
 #include <Adafruit_MotorShield.h>
+#include <Stepper.h>
 
 #define PHOTO_INTERRUPTER_PIN_1 2
 #define PHOTO_INTERRUPTER_PIN_2 3

void moveMotor(int motorNum)
{
    power_twi_enable();
    Adafruit_StepperMotor *motor;
    if (motorNum = 0) { motor = motor1; }
    else if (motorNum = 1) { motor = motor2; }
    motor->step(STEPS_TO_INCREMENT/2,FORWARD,DOUBLE);
    motor->step(STEPS_TO_INCREMENT,BACKWARD,DOUBLE);
    motor->release();
    power_twi_disable();
} //*/

    Serial.print(F("Replacing pellet #"));
    Serial.print(String(inputNum + 1));
    Serial.println(F("..."));
    moveMotor(inputNum);
    delay(500);
  }
  
  else if (PIStates[inputNum] == 0 & PIStates[inputNum] != lastStates[inputNum]) {
