Fri Jul 24, 2009 3:15 am
Fri Jul 24, 2009 5:33 am
void ReadPort()
{
DWORD dwRead;
char chRead[250];
// remember to adjust 250 according to the total data read
char *count = NULL;
/* flush the old values and fill with some arbitary symbol
thats most unlikely to appear in your data to know
the end point after reading */
memset(chRead,'\x91',250);
Sleep( 5L);
ReadFile(hComm, chRead, 250, &dwRead, NULL);
/* now chRead contains data . you can manipulate
it accoring to your needs now. */
}
Wed Jul 29, 2009 10:12 am
Codemiles.com is a participant in the Amazon Services LLC Associates Program, an affiliate advertising program designed to provide a means for sites to earn advertising fees by advertising and linking to Amazon.com
Powered by phpBB © phpBB Group.