aboutsummaryrefslogtreecommitdiffstats
path: root/support/scripts/reset.py
diff options
context:
space:
mode:
Diffstat (limited to 'support/scripts/reset.py')
-rwxr-xr-xsupport/scripts/reset.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/support/scripts/reset.py b/support/scripts/reset.py
index e4d0e99..7594845 100755
--- a/support/scripts/reset.py
+++ b/support/scripts/reset.py
@@ -2,9 +2,9 @@
import serial
import os
-
+from struct import pack
try:
- ser = serial.Serial('/dev/maple', baudrate=115200)
+ ser = serial.Serial('/dev/ttyACM0', baudrate=115200)
ser.open()
# pull dtr and rts low
@@ -13,6 +13,10 @@ try:
# toggle DTR
ser.setDTR(1)
+ ser.setDTR(0)
+
+ programDelay = pack("b",35)
+ ser.write(programDelay)
# close
ser.close()