cups 1.1.23: get Printer-Status via API ...

bFoe bf at sf-c.net
Wed Feb 9 01:18:21 PST 2005


Try to get printer status infos ("cover-open", "media-needed", etc.) via cups 1.1.23 API (RedHat 9 + Fedora core 2 / Printer  Kyocera FS-920).

The function works like the check_printer_state () in backend/ipp.c.

cupsDoRequest (...) returns a valid response. But content of this response is not like expected.

ippFindAttribute (response, "printer-state-reasons", IPP_TAG_KEYWORD);

always returns one entry (num_values == 1): either a "none" (if the queue is up) or a "paused" (stopped the printer) in
values[0].string.text.

Until now I'm not able to get the other infos ("cover-open" [if the cover is open], "media-needed" [if no media in tray], etc.).

With browser admin GIU (localhost:631) you also can't see the "cover-open" etc. ...

Don't know, where the problem is located:
(1) wrong API - function / parameter call
(2) cups does not support this functionality in general
(3) cups server / printer (parameter) communication problem


Any suggestions? - Thanks in advance!


Regards

Bernd.




More information about the cups mailing list