michaelrsweet / lprint

A Label Printer Application
https://www.msweet.org/lprint
Apache License 2.0
219 stars 29 forks source link

Save server configuration & start as daemon #42

Closed CyrosX closed 2 years ago

CyrosX commented 2 years ago

Dear michaelrsweet,

Thanks for your hard work! I have some questions regarding the server mode. What I want to achieve is making a Dymo 450 Duo available to a cups server on another server (same network). This works, but there is a problem.

"lprint server -o server-port=8631 -o server-name=dietpi &" I'm using this command as an autostart on a Raspberry Pi Zero W with DietPi.

So my questions are: Is there another way of "daemonizing" the server? I've installed the package with apt. lib-cups and some other needed packages were installed, but no full cups. Is there another auth-server than cups, which can be used? Maybe system users?

-- Also I cannot modify the printers. :'( We're using yellow DYMO D1 as tape (12x7000mm) and white LW Adress Labels (36x89mm) as labels (dymo-450-label)

user@DietPi:~# lprint modify -d dymo-450-tape -o print-content-optimize=text lprint: Unable to modify printer - Unsupported print-content-optimize-mode-default keyword value.

michaelrsweet commented 2 years ago

@CyrosX You can actually setup a systemd service file to run the server command and collect the logs via stderr ("-o log-file=-").

As for an auth-server, I'm not sure what you mean? What are you trying to do with authentication?

WRT modifying printers, what version of LPrint are you using - my last release or the current Git code? The "print-content-optimize" option really doesn't do anything for the Dymo printers, but you should be able to set any supported value as the default...

CyrosX commented 2 years ago

@michaelrsweet Thank you very much! I've created a systemd service and it's working fine :). The auth-server thing was about modifying via web interface, but I don't really need it (now). I'm using the version in the Debian repos - its 1.0-1, which seems to be the same as the snap (non-edge) version. Should I compile it myself with the git code (Raspberry Pi Zero W)? Right now I'm facing some problems - the printer only prints negative pages somehow (pdf). I'm using now smaller labels, but when I try to modify the printer like this:

lprint modify -d dymo-450-label -o media-ready=oe_return-address-label_0.75x2in

Nothing seems to change - in the .lprintrc file did nothing change either. I've tried to create the printer with the right options from the beginning, but same result.

On a remote cups (a shared linux print sever) I used this command to add it, and set the label size. But there is no option to set something concerning this negative color thing.

lpadmin -p dymo-450-label -v ipp://fqdn:8631/ipp/print/dymo-450-label -E -m everywhere

Also tried driverless for creating the ppd's (seems to enable one or two options more).

What seems to work on Mac (to remote lprint) is setting up the queue with the original drivers, not the everywhere. I've extracted some informations from the ppd and compared. Option -o raw & fit-to-page does not seem to get set.

-> everywhere Version with set options -o PageSize=0.75x2 -o PageRegion=0.75x2 -o ImageableArea=0.75x2 -o PaperDimension=0.75x2 -o InputSlot=MainRoll -o ColorModel=Gray -o Resolution=300dpi -o cupsPrintQuality=Normal

-> original driver version with set options -o ColorSpace=Gray -o PageSize=w54h144 -o PageRegion=w54h144 -o ImageableArea=w54h144 -o PaperDimension=w54h144 -o DymoContinuousPaper=0 -o Resolution=300x600dpi -o DymoHalftoning=ErrorDiffusion -o DymoPrintDensity=Normal -o DymoPrintQuality=Graphics -o Font=Courier

michaelrsweet commented 2 years ago

@CyrosX Sorry for the delay in responding - what do you mean by "negative pages"?

I'm getting ready to release v1.1, which requires PAPPL (recently released v1.1.0) and might fix some of the issues you are seeing.

On macOS clients, they should see the printer as AirPrint and be able to use it directly without needing to manually add it. But regardless the print options will be different from the DYMO driver which uses a bunch of non-standard options and values...

michaelrsweet commented 2 years ago

@CyrosX Please file a new if you still have problems with v1.1...