The old code is no more needed when using overlapped I/O, getOverlappedEvent() returns all required error codes. Calling getCommState()/setCommState() every second in some applications contributes to other downstream issues. For examples: https://github.com/bugst/go-serial/issues/60#issuecomment-625749122 https://github.com/arduino/arduino-ide/issues/375
12 KiB
12 KiB