captdriver icon indicating copy to clipboard operation
captdriver copied to clipboard

LBP310x support

Open vasishath opened this issue 8 years ago • 14 comments
trafficstars

I tried this driver with my LBP3108 (common with LBP 3100 and 3150) and its reporting the printer status correctly i.e idle, paused or turned off etc. But when i try to print a test page, it stops at "rendering complete". I tried restarting the printer but it didn't help. I am a developer and own this printer and am ready to help you with any debug/traces of the CAPT commands exchanged between the PC and printer.

I tried this on Arch Linux. Thanks a lot.

vasishath avatar Dec 10 '16 14:12 vasishath

Hi vasishath, nice to hear you'd like to add a new printer model to captdriver.

Please could you report the printer state reply?

Regards, Laura

missla avatar Jan 07 '17 11:01 missla

Hi Laura,

Thanks for your reply.. How am i supposed to get that ? Will usbmon on wireshark do this ?

Thanks

vasishath avatar Jan 15 '17 07:01 vasishath

Yes. See, for example, https://ask.wireshark.org/questions/11054/analysing-usb-traffic

On Saturday, January 14, 2017 11:59:19 PM EST Vasishath Kaushal wrote:

Hi Laura,

Thanks for your reply.. How am i supposed to get that ? Will usbmon on wireshark do this ?

Thanks

Legimet avatar Jan 15 '17 14:01 Legimet

All you need is enable the CUPS error log.

You may do this with the http CUPS interface at localhost:631 and inpsect the error log from here.

Or may do this by hand: search for 'LogLevel' section in /etc/cups/cupsd.conf and change it to "debug" (default is "info"). Then restart cups service and you'll find all captdirver communications in '/var/log/cups/error_log' file.

missla avatar Jan 18 '17 17:01 missla

here is cups error log when I try to print using LBP3108

