Jump to content

ASYNC GETCOMMERROR: Difference between revisions

From EDM2
Created page with "Returns COM Error (retrieves and clears the COM device error information). ; Category: IOCTL_ASYNC (01h) ; Function: ASYNC_GETCOMMERROR (6Dh) ==Parameter Packet Format== N..."
 
Ak120 (talk | contribs)
mNo edit summary
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
Returns COM Error (retrieves and clears the COM device error information).  
{{DISPLAYTITLE:ASYNC_GETCOMMERROR}}
Returns COM Error (retrieves and clears the COM device error information).


; Category: IOCTL_ASYNC (01h)
;Category: IOCTL_ASYNC (01h)
; Function: ASYNC_GETCOMMERROR (6Dh)  
;Function: ASYNC_GETCOMMERROR (6Dh)


==Parameter Packet Format==
==Parameter Packet Format==
None. Packet pointer must be NULL.  
None. Packet pointer must be NULL.


==Data Packet Format==
==Data Packet Format==
<pre>
{|class="wikitable"
┌───────────────────────────────────────────────────┐
!Field||Length||C Datatype
│Field                      Length     C Datatype
|-
├───────────────────────────────────────────────────┤
|COM Error WORD (COMERR)||WORD||USHORT
│COM Error WORD (COMERR)     WORD       USHORT     │
|}
└───────────────────────────────────────────────────┘
</pre>
;COM Error WORD (COMERR)
The appropriate bits in COM Error WORD are set by the physical device driver when the events described below occur. COM Error WORD is not cleared unless this function is performed by the physical device driver or an OPEN request packet is received by the physical device driver and the COM device is not already open (First Level Open). See Note 5 of ASYNC_SETDCBINFO.


:;Bit 0 ::Receive queue overrun. No room in the physical device driver receive queue to put a character read in from the receive hardware.  
;COM Error WORD (COMERR):The appropriate bits in COM Error WORD are set by the physical device driver when the events described below occur. COM Error WORD is not cleared unless this function is performed by the physical device driver or an OPEN request packet is received by the physical device driver and the COM device is not already open (First Level Open). See Note 5 of [[ASYNC_SETDCBINFO]].
:;Bit 1 ::Receive hardware overrun. A character was not read from the hardware before the next character arrived, causing a character to be lost.  
::Bit 0 : Receive queue overrun. No room in the physical device driver receive queue to put a character read in from the receive hardware.
:;Bit 2 ::The hardware detected a parity error.  
::Bit 1 : Receive hardware overrun. A character was not read from the hardware before the next character arrived, causing a character to be lost.
:;Bit 3 ::The hardware detected a framing error.  
::Bit 2 : The hardware detected a parity error.
:;Bits 4-15 ::Undefined.  
::Bit 3 : The hardware detected a framing error.
::Bits 4-15 : Undefined.


==Returns==
==Returns==
If the call is made with an invalid Parameter Packet value, a general failure error is reported, valid information is not returned in the Data Packet, and the COM Error WORD is not cleared.  
If the call is made with an invalid Parameter Packet value, a general failure error is reported, valid information is not returned in the Data Packet, and the COM Error WORD is not cleared.


==Remarks==
==Remarks==
If a general failure error is not returned, the physical device driver returns the current value of the error WORD and then clears it.  
If a general failure error is not returned, the physical device driver returns the current value of the error WORD and then clears it.


[[Category:IOCtl Commands]]
[[Category:IOCtl Function]]
{{DISPLAYTITLE:ASYNC_GETCOMMERROR (6Dh) }}

Latest revision as of 18:49, 22 October 2021

Returns COM Error (retrieves and clears the COM device error information).

Category
IOCTL_ASYNC (01h)
Function
ASYNC_GETCOMMERROR (6Dh)

Parameter Packet Format

None. Packet pointer must be NULL.

Data Packet Format

Field Length C Datatype
COM Error WORD (COMERR) WORD USHORT
COM Error WORD (COMERR)
The appropriate bits in COM Error WORD are set by the physical device driver when the events described below occur. COM Error WORD is not cleared unless this function is performed by the physical device driver or an OPEN request packet is received by the physical device driver and the COM device is not already open (First Level Open). See Note 5 of ASYNC_SETDCBINFO.
Bit 0 : Receive queue overrun. No room in the physical device driver receive queue to put a character read in from the receive hardware.
Bit 1 : Receive hardware overrun. A character was not read from the hardware before the next character arrived, causing a character to be lost.
Bit 2 : The hardware detected a parity error.
Bit 3 : The hardware detected a framing error.
Bits 4-15 : Undefined.

Returns

If the call is made with an invalid Parameter Packet value, a general failure error is reported, valid information is not returned in the Data Packet, and the COM Error WORD is not cleared.

Remarks

If a general failure error is not returned, the physical device driver returns the current value of the error WORD and then clears it.