Commit 4fd7c1a2 authored by Damien George's avatar Damien George
Browse files

tools, Write data to pyboard in chunks of 256 bytes.

This speeds up writes significantly.
parent 2870d85a
......@@ -104,8 +104,8 @@ class Pyboard:
command_bytes = bytes(command, encoding='ascii')
# write command
for i in range(0, len(command_bytes), 32):
self.serial.write(command_bytes[i:min(i+32, len(command_bytes))])
for i in range(0, len(command_bytes), 256):
self.serial.write(command_bytes[i:min(i + 256, len(command_bytes))])
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment