Skip to content
Discussion options

Josverl
Jun 19, 2024
Collaborator Sponsor

You must be logged in to vote

This is what I use on Mac OS:

#!/usr/bin/env python3
# reset uc on given serial port by toggling rate to 1200
# -*- coding: utf-8 -*-

import sys
import time
import serial

com = serial.Serial(sys.argv[1], 1200, dsrdtr=True)
com.dtr = False
com.rts = False
time.sleep(0.2)
com.close()
time.sleep(4)

I nicked this code from someone on the Raspberry Pi forum, but the version I can find there is one in one of my posts.

On RP2040, you know that the reset has worked because you get a new R/w disk called RPI-RP2 attached

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@Josverl
Comment options

Josverl Jun 25, 2024
Collaborator Author Sponsor

@scruss
Comment options

@Josverl
Comment options

Josverl Jun 26, 2024
Collaborator Author Sponsor

Answer selected by Josverl
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants