Add main.py

This commit is contained in:
Xargana 2025-05-16 15:39:05 +02:00
parent 2ce32c426e
commit 23fc0d976a

19
main.py Normal file
View file

@ -0,0 +1,19 @@
from display.screen import OLEDDisplay
from display.font_manager import FontManager
import time
# Import modules
from modules import ip_address, hello_world
def main():
oled = OLEDDisplay()
font_mgr = FontManager(size=14)
while True:
message = f"{ip_address.get_ip()}\n{hello_world.get_text()}"
font_mgr.draw_multiline_text(oled.draw, message, 0, 0, oled.display.width, oled.display.height)
oled.show_image()
time.sleep(5)
if __name__ == "__main__":
main()