Two issues(?), with default_margins and output_PNG

keenerb
Posts: 23
Joined: Sun Sep 10, 2023 12:34 am

Two issues(?), with default_margins and output_PNG

Post by keenerb »

Using Epson 9-pin, output to pdf
Printouts look good, graphical printouts span two pages.
I changed default_margins to No, printouts are now on one page but not centered.
Removing No and setting a single line default margin of 7,4,0,0 (to center printout) results in no PDF after capture and processing lights stop blinking.

Setting default margin to 7,4,1,1 results in correct output, not sure if that qualifies as a bug but may need clarification in manual?

Setting output_PNG to File results in no processing at all. Once capture is complete, the processing LED never blinks and I never see an output file created in PNG or PDF folders.
RWAP
Site Admin
Posts: 405
Joined: Wed Sep 13, 2017 9:20 pm
Location: Oswestry, Shropshire
Contact:

Re: Two issues(?), with default_margins and output_PNG

Post by RWAP »

Hmm that is interesting - I have not used output_PNG for a long time.

Yes, there is a bug in default margins of 7,4,0,0 so that would explain - I will correct this
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: Two issues(?), with default_margins and output_PNG

Post by RWAP »

Just a question - what settings did you have for output_PNG and create_PDF ?

Are there any errors shown in the logs in /home/pi/data
Retro-Printer Specialists
RWAP Software
RWAP Adventures
SellMyRetro
Retro-Printer Module

Also Involved in:
Icephorm
keenerb
Posts: 23
Joined: Sun Sep 10, 2023 12:34 am

Re: Two issues(?), with default_margins and output_PNG

Post by keenerb »

RWAP wrote: Tue Apr 30, 2024 10:39 am Just a question - what settings did you have for output_PNG and create_PDF ?

Are there any errors shown in the logs in /home/pi/data
root@Retro-Printer:~/config# cat output_PNG
File

root@Retro-Printer:~/config# cat output_PDF
Yes

Ideally I'd like to capture and save both the PNG and the PDF of a file output.

I truncated the logs, sent a job with output_PNG enabled, and nothing was appended to either of the logs in the /home/pi/data folder:

-rw-r--r-- 1 root root 0 Apr 30 08:34 convert-error.log
-rw-r--r-- 1 root root 0 Apr 30 08:34 convert.log

A .raw file was created:

-rw-r--r-- 1 root root 2052 Apr 30 08:37 36.raw

It also fails with output_PDF set to No, so it seems to be wholly an output_PNG issue.

My GUESS would be that whatever folder the "File" option for PNG creation uses might not exist or have a permissions error, but I don't know where that is.
Last edited by keenerb on Tue Apr 30, 2024 12:57 pm, edited 1 time in total.
RWAP
Site Admin
Posts: 405
Joined: Wed Sep 13, 2017 9:20 pm
Location: Oswestry, Shropshire
Contact:

Re: Two issues(?), with default_margins and output_PNG

Post by RWAP »

/root/output_PNG should be set to File (memory stores the image in the memory only).
Retro-Printer Specialists
RWAP Software
RWAP Adventures
SellMyRetro
Retro-Printer Module

Also Involved in:
Icephorm
keenerb
Posts: 23
Joined: Sun Sep 10, 2023 12:34 am

Re: Two issues(?), with default_margins and output_PNG

Post by keenerb »

RWAP wrote: Tue Apr 30, 2024 12:49 pm /root/output_PNG should be set to File (memory stores the image in the memory only).
Sorry, I've been tinkering with it all morning. "File" is when it fails to generate anything. "Memory" is when it works. I updated the post.
RWAP
Site Admin
Posts: 405
Joined: Wed Sep 13, 2017 9:20 pm
Location: Oswestry, Shropshire
Contact:

Re: Two issues(?), with default_margins and output_PNG

Post by RWAP »

I have emailed you some files for testing - this appears to fix both of your issues for me.
Retro-Printer Specialists
RWAP Software
RWAP Adventures
SellMyRetro
Retro-Printer Module

Also Involved in:
Icephorm
keenerb
Posts: 23
Joined: Sun Sep 10, 2023 12:34 am

