diff options
author | Kevin O'Connor <kevin@koconnor.net> | 2017-10-12 21:21:49 -0400 |
---|---|---|
committer | Kevin O'Connor <kevin@koconnor.net> | 2017-10-12 21:46:09 -0400 |
commit | e0f275cddf55fb1afd21bb66c22e3c2a25d8d247 (patch) | |
tree | 4b38b3c532a05ebd30c516bb935c4e10399be828 /klippy/serialhdl.py | |
parent | 07a69df62f7a3470329a3ea0ba1e569ab0e9d0fe (diff) | |
download | kutter-e0f275cddf55fb1afd21bb66c22e3c2a25d8d247.tar.gz kutter-e0f275cddf55fb1afd21bb66c22e3c2a25d8d247.tar.xz kutter-e0f275cddf55fb1afd21bb66c22e3c2a25d8d247.zip |
serialhdl: Don't open port at 1200 baud
The 1200 baud trick on the Arduino Due does both a reset and an
erase. The erase is not desired.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'klippy/serialhdl.py')
-rw-r--r-- | klippy/serialhdl.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/klippy/serialhdl.py b/klippy/serialhdl.py index 8d6d6a7f..e7e35bf8 100644 --- a/klippy/serialhdl.py +++ b/klippy/serialhdl.py @@ -272,11 +272,11 @@ def stk500v2_leave(ser, reactor): # Attempt an arduino style reset on a serial port def arduino_reset(serialport, reactor): - # First try opening the port at 1200 baud - ser = serial.Serial(serialport, 1200, timeout=0) + # First try opening the port at a different baud + ser = serial.Serial(serialport, 2400, timeout=0) ser.read(1) reactor.pause(reactor.monotonic() + 0.100) - # Then try toggling DTR + # Then toggle DTR ser.dtr = True reactor.pause(reactor.monotonic() + 0.100) ser.dtr = False |