This article describes how to enable the Orange PI PC board to work as 3d printers network server.
A software that provides this functionality is OctoPrint
From the OctoPrint site we can download an image for Raspberry PI with the system already ready; in the case of the Orange PI PC we have to install and configure OctoPrint on a Linux image.
You can also use a Linux image available for Orange PI PC and run the steps related to OctoPrint package installation, but you have to check the prerequisites for Octoprint python package installation.
We instead built for this article an image using the Armban scripts.
As a first step, prepare the micro sd card with an Armbian image. In the specific case, we’ll use a Debian Jessie image created using the Armbian script, as indicated on the link
and described also in a previous article
Building Armbian image for Orange PI PC
We followed these steps to build the Armbian image on Ubuntu Xenial 16.04; from a Linux command shell
1 2 3 |
git clone https://github.com/armbian/build cd build ./compile.sh |
In the building options choose
We selected the default kernel configuration
and Debian Jessie as distribution
We built an image with desktop envinronment
After this option, the script proceeds to the compilation. The generated image is Armbian_5.34_Orangepipc_Debian_jessie_next_4.13.12_desktop.img. This image can be downloaded from the link
Armbian image for Orange Pi PC
Start Armbian and create the user for the Jessie image; in this case we choose octoprint/password as user.
If necessary, reconfigure the keyboard with the command
1 2 |
sudo dpg-reconfigure keyboard-configuration |
and proceed to upgrade the system
1 2 |
sudo apt-get update sudo apt-get upgrade |
If the system needs to be configured via a wireless connection, the connection must be active at startup. For this purpose in our case we used the Wicd daemon
Remove the network-manager package
1 |
sudo apt-get remove network-manager |
This command uninstalls network-manager and network-manager-gnome.
Check that the wireless interface is not present in
/etc/network/interfaces
1 |
cat /etc/network/interfaces |
Proceed to Wicd installation
1 |
sudo apt-get install wicd |
Check that the octoprint user is present in the netdev group
1 |
cat /etc/group | grep netdev |
In our case it is already present, giving as a result
If not present, add it with the command
1 2 |
sudo adduser octoprint netdev sudo /etc/init.d/dbus reload |
Start wicd
1 |
sudo systemctl start wicd |
Logon to the armbian graphic desktop and start the wireless configuration with the command
1 |
wicd-client -n |
Configure and save the network connection from the graphical interface.
If you want the remote desktop follow the steps listed in the article
Remote desktop setup for Armbian on Orange PI PC
We can now install Octoprint. Follow the steps available at the link
OctoPrint installation on Linux
Install the prerequisites
1 2 |
sudo apt-get update sudo apt-get install python-pip python-dev python-setuptools virtualenv python-virtualenv git libyaml-dev build-essential |
Create under /opt the octoprint folder and assign the ownership to octoprint
1 2 3 |
sudo mkdir /opt/octoprint sudo chown octoprint:octoprint -R /opt/octoprint |
In a Linux shell command go to /opt/octoprint folder and download the software
1 2 |
cd /opt/octoprint git clone https://github.com/foosel/OctoPrint.git |
Run
1 2 3 4 |
cd OctoPrint virtualenv venv ./venv/bin/pip install pip --upgrade ./venv/bin/python setup.py install |
Create the .octoprint folder
1 |
mkdir ~/.octoprint |
Add octoprint to the following groups to manage the 3d printer using the USB port
1 2 |
sudo usermod -a -G tty octoprint sudo usermod -a -G dialout octoprint |
Check the correct installation by running the command
1 |
/opt/octoprint/OctoPrint/venv/bin/octoprint |
The OctoPrint server can be reached on port 5000 at the IP address of Orange PI PC
http://ipaddress:5000
Install the Cura Engine at this point; place yourself in the octoprint user’s home and download the source package
1 2 |
cd wget https://github.com/Ultimaker/CuraEngine/archive/15.04.6.tar.gz |
Unpack the package
1 |
tar -zxvf 15.04.6.tar.gz |
Go into the unpacked folder
1 |
cd CuraEngine-15.04.6/ |
Run the compilation with the command
1 |
make |
The compiled software is located under the build folder
Create the /opt /octoprint/cura folder and copy the CuraEngine file to this folder
1 2 3 |
mkdir /opt/octoprint/cura cd ~/CuraEngine-15.04.6/build cp CuraEngine /opt/octoprint/cura/ |
The executable is now in the /opt/octoprint/cura folder and will be used later by OctoPrint.
In the next article we’ll treat how to configure OctoPrint’s automatic startup