Npcp Printer Communications - Intermec 730 User Manual

700 series color mobile computer
Hide thumbs Also See for 730:
Table of Contents

Advertisement

#define IOCTL_NPCP_CANCEL
CTL_CODE(FILE_DEVICE_SERIAL_PORT,0x400,METHOD_BUFFERED,FILE_ANY_ACCESS)
#define IOCTL_NPCP_BIND
CTL_CODE(FILE_DEVICE_SERIAL_PORT,0x401,METHOD_BUFFERED,FILE_ANY_ACCESS)
#define IOCTL_NPCP_CLOSE
CTL_CODE(FILE_DEVICE_SERIAL_PORT,0x402,METHOD_BUFFERED,FILE_ANY_ACCESS)
#define IOCTL_NPCP_ERROR
CTL_CODE(FILE_DEVICE_SERIAL_PORT,0x403,METHOD_BUFFERED,FILE_ANY_ACCESS)
#define IOCTL_NPCP_FLUSH
CTL_CODE(FILE_DEVICE_SERIAL_PORT,0x404,METHOD_BUFFERED,FILE_ANY_ACCESS)
#define IOCTL_NPCP_IOCTL
CTL_CODE(FILE_DEVICE_SERIAL_PORT,0x405,METHOD_BUFFERED,FILE_ANY_ACCESS)
#define IOCTL_NPCP_PRTVER
CTL_CODE(FILE_DEVICE_SERIAL_PORT,0x406,METHOD_BUFFERED,FILE_ANY_ACCESS)

NPCP Printer Communications

700 Series Color Mobile Computer User's Manual
S IOCTL_NPCP_CANCEL
This cancels all printing at the printer. It flushes the printer buffers and
reinitializes the printer to its default state. No parameters are required.
S IOCTL_NPCP_BIND
This command is required before any data is sent or received by the
printer. Once the driver is opened, the application must bind the com-
munications session with the printer before any data can be sent or re-
ceived by the printer. If an error occurs during the bind, the application
may use IOCTL_NPCP_ERROR to get the current extended error
code. No parameters are required.
S IOCTL_NPCP_CLOSE
This command closes the current session with the printer. This function
always returns TRUE. No parameters are required.
S IOCTL_NPCP_ERROR
This command returns the extended NPCP error code in PL/N format.
The word returned will contain the PL/N compatible error code in the
low byte and completion flags in the high byte. If the frame that re-
turned an error was not received correctly by the printer the
FRAME_NOT_ACKED bit will be set in the high byte. This operation
always returns TRUE. An output buffer of at least 2 bytes is required.
See "NPCP Error Codes" on page 166.
S IOCTL_NPCP_FLUSH
This command allows the application to poll the printer for errors while
the report is completing the print process at the printer. If an error oc-
curs during the polling process, the operation will return FALSE and
the application can get the extended error code by using
IOCTL_NPCP_ERROR. No parameters are required.
All NPCP printer communications should be based on the following flow:
1 Use CreateFile(); to open the printer driver.
2 Use IOCTL_NPCP_BIND to bind a session with the printer;
IOCTL_NPCP_ERROR to check for errors on the bind to ensure suc-
cess; and IOCTL_NPCP_CANCEL to cancel outstanding print jobs.
Chapter 5
Printer Support
165

Advertisement

Table of Contents
loading

This manual is also suitable for:

750740741760761751 ... Show all

Table of Contents