我正在尝试使用 escputil 来确定墨水量。输入时dev/usb/lp0
它显示'没有这样的文件或目录'。
答案1
尝试使用须藤。 这男人页面escputil还说这个错误是一个已知的错误,请尝试再次重新输入命令,应该可以解决问题。
USB-connected printers sometimes fail to identify or return ink levels.
You may have to repeat the command. This is probably a timing issue in
escputil, not a flaw in the printer.
Anything requiring bidirectional communication with the printer (iden-
tify, ink levels, or head alignment without specifying the printer
model) requires read/write access to the printer port (for example
/dev/lp0). This may require these operations to be performed as root.
In addition, kernel support is required for bidirectional communica-
tion. For Linux version 2.2, CONFIG_PRINTER_READBACK should be
enabled; this is called CONFIG_PARPORT_1284 on 2.4 and later kernels.
If the printer is performing self-test or head cleaning on power up,
the identify and ink level commands will time out, although the printer
successfully receives the command. The command will need to be reis-
sued when the printer is quiescent.
答案2
命令的正确使用方法/dev/usb/lp0其中一些选项如下
检查打印机的墨水量按照下面方法使用
sudo escputil -r /dev/usb/lp0 -s
请检查以下屏幕截图中的输出。就我而言,我正在检查 Epson L210 系列打印机墨水量。
我在命令前使用了 sudo,以便该命令可以以 root 身份执行,并且不会收到权限错误的消息。
到清洁打印机头可以使用以下命令。
sudo escputil -r /dev/usb/lp0 -c
请检查所有要使用的选项escputil使用以下命令。
man escputil
查看下面的屏幕截图,了解使用 man 时 escputil 可用的选项。