Skip to content

Commit aa08b2f

Browse files
committed
cleanup: fixup 18b9df3
1 parent 33231bb commit aa08b2f

File tree

10 files changed

+26
-13
lines changed

10 files changed

+26
-13
lines changed

libraries/WiFiS3/src/Modem.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
#define RESULT_ERROR "ERROR\r\n"
55
#define RESULT_DATA "DATA\r\n"
66

7+
using namespace std;
8+
79
/* -------------------------------------------------------------------------- */
810
ModemClass::ModemClass(int tx, int rx) : beginned(false), delete_serial(false), _timeout(MODEM_TIMEOUT), trim_results(true), read_by_size(false) {
911
/* -------------------------------------------------------------------------- */

libraries/WiFiS3/src/Modem.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ class ModemClass {
2323

2424
void begin(int badurate = 115200);
2525
void end();
26-
bool write(const string &cmd, string &str, char * fmt, ...);
27-
void write_nowait(const string &cmd, string &str, char * fmt, ...);
26+
bool write(const std::string &cmd, std::string &str, char * fmt, ...);
27+
void write_nowait(const std::string &cmd, std::string &str, char * fmt, ...);
2828

2929
bool passthrough(const uint8_t *data, size_t size);
3030
void avoid_trim_results() {
@@ -44,14 +44,14 @@ class ModemClass {
4444
#endif
4545

4646
private:
47-
bool buf_read(const string &cmd, string &data_res);
47+
bool buf_read(const std::string &cmd, std::string &data_res);
4848
bool delete_serial;
4949
UART * _serial;
5050
unsigned long _timeout;
5151
uint8_t tx_buff[MAX_BUFF_SIZE];
5252
bool trim_results;
5353
bool read_by_size;
54-
bool read_by_size_finished(string &rx);
54+
bool read_by_size_finished(std::string &rx);
5555
};
5656

5757
extern ModemClass modem;

libraries/WiFiS3/src/WiFi.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#include "WiFi.h"
22

3+
using namespace std;
34

45
/* -------------------------------------------------------------------------- */
56
CWifi::CWifi() : _timeout(50000){

libraries/WiFiS3/src/WiFi.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,12 @@
1818

1919
class CAccessPoint {
2020
public:
21-
string ssid;
22-
string bssid;
21+
std::string ssid;
22+
std::string bssid;
2323
uint8_t uint_bssid[6];
24-
string rssi;
25-
string channel;
26-
string encryption_mode;
24+
std::string rssi;
25+
std::string channel;
26+
std::string encryption_mode;
2727
};
2828

2929

@@ -34,7 +34,7 @@ class CWifi {
3434
void _config(IPAddress local_ip, IPAddress gateway, IPAddress subnet, IPAddress dns1, IPAddress dns2);
3535
unsigned long _timeout;
3636
uint8_t mac[6];
37-
vector<CAccessPoint> access_points;
37+
std::vector<CAccessPoint> access_points;
3838

3939

4040
IPAddress ip_ap = DEFAULT_IP_AP_ADDRESS;

libraries/WiFiS3/src/WiFiClient.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,16 @@
11
#include "WiFiClient.h"
22

3+
using namespace std;
4+
35
/* -------------------------------------------------------------------------- */
46
WiFiClient::WiFiClient() : _sock(-1), destroy_at_distructor(true), rx_buffer(nullptr) {
5-
rx_buffer = shared_ptr<FifoBuffer<uint8_t,RX_BUFFER_DIM>>(new FifoBuffer<uint8_t,RX_BUFFER_DIM>());
7+
rx_buffer = std::shared_ptr<FifoBuffer<uint8_t,RX_BUFFER_DIM>>(new FifoBuffer<uint8_t,RX_BUFFER_DIM>());
68
}
79
/* -------------------------------------------------------------------------- */
810

911
/* -------------------------------------------------------------------------- */
1012
WiFiClient::WiFiClient(int s) : _sock(s), destroy_at_distructor(false), rx_buffer(nullptr) {
11-
rx_buffer = shared_ptr<FifoBuffer<uint8_t,RX_BUFFER_DIM>>(new FifoBuffer<uint8_t,RX_BUFFER_DIM>());
13+
rx_buffer = std::shared_ptr<FifoBuffer<uint8_t,RX_BUFFER_DIM>>(new FifoBuffer<uint8_t,RX_BUFFER_DIM>());
1214
}
1315
/* -------------------------------------------------------------------------- */
1416

libraries/WiFiS3/src/WiFiClient.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ class WiFiClient : public Client {
6565
protected:
6666
int _sock;
6767
void getSocket();
68-
shared_ptr<FifoBuffer<uint8_t,RX_BUFFER_DIM>> rx_buffer;
68+
std::shared_ptr<FifoBuffer<uint8_t,RX_BUFFER_DIM>> rx_buffer;
6969
int _read();
7070
bool read_needed(size_t s);
7171
void clear_buffer();

libraries/WiFiS3/src/WiFiFileSystem.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
#include "WiFiFileSystem.h"
22

3+
using namespace std;
4+
35
/* -------------------------------------------------------------------------- */
46
WiFiFileSystem::WiFiFileSystem() {
57
/* -------------------------------------------------------------------------- */

libraries/WiFiS3/src/WiFiSSLClient.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
#include "WiFiSSLClient.h"
22

3+
using namespace std;
4+
35
/* -------------------------------------------------------------------------- */
46
WiFiSSLClient::WiFiSSLClient() : _sock(-1){
57
/* -------------------------------------------------------------------------- */

libraries/WiFiS3/src/WiFiServer.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
#include "WiFiServer.h"
22

3+
using namespace std;
4+
35
/* -------------------------------------------------------------------------- */
46
WiFiServer::WiFiServer() : _sock(-1), _port(80) {}
57
/* -------------------------------------------------------------------------- */

libraries/WiFiS3/src/WiFiUdp.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
#include "WiFiUdp.h"
22

3+
using namespace std;
4+
35
/* -------------------------------------------------------------------------- */
46
WiFiUDP::WiFiUDP() : _sock(-1) {
57
/* -------------------------------------------------------------------------- */

0 commit comments

Comments
 (0)