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.
Fork of MTS-Cellular by
Diff: Cellular/UIP.cpp
- Revision:
- 8:2d7259d244d1
- Parent:
- 7:0ee8e69a3e9c
- Child:
- 9:1a03e3f3e7fe
--- a/Cellular/UIP.cpp Wed May 21 15:21:25 2014 -0500 +++ b/Cellular/UIP.cpp Wed May 21 15:28:37 2014 -0500 @@ -35,17 +35,15 @@ bool UIP::init(MTSBufferedIO* io) { - if (io == NULL) { + if (! Cellular::init(io)) { return false; } - this->io = io; - test(); // Reset radio to make sure it's in a good state and wait for it to come back reset(); test(); - return SUCCESS; + return true; } bool UIP::configureSignals(PinName DCD, PinName DTR, PinName RESET) @@ -574,22 +572,6 @@ return code; } -Code UIP::setApn(const std::string& apn) -{ - Code code = sendBasicCommand("AT#APNSERV=\"" + apn + "\"", 1000); - if (code != SUCCESS) { - return code; - } - this->apn = apn; - return code; -} - - -Code UIP::setDns(const std::string& primary, const std::string& secondary) -{ - return sendBasicCommand("AT#DNS=1," + primary + "," + secondary, 1000); -} - bool UIP::ping(const std::string& address) { char buffer[256] = {0}; @@ -724,4 +706,4 @@ } while (!done); return result; -} \ No newline at end of file +}