Can I print from Home Assistant OS running on RaspberryPi4 w/ Wireless Printer?

I have a Canon Printer on my network (it’s connected via WiFi).

Can I somehow run a script to print a PDF from HAOS?

I tried using the “Advanced SSH & Web Terminal” add-on and running the following linux command to see connected printers on my network:
lpstat -p

but unfortunately it didn’t recognize that command. [I’m guessing HAOS doesn’t support all linux commands, but I’m still a newbie with this stuff]

I’m also seeing references to CUPS in the forum, but don’t see any add-ons to install, and unclear if I need that first before I can run command lines?

I would appreciate any help - thank you!

The SSH addon only supports a subset of standard Linux commands. Out of curiosity, why do you want to print from HA?

There are some cups addons floating around, eg GitHub - ncarr/addon-repository: Nicholas' Home Assistant addon repository

However it hasn’t had any attention for 3 years. You could give it a try.

Thanks for highlighting - I was hoping to schedule a simple print test file every few weeks to keep my inkjet printer from drying out (the new tank models need deep cleans if you don’t use them frequently)

Thanks - I’ll try those and see if I can get working - appreciate the help!

Interesting. I had to start doing the same a while ago. A scheduled task on my PC prints a printer status page every 15 days. Printer ink is a scam.

1 Like

It is - and the design is terrible:(

I’ll probably do the same and keep computer on to do the job if I can’t figure out this cups solution (would prefer all automation be centralized and not require my computer be on

Many printers can can accept jobs via other protocols like FTP, SMTP and HTTP.

Depending on your printer model, that may be an easy option. For example, use the SMTP integration to point to the IP of your printer, then use the notify service to send something via SMTP to be printed.

Check the web interface of your printer/documentation to see what is available.

1 Like