def encode_msg(self, msg):
     col = [ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 ]
     for t in msg:
         if self.is_ascii(t):
             col.extend(ledmap(ord(t)))
             if t != ' ':
                 col.append(0x00)    # add space between chars
     return col
Example #2
0
 def encode_msg(self, msg):
     col = [ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 ]
     for t in msg:
         if self.is_ascii(t):
             col.extend(ledmap(ord(t)))
             if t != ' ':
                 col.append(0x00)    # add space between chars
     return col
Example #3
0
import ledfont

t = "h"
d = ledfont.ledmap(ord(t))

for line in d:
    #print format(line, "02x")
    print format(line, "08b")