From a6a8c612b4903e88723fb13d8426e0bce260bfb6 Mon Sep 17 00:00:00 2001 From: Robert Borzutzki Date: Tue, 18 Oct 2022 22:33:54 +0200 Subject: [PATCH] fix --- examples/epd.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/epd.py b/examples/epd.py index 3e4cf15..c85ed81 100644 --- a/examples/epd.py +++ b/examples/epd.py @@ -57,7 +57,7 @@ def subscribe(client: mqtt_client): HRYimage = Image.new('1', (epd.height, epd.width), 255) # 298*126 ryimage: red or yellow image drawblack = ImageDraw.Draw(HBlackimage) drawry = ImageDraw.Draw(HRYimage) - drawblack.text((10, 0), 'Received `{msg.payload.decode()}` from `{msg.topic}` topic', font = font20, fill = 0) + drawblack.text((10, 0), 'Received '+ msg.payload.decode()' from topic', font = font20, fill = 0) epd.display(epd.getbuffer(HBlackimage), epd.getbuffer(HRYimage)) time.sleep(2) @@ -76,7 +76,7 @@ def subscribe(client: mqtt_client): logging.info("Goto Sleep...") epd.sleep() - print(f"Received `{msg.payload.decode()}` from `{msg.topic}` topic") + print(f"Received `{msg.payload.decode()}` from `{msg.topic}` topic") client.subscribe(topic) client.on_message = on_message