bash after collecting data

Discussion as to what further enhancements people would like to see in the software
Post Reply
jorampic
Posts: 2
Joined: Sat Jan 26, 2019 3:08 pm

bash after collecting data

Post by jorampic »

hello, is it possible after when the printer has stored or forwarded his data we will be able to do a bash file script, so that we can send the data via ftp to a server? or can do other things?

Greetings from belgië
RWAP
Site Admin
Posts: 405
Joined: Wed Sep 13, 2017 9:20 pm
Location: Oswestry, Shropshire
Contact:

Re: bash after collecting data

Post by RWAP »

Hi - welcome to the forums.

Yes, the easiest way of doing this would be to set up a script to monitor /home/pi/data/raw for new files and copy them to FTP server.

If you have a look at home/pi/printpcl.sh file as this is what we do for printing captured PCL data.
Retro-Printer Specialists
RWAP Software
RWAP Adventures
SellMyRetro
Retro-Printer Module

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

Re: bash after collecting data

Post by RWAP »

In v3.7 of the Retro-Printer software, this has now been updated to make it easier to understand printpcl.sh and how it works so you can modify it there if you are using the HP conversion.

If you are using Epson ESC/P2 conversion routines, then you can now add a new bash script /home/pi/CustomScript.sh which is launched every time that a page is processed. We pass in 3 parameters - the output_path, the page (print job) being processed and the page number.

To use this, you will need to set /root/config/launch_script to Yes
Retro-Printer Specialists
RWAP Software
RWAP Adventures
SellMyRetro
Retro-Printer Module

Also Involved in:
Icephorm
Post Reply