You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Mbed CLI creates a `.uvprojx` file in the projectfiles/uvision folder. You can open the project file with uVision.
516
516
517
+
### Serial terminal
518
+
519
+
You can open a serial terminal to the COM port of a connected Mbed target (usually board) using the `mbed sterm` command. If no COM port is specified, Mbed CLI will attempt to detect the connected Mbed targets and their COM ports.
520
+
521
+
There are various options to `mbed sterm`:
522
+
*`--port <COM port>` to specify system COM port to connect to.
523
+
*`--baudrate <numeric>` to select the communication baudrate, where the default value is 9600.
524
+
*`--echo <on|off>` to switch local echo (default is `on`).
525
+
*`--reset` to reset the connected target by sending Break before opening the serial terminal.
526
+
527
+
You can also set default port, baudrate and echo mode using the `TERM_PORT`, `TERM_BAUDRATE` and `TERM_ECHO` Mbed CLI configuration options.
528
+
529
+
The following shortcuts are available within the serial terminal:
530
+
- Quit: `CTRL+C` or `CTRL+J`
531
+
- Reset: `CTRL+B` or `CTRL+R`
532
+
- Echo toggle: `CTRL+E`
533
+
- Terminal information: `TAB` or `CTRL+I`
534
+
- Help: `CTRL+H`
535
+
- Menu: `CTRL+T`
536
+
- Change baud rate: `CTRL+T+B`
537
+
538
+
To automate things, you can also add the `--sterm` option to `mbed compile -f` to compile a new program, flash the program/firmware image to the connected target and then open serial terminal to it's COM port:
539
+
540
+
```
541
+
$ mbed compile -t GCC_ARM -m K64F -f --sterm
542
+
```
543
+
517
544
## Testing
518
545
519
546
Use the `mbed test` command to compile and run tests.
error("The serial terminal functionality requires that the 'mbed-terminal' python module is installed.\nYou can install mbed-terminal by running 'pip install mbed-terminal'.", 1)
error("Unable to reset the target board connected to your system.\nThis might be caused by an old interface firmware.\nPlease check the board page for new firmware.", 1)
warning("If you're developing a new target, you can mock the device to continue your development. "
2685
-
"Use 'mbedls --mock ID:NAME' to do so (see 'mbedls --help' for more information)")
2686
-
else:
2687
-
error("This command requires that the 'mbed-greentea' python module is installed.\nYou can install mbed-greentea by running 'pip install mbed-greentea'.", 1)
2703
+
"Use 'mbedls --mock ID:NAME' to do so (see 'mbedls --help' for more information)")
0 commit comments