Author Topic: Anyone successfully using Brother HL-5470dw?  (Read 10657 times)

Dariusz Piatkowski

  • Sr. Member
  • ****
  • Thank You
  • -Given: 12
  • -Receive: 6
  • Posts: 290
    • View Profile
Re: Anyone successfully using Brother HL-5470dw?
« Reply #30 on: February 11, 2016, 05:17:35 am »
Hi Alex,

Two suggestions... First, print to file and compare the output Postscript file for both the working and non-working scenarios.
Second, try varying the font used for printing text format (printer object properties, tab 'Text Format', font option).

Great suggestions...I had actually ventured down that road last night hoping to sneak a peek at what the driver is actualy building in the print job itself. Specifically I was hoping to see the HQ1200 vs 1200 dpi resolution settings.

As it turned out, even a basic TXT file when using the PSPRINT driver produced a fairly large output job when printed @ 1200dpi, here is a quick comparison:

2-09-16   8:50p      9665           0  output_pscript_1200.txt
2-09-16   8:11p    568252           0  output_ps_1200.txt
2-09-16   8:17p      9343           0  output_ps_1200_nofont.txt
2-09-16   8:16p      9218           0  output_ps_300.txt
2-09-16   8:14p      9224           0  output_ps_600.txt

the output_ps* files are from your PSPRINT driver, whereas the single output_pscript_1200.txt file is from the IBM PSCRIPT driver. what I found strange is that at the lower resolutions the resulting text files did NOT embed fonts, whereas at the 1200dpi they did.

Finally, HQ1200 failed to print altogether where I would encounter a crash in the PSPRINT driver itself, here is the entry from my POPUPLOG.OS2 file:

=== START ===
G:\OS2\PMSPOOL.EXE
c000009b
163e0bdc
EAX=00000000  EBX=0000002c  ECX=00000000  EDX=00000000
ESI=0283000c  EDI=02771400 
DS=0053  DSACC=f0f3  DSLIM=ffffffff 
ES=0053  ESACC=f0f3  ESLIM=ffffffff 
FS=150b  FSACC=00f3  FSLIM=00000030
GS=0000  GSACC=****  GSLIM=********
CS:EIP=005b:163e0bdc  CSACC=f0df  CSLIM=ffffffff
SS:ESP=0053:02525bac  SSACC=f0f3  SSLIM=ffffffff
EBP=02525c6c  FLG=00010246

PSPRINT.DRV 0001:00040bdc
=== END ===

The good news (I suppose/hope...???) is that the crash was consistent between the PSCRIPT and PSPRINT drivers, here is the matching log for the PSCRIPT driver:

=== START ===
G:\OS2\PMSPOOL.EXE
c000009b
1657d46c
EAX=00000000  EBX=0000002c  ECX=00000000  EDX=00000000
ESI=0285000c  EDI=02791400 
DS=0053  DSACC=f0f3  DSLIM=ffffffff 
ES=0053  ESACC=f0f3  ESLIM=ffffffff 
FS=150b  FSACC=00f3  FSLIM=00000030
GS=0000  GSACC=****  GSLIM=********
CS:EIP=005b:1657d46c  CSACC=f0df  CSLIM=ffffffff
SS:ESP=0053:02565aac  SSACC=f0f3  SSLIM=ffffffff
EBP=02565b6c  FLG=00010246

PSCRIPT.DRV 0001:0002d46c
=== END ===

Both the crashes produced a SYS3184 error.

Any chance you can troubleshoot this? While printing from your AE editor I was actually getting a "divide by zero" error...but no log in POPUPLOG.OS2.

David McKenna

  • Full Member
  • ***
  • Thank You
  • -Given: 7
  • -Receive: 8
  • Posts: 163
    • View Profile
Re: Anyone successfully using Brother HL-5470dw?
« Reply #31 on: February 12, 2016, 03:45:35 am »
Two suggestions... First, print to file and compare the output Postscript file for both the working and non-working scenarios.
Second, try varying the font used for printing text format (printer object properties, tab 'Text Format', font option).

 Interesting. I printed a small TXT file using AE to file with word wrap on and off using your PSPrint driver with the default font set. I will attach the file and results which are radically different. Maybe you can make sense of it...

Regards
« Last Edit: February 12, 2016, 03:49:38 am by David McKenna »

Dariusz Piatkowski

  • Sr. Member
  • ****
  • Thank You
  • -Given: 12
  • -Receive: 6
  • Posts: 290
    • View Profile
