Fix MacOS write error caused by unflushed buffer
This replaces the current sleep() with the operating system's flush() call to write out the buffer.
I can confirm this helps and works on macOS 11.1
It also improves operations' speed in my Debian Testing
Any news on merging this?
@kaysievers just a nitpick you could add a commit summary describing the issues of failed flashing attempts.
I could confirm that there is macos upload issue with bossac 1.9.1 . We have user report that we have to roll back to bossac 1.8
https://forums.adafruit.com/viewtopic.php?f=19&t=187831 https://forums.adafruit.com/viewtopic.php?f=57&t=187924