Skip to content

Commit 58341d5

Browse files
committed
Add function to set Modem timeout
1 parent eede758 commit 58341d5

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

libraries/WiFiS3/src/Modem.h

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,9 @@
99
/* uncomment this will allow debug for passthrough "binary" commands */
1010
#define MODEM_DEBUG_PASSTHROUGH
1111

12-
#define MODEM_TIMEOUT 10000
13-
#define MAX_BUFF_SIZE 128
12+
#define MODEM_TIMEOUT 10000
13+
#define EXTENDED_MODEM_TIMEOUT 60000
14+
#define MAX_BUFF_SIZE 128
1415

1516
#define DO_NOT_CHECK_CMD "NO_CMD_CHECK"
1617

@@ -62,6 +63,8 @@ class ModemClass {
6263
void debug(bool e) {enable_dbg = e;}
6364
#endif
6465

66+
void timeout(size_t timeout_ms) {_timeout = timeout_ms;}
67+
6568
private:
6669
bool buf_read(const std::string &cmd, std::string &data_res);
6770
bool delete_serial;

0 commit comments

Comments
 (0)