Making firmware (for rpi pico) using docker or rpi?

Basic Information:

Printer Model: Ender3KE
MCU / Printerboard: gd32f303xe
Host / SBC: Docker/Rpi 5

Describe your issue:

  • Rooted my Ender3KE and installed Mainsail using a helper script
  • The klipper installation on the Ender3KE doesn’t seem to contain any source or compilng utilities
  • I would like to connect a rpi pico (rp2040) as secondary mcu. I cannot use the ender3KE linux os to generate firmware file for the pico

Question:

  • How can I most easily generate a firmware image for the rpi pico/rp2040 mcu. I can probably do the flashing manually
  • Is a docker container / VM available for the same
  • I also have klipper running on a rpi 5 for an ender3 (older model) that I could potentially use for the same. But I don’t have access to it for a few days, so if there is a docker container I could use. Would prefer that.

Thank you! Wonderful project =)

ssh into your Pi, or go to whatever Linux instance you’re running

cd ~/klipper
make menuconfig

make clean
make

it’ll generate the uf2 file in the directory

cd ~/klipper/out

either FTP in and copy it somewhere you want it
Or just hook the Pi Pico up to your Pi/Host/Computer/Whatever is running Linux that you’re working under

Hold down the boot button on the RPI Pico when you connect it and it’ll put it into USB mode waiting for a UF2 file, just like a USB drive.

Mount it in Linux or it should pop up in Windows

Copy the UF2 from the “out” directory straight to the RPI Pico “drive” and it’ll flash itself.

Done

Edited to clarify RASPBERRY PI Pico. SKR Pico has a different flashing setup.

Just a correction, on the Pico, there isn’t a “Boot” button. There are two pins that need to have a jumper on them.

From the User Manual:

I should have clarified, the poster mentioned the Raspberry Pi Pico which has a bootsel button

But you’re correct, someone else could read that and think I meant the SKR Pico.

Best to be unambigious.

1 Like

Thank you all!

Is there also a dockerized way about this?

Honestly not sure, Anytime I tried to dip my toe into figuring out docker containers I quickly gave up. Way too complicated for my simple needs.

1 Like

For what it’s worth, I was also able to build the firmware using docker.

I followed the instructions here:

Essentially it needed just two commands once docker and docker compose were installed:

sudo docker compose -f docker-compose.extra.make.yaml run --rm make menuconfig

sudo docker compose -f docker-compose.extra.make.yaml run --rm make

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.