D [31/May/2021:12:30:50 +0800] [Job 85] Applying default options... I [31/May/2021:12:30:50 +0800] [Job 85] Adding start banner page "none". I [31/May/2021:12:30:50 +0800] [Job 85] Adding end banner page "none". I [31/May/2021:12:30:50 +0800] [Job 85] File of type application/vnd.cups-pdf-banner queued by "kylin". D [31/May/2021:12:30:50 +0800] [Job 85] hold_until=0 I [31/May/2021:12:30:50 +0800] [Job 85] Queued on "LBP3108" by "kylin". D [31/May/2021:12:30:50 +0800] [Job 85] time-at-processing=1622435450 D [31/May/2021:12:30:50 +0800] [Job 85] 4 filters for job: D [31/May/2021:12:30:50 +0800] [Job 85] bannertopdf (application/vnd.cups-pdf-banner to application/pdf, cost 32) D [31/May/2021:12:30:50 +0800] [Job 85] pdftopdf (application/pdf to application/vnd.cups-pdf, cost 66) D [31/May/2021:12:30:50 +0800] [Job 85] gstoraster (application/vnd.cups-pdf to application/vnd.cups-raster, cost 99) D [31/May/2021:12:30:50 +0800] [Job 85] rastertocapt (application/vnd.cups-raster to printer/LBP3108, cost 1) D [31/May/2021:12:30:50 +0800] [Job 85] job-sheets=none,none D [31/May/2021:12:30:50 +0800] [Job 85] argv[0]="LBP3108" D [31/May/2021:12:30:50 +0800] [Job 85] argv[1]="85" D [31/May/2021:12:30:50 +0800] [Job 85] argv[2]="kylin" D [31/May/2021:12:30:50 +0800] [Job 85] argv[3]="Test Page" D [31/May/2021:12:30:50 +0800] [Job 85] argv[4]="1" D [31/May/2021:12:30:50 +0800] [Job 85] argv[5]="job-uuid=urn:uuid:5c75826e-3c66-31b6-61b1-563a07865fa5 job-originating-host-name=localhost date-time-at-creation= date-time-at-processing= time-at-creation=1622435450 time-at-processing=1622435450" D [31/May/2021:12:30:50 +0800] [Job 85] argv[6]="/var/spool/cups/d00085-001" D [31/May/2021:12:30:50 +0800] [Job 85] envp[0]="CUPS_CACHEDIR=/var/cache/cups" D [31/May/2021:12:30:50 +0800] [Job 85] envp[1]="CUPS_DATADIR=/usr/share/cups" D [31/May/2021:12:30:50 +0800] [Job 85] envp[2]="CUPS_DOCROOT=/usr/share/cups/doc-root" D [31/May/2021:12:30:50 +0800] [Job 85] envp[3]="CUPS_FONTPATH=/usr/share/cups/fonts" D [31/May/2021:12:30:50 +0800] [Job 85] envp[4]="CUPS_REQUESTROOT=/var/spool/cups" D [31/May/2021:12:30:50 +0800] [Job 85] envp[5]="CUPS_SERVERBIN=/usr/lib/cups" D [31/May/2021:12:30:50 +0800] [Job 85] envp[6]="CUPS_SERVERROOT=/etc/cups" D [31/May/2021:12:30:50 +0800] [Job 85] envp[7]="CUPS_STATEDIR=/run/cups" D [31/May/2021:12:30:50 +0800] [Job 85] envp[8]="HOME=/var/spool/cups/tmp" D [31/May/2021:12:30:50 +0800] [Job 85] envp[9]="PATH=/usr/lib/cups/filter:/usr/bin:/usr/sbin:/bin:/usr/bin" D [31/May/2021:12:30:50 +0800] [Job 85] envp[10]="SERVER_ADMIN=root@kylin-GW-001M1A-FTF" D [31/May/2021:12:30:50 +0800] [Job 85] envp[11]="SOFTWARE=CUPS/2.3.1" D [31/May/2021:12:30:50 +0800] [Job 85] envp[12]="TMPDIR=/var/spool/cups/tmp" D [31/May/2021:12:30:50 +0800] [Job 85] envp[13]="USER=root" D [31/May/2021:12:30:50 +0800] [Job 85] envp[14]="CUPS_MAX_MESSAGE=2047" D [31/May/2021:12:30:50 +0800] [Job 85] envp[15]="CUPS_SERVER=/run/cups/cups.sock" D [31/May/2021:12:30:50 +0800] [Job 85] envp[16]="CUPS_ENCRYPTION=IfRequested" D [31/May/2021:12:30:50 +0800] [Job 85] envp[17]="IPP_PORT=631" D [31/May/2021:12:30:50 +0800] [Job 85] envp[18]="CHARSET=utf-8" D [31/May/2021:12:30:50 +0800] [Job 85] envp[19]="LANG=zh_CN.UTF-8" D [31/May/2021:12:30:50 +0800] [Job 85] envp[20]="PPD=/etc/cups/ppd/LBP3108.ppd" D [31/May/2021:12:30:50 +0800] [Job 85] envp[21]="RIP_MAX_CACHE=128m" D [31/May/2021:12:30:50 +0800] [Job 85] envp[22]="CONTENT_TYPE=application/vnd.cups-pdf-banner" D [31/May/2021:12:30:50 +0800] [Job 85] envp[23]="DEVICE_URI=usb://Canon/LBP3100/LBP3108/LBP3150?serial=0000A48999YI" D [31/May/2021:12:30:50 +0800] [Job 85] envp[24]="PRINTER_INFO=LBP3108" D [31/May/2021:12:30:50 +0800] [Job 85] envp[25]="PRINTER_LOCATION=" D [31/May/2021:12:30:50 +0800] [Job 85] envp[26]="PRINTER=LBP3108" D [31/May/2021:12:30:50 +0800] [Job 85] envp[27]="PRINTER_STATE_REASONS=none" D [31/May/2021:12:30:50 +0800] [Job 85] envp[28]="CUPS_FILETYPE=document" D [31/May/2021:12:30:50 +0800] [Job 85] envp[29]="FINAL_CONTENT_TYPE=application/vnd.cups-raster" D [31/May/2021:12:30:50 +0800] [Job 85] envp[30]="AUTH_I****" I [31/May/2021:12:30:50 +0800] [Job 85] Started filter /usr/lib/cups/filter/bannertopdf (PID 46160) I [31/May/2021:12:30:50 +0800] [Job 85] Started filter /usr/lib/cups/filter/pdftopdf (PID 46161) I [31/May/2021:12:30:50 +0800] [Job 85] Started filter /usr/lib/cups/filter/gstoraster (PID 46162) I [31/May/2021:12:30:50 +0800] [Job 85] Started filter /usr/lib/cups/filter/rastertocapt (PID 46163) I [31/May/2021:12:30:50 +0800] [Job 85] Started backend /usr/lib/cups/backend/usb (PID 46164) D [31/May/2021:12:30:50 +0800] [Job 85] OUTFORMAT="(null)", so output format will be CUPS/PWG Raster D [31/May/2021:12:30:50 +0800] [Job 85] pdftopdf: Last filter determined by the PPD: rastertocapt; FINAL_CONTENT_TYPE: application/vnd.cups-raster => pdftopdf will not log pages in page_log. D [31/May/2021:12:30:50 +0800] [Job 85] CAPT: rastertocapt started D [31/May/2021:12:30:50 +0800] [Job 85] PDF template file doesn't have form. It's okay. D [31/May/2021:12:30:50 +0800] [Job 85] Loading USB quirks from "/usr/share/cups/usb". D [31/May/2021:12:30:50 +0800] [Job 85] Loaded 181 quirks. D [31/May/2021:12:30:50 +0800] [Job 85] Printing on printer with URI: usb://Canon/LBP3100/LBP3108/LBP3150?serial=0000A48999YI D [31/May/2021:12:30:50 +0800] [Job 85] libusb_get_device_list=14 D [31/May/2021:12:30:50 +0800] [Job 85] STATE: +connecting-to-device D [31/May/2021:12:30:50 +0800] [Job 85] STATE: -connecting-to-device D [31/May/2021:12:30:50 +0800] [Job 85] Device protocol: 2 D [31/May/2021:12:30:50 +0800] [Job 85] CUPS_SC_CMD_GET_DEVICE_ID received from driver... D [31/May/2021:12:30:50 +0800] [Job 85] Returning CUPS_SC_STATUS_OK with 100 bytes (MFG:Canon;MDL:LBP3100/LBP3108/LBP3150;CMD:CAPT;VER:3.0;CLS:PRINTER;DES:Canon LBP3100/LBP3108/LBP3150)... D [31/May/2021:12:30:50 +0800] [Job 85] CAPT: printer ID string MFG:Canon;MDL:LBP3100/LBP3108/LBP3150;CMD:CAPT;VER:3.0;CLS:PRINTER;DES:Canon LBP3100/LBP3108/LBP3150 D [31/May/2021:12:30:50 +0800] [Job 85] CAPT: detected printer 'LBP3100/LBP3108/LBP3150' E [31/May/2021:12:30:50 +0800] [Job 85] CAPT: unknown printer 'MFG:Canon;MDL:LBP3100/LBP3108/LBP3150;CMD:CAPT;VER:3.0;CLS:PRINTER;DES:Canon LBP3100/LBP3108/LBP3150' D [31/May/2021:12:30:50 +0800] [Job 85] Set job-printer-state-message to "CAPT: unknown printer 'MFG:Canon;MDL:LBP3100/LBP3108/LBP3150;CMD:CAPT;VER:3.0;CLS:PRINTER;DES:Canon LBP3100/LBP3108/LBP3150'", current level=ERROR D [31/May/2021:12:30:50 +0800] [Job 85] PID 46163 (/usr/lib/cups/filter/rastertocapt) stopped with status 1. D [31/May/2021:12:30:50 +0800] [Job 85] 正在向打印机发送数据。 D [31/May/2021:12:30:50 +0800] [Job 85] Sent 0 bytes... D [31/May/2021:12:30:50 +0800] [Job 85] PID 46160 (/usr/lib/cups/filter/bannertopdf) exited with no errors. D [31/May/2021:12:30:50 +0800] [Job 85] PDF interactive form and annotation flattening done via QPDF D [31/May/2021:12:30:50 +0800] [Job 85] PID 46161 (/usr/lib/cups/filter/pdftopdf) exited with no errors. D [31/May/2021:12:30:50 +0800] [Job 85] Color Manager: Calibration Mode/Off D [31/May/2021:12:30:50 +0800] [Job 85] Calling FindDeviceById(cups-LBP3108) D [31/May/2021:12:30:50 +0800] [Job 85] Failed to send: org.freedesktop.DBus.Error.ServiceUnknown:The name org.freedesktop.ColorManager was not provided by any .service files D [31/May/2021:12:30:50 +0800] [Job 85] Failed to get find device cups-LBP3108 D [31/May/2021:12:30:50 +0800] [Job 85] Calling FindDeviceById(cups-LBP3108) D [31/May/2021:12:30:50 +0800] [Job 85] Failed to send: org.freedesktop.DBus.Error.ServiceUnknown:The name org.freedesktop.ColorManager was not provided by any .service files D [31/May/2021:12:30:50 +0800] [Job 85] Failed to get device cups-LBP3108 D [31/May/2021:12:30:50 +0800] [Job 85] Color Manager: no profiles specified in PPD D [31/May/2021:12:30:50 +0800] [Job 85] Color Manager: ICC Profile: None D [31/May/2021:12:30:50 +0800] [Job 85] Ghostscript using Any-Part-of-Pixel method to fill paths. D [31/May/2021:12:30:50 +0800] [Job 85] Ghostscript command line: gs -dQUIET -dSAFER -dNOPAUSE -dBATCH -dNOINTERPOLATE -dNOMEDIAATTRS -dShowAcroForm -sstdout=%stderr -sOutputFile=%stdout -sDEVICE=cups -r600x600 -dDEVICEWIDTHPOINTS=595 -dDEVICEHEIGHTPOINTS=842 -dcupsBitsPerColor=1 -dcupsColorOrder=0 -dcupsColorSpace=3 -dcupsRowCount=70 -dcupsRowFeed=592 -scupsPageSizeName=A4 -I/usr/share/cups/fonts -c '<</.HWMargins[0.000000 0.000000 0.000000 0.000000] /Margins[0 0]>>setpagedevice' -f -_ D [31/May/2021:12:30:50 +0800] [Job 85] envp[0]="CUPS_CACHEDIR=/var/cache/cups" D [31/May/2021:12:30:50 +0800] [Job 85] envp[1]="CUPS_DATADIR=/usr/share/cups" D [31/May/2021:12:30:50 +0800] [Job 85] envp[2]="CUPS_DOCROOT=/usr/share/cups/doc-root" D [31/May/2021:12:30:50 +0800] [Job 85] envp[3]="CUPS_FONTPATH=/usr/share/cups/fonts" D [31/May/2021:12:30:50 +0800] [Job 85] envp[4]="CUPS_REQUESTROOT=/var/spool/cups" D [31/May/2021:12:30:50 +0800] [Job 85] envp[5]="CUPS_SERVERBIN=/usr/lib/cups" D [31/May/2021:12:30:50 +0800] [Job 85] envp[6]="CUPS_SERVERROOT=/etc/cups" D [31/May/2021:12:30:50 +0800] [Job 85] envp[7]="CUPS_STATEDIR=/run/cups" D [31/May/2021:12:30:50 +0800] [Job 85] envp[8]="HOME=/var/spool/cups/tmp" D [31/May/2021:12:30:50 +0800] [Job 85] envp[9]="PATH=/usr/lib/cups/filter:/usr/bin:/usr/sbin:/bin:/usr/bin" D [31/May/2021:12:30:50 +0800] [Job 85] envp[10]="SERVER_ADMIN=root@kylin-GW-001M1A-FTF" D [31/May/2021:12:30:50 +0800] [Job 85] envp[11]="SOFTWARE=CUPS/2.3.1" D [31/May/2021:12:30:50 +0800] [Job 85] envp[12]="TMPDIR=/var/spool/cups/tmp" D [31/May/2021:12:30:50 +0800] [Job 85] envp[13]="USER=root" D [31/May/2021:12:30:50 +0800] [Job 85] envp[14]="CUPS_MAX_MESSAGE=2047" D [31/May/2021:12:30:50 +0800] [Job 85] envp[15]="CUPS_SERVER=/run/cups/cups.sock" D [31/May/2021:12:30:50 +0800] [Job 85] envp[16]="CUPS_ENCRYPTION=IfRequested" D [31/May/2021:12:30:50 +0800] [Job 85] envp[17]="IPP_PORT=631" D [31/May/2021:12:30:50 +0800] [Job 85] envp[18]="CHARSET=utf-8" D [31/May/2021:12:30:50 +0800] [Job 85] envp[19]="LANG=zh_CN.UTF-8" D [31/May/2021:12:30:50 +0800] [Job 85] envp[20]="PPD=/etc/cups/ppd/LBP3108.ppd" D [31/May/2021:12:30:50 +0800] [Job 85] envp[21]="RIP_MAX_CACHE=128m" D [31/May/2021:12:30:50 +0800] [Job 85] envp[22]="CONTENT_TYPE=application/vnd.cups-pdf-banner" D [31/May/2021:12:30:50 +0800] [Job 85] envp[23]="DEVICE_URI=usb://Canon/LBP3100/LBP3108/LBP3150?serial=0000A48999YI" D [31/May/2021:12:30:50 +0800] [Job 85] envp[24]="PRINTER_INFO=LBP3108" D [31/May/2021:12:30:50 +0800] [Job 85] envp[25]="PRINTER_LOCATION=" D [31/May/2021:12:30:50 +0800] [Job 85] envp[26]="PRINTER=LBP3108" D [31/May/2021:12:30:50 +0800] [Job 85] envp[27]="PRINTER_STATE_REASONS=none" D [31/May/2021:12:30:50 +0800] [Job 85] envp[28]="CUPS_FILETYPE=document" D [31/May/2021:12:30:50 +0800] [Job 85] envp[29]="FINAL_CONTENT_TYPE=application/vnd.cups-raster" D [31/May/2021:12:30:50 +0800] [Job 85] envp[30]="AUTH_INFO_REQUIRED=none" D [31/May/2021:12:30:51 +0800] [Job 85] Start rendering... D [31/May/2021:12:30:51 +0800] [Job 85] Processing page 1... E [31/May/2021:12:30:51 +0800] [Job 85] Unable to open raster stream - : Broken pipe D [31/May/2021:12:30:51 +0800] [Job 85] Error: /ioerror in --showpage-- D [31/May/2021:12:30:51 +0800] [Job 85] Operand stack: D [31/May/2021:12:30:51 +0800] [Job 85] true (/var/spool/cups/tmp/gs_4YEx8g) --nostringval-- 1 true D [31/May/2021:12:30:51 +0800] [Job 85] Execution stack: D [31/May/2021:12:30:51 +0800] [Job 85] %interp_exit .runexec2 --nostringval-- showpage --nostringval-- 2 %stopped_push --nostringval-- showpage showpage false 1 %stopped_push 1990 2 3 %oparray_pop 1989 2 3 %oparray_pop 1977 2 3 %oparray_pop showpage 1978 4 3 %oparray_pop showpage showpage 2 1 1 showpage %for_pos_int_continue 1981 4 7 %oparray_pop showpage showpage 1840 3 9 %oparray_pop showpage showpage D [31/May/2021:12:30:51 +0800] [Job 85] Dictionary stack: D [31/May/2021:12:30:51 +0800] [Job 85] --dict:740/1123(ro)(G)-- --dict:1/20(G)-- --dict:80/200(L)-- --dict:80/200(L)-- --dict:135/256(ro)(G)-- --dict:315/325(ro)(G)-- --dict:31/32(L)-- --dict:6/9(L)-- --dict:7/20(L)-- D [31/May/2021:12:30:51 +0800] [Job 85] Current allocation mode is local D [31/May/2021:12:30:51 +0800] [Job 85] Last OS error: Broken pipe D [31/May/2021:12:30:51 +0800] [Job 85] GPL Ghostscript 9.50: Unrecoverable error, exit code 1 D [31/May/2021:12:30:51 +0800] [Job 85] Rendering completed D [31/May/2021:12:30:51 +0800] [Job 85] Waiting for read thread to exit... D [31/May/2021:12:30:51 +0800] [Job 85] PID 46162 (/usr/lib/cups/filter/gstoraster) stopped with status 1. D [31/May/2021:12:30:58 +0800] [Job 85] Read thread still active, aborting the pending read... D [31/May/2021:12:30:59 +0800] [Job 85] PID 46164 (/usr/lib/cups/backend/usb) exited with no errors. E [31/May/2021:12:30:59 +0800] [Job 85] Job stopped due to filter errors; please consult the /var/log/cups/error_log file for details. D [31/May/2021:12:30:59 +0800] [Job 85] The following messages were recorded from 12时30分50秒 to 12时30分50秒 D [31/May/2021:12:30:59 +0800] [Job 85] Printer found with device ID: MFG:Canon;MDL:LBP3100/LBP3108/LBP3150;CMD:CAPT;VER:3.0;CLS:PRINTER;DES:Canon LBP3100/LBP3108/LBP3150 Device URI: usb://Canon/LBP3100/LBP3108/LBP3150?serial=0000A48999YI D [31/May/2021:12:30:59 +0800] [Job 85] End of messages D [31/May/2021:12:30:59 +0800] [Job 85] printer-state=3(idle) D [31/May/2021:12:30:59 +0800] [Job 85] printer-state-message="Rendering completed" D [31/May/2021:12:30:59 +0800] [Job 85] printer-state-reasons=none D [31/May/2021:12:31:00 +0800] [Job 85] Unloading... D [31/May/2021:12:31:03 +0800] [Job 85] Loading attributes... D [31/May/2021:12:31:03 +0800] [Job 85] time-at-completed=1622435463 I [31/May/2021:12:31:03 +0800] [Job 85] Job canceled by "kylin" I [31/May/2021:12:31:03 +0800] [Job 85] Canceled by "kylin".

