So, w.r.t. your @PJL INFO CONFIG dump, well, your Brother firmware seems to completely ignore the "LANGUAGES" variable. There's one other way to possibly find out at least what command languages your printer understands (besides obviously understanding Brother's variant of PJL): snmpwalk -c public 10.0.1.19 .1.3.6.1.4.1.2699.1.2 (that tool is of course from pkgsrc/net/net-snmp FYI this is the "PRINTER-PORT-MONITOR-MIB" (which for some reason I don't understand is under the "enterprises" OIDs) My printer says the following, a look at the "CMD:" substring of the ppmPrinterIEEE1284DeviceId: PRINTER-PORT-MONITOR-MIB::ppmGeneralNaturalLanguage.0 = STRING: en-CA PRINTER-PORT-MONITOR-MIB::ppmGeneralNumberOfPrinters.0 = Gauge32: 1 PRINTER-PORT-MONITOR-MIB::ppmGeneralNumberOfPorts.0 = Gauge32: 3 PRINTER-PORT-MONITOR-MIB::ppmPrinterName.1 = STRING: BRN001BA9BAB074 PRINTER-PORT-MONITOR-MIB::ppmPrinterIEEE1284DeviceId.1 = STRING: "MFG:Brother;CMD:PJL,XL2HB;MDL:HL-3045CN series;CLS:PRINTER;CID:Brother Color Type2;" PRINTER-PORT-MONITOR-MIB::ppmPrinterNumberOfPorts.1 = Gauge32: 3 PRINTER-PORT-MONITOR-MIB::ppmPrinterPreferredPortIndex.1 = INTEGER: 1 PRINTER-PORT-MONITOR-MIB::ppmPrinterHrDeviceIndex.1 = INTEGER: 1 PRINTER-PORT-MONITOR-MIB::ppmPrinterSnmpCommunityName.1 = STRING: "public" PRINTER-PORT-MONITOR-MIB::ppmPrinterSnmpQueryEnabled.1 = INTEGER: true(1) PRINTER-PORT-MONITOR-MIB::ppmPortEnabled.1.1 = INTEGER: true(1) PRINTER-PORT-MONITOR-MIB::ppmPortEnabled.1.2 = INTEGER: true(1) PRINTER-PORT-MONITOR-MIB::ppmPortEnabled.1.3 = INTEGER: true(1) PRINTER-PORT-MONITOR-MIB::ppmPortName.1.1 = STRING: HL-3045CN series-LPR PRINTER-PORT-MONITOR-MIB::ppmPortName.1.2 = STRING: HL-3045CN series-RAW PRINTER-PORT-MONITOR-MIB::ppmPortName.1.3 = STRING: HL-3045CN series-IPP PRINTER-PORT-MONITOR-MIB::ppmPortServiceNameOrURI.1.1 = STRING: lpr://BRN001BA9BAB074/BINARY_P1 PRINTER-PORT-MONITOR-MIB::ppmPortServiceNameOrURI.1.2 = STRING: PRINTER-PORT-MONITOR-MIB::ppmPortServiceNameOrURI.1.3 = STRING: http://BRN001BA9BAB074:631/ipp PRINTER-PORT-MONITOR-MIB::ppmPortProtocolType.1.1 = INTEGER: 8 PRINTER-PORT-MONITOR-MIB::ppmPortProtocolType.1.2 = INTEGER: 11 PRINTER-PORT-MONITOR-MIB::ppmPortProtocolType.1.3 = INTEGER: 44 PRINTER-PORT-MONITOR-MIB::ppmPortProtocolTargetPort.1.1 = INTEGER: 515 PRINTER-PORT-MONITOR-MIB::ppmPortProtocolTargetPort.1.2 = INTEGER: 9100 PRINTER-PORT-MONITOR-MIB::ppmPortProtocolTargetPort.1.3 = INTEGER: 631 PRINTER-PORT-MONITOR-MIB::ppmPortProtocolAltSourceEnabled.1.1 = INTEGER: false(2) PRINTER-PORT-MONITOR-MIB::ppmPortProtocolAltSourceEnabled.1.2 = INTEGER: false(2) PRINTER-PORT-MONITOR-MIB::ppmPortProtocolAltSourceEnabled.1.3 = INTEGER: false(2) PRINTER-PORT-MONITOR-MIB::ppmPortPrtChannelIndex.1.1 = INTEGER: 1 PRINTER-PORT-MONITOR-MIB::ppmPortPrtChannelIndex.1.2 = INTEGER: 2 PRINTER-PORT-MONITOR-MIB::ppmPortPrtChannelIndex.1.3 = INTEGER: 9 PRINTER-PORT-MONITOR-MIB::ppmPortLprByteCountEnabled.1.1 = INTEGER: false(2) PRINTER-PORT-MONITOR-MIB::ppmPortLprByteCountEnabled.1.2 = INTEGER: false(2) PRINTER-PORT-MONITOR-MIB::ppmPortLprByteCountEnabled.1.3 = INTEGER: false(2) End of MIB This can also be seen in: JETDIRECT3-MIB::gdStatusId.0 = STRING: "MFG:Brother;CMD:PJL,XL2HB;MDL:HL-3045CN series;CLS:PRINTER;CID:Brother Color Type2;" (OID: .1.3.6.1.4.1.11.2.3.9.1.1.7.0) And in: BROTHER-MIB::brieee1284id.0 = STRING: "MFG:Brother;CMD:PJL,XL2HB;MDL:HL-3045CN series;CLS:PRINTER;CID:Brother Color Type2;" (OID: .1.3.6.1.4.1.2435.2.3.9.1.1.7.0) However the full walk of the PRINTER-PORT-MONITOR-MIB should also tell you exactly what ports and protocols your printer is listening on (though I've not yet found a reference defining the ppmPortProtocolType values). At Sat, 4 Jul 2020 13:13:02 +0200, Rocky Hotas <rockyhotas%firemail.cc@localhost> wrote: Subject: Re: Use network printer from NetBSD > > I searched in the configuration panel, both physically in the printer, > and from the web interface. > Till now I hadn't found nothing similar to emulation. In the TCP/IP > settings, however, I just found this: > > Enabled Services > BRN3C2AF4E874A2 > BINARY_P1 > TEXT_P1 > POSTSCRIPT_P1 > PCL_P1 > BRN3C2AF4E874A2_AT > > Each of them has a minimum possible configuration. For example, > > TEXT_P1 > Service Name TEXT_P1 > Service Port P1 > Protocols TCP/IPIPP > Filter Text Substitution > Control Strings Beginning of Job 1) > End of Job 11)\0C > Raw TCP Port 9100 > Service Options Bi-Directional That may not mean anything -- my printer also defines those "Service Names", but it seems to completely ignore them. I only get blank pages if I use them as LPD queue names. In fact I've so far been unable to generate anything printing on my printer either, even after sending it munged output from 'gs -sDEVICE=pxlmono'. I must still be missing some critical secret to the mostly undocumented XL2HB format. The printer starts up and warms up, then silently gives up without even ejecting a blank page. If your printer really does understand postscript then this script should print something (and show things on the telnet output): #!/bin/sh { printf '\033%%-12345X@PJL\n' printf '@PJL INITIALIZE\n' printf '\033%%-12345X@PJL\n' printf '@PJL INFO ID\n' printf '@PJL INFO CONFIG\n' printf '@PJL INFO VARIABLES\n' printf '@PJL INFO STATUS\n' printf '@PJL INFO FEATURES\n' printf '@PJL INFO OPTIONS\n' printf '@PJL INFO FILESYS\n' printf '@PJL INFO LOG\n' printf '@PJL INFO PRODINFO\n' printf '@PJL INFO SUPPLIES\n' printf '@PJL USTATUS DEVICE = VERBOSE\n@PJL USTATUS JOB = ON\n@PJL USTATUS PAGE = ON\n@PJL INFO USTATUS\n' printf '@PJL JOB NAME = "test job"\n' printf '@PJL INFO PAGECOUNT\n' printf '@PJL ENTER LANGUAGE = POSTSCRIPT\n' cat <<__EOF__ %!PS 0.5 setgray clippath pathbbox moveto lineto stroke newpath 100 200 moveto 200 250 lineto 100 300 lineto 2 setlinewidth stroke showpage __EOF__ printf '\004' printf '\033%%-12345X@PJL\n@PJL EOJ NAME = "test job"\n'; printf '@PJL USTATUSOFF\n@PJL INFO PAGECOUNT\n@PJL INFO STATUS\n'; printf '\033%%-12345X'; sleep 30 } | telnet 10.0.1.19 9100 BTW, the PJL language is documented for my printer in the "Command Reference Guide for Software Developers": https://download.brother.com/welcome/doc002907/Tech_Manual_AC.pdf -- Greg A. Woods <gwoods%acm.org@localhost> Kelowna, BC +1 250 762-7675 RoboHack <woods%robohack.ca@localhost> Planix, Inc. <woods%planix.com@localhost> Avoncote Farms <woods%avoncote.ca@localhost>
Attachment:
pgpPKt404El29.pgp
Description: OpenPGP Digital Signature