Advertisement
Guest User

Untitled

a guest
Apr 20th, 2014
41
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.89 KB | None | 0 0
  1. // Print GPS link
  2.   if (inputstringComplete == true && inputString == gpspass) {
  3.     SendTextMessage();
  4.     //Serial.println("Current GPS Location:");
  5.     //Serial.println();
  6.     //Serial.print("https://www.google.com/maps/place/");
  7.     //Serial.print(gps.location.lat(), 6);
  8.     //Serial.print(",");
  9.     //Serial.print(gps.location.lng(), 6);
  10.     // clear the string:
  11.     inputString = "";
  12.     inputstringComplete = false;
  13.   }
  14.  
  15.  
  16.  
  17. //SendTextMessage()
  18. ///this function is to send a sms message
  19. void SendTextMessage()
  20. {
  21.   Serial.println("Current GPS Location:");
  22.   Serial.println();
  23.   Serial.print(F("https://www.google.com/maps/place/"));
  24.   Serial.print(gps.location.lat(), 6);
  25.   Serial.print(F(","));
  26.   Serial.print(gps.location.lng(), 6);
  27.   //end of message
  28.   delay(100);
  29.   Serial.println((char)26);//the ASCII code of the ctrl+z is 26
  30.   delay(100);
  31.   Serial.println();
  32.  
  33.  
  34. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement