#This article is how to install python librarily in RASBIAN JESSIE Light version.
# e INK display can be purchased from https://www.waveshare.com/
# 7.5" HD, which was reasonable price level , is DISCONTINUED as of October 2021
https://www.waveshare.com/wiki
https://www.waveshare.com/wiki/2.13inch_e-Paper_HAT
https://www.waveshare.com/wiki/4.2inch_e-Paper_Module_(B)
https://www.waveshare.com/wiki/7.5inch_e-Paper_HAT
https://www.waveshare.com/wiki/7.5inch_HD_e-Paper_HAT
https://www.waveshare.com/wiki/2.13inch_e-Paper_HAT_(B)#Documentation
sudo apt-get update
#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
#enable I2C and SPI in option
sudo raspi-config
I2C and SPI >> Enabled #In Interfacing options
#download and install https://pypi.python.org/pypi/RPi.GPIO
sudo pip install RPi.GPIO
또는 python3에서 ↓
sudo pip3 install RPi.GPIO
#pip 가 없다면 sudo apt-get install python3-pip 로 설치, python3버전
#pip 가 없다면 sudo apt-get install python-pip 로 설치, python2버전
#위 명령어로 해결
wget https://files.pythonhosted.org/packages/e2/58/6e1b775606da6439fa3fd1550e7f714ac62aa75e162eed29dbec684ecb3e/RPi.GPIO-0.6.3.tar.gz
tar -xzf RPi.GPIO-0.6.3.tar.gz
cd RPi.GPIO-0.6.3
sudo python setup.py install
sudo apt-get install python-smbus
sudo apt-get install python-serial
# download and install SPIDEV from https://pypi.python.org/pypi/spidev
sudo pip install spidev
또는 python3에서 ↓
sudo pip3 install spidev
wget https://files.pythonhosted.org/packages/36/83/73748b6e1819b57d8e1df8090200195cdae33aaa22a49a91ded16785eedd/spidev-3.2.tar.gz
tar -xzf spidev-3.2.tar.gz
cd spidev-3.2
sudo python setup.py install
sudo apt-get install python-imaging
# add following blue texts in modules
sudo nano /etc/modules
i2c-bcm2708
i2c-dev
#DEMO CODE in case of 2.9INCH
wget https://www.waveshare.com/w/upload/7/78/2.9inch_e-Paper_Module_code.7z
#DEMO CODE in case of 2.13INCH
wget https://www.waveshare.com/w/upload/1/1c/2.13inch_e-Paper_HAT-code.7z
#DEMO CODE in case of 7.5inch from https://www.waveshare.com/wiki/File:7.5inch-e-paper-hat-code.7z
wget https://www.waveshare.com/w/upload/0/06/7.5inch-e-paper-hat-code.7z
sudo apt-get install p7zip-full
7za x filename.7z
# In case of Rasbian LITE version, font is not installed, so it should be installed by following command
sudo apt-get install python-pygame
DIRECTIONS / 주의사항
Refresh mode 갱신방식
- Full refresh: e-Paper flicker when full refreshing to remove ghost image for best display.
- Partial refresh: It don't flicker if you use partial refresh (only some of the two-color e-paper support partial refresh).
- Note that you cannot use Partial refresh all the time, you should full refresh e-paper regularly, otherwise, ghost problem will get worse even damage.
- 부분적인 갱신을 항상 사용하실 수 없습니다, 전체 갱신을 규칙적으로 사용하셔야 합니다, 그렇지 않으면 잔상현상이 나빠지고 제품 손상을 입을 수 있습니다.
Refresh rate 갱신비율
- When using, you should set the update interval at least 180s.(except Partial supportable types)
- 사용하실때, 화면 업데이트를 3분 간격으로 해주십시오(부분갱신 제외)
- Please set the e-Paper to sleep mode or power off it directly, otherwise, the e-Paper is damaged because of working in high voltage for long time.
- e-paper를 절전모드나 전원을 직접끄게 설정해 주십시오, 그렇지 않으면 오랜시간 높은 전원으로 인해 손상을 입습니다.
- You need to update the content of three-color e-Paper at least one time every 24h to avoid from burn-in problem.
Working place 동작장소
- We recommend you to use the e-Paper indoor. If you need to set the e-paper outdoor, Please place the e-paper in shadow and protect it from UV. When you designed you e-paper product, you should take care about the working situation like temperature, humidity, etc.
Please set the e-paper to sleep mode or disconnect it if you needn't refresh the e-paper but need to power on your development board or Raspberry Pi for long time.Otherwise, the voltage of panel keeps high and it will damage the panel
오랫동안 라즈베리파이의 화면을 갱신하지 않고 전원을 오랫동안 켜놓아야 할 경우 전원을 빼거나 절전모드로 설정하십시오, 그렇지 않으면 높은 전원으로 인해 화면에 손상을 가합니다.
# ROTATE
#180 degree rotate #Insert transpose(Image.ROTATE_180)
# ref1 https://www.raspberrypi.org/forums/viewtopic.php?t=228836
# ref2 https://pillow.readthedocs.io/en/5.1.x/handbook/tutorial.html?highlight=Rotate
HBlackimage = Image.new('1', (epd4in2b.EPD_WIDTH, epd4in2b.EPD_HEIGHT), 255) # 298*126
~~~~
HBlackimage = HBlackimage.transpose(Image.ROTATE_180)
epd.display(epd.getbuffer(HBlackimage), epd.getbuffer(HRedimage))
'Computer > Linux' 카테고리의 다른 글
Xiaomi Mijia Hygrothermo V2 read data from Python3 샤오미 온습도계V2 파이썬으로 읽기 (0) | 2019.02.07 |
---|---|
Wifi password setting/change (0) | 2019.02.07 |
라즈베리파이 블루투스 활용 (0) | 2019.02.07 |
라즈베리파이 Servo motor SG90 (0) | 2019.02.07 |
Transmission (0) | 2019.02.07 |
Wifi access point 2개 저장하기 (0) | 2019.02.07 |
라즈베리파이 - I2C 1602 LCD module (0) | 2019.02.07 |
라즈베리파이 최초 SD 카드 작성 후 SSh 접속 (0) | 2019.02.07 |