flush file buffer incrementally if needed
Merge branch 'mk2' of github.com:autosportlabs/RaceCapture-Pro_firmware into mk2