Skip to content

Commit 6d0086e

Browse files
committed
restored power_up()
power_up() * voltages * border waveform * RAM X/Y COUNT had been dropped during 'z' troubleshooting, but test clean now so added back to match SSD1680 behavior.
1 parent 1be3100 commit 6d0086e

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

adafruit_epd/ssd1680.py

+15
Original file line numberDiff line numberDiff line change
@@ -247,12 +247,27 @@ def power_up(self):
247247
bytearray([self._height, (self._height) >> 8, 0x00]),
248248
)
249249
self.command(_SSD1680_DATA_MODE, bytearray([0x03]))
250+
251+
# Set voltages
252+
self.command(_SSD1680_WRITE_VCOM_REG, bytearray([0x36]))
253+
self.command(_SSD1680_GATE_VOLTAGE, bytearray([0x17]))
254+
self.command(_SSD1680_SOURCE_VOLTAGE, bytearray([0x41, 0x00, 0x32]))
255+
250256
self.command(_SSD1680_SET_RAMXPOS, bytearray([0x00, (self._width // 8)]))
251257
self.command(
252258
_SSD1680_SET_RAMYPOS,
253259
bytearray([0x00, 0x00, self._height, (self._height) >> 8]),
254260
)
255261

262+
# Set border waveform
263+
self.command(_SSD1680_WRITE_BORDER, bytearray([0x05]))
264+
265+
# Set ram X count
266+
self.command(_SSD1680_SET_RAMXCOUNT, bytearray([0x01]))
267+
# Set ram Y count
268+
self.command(_SSD1680_SET_RAMYCOUNT, bytearray([self._height, 0]))
269+
self.busy_wait()
270+
256271
def update(self):
257272
"""Update the display specifically for SSD1680Z."""
258273
self.command(_SSD1680_DISP_CTRL2, bytearray([0xF7])) # Full update for SSD1680Z

0 commit comments

Comments
 (0)