         rain_counter_reset = false ;
     }
 
-    // @todo send SMS 
-
-}
-
-void pat_watchdog() {
+#if !defined(AWS_NO_GSM)
+    gsmSerial.print("\r");  
+    micro_delay(20);
+    gsmSerial.print("AT+CMGF=1\r");
+    micro_delay(20);
+    gsmSerial.print("AT+CMGS=\"+918553518338\"\r"); 
+    micro_delay(20);
+    // pat watchdog
     wdt_reset();
+
+    gsmSerial.print("Yuktix H");
+    if(dht22_code !=  DHT_ERROR_NONE) { 
+        gsmSerial.println("ERR");
+        gsmSerial.print(dht22_code);
+        
+    } else {
+        gsmSerial.println(humidity);
+        gsmSerial.print(" T");
+        gsmSerial.print(dht22_temp);
+    }
+
+    gsmSerial.print(" P");
+    gsmSerial.print(pressure);
+    gsmSerial.print(" R");
+    gsmSerial.print(total_rain);
+    gsmSerial.println();
+    gsmSerial.write(0x1A);
+    micro_delay(100); 
+    // pat watchdog
+    wdt_reset();
+
+#endif
+
 }
 
 void calculate_rain() {

#include <DS1307RTC.h>
#include <AWS.h>



#define DHT22_PIN 6
#define AWS_NO_SERIAL 1 


    // sync interval is default 5 minutes

    rtc_code = init_rtc(__TIME__,__DATE__);
    micro_delay(20);

    if(rtc_code == AWS_RTC_ERROR_NONE) {
        setSyncProvider(RTC.get);   
        if(timeStatus()!= timeSet) {
            // wait a bit
            micro_delay(400);
        }

        // try again
