Google Chat: zj734465502@gmail.com
+86-0755-88291180
sales01@spotpear.com
dragon_manager@163.com
services01@spotpear.com
manager01@spotpear.com
WhatsApp:13246739196
We provide examples for four popular platforms: Arduino UNO, Jetson Nano, Raspberry Pi, and STM32. You can refer to the corresponding part according to the platform you use(This is a common template will be used by all types of the e-Paper, please refer to the corresponding type you have)
The example we provide for Arduino platform is based on Waveshare UNO PLUS (it is compatible with official Arduino UNO R3). If you use other Arduino board which is not compatible with UNO, you may need to change the wring.
e-Paper | Arduino |
Vcc | 5V |
GND | GND |
DIN | D11 |
CLK | D13 |
CS | D10 |
DC | D9 |
RST | D8 |
BUSY | D7 |
Download demo codes from Resources, unzip it to get projects. Arduino example is located in the directory ~/Arduino UNO/…
Open project according to the type. For example, if the e-Paper you have is 1.54inch e-Paper Module, please open the epd1in54 folder and run project epd1in54.ino.
Open project, choose the correct Board and Port, then compile and upload it to board.
Note: Because of the small RAM of Arduino, it cannot support drawing function, therefore, we only provide image display function. The image data are stored in flash. Or you can think about using Waveshare e-Paper Shield for Arduino board
Use an 8PIN cable to connect, please refer to the pin correspondence table below:
e-Paper | Arduino UNO | Mega2560 |
VCC | 5V | 5V |
GND | GND | GND |
DIN | D11 | D51 |
CLK | D13 | D52 |
CS | D10 | D10 |
DC | D9 | D9 |
RST | D8 | D8 |
BUSY | D7 | D7 |
If the board you get is the HAT version like 2.13inch e-Paper HAT, you can directly attach it on the 40PIN GPIO of Raspberry Pi. Or you can wire ti to Raspberry Pi with 8PIN cable.
e-Paper | Raspberry Pi | |
BCM2835 | Board | |
VCC | 3.3V | 3.3V |
GND | GND | GND |
DIN | MOSI | 19 |
CLK | SCLK | 23 |
CS | CE0 | 24 |
DC | 25 | 22 |
RST | 17 | 11 |
BUSY | 24 | 18 |
sudo raspi-config Choose Interfacing Options -> SPI -> Yes to enable SPI interface
sudo reboot
Please makre sure that SPI interface was not used by other device
wget http://www.airspayce.com/mikem/bcm2835/bcm2835-1.60.tar.gz tar zxvf bcm2835-1.60.tar.gz cd bcm2835-1.60/ sudo ./configure sudo make sudo make check sudo make install #For more details, please refer to http://www.airspayce.com/mikem/bcm2835/
sudo apt-get install wiringpi #For Pi 4, you need to update it: cd /tmp wget https://project-downloads.drogon.net/wiringpi-latest.deb sudo dpkg -i wiringpi-latest.deb gpio -v #You will get 2.52 information if you install it correctly
#python2 sudo apt-get update sudo apt-get install python-pip sudo apt-get install python-pil sudo apt-get install python-numpy sudo pip install RPi.GPIO sudo pip install spidev #python3 sudo apt-get update sudo apt-get install python3-pip sudo apt-get install python3-pil sudo apt-get install python3-numpy sudo pip3 install RPi.GPIO sudo pip3 install spidev
Open terminal and execute command to download demo codes
sudo git clone https://github.com/waveshare/e-Paper cd e-Paper/RaspberryPi\&JetsonNano/
Find the main.c file, uncomment the definition of e-Paper types, then compile and run the codes.
cd c make clean make sudo ./epd
Run examples, xxx is the name of the e-Paper. For example, if you want to run codes of 1.54inch e-Paper Module, you xxx should be epd_1in54
cd python/examples # python2 sudo python xxx.py # python3 sudo python3 xxx.py
The example for Jetson Nano use software SPI, speed of sfotware SPI is a little slow
Jetson Nano's 40PIN GPIO is compatible with Raspberry PI, and API of Jetson.GPIo is same as RPi.GPIO, therefore, the pin numbers of Jetson nano are same as Raspberry Pi's
e-Paper | Jetson Nano Developer Kit | |
BCM2835 | Board | |
VCC | 3.3V | 3.3V |
GND | GND | GND |
DIN | 10(SPI0_MOSI) | 19 |
CLK | 11(SPI0_SCK | 23 |
CS | 8(SPI0_CS0) | 24 |
DC | 25 | 22 |
RST | 17 | 11 |
BUSY | 24 | 18 |
sudo apt-get update sudo apt-get install python3-pip sudo pip3 install Jetson.GPIO sudo groupadd -f -r gpio sudo usermod -a -G gpio your_user_name sudo cp /opt/nvidia/jetson-gpio/etc/99-gpio.rules /etc/udev/rules.d/ sudo udevadm control --reload-rules && sudo udevadm trigger
Note: your_user_name is the user name of your Jetson, for example:waveshare
sudo apt-get install python-smbus
sudo apt-get install python3-pil sudo apt-get install python3-numpy
Open terminal and execute commands:
sudo git clone https://github.com/waveshare/e-Paper cd e-Paper/RaspberryPi\&JetsonNano/
Find main.c file, Open it and uncommend the e-Paper which you use, compile and run it
cd c make clear make sudo ./epd
Run examples, xxx is the name of e-Paper. For example, if you want to run examples of 1.54inch e-Paper Module, xxx should be epd_1in54
cd python/examples # python2 sudo python xxx.py # python3 sudo python3 xxx.py
The examples we provide are based on Wavshare Open103Z , the connecting method provide is based on STM32F13ZET6 as well. For other board, please port it by yourself.
e-Paper | STM32F103ZET6 |
Vcc | 3.3V |
GND | GND |
DIN | PA7 |
CLK | PA5 |
CS | PA3 |
DC | PA2 |
RST | PA1 |
BUSY | PA3 |
Enter the directly of STM32 examples, open project by Keil5 software. Set Board and programmer, then compile and download it to board