rpi-pico-w/upython/uart.py 2025-07-26
Any
print()
command ends up on the USB, and is shown on the computer via programs such as ampy get back.However, you can also send data over actual UART.
We managed to get it working based on: timhanewich.medium.com/using-uart-between-a-raspberry-pi-pico-and-raspberry-pi-3b-raspbian-71095d1b259f with the help of a DSD TECH USB to TTL Serial Converter CP2102 just as shown at: stackoverflow.com/questions/16040128/hook-up-raspberry-pi-via-ethernet-to-laptop-without-router/39086537#39086537 for the RPI.
How to run a MicroPython script from a file on the Raspberry Pi Pico W from the command line? Updated 2025-07-26
The first/only way Ciro could find was with ampy: stackoverflow.com/questions/74150782/how-to-run-a-micropython-host-script-file-on-the-raspbery-pi-pico-from-the-host/74150783#74150783 That just worked and it worked perfectly!
pipx install adafruit-ampy
ampy --port /dev/ttyACM0 run blink.py
Program Raspberry Pi Pico W with MicroPython Updated 2025-07-26
Then there are two appraoches:
- thonny if you like clicking mouse buttons:and select the interpreter as the Pico.
pipx install thonny
- ampy if you like things to just run from the CLI: How to run a MicroPython script from a file on the Raspberry Pi Pico W from the command line?
Raspberry Pi Pico W UART Updated 2025-07-16
You can connect form an Ubuntu 22.04 host as:When in but be aware of: Raspberry Pi Pico W freezes a few seconds after after screen disconnects from UART.
screen /dev/ttyACM0 115200
screen
, you can Ctrl + C to kill main.py
, and then execution stops and you are left in a Python shell. From there:- Ctrl + D: reboots
- Ctrl + A K: kills the GNU screen window. Execution continues normally
Other options:
- ampy
run
command, which solves How to run a MicroPython script from a file on the Raspberry Pi Pico W from the command line?