Re: Anyone successfully using Brother HL-5470dw?
« Reply #32 on: February 12, 2016, 05:14:00 am »
...I printed a small TXT file using AE to file with word wrap on and off using your PSPrint driver with the default font set. I will attach the file and results which are radically different....

Interesting indeed...WRAPON includes the embedded font, WRAPOFF does not.

Further on:

WRAPON translates the font to CourierNew
WRAPOFF simply maps it to Courier

Similar to what I'm seeing with PSPRINT driver and high res:
1200dpi embeds CourierNew...while PSPRINT driver with high res but "No embed" maps to Courier only

Meanwhile, PSCRIPT maps to Courier regardless of what resolution I pick.

roberto

  • Sr. Member
  • ****
  • Thank You
  • -Given: 13
  • -Receive: 6
  • Posts: 313
    • View Profile
Re: Anyone successfully using Brother HL-5470dw?
« Reply #33 on: February 12, 2016, 12:49:07 pm »
Hello,
Well, I do not understand what are you doing to get that error.Can you explain in detail your settings .
With the printer HL-5470dw send to ps printing a file , I have no such error, in HQ and with and without font courier new, mark and without mark in options, use downloaded fonts.
I'm using this printer from this psprint-30_905-import3.zip file.

Saludos

Dariusz Piatkowski

  • Sr. Member
  • ****
  • Thank You
  • -Given: 12
  • -Receive: 6
  • Posts: 290
    • View Profile
Re: Anyone successfully using Brother HL-5470dw?
« Reply #34 on: February 13, 2016, 12:11:22 am »
...Well, I do not understand what are you doing to get that error.Can you explain in detail your setting...

I am simply selecting HQ1200 in the Output=>Resolution section of the print driver. The minute I try to send a print job using HQ1200 the actual driver (PSPRINT & PSCRIPT) crashes.

...With the printer HL-5470dw send to ps printing a file , I have no such error, in HQ and with and without font courier new, mark and without mark in options, use downloaded fonts....

OK, but what printer are you actualy using? I did not think you have the same Brother HL-5470DW model that I have. So if you have something different our results may very well be quite different.

Here is another take on this: in the built AuxPrinter pak you kindly made available you have not included the actual PPD, therefore, I can not tell what settings you defined for the HQ1200 and 1200dpi settings. In my case the settings are different, otherwise if the driver simply passes the "<</HWResolution [1200 1200] >>" command to the printer it will not actually set it properly.

Here is what is contained in my final print job, which is a PS file:

%%BeginFeature: *Resolution 1200dpi
<</HWResolution [1200 1200] >> setpagedevice
statusdict/true1200 known{statusdict begin true true1200 end}if
%%EndFeature

So the whole <BeginFeature> -- <EndFeature> is a control string, and this is a different value for 1200dpi vs HQ1200.

Alex Taylor

  • Full Member
  • ***
  • Thank You
  • -Given: 10
  • -Receive: 14
  • Posts: 218
    • View Profile
Re: Anyone successfully using Brother HL-5470dw?
« Reply #35 on: February 13, 2016, 01:39:23 pm »
This crash strongly suggests that PIN couldn't cope with the PPD. 

Try printing using the 'Generic Postscript (Enhanced)' model and see if you have better luck.

roberto

  • Sr. Member
  • ****
  • Thank You
  • -Given: 13
  • -Receive: 6
  • Posts: 313
    • View Profile
Re: Anyone successfully using Brother HL-5470dw?
« Reply #36 on: February 13, 2016, 01:44:38 pm »
Quote
I am simply selecting HQ1200 in the Output=>Resolution section of the print driver. The minute I try to send a print job using HQ1200 the actual driver (PSPRINT & PSCRIPT) crashes.
This is what you would expect . If you want to go with fiat 500 to 300kmh . You're defining your printer as having the ability to print an array of 1200x1200 = 1440000 points , and that is not so. Your printer can only print 2400x600 = 1440000 points. In both cases the final resolution is 1200

Quote
OK, but what printer are you actualy using? I did not think you have the same Brother HL-5470DW model that I have. So if you have something different our results may very well be quite different.
I have not the printer, but David McKenna , he showed us the text , and files generated with the same text, expecting a similar result. As you said , you went out on a line text, overwritten .
Quote
Here is another take on this: in the built AuxPrinter pak you kindly made available you have not included the actual PPD, therefore, I can not tell what settings you defined for the HQ1200 and 1200dpi settings. In my case the settings are different, otherwise if the driver simply passes the "<</HWResolution [1200 1200] >>" command to the printer it will not actually set it properly.
In my reply nº13, I send you linux file for this printer, from the manufacture, for this printer model. And you are using a ppd description from other printer capable to print 1200x1200 us HL-5250dn. I no include it in file psprint-30_905-import3.zip, because the size maximun that i can upload to this foro.
Quote
Here is what is contained in my final print job, which is a PS file:

