ScreenUPG Assembly > ScreenUPG Namespace > ScreenUPG Class : setPeripheralControl Method |
The relevant arguments for the SendStatus method are:
UTS_DEVICESTATUS for the first parameter (type) when dealing with UTS/INT-1 statuses.
The second parameter should be a 1 byte value of one of the following:
Value | Description |
---|---|
UTS_DEVICESTATUS_THRU | for an Acknowledgement/Thru |
UTS_DEVICESTATUS_ERROR | for an Error/NACK |
UTS_DEVICESTATUS_NOTREADY | for a slightly different Error |
UTS_DEVICESTATUS_OFFLINE | for another slightly different error |
UTS_DEVICESTATUS_POC | for a Power-on Confidence (should only be used at startup) |
If an application wants to control INT-1 peripheral responses it should call setPeripheralControl(true) at startup and then check that getPeripheralControl confirms that with a returned value of true. Then, after every text message is received for the printer, the application should call SendStatus with one of the possible arguments. The first two values (UTS_DEVICESTATTUS_THRU and UTS_DEVICESTATUS_ERROR) will likely be sufficient. Calling SendStatus when a print operation is not outstanding will result in no peripheral status being sent to the host.
As an aide to tell when the application should be sending a printer status, the getOIAContents method can be used. The UTS OIA data contains two pieces of data which the application may want to check. Byte 102 is the Printer DID. If peripheral control is enabled, then this byte 102 value will be the currently selected printer DID (normally 0x73) or 0 if no Printer DID is selected. A Byte 104 has been added to the UTS OIA data - which is a "Printer Status Response" indication. This is intended as a aide in determine when the host is performing a print operation. The "Printer Status Response" byte is 1 if a printer status response is outstanding (i.e. the application needs to call SendStatus to complete the host operation) and 0 otherwise. If peripheral control is set to false, then byte 104 will always be 0.
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2
ScreenUPG Class
ScreenUPG Members
getOIAContents Method
getPeripheralControl Method
SendStatus(Int32,Byte[]) Method
SendStatus(Int32,SByte[]) Method
UTS_DEVICESTATUS Property
UTS_DEVICESTATUS_READY Property
UTS_DEVICESTATUS_BUSY Property
UTS_DEVICESTATUS_ERROR Property
UTS_DEVICESTATUS_NOTREADY Property
UTS_DEVICESTATUS_THRU Property
UTS_DEVICESTATUS_OFFLINE Property
UTS_DEVICESTATUS_POC Property