cyanogenic avatar May 31 '21 04:05 cyanogenic

Something is wrong with your Ghostscript, not with captdriver. Is the PPD file readable?

agalakhov avatar May 31 '21 09:05 agalakhov

Something is wrong with your Ghostscript, not with captdriver. Is the PPD file readable?

yes, it's readable

cyanogenic avatar May 31 '21 09:05 cyanogenic

Actually, I think our driver is at fault here, at time of writing. I noticed this in the log posted by @cyanogenic :

D [31/May/2021:12:30:50 +0800] [Job 85] Set job-printer-state-message to "CAPT: unknown printer 'MFG:Canon;MDL:LBP3100/LBP3108/LBP3150;CMD:CAPT;VER:3.0;CLS:PRINTER;DES:Canon LBP3100/LBP3108/LBP3150'", current level=ERROR

We have an unknown printer error. Captdriver does not yet recognise the LBP3100/3108/3150 printer family. We have printed to the LBP 3010, a different but similar printer, with commits d6c5861 and earlier.

@cyanogenic: try adding this line at the end of src/prn_lbp2900.c:

register_printer("LBP3100/LBP3108/LBP3150", lbp3010_ops.ops, EXPERIMENTAL);
// attempt to use LBP3010 ops to support LBP3100 family

This will attempt to reuse LBP3010 code to support your LBP3108. I don't have an LBP3100, but I am making a wild guess based on comparisons between the specifications for the 3010 and the 3100. The printers seem to have identical specifications except for the printing speed.

