a library to use GPRS like ethernet or wifi, which makes it possible to connect to the internet with your GPRS module

Dependencies:   BufferedSerial

Dependents:   ThinkSpeak_Test roam_v1 roam_v2 finalv3

Fork of GPRSInterface by wei zou

Revision:
9:38800611a613
Parent:
4:1142bdd07989
Child:
13:379ce1d51b88
--- a/Socket/TCPSocketConnection.cpp	Tue May 06 03:56:03 2014 +0000
+++ b/Socket/TCPSocketConnection.cpp	Mon Mar 09 07:25:05 2015 +0000
@@ -36,13 +36,16 @@
     }
 
     if (!gprs->connect(_sock_fd, TCP, host, port)) {
-        return false;
+        return -1;
     }
-    return true;
+    return 0;
 }
 
 bool TCPSocketConnection::is_connected(void)
 {
+    if (_sock_fd < 0) {
+        return false;
+    }
     return gprs->is_connected(_sock_fd);
 }