Introduction: Make a Scanner Wireless
This tutorial describes how to convert a usb scanner to wireless using a Raspberry Pi. Once setup, you will be able to scan documents, convert the scanned document to PDF, and then transfer the document wirelessly via WiFi to any computer in your home.
Best of all, your flatbed scanner doesn't need to be anywhere near your laptop or PC.
- Raspberry Pi 3 Microcontroller (Purchase on Amazon)
- USB Cable ( Use the cable you used to connect your scanner to your PC)
- Raspberry Pi Power Adapter (Purchase on Amazon)
- Ethernet cord
- Home WiFi Network
- USB Flatbed scanner
- Compatible scanners can be found here:
Ensure that your scanner is compatible, before starting this project.
Step 1: Get Your Pi Working in Headless Mode
Obviously, your Pi isn't wireless after following the steps in this video. Step 2 will go into detail on how to accomplish this.
Since your Pi is going to be plugged into a scanner, my guess is that you do not want a monitor, mouse, or keyboard plugged into the Pi when it's doing this task for you. If this is the case, you can use the above YouTube tutorial to setup a Raspberry Pi without a keyboard or mouse ever being plugged into it.
For notes and web-links I refer to in the video, see the below notes
To find the default gateway, in other-words known as your router’s IP address, type this command into the windows command prompt: ipconfig
To get putty for windows, go to this web address
Default username and password for the PI
This is the command, I used at the SSH prompt to get the PI’s VNC settings:
To download VNC viewer for Windows or Mac, go to
Some alternative notes for macOS users
Find your local Default Gateway using a Macintosh computer:
To see how to activate VNC on the Macintosh, watch this video
Step 2: Connect Your Raspberry Pi to WiFi
If as of now, your Pi is connected via a wired ethernet connection to your router as shown in the main video from step 1, do as follows:
- Connect to Raspberry Pi via VNC as shown from the keyboard / mouse workaround video in step 1
- Connect to your wireless network as shown in the tutorial found at the below link
Now that your Pi is connected to WiFi
- You can now unplug your Pi's ethernet and power cord
- Move your Pi to wherever your scanner is located
- Plug your Pi into power
Step 3: Make Usb Scanner Wireless
Important: Watch the embedded video for this section before continuing.
Below are the notes for the embedded video
Below are all websites and command prompt commands presented in this video
Determine if your scanner is compatible: http://www.sane-project.org/sane-supported-devices.html
To download the Fing app for your phone: https://www.fing.io/
Commands that were used to install the SANE software
aptitude install xinetd sane-utils
To run any of the commands between the dotted lines, you must be in the sane SANE space. To get to the SANE user space from the command prompt, input the below command:
Setup the software once in the SANE user space:
To start the sane software:
su -s /bin/sh - saned
To get the manufacturer and the name of your scanner:
Allow the sane software to write to the Documents directory:
chmod 777 Documents
Below was the command that I used to scan the document:
scanimage -d 'pixma:04A91712_14799B' --resolution 300 -x 2550 -y 3300 > /home/pi/Documents/essayoutline.ppm
Remember: 'pixma:04A91712_14799B' was the name of the scanner that I was connected to.
Step 4: Convert Scanned Image to PDF
Follow the instructions in the below video to convert scanned image to PDF. For multipage PDF's see the below notes.
Below, are the commands that you must type into the terminal to install the imagemagick software:
sudo apt-get update
sudo apt-get install imagemagick
The convert command that produces a pdf document from an image file is as follows:
convert -density 300 /file path/filename -compress JPEG /file path/file name.pdf
Note: filename includes the image file extension
If you have more than 1 page (Below example is if you had two files)
convert -density 300 /file path/filename1 /file path/filename2 -compress JPEG /file path/file name.pdf
This was the line I entered from the video: (Keep in mind it was only one page)
convert -density 300 /home/pi/Documents/essayoutline.ppm -compress JPEG /home/pi/Documents/essayoutline.pdf
Step 5: Transfer the Scanned Documents From Raspberry Pi to Computer
Disclaimer: The video tutorials for both Windows and macOS were not made by me. These videos were exceptionally great, so I do not see the need to reinvent the work of others. I've pasted links to their YouTube channels, so please check them out.
I have only watched this video and have not actually done this myself. Their video was very clear and concise, so I have gone ahead and promoted it here for it's quality.
Credit for the above video: Brush Automation
Alexander has created an awesome tutorial here. I did exactly as he described, and everything worked beautifully.
Credit for the video: Alexander Baran-Harper
For iPhone and iPad
I've tested the software myself to ensure it works as advertised. Keep in mind that the software I am recommending for grabbing files from the Raspberry did cost $7.00 Canadian at the time this article was written.
If you want to use the iFiles 2 software, you will have to do as follows:
On your Raspberry Pi, install the netatalk software. Below are the commands that you will need to input at the Raspberry Pi's terminal to install the software.
sudo apt-get update sudo apt-get install netatalk
If you so desire, you can download the iFiles 2 software here:
See this video to see how to connect iFiles 2 to your Raspberry.
If you need to get your Raspberry's IP address, remember that you can use the fing app (See below link)
Step 6: Automate Using Bash (Optional)
Using bash (shell) scripting we can automate the entire process of scanning a document with our scanner and then even convert it to a multipage pdf document.
For the bash code, goto my GitHub account
Once you have the code found at the above link, you will have to paste it into a text file on your Pi. Watch the below video for further instruction
To run the script file:
- Double Click on it
- Click Execute in Terminal
Participated in the
First Time Author Contest