Re: Two issues(?), with default_margins and output_PNG

Post by keenerb »

Code: Select all

root@retro-printer:/home/pi/temp/sdl/escparser# ls -la
total 1968
drwxr-xr-x  5 root root   4096 Apr 24 10:46 .
drwxr-xr-x  3 root root   4096 Sep 14  2023 ..
-rwxr-xr-x  1 root root 101868 May  1 17:31 convert-apple
-rwxr-xr-x  1 root root  93388 May  1 17:31 convert-dmp
-rwxr-xr-x  1 root root 118660 May  1 17:31 convert-escp2
-rwxr-xr-x  1 root root  84392 May  1 17:31 convert-escpage
-rwxr-xr-x  1 root root  79840 Apr 11 12:23 convert-flasher
-rwxr-xr-x  1 root root  97548 May  1 17:31 convert-ibm
-rwxr-xr-x  1 root root  88992 May  1 17:31 convert-lps300
-rwxr-xr-x  1 root root 107184 May  1 17:31 convert-mt660
-rwxr-xr-x  1 root root 127968 May  1 17:31 convert-mtplesc
-rwxr-xr-x  1 root root  84596 May  1 17:31 convert-pcl
-rwxr-xr-x  1 root root 102312 May  1 17:31 convert-printronix
-rwxr-xr-x  1 root root 105752 May  1 17:31 convert-pt88
-rwxr-xr-x  1 root root  98148 May  1 17:31 convert-qt2100
-rwxr-xr-x  1 root root  79868 May  1 17:31 convert-raw
-rwxr-xr-x  1 root root  80068 May  1 17:31 convert-rawjobs
-rwxr-xr-x  1 root root 158280 May  1 17:31 convert-seiko
-rwxr-xr-x  1 root root 106088 May  1 17:31 convert-sp700
-rwxr-xr-x  1 root root  84176 May  1 17:31 convert-txt
drwxr--r-- 14 root root   4096 Sep 14  2023 fonts
drwxr--r--  2 root root   4096 Sep 14  2023 library
-rwxr-xr-x  1 root root 163728 May  1 17:31 retroprinter
-rwxr-xr-x  1 root root    107 Dec 21  2022 retroprinter-restart.sh
-rwxr-xr-x  1 root root     76 Dec 21  2022 retroprinter-stop.sh
drwxr-xr-x 12 root root   4096 Oct  7  2021 WiringPi
Did a fresh install from your latest download, uploaded the contents of that zip file, and verified that it will create pdfs. output_PNG still never triggers the blinking orange light or process data.
keenerb
Posts: 23
Joined: Sun Sep 10, 2023 12:34 am

Re: Two issues(?), with default_margins and output_PNG

Post by keenerb »

I may have done something wrong with your new release anyway. It is currently acting as if timeout is set to -1, even though it's set to 4 in the text file.

Is this expected output for retroprinter-restart.sh ?

root@retro-printer:/home/pi/temp/sdl/escparser# ./retroprinter-restart.sh
retroprinter will be killed
./retroprinter-restart.sh: line 1: 877 Killed /etc/init.d/retroprinter stop
inotifywait: no process found
Traceback (most recent call last):
File "/home/pi/rtc/USB-RTC-Key/UPDATE_RaspberryPi.py", line 10, in <module>
from JAUSBRTC import JAUSBRTC
File "/home/pi/rtc/USB-RTC-Key/JAUSBRTC/JAUSBRTC.py", line 7, in <module>
import hid
ModuleNotFoundError: No module named 'hid'
retroprinter will be started


I see some missing modules and errors.
keenerb
Posts: 23
Joined: Sun Sep 10, 2023 12:34 am

Re: Two issues(?), with default_margins and output_PNG

Post by keenerb »

Alrighty, your updated files work.

PNG is being created, PDF is being created.

One problem is that the timeout doesn't seem to be working with your new files. When I hit print screen on an msdos window the green "data receive" light flashes but never proceeds to "processing." If I then print a file from, say, Works, it appends the prtscr buffer in front of the document.

So a mixed bag, progress but with a small regression it seems!
Post Reply