def __init__(self, w, h):
        self.WIDTH = w
        self.HEIGHT = h
        self._width = w
        self._height = h

        self.rotation = 0
        self.cursor_x = 0
        self.cursor_y = 0
        
        self.textsize = 1
        self.textcolor = 0xFFFF
        self.textbgcolor = 0xFFFF
        
        self.wrap = True
        self.font = glcdfont().getfont()
示例#2
0
    def __init__(self, w, h):
        self.WIDTH = w
        self.HEIGHT = h
        self._width = w
        self._height = h

        self.rotation = 0
        self.cursor_x = 0
        self.cursor_y = 0

        self.textsize = 1
        self.textcolor = 0xFFFF
        self.textbgcolor = 0xFFFF

        self.wrap = True
        self.font = glcdfont().getfont()
#!/usr/bin/python
# A bunch of random tests for drawing GFX on the matrices

import time
from glcdfont import glcdfont
from Adafruit_8x8 import EightByEight

grid1 = EightByEight(address=0x70)
grid2 = EightByEight(address=0x71)
grid3 = EightByEight(address=0x72)
grid1.setBrightness(8)
grid2.setBrightness(8)
grid3.setBrightness(8)
font = glcdfont().getfont()

#print(font)
grid1.fillScreen()
grid1.writeDisplay()
time.sleep(.25)
grid1.clear()

grid2.fillScreen()
grid2.writeDisplay()
time.sleep(.25)
grid2.clear()

grid3.fillScreen()
grid3.writeDisplay()
time.sleep(.25)
grid3.clear()
示例#4
0
#!/usr/bin/python
# A bunch of random tests for drawing GFX on the matrices

import time
from glcdfont import glcdfont
from Adafruit_8x8 import EightByEight

grid1 = EightByEight(address=0x70)
grid2 = EightByEight(address=0x71)
grid3 = EightByEight(address=0x72)
grid1.setBrightness(8)
grid2.setBrightness(8)
grid3.setBrightness(8)
font = glcdfont().getfont()

#print(font)
grid1.fillScreen()
grid1.writeDisplay()
time.sleep(.25)
grid1.clear()

grid2.fillScreen()
grid2.writeDisplay()
time.sleep(.25)
grid2.clear()

grid3.fillScreen()
grid3.writeDisplay()
time.sleep(.25)
grid3.clear()