Please be aware that the lbp3010 ops have been largely untested since d6c5861. If the above hack doesn't work, try checking out d6c5861, adding the register_printer(...) line above, and try again. :crossed_fingers:

mounaiban avatar Jun 03 '21 15:06 mounaiban

Actually, I think our driver is at fault here, at time of writing. I noticed this in the log posted by @cyanogenic :

D [31/May/2021:12:30:50 +0800] [Job 85] Set job-printer-state-message to "CAPT: unknown printer 'MFG:Canon;MDL:LBP3100/LBP3108/LBP3150;CMD:CAPT;VER:3.0;CLS:PRINTER;DES:Canon LBP3100/LBP3108/LBP3150'", current level=ERROR

We have an unknown printer error. Captdriver does not yet recognise the LBP3100/3108/3150 printer family. We have printed to the LBP 3010, a different but similar printer, with commits d6c5861 and earlier.

@cyanogenic: try adding this line at the end of src/prn_lbp2900.c:

register_printer("LBP3100/LBP3108/LBP3150", lbp3010_ops.ops, EXPERIMENTAL);
// attempt to use LBP3010 ops to support LBP3100 family

This will attempt to reuse LBP3010 code to support your LBP3108. I don't have an LBP3100, but I am making a wild guess based on comparisons between the specifications for the 3010 and the 3100. The printers seem to have identical specifications except for the printing speed.

