Don't bother with individual bytes because writing one at a time to an SD card will slow things down. The best way would be a have two buffers in RAM of perhaps 1024 bytes, and when one is full,...