   state = determine_state();  // open/closed
   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) {

// Rain 
#define DPIN_RAIN 12           
// input from rain sensor (digital)

// Global variables


  if (condition == COND_RAIN){
    Serial.print("condition = rain ");    
  }
  Serial.print("Analog Rain Signal = ");
  Serial.print(int(rain_mv));
  Serial.println("mV");
}

int determine_state() {
