Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: Chemical_Sensor_DMA GPRS DPG_FINAL MBed_Adafruit-GPS-Library SDFileSystem Socket mbed
Diff: Socket/TCPSocketConnection.cpp
- Revision:
- 21:3d922bea5d77
- Parent:
- 19:404594768414
diff -r 84661ac75715 -r 3d922bea5d77 Socket/TCPSocketConnection.cpp
--- a/Socket/TCPSocketConnection.cpp Wed Oct 21 19:46:32 2015 +0000
+++ b/Socket/TCPSocketConnection.cpp Fri Nov 06 20:53:59 2015 +0000
@@ -48,7 +48,8 @@
}
int TCPSocketConnection::send(char* data, int length)
-{
+{
+ printf("Current Socket is %d \r\n", _sock_fd);
int size = gprs->wait_writeable(_sock_fd, length);
if (size < 0) {
return -1;
@@ -63,7 +64,10 @@
{
return send(data,length);
}
-
+void TCPSocketConnection::setSocket(int currentSocket)
+{
+ _sock_fd = currentSocket;
+}
int TCPSocketConnection::receive(char* data, int length)
{
#if 0