I just got a pico. I placed the uf2 micropython file on it. The device then is unmounted from the system (Ubuntu 20.04). It is never automatically mounted back like all tutorials say.

Anyway, i unplug and plug it back in. I start thonny and type a simple program to test if my pico is working:

import machine
import utime

led_pin = machine.Pin(25, machine.Pin.OUT)

while True:

When i hit Run, it opens up a window in order to save the file somewhere. I select the external storage (that is pico). Note that it doesn't explicitly ask me whether i want to save the file to the computer or the pico - like all the tutorials i watched.

I save the file as blink.py, hit Run and i get an error that:

>>> %Run blink.py
Traceback (most recent call last):
  File "/media/user1/RPI-RP2/blink.py", line 1, in <module>
    import machine
ModuleNotFoundError: No module named 'machine'

I am not sure i understand what is going on, or if i am doing something wrong...

1 Answer 1


OK, i found the solution. I had installed thonny with:

sudo apt install thonny

This version does not support pico. Pico was not even in the list of the interpreters.

So i uninstalled it with: sudo apt remove thonny

I installed thonny with downloading this installer:

wget -O thonny-latest.sh https://thonny.org/installer-for-linux

Changed permissions with:

chmod +x thonny-latest.sh

And then the program was installed. I opened it. Then selected the pico interpreter from the Tools menu, and it even installed micropython on the pico itself.

Everything run smoothly.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.