我将在Linux或Windows中工作。
在Github上,IPP样例软件是一个完整的、开源的、符合IPP-2.2和IPP Everywhere标准的打印机模拟器。它由打印机工作组(PWG)提供,该组织标准化了IPP(Internet Printing Protocol)。
IPP样例软件可以在任何主要平台上编译:Linux、Windows、macOS。
该软件目前仍处于测试版,但已经非常实用。它提供的命令行工具之一是ippserver
。这就是你要找的模拟打印机。它比苹果的打印机模拟器功能更强大,但没有图形用户界面。你需要熟悉运行命令行工具。
一旦你能够启动ippserver
(带有适当的选项),你就会在网络上拥有一个完整的虚拟IPP打印机实例。你可以使用它来测试任何(或自己编写的)IPP客户端软件。
IPP示例提供了另一个重要的工具,ipptool
。它可以作为IPP客户端使用。您可以使用两者进行测试。在这个ASCII-cast中看看它是如何工作的:
如果您想自己尝试,并且使用的是Linux系统,您甚至不需要自己构建它。只需使用我提供的软件AppImage(由一个单独的可执行文件组成),无需进行“安装”步骤即可直接运行。以下是具体步骤:
Download it:
wget https://github.com/KurtPfeifle/ippsample/releases/download/continuous/ippsample-x86_64.AppImage
Make AppImage executable (and optionally rename it to ippsample
):
chmod a+x ippsample-x86_64.AppImage
mv ippsample-x86_64.AppImage ippsample
Have a look at its built-in help screen:
./ippsample --ai-usage
Run it:
./ippsample ipptool -t -v ipp://xxx.xxx.xxx.xxx/ipp/print ipp-2.0.test
(This would run a test suite to validate complete IPP-2.0 compliance of the IPP printer on IP address xxx.xxx.xxx.xxx.)
打印作业:
./ippsample ipptool -t -v \
-f my.pdf \
ipp://xxx.xxx.xxx.xxx/ipp/print \
print-job.test
(这会将my.pdf作为打印作业发送到打印机。)
验证打印机的print-uri
支持:
./ippsample ipptool -t -v \
-o document-uri=https://ftp.pwg.org/pub/pwg/candidates/cs-ippeve10-20130128-5100.14.pdf \
ipp://xxx.xxx.xxx.xxx/ipp/print \
print-uri.test
(这会告诉打印机从document-uri获取指定的PDF并打印。)
job-impressions-completed
。该工具节省了很多纸张。impressions-completed > 0
。这将导致真正的-而不是模拟的-打印。