WeMOS D1 mini: D1 read data

From OnnoWiki
Jump to navigation Jump to search
/*
 * D1 read data
 * 
 *
 * 
 */

void setup() {
  pinMode(D1,INPUT);
  // initialize serial communications at 9600 bps
  Serial.begin(9600);
}

void loop() {
  in = digitalRead(D1); 
  Serial.println(in); 
  Serial.println("\n"); 
  delay(1000);
}