%%BeginFeature: *Resolution 1200dpi
<</HWResolution [1200 1200] >> setpagedevice
statusdict/true1200 known{statusdict begin true true1200 end}if
%%EndFeature

So the whole <BeginFeature> -- <EndFeature> is a control string, and this is a different value for 1200dpi vs HQ1200.
You want print in a diferent resolution that the manufacture propose for this printer, the error is normal. I untherstand.
Saludos

Dariusz Piatkowski

  • Sr. Member
  • ****
  • Thank You
  • -Given: 12
  • -Receive: 6
  • Posts: 290
    • View Profile
Re: Anyone successfully using Brother HL-5470dw?
« Reply #37 on: February 13, 2016, 03:19:31 pm »
Alex,

This crash strongly suggests that PIN couldn't cope with the PPD. 

Try printing using the 'Generic Postscript (Enhanced)' model and see if you have better luck.

PIN did not produce any import errors...but indeed, it "feels" like something didn't quite go through correctly. The fact that the as-is PPD configuration of moving the Resolution configuration to the Features section does not work implies that the resulting driver import didn't quite configure things correctly.

Is there anything else I can do to better understand what is causing the failure with HQ1200 setting?

Dariusz Piatkowski

  • Sr. Member
  • ****
  • Thank You
  • -Given: 12
  • -Receive: 6
  • Posts: 290
    • View Profile
Re: Anyone successfully using Brother HL-5470dw?
« Reply #38 on: February 13, 2016, 03:40:21 pm »
Roberto,

...This is what you would expect . If you want to go with fiat 500 to 300kmh . You're defining your printer as having the ability to print an array of 1200x1200 = 1440000 points , and that is not so. Your printer can only print 2400x600 = 1440000 points. In both cases the final resolution is 1200

Oh boy, your interpretation of what I'm attempting to do is quite incorrect.

The printer (HL-5470DW) very much has the capability I am instructing it to use. The specs state the following:
1) 1200 dpi = 1200x1200
2) HQ1200 = 2400x600

...so it certainly can print HQ1200 at the resolution I specify in the PPD control string, but it is the additional control parameter that actually "translate" the [1200 1200] to [2400 600] resulting dpi setting.

I've attached the Brother PPD file with the Features section defintion and my final PPD with the Resolution section definition.

...In my reply nº13, I send you linux file for this printer, from the manufacture, for this printer model. And you are using a ppd description from other printer capable to print 1200x1200 us HL-5250dn....

Oh no, that is absolutely incorrect. The PPD files I'm using are the original Brother HL-5470DW PPD files. I am not using another model PPD (as you suggested the HL-5250dn). So from that perspective my results suggest that the Brother PPD defined printer features can not be successfully used in OS/2 given either the PSCRIPT or PSPRINT drivers.

...You want print in a diferent resolution that the manufacture propose for this printer, the error is normal. I untherstand...

No. Again, please take a look at the attached PPD files I am actually working with. These are original Brother HL-5470DW files with only difference being a shift of the Features section to the Resolution section.

I've also attached the Brother SPECs PDF for this particular printer.

Meanwhile, the Linux "driver" files I have looked at all reference CUPS print system. So the actual details of what's contained in the PPD itself actually tell nothing about sending direct JCL statement to the printer, case in point, here is the matching Resolution section:

=== START ===
*%==== 5.14 Finishing Features =================================
*%%%%% Resolution and Appearance Control %%%%%
*OpenUI *Resolution: PickOne
*OrderDependency: 11 AnySetup *Resolution
*DefaultResolution: 600dpi
*Resolution   300dpi: "                      "
*Resolution   600dpi: "                      "
*Resolution   2400x600dpi/HQ1200dpi: "                    "
*Resolution   1200dpi: "                    "
*CloseUI: *Resolution
=== END ===

I've also attached that file to this post.
« Last Edit: February 13, 2016, 03:50:47 pm by Dariusz Piatkowski »

ivan

  • Hero Member
  • *****
  • Thank You
  • -Given: 0
  • -Receive: 24
  • Posts: 650
    • View Profile
