pio_monitor_read
Read new serial output from an active PlatformIO monitor session. Use a regex to wait for specific messages or set a timeout to fetch at least one new line.
Instructions
Read new serial lines from a session since cursor (start at 0) and get the next cursor back. Set wait_for to a regex to block up to timeout_s until a matching line arrives (e.g. wait_for='setup done|Guru Meditation'). Without wait_for and with timeout_s>0 it waits for at least one new line.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cursor | No | ||
| wait_for | No | ||
| max_lines | No | ||
| timeout_s | No | ||
| session_id | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||