Printing using IPP without drivers (IPP Client)

I have a device / device in which you cannot install drivers. I would like to add the ability to support network / IPP / AirPrint printers by adding IP addresses to the user.

Since I do not print through windows (which will use IPP), how can I use IPP myself? Is there a C # client (or any Windows library) that allows you to interact with IPP IPP printers?

+7
printing network-protocols network-printers ipp-protocol
source share
2 answers

There are several implementations of IPP-Client and IPP libraries available for different programming languages ​​(java / php / python).

A practical solution would be to use ipptool available at http://cups.org/software.php

create an ipp batch file called printfile.ipp :

 { OPERATION Print-Job GROUP operation-attributes-tag ATTR charset attributes-charset utf-8 ATTR language attributes-natural-language en ATTR uri printer-uri $uri FILE $filename } 

Now you can print the PDF file using the following options:

ipptool -tv -f mydoc.pdf ipp://192.168.2.207 printfile.ipp

Verify that the printer (or print server) supports the document format you are sending. I assume that you are familiar with how to execute an external command in your application.

(Although ipptool provided by CUPS, it works fine with any IPP printer. Check RFC 3510 or the documentation for your printers for the appropriate printer-uri scheme)

+6
source share

IPP Software Example

Meanwhile, the IPP software example (which includes ipptool mentioned above in ipptool ) is a separate project on Github. It is currently under the auspices of the Printers Working Group (PWG), the body that standardized IPP (Internet Printing Protocol).

Although the software is currently in beta, it is already very functional. It comes with two main command line tools:

  1. ippserver . Run it (with the appropriate parameters), and you will have a full-fledged instance of the IPP server on your network, acting as a virtual IPP printer (or an IPP server that hosts several IPP virtual queues), which you can use to test any ( or yourself) is written) IPP client software against.

  2. ipptool This is an IPP client program that can send any combination of IPP requests to any IPP instance on the network (CUPS server, ippserver , printer equipment with ippserver IPP) and check its responses. The software comes with several prepared text files containing sample IPP requests, all with the suffix .test for their file names.

For your purpose, you can run these commands:

  1. ipptool -t -v ipp://xxx.xxx.xxx.xxx/ipp/print get-printer-attributes.test . This command will ask any IPP printer for its supported IPP attributes. This should include an element about alleged IPP version support. For example, ipp-versions-supported (1setOf keyword) = 1.0,1.1,2.0 reports with support for ipp-versions-supported (1setOf keyword) = 1.0,1.1,2.0 .

  2. ipptool -t -v ipp://xxx.xxx.xxx.xxx/ipp/print ipp-1.1.test . This command will launch a full set of verification tools on the printer in order to verify its real IPP-1.1 compliance.

  3. ipptool -t -v ipp://xxx.xxx.xxx.xxx/ipp/print ipp-2.0.test . This command will launch a full set of verification tools on the printer to verify its real compatibility with IPP-2.0.

  4. ipptool -t -v ipp://xxx.xxx.xxx.xxx/ipp/print ipp-2.0.test . This command will launch a full set of verification tools on the printer to verify its real compatibility with IPP-2.0.

  5. ipptool -t -v ipp://xxx.xxx.xxx.xxx/ipp/print ipp-2.1.test . This command will launch a full set of verification tools on the printer to verify that it matches the real IPP-2.2.

  6. ipptool -t -v ipp://xxx.xxx.xxx.xxx/ipp/print ipp-2.2.test . This command will launch a full set of verification tools on the printer to verify that it matches the real IPP-2.2.

  7. ipptool -t -v ipp://xxx.xxx.xxx.xxx/ipp/print ipp-everywhere.test . This command will run the full IPP Everywhere verification package (which is the most recent IPP standard) for the printer to verify that it matches IPP Everywhere.


AppImage Sample IPP Software

To facilitate this type of testing for you guys, I created a ready-made executable AppImage from the IPP software example, which should be able to run directly (does not require "installation"!) On all Linux x86_64 distributions.

You can use it (almost) on any Linux system without CUPS or ippsample installed!

AppImage integrates all the basic IPP Sample Software project command line executables. These executables will work as AppImage subcommands. See further down for examples.

  1. Download:

     wget https://github.com/KurtPfeifle/ippsample/releases/download/continuous/ippsample-x86_64.AppImage 
  2. Make AppImage executable (and rename it to ippsample if necessary):

     chmod a+x ippsample-x86_64.AppImage mv ippsample-x86_64.AppImage ippsample 
  3. Take a look at the built-in help screen:

     ./ippsample --ai-usage 
  4. Run it:

     ./ippsample ipptool -t -v ipp://xxx.xxx.xxx.xxx/ipp/print ipp-2.0.test 
  5. Find all IPP-enabled printers nearby:

     ./ippsample ippfind 

    will give like:

     ipp://HPA0B3CCF051B9.local:631/ipp/printer ipp://lenjessie2.local:8444/ipp/print ipp://mbp14.papercut-ipv4.local:631/printers/OJ6500 ipp://mbp14.papercut-ipv4.local:631/printers/libreoffice-pin-code-drucker 
  6. Select one printer, print the job:

     ./ippsample ipptool \ -tv \ -f ./printjob.pdf \ ipp://HPA0B3CCF051B9.local:631/ipp/printer \ print-job.test 

ASCIinema ASCIIcast

Here is the (older) ASCIinema cast of ASCIinema, which illustrates what I wrote about and how to use the IPP Sample Software (and its AppImage):

asciicast

+1
source share

All Articles