Converting the Raspberry Pi to a wireless print server

Installing CUPS

CUPS (Common Unix Printing System) manages printers connected via USB or the network and provides a management interface. You can install CUPS on your system by running:

sudo apt-get install cups

You will want to add the pi user to the lpadmin group, so it can access the administrative functions of CUPS:

sudo usermod -a -G lpadmin pi

After the install, CUPS runs as a system service and provides a management interface on the local system. If the network on which the Rasp Pi resides is trustworthy – and that is the case with your home LAN – just run

sudo cupsctl --remote-any
sudo /etc/init.d/cups restart

to access CUPS on the network. The management interface is then available via the IP address of the Raspberry Pi in your web browser – in this example, at http://192.168.0.100:631/.

Setting Up the Printer

To install the printer, go to the CUPS web interface Administration menu and press the Add Printer button. The interface now switches to administration mode and prompts you for a username and password. You can use the pi user account set up previously.

If the printer itself (here, the Canon Pixma MP160) is connected via USB and turned on, CUPS automatically detects and displays it. Select the MP160, and then press Next. You can now enter a description for the device and share the printer on the network. In the next step, select the driver Canon PIXMA MP160 - CUPS+ Gutenprint v5.2.9 (en). A click on Add printer takes you to the default settings, where you typically do not need to change anything.

If all goes well, the printer is then available via CUPS. A click on the Canon_MP160 link shows you the printer, and you can select Print test page in the upper left selection to check to see whether the device works as desired.

Buy this article as PDF

Express-Checkout as PDF

Pages: 4

Price $2.95
(incl. VAT)

Buy Raspberry Pi Geek

SINGLE ISSUES
 
SUBSCRIPTIONS
 
TABLET & SMARTPHONE APPS
Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content