lotus



previous page: 10.1: CommNotifyProc
  
page up: Programming VCOMM FAQ
  
next page: 10.3: PortEscapeFunction

10.2: CommTimeouts




Description

This article is from the Programming VCOMM FAQ, by nelson@desktop.nsc.com (Taed Nelson) with numerous contributions by others.

10.2: CommTimeouts


Communications timeouts make use of the COMMTIMEOUTS structure in _PortData.
The timeouts and callbacks, when using COMMTIMEOUTS, are handled by VCOMM.

Unfortunately, this seems to only work for Win32 applications, such as
HyperTerminal. (Oddly enough, Dial-Up Networking does not make use of
CommTimeouts, but I'm not sure if it is due to it not being Win32 or something
else.)

Serial.vxd implements its own form of 100 ms timeouts for received characters.
This is implemented via escape functions that enable and disable the "timer
logic". This seems necessary for port drivers to implement if they want to
efficiently handle non-Win32 applications.

Apparently, when a Win32 application is running, VCOMM will disable the timer
logic via the escape function. I don't know if it automatically enables it
for non-Win32, or if it is up to the application.

[See also "dwLastReceivedTime".]


 

Continue to:















TOP
previous page: 10.1: CommNotifyProc
  
page up: Programming VCOMM FAQ
  
next page: 10.3: PortEscapeFunction