I see where you're getting at.
So I'm looking for a way to get byte(FF)+timestamp+byte(FF) into a buffer so I can use fwrite to get that buffer into the file.
Trying to create a buffer for the FF byte should be something like this I suppose:
Code:
CHAR byteBuffer[1];
byteBuffer[0] = 255;
printf("byteBuffer: %X \n", byteBuffer);
But it is not working as expected:
Output: "byteBuffer: BFFFF48F"
Expected: "byteBuffer: FF"
How do I tell C that 255 is a single byte value?