Re: Anyone successfully using Brother HL-5470dw?
« Reply #39 on: February 13, 2016, 10:16:59 pm »
Hi Dariusz,

I think the root of the problem is in your statement
Quote
the Linux "driver" files I have looked at all reference CUPS print system

Almost all laser printers have a basic engine resolution of 600 dpi.  Anything above that is provided as a function of the driver with the PPD only telling the driver what to show in is settings page.  This is true for the windows, OS x and CUPS drivers.

I don't think any native OS/2 driver, laser or otherwise, sees anything beyond 600 dpi. By asking for 1200 dpi the driver does not know how to interpret that and, being dumb, sends the wrong code to the printer.

Dariusz Piatkowski

  • Sr. Member
  • ****
  • Thank You
  • -Given: 12
  • -Receive: 6
  • Posts: 290
    • View Profile
Re: Anyone successfully using Brother HL-5470dw?
« Reply #40 on: February 13, 2016, 11:36:01 pm »
...I think the root of the problem is in your statement
Quote
the Linux "driver" files I have looked at all reference CUPS print system

Almost all laser printers have a basic engine resolution of 600 dpi.  Anything above that is provided as a function of the driver with the PPD only telling the driver what to show in is settings page.  This is true for the windows, OS x and CUPS drivers.

I don't think any native OS/2 driver, laser or otherwise, sees anything beyond 600 dpi. By asking for 1200 dpi the driver does not know how to interpret that and, being dumb, sends the wrong code to the printer.

Hmm...OK, point noted. However when I print here there is a very real difference between the output of a 600dpi vs 1200dpi print job. So it appears at least that the PPD supplied Postscript job control "string" does somehow cause the driver itself to format the remainder of the print job into a higher resolution. It is only the HQ1200 setting that causes the OS/2 print driver to crash.

Take a peek at the attached output files, these are a result of:

