@@ -242,7 +242,7 @@ def power_up(self):
242242
243243 self .command (
244244 _SSD1680_DRIVER_CONTROL ,
245- bytearray ([self ._height & 0xFF , (self ._height ) >> 8 , 0x00 ]),
245+ bytearray ([self ._height , (self ._height ) >> 8 , 0x00 ]),
246246 )
247247 self .command (_SSD1680_DATA_MODE , bytearray ([0x03 ]))
248248
@@ -251,19 +251,19 @@ def power_up(self):
251251 self .command (_SSD1680_GATE_VOLTAGE , bytearray ([0x17 ]))
252252 self .command (_SSD1680_SOURCE_VOLTAGE , bytearray ([0x41 , 0x00 , 0x32 ]))
253253
254- self .command (_SSD1680_SET_RAMXPOS , bytearray ([0x00 , (self ._width // 8 ) - 1 ]))
254+ self .command (_SSD1680_SET_RAMXPOS , bytearray ([0x00 , (self ._width // 8 )]))
255255 self .command (
256256 _SSD1680_SET_RAMYPOS ,
257- bytearray ([0x00 , 0x00 , ( self ._height - 1 ) & 0xFF , (self ._height - 1 ) >> 8 ]),
257+ bytearray ([0x00 , 0x00 , self ._height , (self ._height ) >> 8 ]),
258258 )
259259
260260 # Set border waveform
261261 self .command (_SSD1680_WRITE_BORDER , bytearray ([0x05 ]))
262262
263263 # Set ram X count
264- self .command (_SSD1680_SET_RAMXCOUNT , bytearray ([0x00 ]))
264+ self .command (_SSD1680_SET_RAMXCOUNT , bytearray ([0x01 ]))
265265 # Set ram Y count
266- self .command (_SSD1680_SET_RAMYCOUNT , bytearray ([0x00 , 0x00 ]))
266+ self .command (_SSD1680_SET_RAMYCOUNT , bytearray ([self . _height , 0 ]))
267267 self .busy_wait ()
268268
269269 def update (self ):
0 commit comments