 void loop() {
   // determine current state, condition, and fault
   state = determine_state();  // open/closed
-  condition = determine_cond(); // rain or not
+// next line removed because we are going to use analog rain triggering
+// condition = determine_cond(); // rain or not
   fault = determine_fault(); // check for motor fault
-  rain_mv = MILLIVOLTS_PER_COUNT * float(analogRead(APIN_RAIN));
   // print if there is a state change
   if (state != last_state) {
     if (state==STATE_OPENED) {

void setup() {
  // Start serial for input / output
  Serial.begin(9600);
  Serial.println("EM27Sun Cover Driver v1.2");
  // Set up for the Stepper motor
  stepper.setPinsInverted(true,false,true); // sets direction and enable pins inverted
  stepper.setMaxSpeed(USTEP_DIVISOR * STEP_SPEED);

        break;
      case '?':
        report_state();
        break;
      case 'v':
      case 'V':
        verbose_logging = !verbose_logging;
        if (verbose_logging) {
          Serial.println("User requested verbose logging");
        }
        else {
          Serial.println("Verbose logging is off");          
        }
        break;
      default:
        Serial.println("Command not recognized");
