diff --git a/src/command.rs b/src/command.rs index 73470d9..a007a23 100644 --- a/src/command.rs +++ b/src/command.rs @@ -279,6 +279,22 @@ impl Command { } } + pub fn tcp_transparent_mode() -> Command { + Command { + text: "AT+CIPMODE=1".to_string(), + timeout: Duration::from_millis(3000), + contains: Some("OK".to_string()), + } + } + + pub fn tcp_exit_data_mode() -> Command { + Command { + text: "ATO".to_string(), + timeout: Duration::from_millis(3000), + contains: Some("CLOSED".to_string()), + } + } + pub fn tcp_send() -> Command { Command { text: "AT+CIPSEND".to_string(),