How to Turn Your Raspberry Pi into a 3D Printing ‘Factory’ with OctoPi!

How to Turn Your Raspberry Pi into a 3D Printing 'Factory' with OctoPi!

Octoprint official link: https://octoprint.org/
OctoPrint is a powerful open-source software for remotely controlling and monitoring one or multiple 3D printers. You can start, stop, or pause prints, and even change print temperature and settings during the print process. Additionally, it supports video streaming or capturing images during printing. It can achieve almost all the functionalities you need. With various available plugins, you can even obtain advanced features like receiving notifications via WhatsApp when printing is complete or posting print progress on social media.
What is OctoPrint?
OctoPrint is a free open-source 3D printer control software that provides a web interface for remote monitoring and managing 3D printers. After connecting to your printer via USB, you can control and monitor the printing process using any device with a web browser, and even adjust printing parameters in real-time. OctoPrint processes and connects through Raspberry Pi, a low-cost single-board Linux computer, making it easy to use and powerful.
How to Turn Your Raspberry Pi into a 3D Printing 'Factory' with OctoPi!
OctoPrint was developed by Gina Häußge in 2012 and has become one of the most popular 3D printing control tools in the maker community. Continuous updates and regular releases of new features have made it highly regarded in the 3D printing field.
The main operating platform for OctoPrint is OctoPi, a Raspberry Pi image pre-installed with OctoPrint. OctoPi simplifies the setup process, allowing you to connect your 3D printer to OctoPrint in just a few easy steps and start utilizing its various powerful features, such as remote control, real-time monitoring, time-lapse video recording, temperature curve display, G-code viewing, and real-time monitoring of the printing process via a webcam.
Core Features of OctoPrint
  • Remote Control and Monitoring: Control and monitor every detail of your 3D printer and print jobs through any web browser.

  • Webcam Integration: View the printing process in real-time with HD video streaming (requires a compatible webcam).

  • G-code Viewer: Visualize the G-code being executed during the print process in real-time for analysis and adjustment.

  • Temperature Control: Adjust the temperatures of the hotend, print bed, and print chamber in real-time to ensure print stability.

  • Print Job Management: Upload, start, pause, resume, and cancel print jobs remotely, easily managing multiple print tasks.

  • Custom Controls: Create custom buttons to perform specific printer operations (like homing axes, extruding filament, etc.) to improve operational efficiency.

  • Plugin System: Expand OctoPrint’s functionalities through a rich library of plugins to meet specific application needs.

OctoPrint allows you to have more control over your 3D printing. Follow this step-by-step setup guide to learn how to install OctoPi on your Raspberry Pi!
For many 3D printers, you need to upload the files to be printed via the SD card slot or USB port. This means every time you want to print, you have to, for example, insert the SD card into your computer, load the G-code onto the card, and then insert it back into the 3D printer. Printers without an SD card slot need to be connected to the computer throughout the printing process.
With OctoPrint, you won’t have such inconveniences. You can access the printer via Wi-Fi and perform many tasks, such as uploading and starting prints, monitoring prints through a live camera, recording time-lapse videos, controlling the printer, and more! It is a very popular tool among 3D printing enthusiasts, greatly enhancing the user experience.
In this article, we will show you how to install OctoPi on one of the Raspberry Pi motherboards, which is one of the most well-known and commonly used single-board computers (SBCs). Once OctoPi is up and running, you can add various features and options provided by OctoPrint.

OctoPrint Setup: How to Install OctoPi on Raspberry Pi

What Do You Need?

How to Turn Your Raspberry Pi into a 3D Printing 'Factory' with OctoPi!

To get started with OctoPrint, you will need the following items:
  • Raspberry Pi: OctoPrint strongly recommends using Raspberry Pi 3B, 3B+, 4B, or Zero 2 W models. Raspberry Pi 1 and 2 versions are compatible with OctoPrint but are not officially supported, while Pi Zero and Zero W are “not explicitly recommended.” As of the writing of this article, Raspberry Pi 5 is also not supported. Unsupported motherboards may experience performance issues, potentially negatively impacting the 3D printing process, so use them at your own risk. This tutorial will only cover installations on the recommended motherboards.
  • Power Adapter for Pi: This item is often overlooked but is crucial for ensuring the motherboard receives enough power. According to the official documentation, all models require a 5.1V power supply, but power connections vary by model (3B/3B+ and Zero 2W use Micro-USB, while 4B uses USB Type-C). The current also depends on the motherboard model (3B/3B+ and Zero 2W require 2.5A, while 4B requires 3.0A). Low voltage during printing may also lead to performance issues.Warning: Cheap phone chargers may not provide sufficient current for the Raspberry Pi. Therefore, it is best to use a high-quality power adapter rated for at least 3 amps. The official power adapter would be a good choice. Additionally, high-quality USB cables should be used to ensure proper power supply.
  • Micro or Full-Size SD Card: You need a card suitable for your Pi (possibly MicroSD), and if your computer only accepts full-size SD cards, you will also need an SD adapter or USB card reader. Unless you plan to queue print a lot of content through OctoPrint, an 8GB card should be sufficient. For users planning to regularly make time-lapse videos, a 16GB or 32GB card may be more appropriate.
  • USB Cable: Used to connect the Raspberry Pi to the 3D printer. Please note what type of connection your 3D printer has—USB Type-A, Type-B, Mini, or Micro. The Pi end is USB Type-A. We also recommend taping over the 5V pin of the USB cable to prevent your Raspberry Pi from inadvertently attempting to power the printer’s controller board. Many printers (like the Ender 3 Pro with an 8-bit board) are known to cause many issues (such as low voltage warnings, unstable Wi-Fi). So this will help you avoid potential problems later on.
