Sending command over serial >64 bytes (>128 bytes)

If you rewrite your code by testing Serial.avalable() before read()ing the byte, I think you'll also solve the corruption problem.

(edit: while it's fascinating to mess with the core libraries, I'd leave this as an exercise to better understand the Arduino internals, not as a way to solve one's own bugs :slight_smile: )