Please be aware that the lbp3010 ops have been largely untested since d6c5861. If the above hack doesn't work, try checking out d6c5861, adding the register_printer(...) line above, and try again. 🤞

It did work! thanks a lot But there is still one single problem, the printer prints too slow... Just like it treats every page as a single job

cyanogenic avatar Jun 04 '21 01:06 cyanogenic

Yes, it treats every page as a single job (now). The reason is, multi-page printing is buggy and the printer tends to hang. You can try to edit the code to re-enable multi-page printing. YMMV.

agalakhov avatar Jun 04 '21 10:06 agalakhov

Which PPD file did you use @cyanogenic, Canon-LBP2900.ppd or Canon-LBP3000.ppd?

As for the slow printing, I think it is also due the pipeline from document to device:

When you print from a vector or mixed vector and raster document (this includes PDFs, word processor documents and web pages), GhostScript is used by CUPS to render a raw raster from your document. This raw raster is then taken by captdriver and converted to the Hi-SCoA format accepted by the printer.

This goes the same way for apps that output rasters directly, except that GhostScript is in such cases not required.

There are two bottlenecks here: GhostScript (which can be really slow at times) and hiscoa-compress.c, which I believe has plenty of room for improvement.

Just take a look inside do_print() in src/rastertocapt.c...