Of course, you also need a 3D printer compatible with OctoPrint.

Flashing the OctoPi Image

How to Turn Your Raspberry Pi into a 3D Printing 'Factory' with OctoPi!

The easiest way to run OctoPrint is to start the Raspberry Pi by flashing the OctoPi image. To do this, you need a tool to flash the SD card. We recommend using the Raspberry Pi Imager, which is available for Windows, MacOS, and Linux.
https://www.raspberrypi.com/software/
Before you start, please note that after flashing the OctoPi image on the Raspberry Pi, you do not need to install OctoPrint separately. It is included in the OctoPi installation, so no further installation is required afterward.
Here’s how to do it:
  1. Download and install the Raspberry Pi Imager from the Raspberry Pi Foundation.
  2. Insert the SD card into your computer or connect it using an adapter. There is no need to format the SD card beforehand.
  3. Open the Raspberry Pi Imager, click on “Choose OS” under “Operating System.”
  4. Then go to “Other Specific OS > 3D Printing > OctoPi.” The latest version should be there.
  5. Click the gear button in the bottom right corner to open “Advanced Options.”
  6. Under “Set Username and Password,” add a system password. Make sure to keep the username as “pi,” as this username and password are only used for SSH connections, not for logging into OctoPrint.
  7. Next, you can add Wi-Fi settings for the Raspberry Pi. Check the “Configure Wi-Fi” checkbox and enter your network SSID and password.
  8. Select your country code from the “Wi-Fi Country” dropdown menu. Click “Save.”
  9. Return to the main window, click “Choose Storage,” and select the SD card.
10. Click “Write,” and the Raspberry Pi Imager will download and install the OctoPrint image.
Once the installation is complete, the software will perform a quick verification, and you should be ready to go.
For more guidance, please check the Raspberry Pi YouTube tutorial.
Get the latest version of OctoPi from GitHub: https://github.com/guysoft/OctoPi

How to Turn Your Raspberry Pi into a 3D Printing 'Factory' with OctoPi!

Alternatively, you can also use Etcher, a free tool for Windows and MacOS. Here are the steps:https://etcher.balena.io/
  1. Download the latest version of OctoPi from the GitHub repository.
  2. Extract the downloaded image file. You should get an image file ending with “.img.”
  3. Insert the SD card into your computer. Again, there is no need to format the card beforehand.
  4. Open Etcher, select your SD card, choose the OctoPi image, and click “Flash.”
Once the flashing is complete, you can start using it!

Setting Up Wi-Fi

Make sure to uncomment your country code (Source: Lucas Carolo via All3DP)
How to Turn Your Raspberry Pi into a 3D Printing 'Factory' with OctoPi!
If you set up Wi-Fi using the Raspberry Pi Imager, please skip directly to the “Connecting Pi to Printer” section of this tutorial. Otherwise, follow the steps below to manually configure your Wi-Fi information.
  1. If the SD card was ejected after flashing with Raspberry Pi Imager or Etcher, make sure to reinsert it into the computer.

  2. Open your SD card directory (usually named “boot”). It should be located where external drives typically show up.

  3. There are many files here, but don’t be afraid. We are looking for the “octopi-wpa-supplicant.txt” file.

  4. We need to edit that file, but do not use Windows Notepad or MacOS TextEdit to open it, as this may introduce problems. We recommend using Notepad++ for Windows users and Atom or Visual Studio Code for MacOS users.

https://community.octoprint.org/t/wifi-setup-and-troubleshooting/184#heading–wrong-text-editor

Ensure Secure Communication

How to Turn Your Raspberry Pi into a 3D Printing 'Factory' with OctoPi!

Each Raspberry Pi motherboard comes with a default username and password for SSH access. Therefore, it is highly recommended to change the password to prevent others from connecting to your OctoPrint and controlling your 3D printer.
If you previously created a password using Raspberry Pi Imager, please skip to the next section. If not, start the Pi and connect to it via SSH.
  1. Insert the SD card into the Pi’s slot. If you need to use a Wi-Fi adapter, make sure it is connected to the Pi’s USB port.

  2. Power the Pi by plugging in the power cable.

  3. Open CMD (Windows) or Terminal (macOS), and run ssh [email protected] (or replace “octopi.local” with the IP address assigned to the Raspberry Pi by your router).

  4. If it returns “Are you sure you want to continue connecting? (yes/no)?” type yes and press Enter.

  5. Enter the Pi’s default password: raspberry. Press Enter.

