# How do I know if I flashed my pico correctly?

**URL:** <https://erlangforums.com/t/how-do-i-know-if-i-flashed-my-pico-correctly/4491>\
**Category:** AtomVM Forum\
**Tags:** atomvm-questions\
**Created:** [February 14, 2025, 10:51am UTC](https://erlangforums.com/t/how-do-i-know-if-i-flashed-my-pico-correctly/4491 "2025-02-14T10:51:36Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![kwando](https://erlangforums.com/user_avatar/erlangforums.com/kwando/32/1587_2.png) [@kwando](https://erlangforums.com/u/kwando)\
**Post date:** [February 14, 2025, 10:51am UTC](https://erlangforums.com/t/how-do-i-know-if-i-flashed-my-pico-correctly/4491/1 "2025-02-14T10:51:36Z")

</div>

I got a Pico W and I’m trying to get started with AtomWM. I downloaded `AtomVM-pico_w-v0.6.5.uf2` and `atomvmlib-v0.6.5.uf2` from GitHub and I moved them to the board with `cp`:

```erlang
cp AtomVM-pico_w-v0.6.5.uf2 /Volumes/RPI-RP2/.
cp atomvmlib-v0.6.5.uf2 /Volumes/RPI-RP2/.

```

I connected it to my Mac while pressing the button on it, and I could see it mounted at `/Volumes/RPI-RP2`.

How do I verify I did this part properly? The device automatically mounts it self at `/Volumes/RPI-RP2/` now even even the button is not pressed? Is that correct?

---

<div class="post-metadata">

**Author:** ![kwando](https://erlangforums.com/user_avatar/erlangforums.com/kwando/32/1587_2.png) [@kwando](https://erlangforums.com/u/kwando)\
**Post date:** [February 14, 2025, 12:18pm UTC](https://erlangforums.com/t/how-do-i-know-if-i-flashed-my-pico-correctly/4491/2 "2025-02-14T12:18:02Z")

</div>

I figured it out!

`minicom --dev /dev/cu.usbmodem101`

 ![Skärmavbild 2025-02-14 kl. 13.16.25](https://erlangforums.com/uploads/default/original/2X/2/259851f231bf75da87d012b17a5c0d9ebdea2c20.jpeg)

---

<div class="post-metadata">

**Author:** ![Winford](https://erlangforums.com/user_avatar/erlangforums.com/winford/32/1246_2.png) [@Winford](https://erlangforums.com/u/Winford)\
**Post date:** [February 14, 2025, 4:26pm UTC](https://erlangforums.com/t/how-do-i-know-if-i-flashed-my-pico-correctly/4491/3 "2025-02-14T16:26:27Z")

</div>

Glad you got that figured out already!

Sometimes the Pico DFU can be frustrating, the drag and drop (or cp in the terminal) upload method is probably easier for kids or anyone just getting into microcontrollers, but you get no confirmation that the firmware was copied to flash successfully, or error if there was a problem.

Fortunately this is only during uploading the VM and libraries. When it comes to flashing your application we tried to make sure the rebar3 and mix plugins give you helpful error messages if flashing didn’t work. You also will not need to do the fiddling around with unplugging and pressing the boot button while you plug the usb back in, both plugins will reset the device to bootloader mode automatically.

Hope the rest of your adventure goes smoothly, and if not don’t hesitate to ask for help or let us know where you are having trouble! The more feedback we get, the better we can make the experience for everyone.

---

<div class="post-metadata">

**Author:** ![Winford](https://erlangforums.com/user_avatar/erlangforums.com/winford/32/1246_2.png) [@Winford](https://erlangforums.com/u/Winford)\
**Post date:** [February 14, 2025, 4:37pm UTC](https://erlangforums.com/t/how-do-i-know-if-i-flashed-my-pico-correctly/4491/4 "2025-02-14T16:37:57Z")

</div>

> [@kwando](#):
>
> How do I verify I did this part properly? The device automatically mounts it self at `/Volumes/RPI-RP2/` now even even the button is not pressed? Is that correct?

This does make me slightly suspicious that maybe the libraries did not flash correctly… The VM is obviously there, (but hello\_world only relies on nif and/or bif functions in the VM). After flashing the device should show in /dev (I believe as a “modem” device on Mac, I use Linux and it presents a little differently there).

The initial flash of the VM is a 2 step process, first the VM. The device should unmount automatically after a few seconds, at which point you need to power cycle back into boot mode (with the button), and flash the libraries the second time the device mounts.

If you run into an error message that a particular function or module (that is part of the atomvmlib standard libraries) is undefined try reflashing just the libraries.

---

<div class="post-metadata">

**Author:** ![kwando](https://erlangforums.com/user_avatar/erlangforums.com/kwando/32/1587_2.png) [@kwando](https://erlangforums.com/u/kwando)\
**Post date:** [February 14, 2025, 7:10pm UTC](https://erlangforums.com/t/how-do-i-know-if-i-flashed-my-pico-correctly/4491/5 "2025-02-14T19:10:22Z")

</div>

I got the blinky program to run as well without uploading the VM or the libs again, so I suppose it was uploaded correctly.

I think it would be helpful to add some notice short notice about how to use `screen` or `minicom` to see the console output, would certainly help folks like me that are just getting their feet wet with working with these microcontrollers 🙂

In order to flash new code to the board I have to run `picotool reboot` while pressing the BOOTSEL button and running `rebar3 atomvm pico_flash`.  
Maybe I need to add picotool to my PATH for it to work automatically? I haven’t tried that yet.

In general I found it quite easy to get started with this and I’m looking forward to tinker with it. Would you recommend to use an ESP32 instead?

---

<div class="post-metadata">

**Author:** ![Winford](https://erlangforums.com/user_avatar/erlangforums.com/winford/32/1246_2.png) [@Winford](https://erlangforums.com/u/Winford)\
**Post date:** [February 14, 2025, 8:34pm UTC](https://erlangforums.com/t/how-do-i-know-if-i-flashed-my-pico-correctly/4491/6 "2025-02-14T20:34:14Z")

</div>

> [@kwando](#):
>
> I got the blinky program to run as well without uploading the VM or the libs again, so I suppose it was uploaded correctly.

Blinky also just uses nifs, you will know for sure when you try to use lists, or maps modules 😉

> [@kwando](#):
>
> I think it would be helpful to add some notice short notice about how to use `screen` or `minicom` to see the console output, would certainly help folks like me that are just getting their feet wet with working with these microcontrollers 🙂

We do cover this in the [Getting Started](https://www.atomvm.net/doc/main/getting-started-guide.html) section of the docs, but in the RP2xxx section we only list `screen` or `minicom` under the requirements for viewing the console, without going into their use. Adding a notice to the flash tasks of the rebar3 and mix plugins would be a nice idea too! Would you mind opening an issue (bonus points for a PR addressing it 😁) in the plugin repo so we don’t forget to do this?

> [@kwando](#):
>
> Maybe I need to add picotool to my PATH for it to work automatically? I haven’t tried that yet.

That will take care of it, it looks like I forgot to expose a way to specify the path to picotool, so presently it must be in the PATH.

> [@kwando](#):
>
> In general I found it quite easy to get started with this and I’m looking forward to tinker with it.

So glad to hear this! If you do find our [documentation](https://www.atomvm.net/doc/main) lacking, unclear, or incorrect in any way, please let us know. Same with any tooling or general user experience problems/suggestions. We really want to make microcontrollers easy for anyone familiar with the BEAM to get started with, and conversely we want this to be a good learning environment for MCU users to learn about the BEAM. There are a lot of Micropython users out there struggling with concurrency issues that would have their minds blown by all of the other strength of the BEAM, beyond just solving those concurrency problems.

> [@kwando](#):
>
> Would you recommend to use an ESP32 instead?

I would say use what you have to start with, but ESP32 support is considerably more mature than RP2. If you have an ESP32 on hand I would recommend using both! Many applications will work on both platforms without modification. There are many more peripheral drivers for ESP32 supported by AtomVM; I2C, SPI, ADC, LEDC, to name a few. The RP2 (both RP2040 and RP2350) currently only have GPIO driver, and a network driver for the Pico W. Network support for RP2350 (Pico 2W) is likely some time away, the task of adding the WiFI driver for the new devices was not a trivial change. I don’t want to discourage you from using the RP2 platform either, the only way these things improve is through use, testing, and user feedback. If we don’t get any issues opened on GitHub for the Pico it is easy for our small team to focus attention on other areas where we do get feedback 😉

---

<div class="post-metadata">

**Author:** ![kwando](https://erlangforums.com/user_avatar/erlangforums.com/kwando/32/1587_2.png) [@kwando](https://erlangforums.com/u/kwando)\
**Post date:** [February 15, 2025, 12:58pm UTC](https://erlangforums.com/t/how-do-i-know-if-i-flashed-my-pico-correctly/4491/7 "2025-02-15T12:58:09Z")

</div>

Got it running on both the pico W and an ESP32, got the network up and running the pico too!

I didn’t enjoy micropython at all, so that’s why I tried AtomVM on the pico board at first 🙂 I already feel more confident with atomvm than I ever did with that python toolchain. My endgoal is to run gleam code (which is basically Erlang) on AtomVM 🙂

Apparently I managed to get the libs installed also, since I could use the lists module.

Also, `picotool` and `esptool` is available via brew on Mac so I could have skipped the steps of compiling those things myself.

I had to abandon `minicom`, I could not figure out how to exit that thing (`kill` to the rescue). I had no luck with any of the keyboard shortcuts mentioned around the net, but `screen` works just fine though and it exits automatically when the serial port closes.

There is no 1-wire lib right? Didn’t see it listed near i2c,spi,uart etc in the docs. Do you think bit-banging it via GPIO would work on the pico/esp32? I have bunch of DS18B20 sensors that would be cool to read.

---

<div class="post-metadata">

**Author:** ![Winford](https://erlangforums.com/user_avatar/erlangforums.com/winford/32/1246_2.png) [@Winford](https://erlangforums.com/u/Winford)\
**Post date:** [February 15, 2025, 4:07pm UTC](https://erlangforums.com/t/how-do-i-know-if-i-flashed-my-pico-correctly/4491/8 "2025-02-15T16:07:24Z")

</div>

Wonderful! Glad you got both boards working! Since you got the pico WiFi working for you, I assume you have them talking to each other already?

> [@kwando](#):
>
> I didn’t enjoy micropython at all, so that’s why I tried AtomVM on the pico board at first 🙂 I already feel more confident with atomvm than I ever did with that python toolchain. My endgoal is to run gleam code (which is basically Erlang) on AtomVM 🙂

Hahaha , I had no idea you were one of the people I was taking about there! 😉 In this case I strongly recommend you “Learn You Some Erlang for Great Good!”!!! You can view it online for free at:

> **[Learn You Some Erlang for Great Good!](https://learnyousomeerlang.com/)**
>
> Learn you some Erlang for great good! An Erlang tutorial for beginners and others too.

I found it an extremely valuable resource! I have a hard copy that I often refer to, several years into my Erlang learning journey. 😁

> [@kwando](#):
>
> My endgoal is to run gleam code (which is basically Erlang) on AtomVM 🙂

Good timing! We should have some Gleam examples being merged into the AtomVM repo in the coming days, if not already by the time I write this… We should also have some added to the atomvm\_examples repo soon.

> [@kwando](#):
>
> I had to abandon `minicom`, I could not figure out how to exit that thing (`kill` to the rescue). I had no luck with any of the keyboard shortcuts mentioned around the net

You should be able to exit minicom by pressing:

`CTRL-a` (and then just) `x`

If that does not work pressing `CTRL-a` followed by `z` _should_ bring up the help menu. The help menu would show the shortcut for exit if it has been changed to another letter… This help menu is a bit misleading, you use the lowercase version of the letters (it displays them as capitals).

> [@kwando](#):
>
> There is no 1-wire lib right?

Correct, not yet anyway. I have never used 1-wire so I cannot give you a good answer for this yet. I would say you should [open an issue in the AtomVM](https://github.com/atomvm/AtomVM/issues) repo for 1-wire support. This will get the attention of more of the developers, and help us gauge interest. Someone might also be able to suggest a bit-bang workaround there, until a driver can be developed.

Thanks for all of your feedback so far! Looking forward to hearing about your future adventures. 😁
