PortRead


cCall [pPortRead], <hPort, <OFFSET32 achBuffer>, \
    cchRequested, <OFFSET32 cchReceived>>
or      eax, eax
jz      error_handler

Called by the _VCOMM_ReadComm service to read characters from the receive queue for the specified port. Uses the C calling convention. Must be callable at interrupt time.

hPort

Address of a _PORTINFORMATION structure returned by the PortOpen function.

achBuffer

Address of a buffer that receives the characters.

cchRequested

Number of characters to read from the receive queue.

cchReceived

Address of a 32-bit variable that receives the number of characters actually read.

The port driver must update the QInGet field of the _PORTDATA structure. The port driver may need to issue flow-control signals if the number of characters in the receive queue drops below the XON limit. The XON limit is specified by the device control block (_DCB structure) for the port.

See also _DCB, _PORTDATA, _PORTINFORMATION, PortOpen, _VCOMM_ReadComm