Serial Port Communications (Error 995) from ReadFile

1332 views
Skip to first unread message

Todd Williams

unread,
Jan 14, 2003, 5:52:20 PM1/14/03
to
I have a Multi-Threaded MFC App that uses the Win32 API for serial port
communication. The App uses Overlapped I/O In the WriteFile( )and
ReadFile( ) API calls.

The Problem I have is, one of the Modems I'm using gets an "Error 995" on a
ReadFile() during communication.
This is a Microsoft System Error that say's "The I/O operation has been
aborted because of either a thread exit or application request."

None of the threads exit so I'm not sure if this is a heap problem or
something else.

Can anyone help?

Thanks Todd


Farooque Khan

unread,
Jan 15, 2003, 12:34:12 AM1/15/03
to

May be you are hit by a communication time out. See SetCommTimeouts()

-Farooque

"Todd Williams" <twil...@napcosecurity.com> wrote in message
news:eXod$9BvCHA.2288@TK2MSFTNGP09...

arkadyf

unread,
Jan 15, 2003, 10:48:29 AM1/15/03
to
Maybe few threads try to open the same port ?
Arkady

"Farooque Khan" <farooquek-at-concretioindia-dot-com> wrote in message
news:OYYr1XFvCHA.2668@TK2MSFTNGP12...

Todd Williams

unread,
Jan 16, 2003, 1:09:37 PM1/16/03
to

Changing the timeout values did fix one of my problems. But I'm still
getting "Error 995".

Thanks Todd

"Farooque Khan" <farooquek-at-concretioindia-dot-com> wrote in message
news:OYYr1XFvCHA.2668@TK2MSFTNGP12...

john.jen...@gmail.com

unread,
Jun 20, 2014, 8:14:08 PM6/20/14
to
Changing the Comm Time Outs as you suggest just fixed this problem for me.
Thanks a lot!
Reply all
Reply to author
Forward
0 new messages