The contents of the file flow.c were found in the avrdude project. They look like they may be a good starting point for serial communication on windows.