/go-epdfuse

A library for interacting with the PaPiRus via the repaper gratis library

Primary LanguageGoGNU General Public License v2.0GPL-2.0

epdfuse Travis CI Godoc Reference

epdfuse is a library for interacting with the PaPiRus epaper display using golang and the repaper epd fuse native library.

This library provides the ability to write arbitrary text and images to the display as well as clear the display.

It leverages the goxbm project to convert images to the XBM format used by EPD Fuse.

Example Image

Install and setup

Install Go

Go runs easily on the Raspberry PI. This stackexchange answer provides a quick overview: http://raspberrypi.stackexchange.com/a/46828/167.

If cross compiling on a different computer, use these settings GOARM=5 GOOS=linux GOARCH=arm.

GOARM=5 GOOS=linux GOARCH=arm go build

Install Fuse Driver

The repaper fuse driver is required to use this golang library.

# Install fuse driver
apt-get install libfuse-dev -y
# Install fonts
apt-get install fonts-freefont-ttf -y

rm -R /tmp/papirus
mkdir /tmp/papirus
cd /tmp/papirus
git clone https://github.com/repaper/gratis.git

cd /tmp/papirus/gratis
make rpi EPD_IO=epd_io.h PANEL_VERSION='V231_G2'
make rpi-install EPD_IO=epd_io.h PANEL_VERSION='V231_G2'
systemctl enable epd-fuse.service
systemctl start epd-fuse

Get the go-epdfuse project

Download and install the project with go

go get github.com/wmarbut/go-epdfuse

Run an example

cd $GOPATH/github.com/wmarbut/go-epdfuse/examples/papirus-text
go build
./paprius-text "Hello World!"