0

I am using a rapberry pi pico to read the temprature from a k-type thermocouple. in the code, I added a while loop, but no way to break it, and I also named it main.py. the code automatically runs on startup, and I cant stop it. I've tried to stop it in thonny and pressing CTRL+C. it keeps saying the pico is busy, and I have to wait till the program ends. I tried to open it in storage mode, but it continues to run the script. I also soldered a wire to the TP6 pad to make sure the bootsel button wasnt broken. still nothing. I think I have to flash RenameMainDotPy to the pico, but I'm not sure how to do that as the pico wont open in storage mode.

any help would be greatly appreciated.

Ezra
  • 19
  • 8
  • I would start by just using a simple serial communication program (I like [`picocom`](https://github.com/npat-efault/picocom), which is packaged for most distributions) and using that to send a ^c. Worst case, you should be able to just re-flash the firmware following [the instructions](https://micropython.org/download/rp2-pico/). – larsks Sep 18 '22 at 01:20
  • Another reason to use the SDK `:)` Seriously, If you have a 2nd, you can use it as a debug-probe running `picoprobe` (you can compile with SDK). See the write-up at [Pico Debugging](https://www.digikey.com/en/maker/projects/raspberry-pi-pico-and-rp2040-cc-part-2-debugging-with-vs-code/470abc7efb07432b82c95f6f67f184c0) or see [Getting Started with Pico - Appendix A](https://datasheets.raspberrypi.com/pico/getting-started-with-pico.pdf) You can re-flash that way as well. – David C. Rankin Sep 18 '22 at 01:37

0 Answers0