water sansor 1

Dependencies:   mbed

Revision:
0:2b430503298a
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/watersensor.h	Fri Oct 27 03:54:15 2017 +0000
@@ -0,0 +1,15 @@
+const int VAL_PROBE = 0;
+const int ledPin = 13;
+
+void setup(){
+  pinMode(ledPin,OUTPUT); 
+  pinMode(sensor_in,INPUT); 
+}
+
+void loop(){
+   if(digitalRead(sensor_in)== LOW){
+        digitalWrite(ledPin,HIGH); 
+     }else{
+        digitalWrite(ledPin,LOW); 
+     }
+}
\ No newline at end of file