implement iterator on reader (serial rx)
This commit is contained in:
parent
792eef13ba
commit
08c5cabe6d
2 changed files with 91 additions and 43 deletions
|
@ -271,7 +271,7 @@ impl Command {
|
|||
}
|
||||
}
|
||||
|
||||
pub fn tcp_send(size: usize) -> Command {
|
||||
pub fn tcp_send_size(size: usize) -> Command {
|
||||
Command {
|
||||
text: format!("AT+CIPSEND={}", size),
|
||||
timeout: Duration::from_millis(3000),
|
||||
|
@ -279,11 +279,11 @@ impl Command {
|
|||
}
|
||||
}
|
||||
|
||||
pub fn tcp_write(payload: &str) -> Command {
|
||||
pub fn tcp_send() -> Command {
|
||||
Command {
|
||||
text: payload.to_string(),
|
||||
timeout: Duration::from_millis(2000),
|
||||
contains: Some("> ".to_string()),
|
||||
text: "AT+CIPSEND".to_string(),
|
||||
timeout: Duration::from_millis(3000),
|
||||
contains: Some(">".to_string()),
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue