Waveshare 2.9" E-Paper Display (It's driving me mad plz) #12180
Unanswered
minizom
asked this question in
Hardware & Peripherals
Replies: 2 comments 3 replies
-
I haven't tangled with that particular display but I've found waveshare fairly responsive to technical questions if your patient. |
Beta Was this translation helpful? Give feedback.
1 reply
-
Modifying display divers requires a fair degree of experience. Unless you're confident to tackle this, my advice is to find out what displays are already supported and choose one of those. This link details some supported displays including eInk/ePaper. You could also look at awesome micropython. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I will pre-empt this with I am a fool, and there is probably a simple solution I'm not seeing. I am using the Waveshare Waveshare 2.9" E-Paper Display Module for Raspberry Pi Pico (Black/White) (296×128). I have tested the hardware thoroughly and all of it works ok. It displays the text horizontally when the display is verticle. I simply want to have the text display horizontally (across) the e-ink display when it is landscape. I am new wot micro python (yes I'm one of those people)
I am aware there are a number of similar issues/threads/guides with other waveshape displays such as
https://forum.micropython.org/viewtopic.php?f=18&t=6319&sid=b987deb8bb64da2bb21b5db6f5433764
or https://github.com/waveshareteam/e-Paper/blob/master/RaspberryPi_JetsonNano/python/lib/waveshare_epd/epd2in9d.py
But I simply cannot get it to work and I'm on the verge of giving up and purchasing a shitty LCD to do the job.
the guide they provide is: https://www.waveshare.com/wiki/2.9inch_e-Paper_Module_Manual#Working_With_Raspberry_Pi
and I have attached ta trimmed-down example code.
I have tried a number of methods, but most were rubbish.
I'm guessing the answer is in one of several lines.
swapping framebuf.MONO_HLSB) to framebuf.MONO_VLSB) (might have the wrong idea about what that does )
and starts with the correct landscape code 'self.send_data(0x07)' in 'def init'
Any help would be appreciated, or If u just want to mock that is also ok. let me know if I can provide any other information.
Code below:
`from machine import Pin, SPI
import framebuf
import utime
EPD_2IN9D_lut_vcomDC =[
0x00, 0x08, 0x00, 0x00, 0x00, 0x02,
0x60, 0x28, 0x28, 0x00, 0x00, 0x01,
0x00, 0x14, 0x00, 0x00, 0x00, 0x01,
0x00, 0x12, 0x12, 0x00, 0x00, 0x01,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00,
]
EPD_2IN9D_lut_ww =[
0x40, 0x08, 0x00, 0x00, 0x00, 0x02,
0x90, 0x28, 0x28, 0x00, 0x00, 0x01,
0x40, 0x14, 0x00, 0x00, 0x00, 0x01,
0xA0, 0x12, 0x12, 0x00, 0x00, 0x01,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
]
EPD_2IN9D_lut_bw =[
0x40, 0x17, 0x00, 0x00, 0x00, 0x02,
0x90, 0x0F, 0x0F, 0x00, 0x00, 0x03,
0x40, 0x0A, 0x01, 0x00, 0x00, 0x01,
0xA0, 0x0E, 0x0E, 0x00, 0x00, 0x02,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
]
EPD_2IN9D_lut_wb =[
0x80, 0x08, 0x00, 0x00, 0x00, 0x02,
0x90, 0x28, 0x28, 0x00, 0x00, 0x01,
0x80, 0x14, 0x00, 0x00, 0x00, 0x01,
0x50, 0x12, 0x12, 0x00, 0x00, 0x01,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
]
EPD_2IN9D_lut_bb =[
0x80, 0x08, 0x00, 0x00, 0x00, 0x02,
0x90, 0x28, 0x28, 0x00, 0x00, 0x01,
0x80, 0x14, 0x00, 0x00, 0x00, 0x01,
0x50, 0x12, 0x12, 0x00, 0x00, 0x01,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
]
'''
'''
EPD_2IN9D_lut_vcom1 =[
0x00, 0x19, 0x01, 0x00, 0x00, 0x01,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00
,0x00, 0x00,
]
EPD_2IN9D_lut_ww1 =[
0x00, 0x19, 0x01, 0x00, 0x00, 0x01,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
]
EPD_2IN9D_lut_bw1 =[
0x80, 0x19, 0x01, 0x00, 0x00, 0x01,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
]
EPD_2IN9D_lut_wb1 =[
0x40, 0x19, 0x01, 0x00, 0x00, 0x01,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
]
EPD_2IN9D_lut_bb1 =[
0x00, 0x19, 0x01, 0x00, 0x00, 0x01,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
]
EPD_WIDTH = 128
EPD_HEIGHT = 296
RST_PIN = 12
DC_PIN = 8
CS_PIN = 9
BUSY_PIN = 13
FULL_UPDATE = 0
PART_UPDATE = 1
class EPD_2IN9_D(framebuf.FrameBuffer):
def init(self):
self.reset_pin = Pin(RST_PIN, Pin.OUT)
if name=='main':
epd = EPD_2IN9_D()
epd.Clear(0x00)
Beta Was this translation helpful? Give feedback.
All reactions