I am thinking of a workaround in which we pre-compress every page at the start of the print job, or at least a few at a time. This will certainly significantly increase the time needed to set up a print job and the amount of memory used. However, the delay between pages can be greatly reduced. Those who need to print multiple copies of complex pages, while running the printer in cold weather*, will benefit most.

*When the printer pauses to wait for the driver, the fuser cools down. On an LBP3000, the time needed to bring the fuser back to the working temperature, when the print job resumes after longer delays, can be a few extra seconds per page at ~15°C than it does at ~25°C. The lost heat also means that we are consuming a lot more energy.

mounaiban avatar Jun 06 '21 10:06 mounaiban

In early version of the driver I had issues with multi-page printing. The printer froze after first page and required hard reset (power off). As a workaround I added full reset after each page ("end job - start job"). It was terribly slow but at least it worked.

agalakhov avatar Jun 06 '21 10:06 agalakhov

Which PPD file did you use @cyanogenic, Canon-LBP2900.ppd or Canon-LBP3000.ppd?

As for the slow printing, I think it is also due the pipeline from document to device:

When you print from a vector or mixed vector and raster document (this includes PDFs, word processor documents and web pages), GhostScript is used by CUPS to render a raw raster from your document. This raw raster is then taken by captdriver and converted to the Hi-SCoA format accepted by the printer.

