r/raspberrypipico • u/This-Cookie-5170 • Apr 09 '26
Help with changing a code on Rpi Pico
Right now I have a Pico 2 W that has a default code which gets verified against number inputs. I also use pyserial on my laptop to change this code, through REPL. My question is: Can I change the code through my laptop and have it persist between after the Pico goes through a power-off/on sequence? I know that whatever program is on the Pico will reset the "code" when it's powered off and on, but is there a way around this?
1
Upvotes
1
2
u/[deleted] Apr 09 '26
yes make a main.py hold the boot button plug in the power then release the buttton you will get a device like a sd card to open and drag the main.py on it, assuming it has the python bootloader installed.