1) producing a Postscript job on win7 using Brother HL-5470DW Postrcript drivers (win_xxx)
2) producing a Postscript job on OS/2 using Brother HL-5470DW PPD and PSCRIPT driver (pscript_xxx)
3) producing a Postscript job on OS/2 using Brother HL-5470DW PPD and PSPRINT driver (psprint_xxx)
4) producing a Postscript job on OS/2 using Generic Postscript (Enhanced) PPD and PSPRINT driver (as per Alex's earlier suggestion) (genen_xxx)

You will find that in the win7 produced print jobs the ONLY difference is the PPD supplied control string for HQ1200 resolution, namely:

1200dpi
======
featurebegin{
%%BeginFeature: *CAPT SFine
<</HWResolution [1200 1200] >> setpagedevice
statusdict/true1200 known{statusdict begin true true1200 end}if

%%EndFeature
}featurecleanup

HQ1200
======
featurebegin{
%%BeginFeature: *CAPT Fine
<</HWResolution [1200 1200] >> setpagedevice
statusdict/true1200 known{statusdict begin false true1200 end}if

%%EndFeature
}featurecleanup

For some reason that HQ1200 control string is causing our OS/2 driver to die.

Alright...how the heck does one debug a printer driver? Alex??? lol...what's the "secret sauce" to actually do this with?
« Last Edit: February 13, 2016, 11:41:16 pm by Dariusz Piatkowski »

roberto

  • Sr. Member
  • ****
  • Thank You
  • -Given: 13
  • -Receive: 6
  • Posts: 313
    • View Profile
Re: Anyone successfully using Brother HL-5470dw?
« Reply #41 on: February 14, 2016, 03:51:41 pm »
Hello
The 2 files brp5470......ppd are not pscript, are PCL5 or PCL6, this is a HP LaserJet code.
*%==== PostScript Patches ==========
*%*JobPatchFile 1: "statusdict/setusbbinary known{statusdict begin true setusbbinary end}if"

*%==== JCL Features ==========================
*%JCLBegin:           "<1B>%-12345X@PJL JOB<0A>"
*%JCLToPSInterpreter: "@PJL ENTER LANGUAGE = POSTSCRIPT <0A>"
*%JCLEnd:             "<1B>%-12345X@PJL EOJ <0A><1B>%-12345X"

You can comment me your doing your printer with the file that I send to the forum, in these two resolutions
1º      600
2nd  1200

Saludos

Dariusz Piatkowski

  • Sr. Member
  • ****
  • Thank You
  • -Given: 12
  • -Receive: 6
  • Posts: 290
    • View Profile
Re: Anyone successfully using Brother HL-5470dw?
« Reply #42 on: February 15, 2016, 02:17:18 am »
...The 2 files brp5470......ppd are not pscript, are PCL5 or PCL6, this is a HP LaserJet code.
*%==== PostScript Patches ==========
*%*JobPatchFile 1: "statusdict/setusbbinary known{statusdict begin true setusbbinary end}if"

*%==== JCL Features ==========================
*%JCLBegin:           "<1B>%-12345X@PJL JOB<0A>"
*%JCLToPSInterpreter: "@PJL ENTER LANGUAGE = POSTSCRIPT <0A>"
*%JCLEnd:             "<1B>%-12345X@PJL EOJ <0A><1B>%-12345X"
...

I'm sorry, but the very same files you picked that section from start as follows:

=== START ===
*PPD-Adobe: "4.3"
*%================================================
*%   Copyright(C) 2012 Brother Industries, Ltd.
*%   "Brother HL-5470DW BR-Script3"
*%================================================

*%==== General Information Keywords ========================
*FormatVersion: "4.3"
*FileVersion: "1.0"
*LanguageEncoding: OS2-850
*LanguageVersion: English
*Manufacturer: "Brother"
*PCFileName: "BRP5470E.PPD"
*Product: "(Brother HL-5470DW series)"
*PSVersion: "(3010.106) 5"
*ShortNickName: "Brother HL-5470DW BR-Script3"
*ModelName: "Brother HL-5470DW BR-Script3"
*NickName: "Brother HL-5470DW BR-Script3"
...
=== END ===

So YES, these in fact are printer PPDs, they describe the printer controls using Postscript formatting/control statements. The output files I included are also poscript raw jobs, literally, stuff that normally would have gone out to the printer but was instead re-directed to a flat file.

Anyways, the JCL section you pointed out tells the printer to invoke the Postscript interpreter for this particular printer. In fact, the WIN7 generated files actually show this taking effect:

=== START ===
%-12345X@PJL JOB
@PJL SET STRINGCODESET=HPROMAN8
@PJL ENTER LANGUAGE=POSTSCRIPT
%!PS-Adobe-3.0
...
=== END ===

I've attached the "PostScript - Printer Description File Format Specification - PPD_Spec_v4_3" for reference, it goes into much more details then what I can make sense of at the moment...LOL

As I stated before, my printer works great with all resolutions but HQ1200, your PPD definitions do not address this, they are only for standard dpi resolutions.

roberto

  • Sr. Member
  • ****
  • Thank You
  • -Given: 13
  • -Receive: 6
  • Posts: 313
    • View Profile
Re: Anyone successfully using Brother HL-5470dw?
« Reply #43 on: February 15, 2016, 09:08:58 am »
Sorry but I left the thread.
If anyone wants to know more I recommend you read this thread :
http://www.os2world.com/forum/index.php/topic,896.0.html

The psprint-30_905-import3.zip file has an interesting mistake, if you install the printer Brother MFC-L2720DW , if you mark the folder as hold, you can retain the fonts that are sent to the printer.
This error affects only the installation in some cases,and  installing fonts , but not to the printing itself in all its various resolutions .
If after installation you want to delete , you only have to remove the printer, the driver , and rename or delete the psprint folder.
Saludos

Alex Taylor

  • Full Member
  • ***
  • Thank You
  • -Given: 10
  • -Receive: 14
  • Posts: 218
    • View Profile
Re: Anyone successfully using Brother HL-5470dw?
« Reply #44 on: February 15, 2016, 12:18:55 pm »
Interesting. I printed a small TXT file using AE to file with word wrap on and off using your PSPrint driver with the default font set. I will attach the file and results which are radically different. Maybe you can make sense of it...

I think AE either does or causes some weird things with the fonts, I was testing here and couldn't get AE to embed the font at all despite.

Regarding the garbled text, it appears that if a TT font is embedded, the character and line advances are all wrong.  It is wrapping the text, it's just that it thinks each character is a fraction of its proper width, and the line is also not advanced when it wraps (or, probably more accurately, it's calculating the line advance as 0).  I can reproduce this, but I have as yet no answer for why it's happening.  It's quite possible I missed implementing some necessary logic somewhere.  You can circumvent the problem by setting the default text font to a Type 1 font like Courier (not New), since the PS font embedding logic appears unaffected.

This seems to be unrelated to the crash you are getting with the super-fine dpi resolution for the Brother printer.  I will note that I have a Brother printer driver (HL-3075), and if I print a text file with resolution set to anything above 600, the page appears blank (although there is no crash).