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.
Dependents: WiFi neurGAI_WIFI thingspeak thingspeak2
Diff: Socket/TCPSocketServer.cpp
- Revision:
- 11:b912f91e3212
- Parent:
- 4:74bfdd00362a
- Child:
- 13:108340829acc
diff -r 81445de1fe27 -r b912f91e3212 Socket/TCPSocketServer.cpp --- a/Socket/TCPSocketServer.cpp Thu Aug 23 16:03:52 2012 +0000 +++ b/Socket/TCPSocketServer.cpp Fri Aug 24 13:07:01 2012 +0000 @@ -25,15 +25,14 @@ int TCPSocketServer::bind(int port) { // use udp auto pairing char cmd[20]; - if (!wifi->sendCommand("set ip proto 2\r", "AOK")) + /*if (!wifi->sendCommand("set ip proto 2\r", "AOK")) return -1; if (!wifi->sendCommand("set ip flags 0x07\r", "AOK")) - return -1; + return -1;*/ + wifi->setProtocol(TCP); sprintf(cmd, "set ip local %d\r", port); if (!wifi->sendCommand(cmd, "AOK")) return -1; - if (!wifi->sendCommand("save\r", "Stor")) - return -1; wifi->exit(); return 0; }