OctoPrint-TFT, a touch interface for TFT touch modules based on GTK+3.
This is an X application that is executed directly in the X Server, without any window manager, as the frontend of an OctoPrint server on a Raspberry Pi equipped with any TFT Touch module.
It allows you to control your 3D Printer, like you can do with any TFT/LCD panel, but using OctoPrint and a Raspberry Pi.
- Print jobs monitoring.
- Temperature and Filament management.
- Jogging operations.
TouchUI is an amazing plugin for Octoprint. It was created as a responsive design for access to OctoPrint from low resolution devices such as smartphones, tablets, etc.
Executing TouchUI under a RPi w/TFT modules presents two big problems:
- It is not optimized to be used with resistive touch screens with low resolutions like 480x320
- It requires a browser to be used for access, consuming extra resources.
For these reasons I developed this X application to be used with my 3d printer.
OctoPrint-TFT is based on Golang, usually this means no dependencies, but in this case GTK+3 is used. Therefore, GTK+3 libraries are required to be installed on the system.
If you are using Raspbian or any other Debian based distribution, GTK+3 can be installed using:
> sudo apt-get install libgtk-3-0Since OctoPi does not come with a graphical environment, additionally install:
> sudo apt-get install xserver-xorg xinitThe recommended way to install OctoPrint-TFT is use the .deb packages from the Releases page. The packages are available for Debian based distributions such as Raspbian and OctoPi for versions jessie and stretch.
For example for a Raspbian Jessie:
> wget https://github.com/mcuadros/OctoPrint-TFT/releases/download/v0.1.0/octoprint-tft_0.1.0-1.jessie_armhf.deb
> dpkg -i octoprint-tft_0.1.0-1.jessie_armhf.debThe compilation and packaging tasks are managed by the Makefile and backed on Docker. Docker is used to avoid installing any other dependencies since all the operations are done inside of the container.
If you need to install docker inside Raspbian or any other linux distrubution just run:
> curl -fsSL get.docker.com -o get-docker.sh
> sh get-docker.shYou can read more about this at
docker-install
To compile the project, assuming that you already cloned this repository, just execute the build target, this will generate in build folder all the binaries and debian packages:
> make build
> ls -1 build/If you are using Raspbian you can install any of the .deb generated packages.
If not, just use the compiled binary.
If you have difficulty getting this working with your TFT, please see the wiki page: TFT Installation Tips
The basic configuration is handled via environment variables, if you are using the .deb package you can configure it at /etc/octoprint-tft-environment.
-
OCTOPRINT_CONFIG_FILE- Location of OctoPrint'sconfig.yamlfile. If this is not set, the file will be searched for at thepihome folder (or the home folder of the current user). Only used for locally installed OctoPrint servers. -
OCTOPRINT_HOST- OctoPrint HTTP address, example:http://localhost:5000. If OctoPrint is locally installed, this will be read from theconfig.yamlfile. The http:// is necessary. -
OCTOPRINT_APIKEY- OctoPrint-TFT expects an API key to be supplied. This API key can be either the globally configured one, or a user specific one if “Access Control” is enabled. If OctoPrint is locally installed this will be read from theconfig.yamlfile. -
OCTOPRINT_TFT_STYLE_PATH- Several themes are supported, and style configurations can be done through CSS. This variable defines the location of the application theme. -
OCTOPRINT_TFT_RESOLUTION- Resolution of the application, should be configured to the resolution of your screen. For example:800x480. By default480x320.
Custom controls to execute GCODE instructions and commands to execute shell commands can be defined in the config.yaml file.
The controls are limit to static controls without inputs.
GNU Affero General Public License v3.0, see LICENSE
The artwork being use in the at the default style created by @majurca is under the lincese Attribution 3.0 Unported (CC BY 3.0)