This goes the same way for apps that output rasters directly, except that GhostScript is in such cases not required.

There are two bottlenecks here: GhostScript (which can be really slow at times) and hiscoa-compress.c, which I believe has plenty of room for improvement.

Just take a look inside do_print() in src/rastertocapt.c...

I am thinking of a workaround in which we pre-compress every page at the start of the print job, or at least a few at a time. This will certainly significantly increase the time needed to set up a print job and the amount of memory used. However, the delay between pages can be greatly reduced. Those who need to print multiple copies of complex pages, while running the printer in cold weather*, will benefit most.

*When the printer pauses to wait for the driver, the fuser cools down. On an LBP3000, the time needed to bring the fuser back to the working temperature, when the print job resumes after longer delays, can be a few extra seconds per page at ~15°C than it does at ~25°C. The lost heat also means that we are consuming a lot more energy.

I use ppd for lbp3000. Thank you all for your support

cyanogenic avatar Jun 06 '21 10:06 cyanogenic

@cyanogenic (or anyone reading this): if you still have access to your LBP3100, would you be ok with posting the 0xA1A1 response from your printer, either here or in #38?

If you have been printing with captdriver with debug logging on, just run grep -n6 "A1 A1" /var/log/cups/error_log.

If nothing appears, try the older logs using zcat /var/log/cups/error_log.2.gz | grep -n6 "A1 A1" -, repeating the process with error_log.3.gz and so on as necessary. We only need the numbers in the A1 A1 packet response, everything else in the log is not needed.

Thanks in advance!

mounaiban avatar Nov 03 '22 07:11 mounaiban