LinuxCommandLibrary

mpremote

microPython remote control tool

TLDR

Connect to device

$ mpremote
copy
Run Python code
$ mpremote exec "[print('hello')]"
copy
Copy file to device
$ mpremote cp [local.py] :[remote.py]
copy
Copy file from device
$ mpremote cp :[remote.py] [local.py]
copy
Run script on device
$ mpremote run [script.py]
copy
Enter REPL
$ mpremote repl
copy
List files on device
$ mpremote ls
copy
Mount local directory
$ mpremote mount [.]
copy

SYNOPSIS

mpremote [command] [options]

DESCRIPTION

mpremote is the MicroPython remote control tool. It manages MicroPython devices.
The tool copies files, runs code, and provides REPL access. Works over USB serial.

PARAMETERS

COMMAND

Operation to perform.
connect DEVICE
Connect to specific device.
exec CODE
Execute Python code.
cp SRC DST
Copy files (: prefix for device).
run FILE
Run local script on device.
repl
Enter interactive REPL.
--help
Display help information.

CAVEATS

Requires MicroPython device. Serial connection needed. Python 3 required.

HISTORY

mpremote was developed by the MicroPython project as the official device management tool.

SEE ALSO

rshell(1), ampy(1), python(1)

> TERMINAL_GEAR

Curated for the Linux community

Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community