aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xsupport/scripts/reset.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/support/scripts/reset.py b/support/scripts/reset.py
index 9be5607..ad26d10 100755
--- a/support/scripts/reset.py
+++ b/support/scripts/reset.py
@@ -3,6 +3,7 @@
import serial
import os
import sys
+import time
from struct import pack
def get_maple_device_path(file_prefix):
@@ -68,14 +69,20 @@ try:
# try to toggle DTR/RTS (old scheme)
ser.setRTS(0)
+ time.sleep(0.01)
ser.setDTR(0)
+ time.sleep(0.01)
ser.setDTR(1)
+ time.sleep(0.01)
ser.setDTR(0)
# try magic number
ser.setRTS(1)
+ time.sleep(0.01)
ser.setDTR(1)
+ time.sleep(0.01)
ser.setDTR(0)
+ time.sleep(0.01)
ser.write("1EAF")
# ok we're done here