fix
This commit is contained in:
parent
636a76a4e7
commit
f163533b08
@ -46,8 +46,8 @@ try:
|
|||||||
#epd.display(epd.getbuffer(HBlackimage), epd.getbuffer(HRedimage))
|
#epd.display(epd.getbuffer(HBlackimage), epd.getbuffer(HRedimage))
|
||||||
epd.DisplayPartial(epd.getbuffer(HBlackimage))
|
epd.DisplayPartial(epd.getbuffer(HBlackimage))
|
||||||
|
|
||||||
values_image = Image.new('1', (epd.height, epd.width), 255)
|
#values_image = Image.new('1', (epd.height, epd.width), 255)
|
||||||
values_draw = ImageDraw.Draw(values_image)
|
#values_draw = ImageDraw.Draw(values_image)
|
||||||
|
|
||||||
time.sleep(2)
|
time.sleep(2)
|
||||||
|
|
||||||
@ -82,9 +82,9 @@ def on_message(client, userdata, msg):
|
|||||||
line = 60
|
line = 60
|
||||||
|
|
||||||
print(line)
|
print(line)
|
||||||
values_draw.rectangle((150, line, 220, 50), fill = 0)
|
drawblack.rectangle((150, line, 220, 50), fill = 0)
|
||||||
values_draw.text((150, line), msg.payload.decode(), font = font10, fill = 0)
|
drawblack.text((150, line), msg.payload.decode(), font = font10, fill = 0)
|
||||||
epd.DisplayPartial(epd.getbuffer(values_image))
|
epd.DisplayPartial(epd.getbuffer(HBlackimage))
|
||||||
time.sleep(1)
|
time.sleep(1)
|
||||||
#print(f"`{msg.topic}`: `{msg.payload.decode()}`")
|
#print(f"`{msg.topic}`: `{msg.payload.decode()}`")
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user