Now you should be logged into the Pi. To change the default password, do the following:
  1. Run sudo raspi-config. It will ask you to enter the default password again.

  2. The first option should be “Change User Password.” Press Enter.

  3. Enter the new password twice.

That’s it! Now your OctoPrint instance is secured. Whenever you want to access the Pi via SSH, use this new password.
Connecting Pi to Printer

How to Turn Your Raspberry Pi into a 3D Printing 'Factory' with OctoPi!

Now it’s time to put all the components together. In this step, we will connect the Raspberry Pi to your 3D printer:
  1. If you set up Wi-Fi and password using Raspberry Pi Imager, insert the SD card into the Pi’s slot. If you manually changed the Pi’s password, disconnect the power from the motherboard.

  2. Connect the Pi to your 3D printer using the USB cable.

  3. Power the Pi and your 3D printer.

Setting the Interface

How to Turn Your Raspberry Pi into a 3D Printing 'Factory' with OctoPi!

Once the Pi starts, you should be able to access OctoPrint via the local network

  1. In any browser, enter “http://octopi.local” (or the IP address assigned to the Pi by your router). Ensure your computer is connected to the same network as the Pi.

  2. You should be able to see the OctoPrint interface and a setup wizard pop up. Follow the prompts and ensure to set a username and password for OctoPrint. Note that this is different from the username and password you set for the Raspberry Pi.

  3. Connect to the printer by opening the “Connection” panel on the left. Set the options to “AUTO,” then click “Connect.” If this does not work, try manually setting the serial port and baud rate until successfully connected.

Finding the Raspberry Pi’s IP Address

Terminal Method
If “http://octopi.local” does not work for you, or if you want to directly access the Raspberry Pi via IP address, you can get it from the Pi itself (provided a display is connected). Here’s how:
  1. Turn on the Raspberry Pi and connect a keyboard and mouse to it. Ensure it is successfully connected to the Wi-Fi network.

  2. Open the terminal on the Raspberry Pi (usually defaults to open on OctoPi).

  3. Type “hostname -I” in the terminal and press Enter.

  4. The first part of the output will contain your Pi’s IP address, separated by dots. For example: 192.xx.x.x (where “x” is a number).

PING Method

If your Raspberry Pi does not have a display, the ping method will be very useful. Please follow these steps to use it:
  • Ensure the Raspberry Pi is powered on and connected to your Wi-Fi network.

  • Connect another computer (which can be running Windows, MacOS, or Linux) to the same Wi-Fi network.

  • Open the terminal (MacOS, Linux) or command prompt (Windows), and type “ping octopi.local.” If you changed the hostname during installation or afterward, make sure to replace “octopi.local” with the actual hostname. If you don’t remember changing anything, it is likely the default “octopi.local.”

  • After sending the command, you should start seeing the Raspberry Pi’s IP address in the output. For example, 192.14.1.2.

If you want to explore more methods, feel free to check this guide on how to find your Raspberry Pi on the network.
Congratulations! You have successfully set up OctoPrint. To print for the first time through OctoPrint, click the “Upload” button in the lower left corner and select a sliced G-code file. Once imported, all files will be displayed in the list in the “Files” panel. To start printing, click the small printer icon. But that’s not all…

Familiarizing with the Operation

How to Turn Your Raspberry Pi into a 3D Printing 'Factory' with OctoPi!

From the image, you can see that there are several other tabs to click to navigate to different parts of OctoPrint. Let’s take a look at their functionalities:
  • Temperature (Purple): Here, you can view the current temperature of the extruder and print bed on the graph. You can also set the corresponding target temperatures.

  • Control (Blue): If your Raspberry Pi is connected to a webcam, you can view the live video stream here. You can also send control-related commands to the printer, such as moving the X, Y, Z axes, extruding and retracting filament, turning off motors, turning fans on or off, setting flow rates, etc.

  • G-code Viewer (Orange): As the name suggests, this feature displays the current layer being printed. You can also jump forward or backward in the visualizer to see the printing process of the entire model.

  • Terminal (Brown): Here, you can manually enter G-code commands and send them directly to the printer. For example, entering M115 will display the current firmware version of the printer in the terminal.

  • Time-lapse (Pink): You can start or adjust the configurations for time-lapse photography.

Not too difficult, right? Now you are free to explore all the features and plugins of OctoPrint!

If you’re looking for Raspberry Pi standard products and industrial products, feel free to contact us~

1. Scan the QR code to add Engineer Yang for consultation.

How to Turn Your Raspberry Pi into a 3D Printing 'Factory' with OctoPi!

2. Send us your contact information via private message, and we will get in touch with you as soon as possible.
3. Shanghai Jingheng’s official website for Raspberry Pi distributors: https://www.edatec.cn/cn
How to Turn Your Raspberry Pi into a 3D Printing 'Factory' with OctoPi!
1
How to Turn Your Raspberry Pi into a 3D Printing 'Factory' with OctoPi!

We will update regularly~

Follow Raspberry Pi developers~

Learn more about Raspberry Pi related content~

Leave a Comment