No, you're not really missing anything: you can use [man]fopen[/man], [man]fread[/man] and the rest to write binary files the same as any other. You might want to look at [man]pack[/man] and [man]sprintf[/man] to make turning data into binary a bit easier.