Changing the PiPico boot mode from PowerShell

To put the Pi Pico into programming mode, you need to open a connection to it at its magic number port speed. This set of commands allows me to set the mode and upload an .ino file.

Note that the standard magic number is 1200 baud, but in this instance, I’m using 300 baud after making a change to the Arduino library.

First we need to define the port, with the connection speed:

$port300= new-Object System.IO.Ports.SerialPort COM11,300,None,8,one;

Now, whenever we want to write a new file to the Pico, we issue the following command:

taskkill -f -im kitty.exe; Start-Sleep -Seconds 0.25; $port300.Close(); $port300.Open(); arduino-cli compile --upload --fqbn rp2040:rp2040:rpipico --port UF2_Board .\k3ng_keyer.ino && kitty -serial COM11 115200

That’s it.

Lance

August ’24

Leave a Reply

Your email address will not be published. Required fields are marked *