print direct setup

cory thompson
Posts: 13
Joined: Thu Feb 17, 2022 1:02 pm

print direct setup

Post by cory thompson »

Hi all,

I'm looking for some help.
I have some old controllers manucatured by the compny I work for. I have a options to print using ASCII, Kyocera, Brother, HP PCL5, Epson, and Microline.

I am able to print via the retro printer using various of the above modes, along with output_PDF, output_printer.

I would like to print direct, removing the processing, to speed thing up, but I can't get it to work.
I've tried various option following the manual, and rebooting the pie each time. I've tried with and without a printer installed.

I'm now wondering if the printer I have is too new? Its a HP Laserjet pro M404DN I can install the pcl6 cups driver and test print works. if I install the pcl5 driver and test print, the printer will warm up as if its going to print but halts.

I'm now wondering if because the HP printer is pcl6 and Im sending pcl5 that this may be my issue.

/usr/sbin/lpinfo -v returns direct :usb://HP/LaseJet........
I dont know if this is correct.

Has anyone any suggestions on using usb_passthrough and a compatible laser printer?

Thanks all.
cory thompson
Posts: 13
Joined: Thu Feb 17, 2022 1:02 pm

Re: print direct setup

Post by cory thompson »

Just to add to this.

I sent a command: echo test > /dev/usb/lp0

The printer lit up and the display showed that it was printer. no paper comes out until I unplug the usb and then the test page is printed.

I suppose this means the printer is available on lp0

Thanks
RWAP
Site Admin
Posts: 512
Joined: Wed Sep 13, 2017 9:20 pm
Location: Oswestry, Shropshire
Contact:

Re: print direct setup

Post by RWAP »

I admit that the usb_passthrough has never really been tested by me in anger, I can only assume it works as designed as we basically capture the incoming data and echo it direct to the usb printer ("/dev/usb/lp0").

I guess the problem may well be as you say that the HP Laserjet printer does not understand the PCL5 data (as you cannot print a test page using a PCL5 driver). I am however, surprised as I thought most (if not all) PCL printers were backwards compatible. You do of course also need to ensure that the controllers are set to output to HP PCL5

Unfortunately, I don't actually have a HP printer at the moment to test this mode.

By the way - are you using the latest v3.15c software image - that is certainly quicker than previous versions.

One thing you could try, is to enter the following:

Code: Select all

cd /home/pi/temp/sdl/escparser
./retroprinter-stop.sh
./retroprinter 4 3
Then try printing and see if you get any error messages or warnings on screen.

You might also want to try

Code: Select all

nano /root/config/test_mode
Set this to yes, and see if you get any more information - I don't think you will see much in usb_passthrough!
Retro-Printer Specialists
RWAP Software
RWAP Adventures
SellMyRetro
Retro-Printer Module

Also Involved in:
Icephorm
RWAP
Site Admin
Posts: 512
Joined: Wed Sep 13, 2017 9:20 pm
Location: Oswestry, Shropshire
Contact:

Re: print direct setup

Post by RWAP »

cory thompson wrote: Thu Feb 17, 2022 4:04 pm Just to add to this.

I sent a command: echo test > /dev/usb/lp0

The printer lit up and the display showed that it was printer. no paper comes out until I unplug the usb and then the test page is printed.

I suppose this means the printer is available on lp0

Thanks
You would normally need to add a $0c byte to signify end of page - the printer will be waiting until it has a full page of information before printing.

Have you tried using the output from the controllers as ASCII ??
Retro-Printer Specialists
RWAP Software
RWAP Adventures
SellMyRetro
Retro-Printer Module

Also Involved in:
Icephorm
cory thompson
Posts: 13
Joined: Thu Feb 17, 2022 1:02 pm

Re: print direct setup

Post by cory thompson »

I'll give these commands a try. I've tried setting the emulation to txt and to epson, setting my controllers to ASCII and epson respectively but these dint help, only produced the same, prints with processing.
cory thompson
Posts: 13
Joined: Thu Feb 17, 2022 1:02 pm

Re: print direct setup

Post by cory thompson »

With the suggested commands, it looks to be writing the raw file ok.

No more data received from centronics port
write /tmp/24.raw
4 sec over
command = cp /tmp/24.raw /home/pi/data/raw/24.raw
No more data received from centronics port
4 sec over

I dont see any errors.

Forgot to mention I'm on v3.15

Thanks
Cory.
cory thompson
Posts: 13
Joined: Thu Feb 17, 2022 1:02 pm

Re: print direct setup

Post by cory thompson »

I've been at it again this morning.

I can verify I have a default printer using "lpstat -d" and I can print the txt files sent from our controllers using "lp filename.txt"
I can see a raw file enter the folder after my controller send a print job and I can open it and looks as expected. It just won't print automatically. :cry:
If I try print the raw file "lp 26.raw" the printer displays printing but halts until I unplug the usb.

I sort of visualise this working with ASCII best for my needs. e.g. I print a text file to the pi, then some process monitors the folder for new files and prints them, and maybe then stores them in a completed folder for a while, in case something goes wrong with the print, but ideally this would be factored in.

Unfortunately I lack the skill set to do this in linux.
cory thompson
Posts: 13
Joined: Thu Feb 17, 2022 1:02 pm

Re: print direct setup

Post by cory thompson »

IMG_20220218_154721.jpg
IMG_20220218_154721.jpg (109.95 KiB) Viewed 10950 times
I've set the output_printer to yes and run suggested commands again and managed to get the attached image to print, although the information is jiberish, it may be relevant to my issue?
RWAP
Site Admin
Posts: 512
Joined: Wed Sep 13, 2017 9:20 pm
Location: Oswestry, Shropshire
Contact:

Re: print direct setup

Post by RWAP »

Potentially - as it happens I need to get a new printer today, so will get a HP printer.

If you can send me some captured raw files that would help.

Also try setting:

Code: Select all

nano /root/config/bit_depth
to 7
Retro-Printer Specialists
RWAP Software
RWAP Adventures
SellMyRetro
Retro-Printer Module

Also Involved in:
Icephorm
cory thompson
Posts: 13
Joined: Thu Feb 17, 2022 1:02 pm

Re: print direct setup

Post by cory thompson »

Thank you.
I'll send some over when I get back to the office.

I have also tried a Samsung printer, the latest retro printer software, sending print jobs from a pc, albeit with a usb to centronics adapter, and various drivers but the outcome is the same.
Post Reply