Run program on power up

I’ve tried creating the file “main.py” in just about every place I can think of. I’ve tried “/”, “/sd”, “/pyboard”, “/sd”, and “/sd/pyboard”. “/pyboard” is where I’ve read that it is supposed to go but that didn’t work. Since pico boards are used just about everywhere, I would think that getting one to run a program on power up would be easy. So, would anyone tell me the secret? Or point me to documentation that works?

I figured this out. It seems that the uf2 files have boot.py and/or main.py and trying to replace them was not the way to go. After I solved my problem using thonny, (imagine having two bad cables in a row! Finally a good one) I was able to put a version of micro python on the device and my own main.py file. All is good for now.