From 9fac0c61a4a049d46e326d863f8e30fdbc78f59d Mon Sep 17 00:00:00 2001 From: Thomas Farstrike Date: Wed, 9 Jul 2025 12:53:06 +0200 Subject: [PATCH] About app: add more info --- .../com.micropythonos.about/META-INF/MANIFEST.JSON | 6 +++--- .../apps/com.micropythonos.about/assets/about.py | 14 ++++++++++++++ 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/internal_filesystem/builtin/apps/com.micropythonos.about/META-INF/MANIFEST.JSON b/internal_filesystem/builtin/apps/com.micropythonos.about/META-INF/MANIFEST.JSON index a78af768..89cfd31d 100644 --- a/internal_filesystem/builtin/apps/com.micropythonos.about/META-INF/MANIFEST.JSON +++ b/internal_filesystem/builtin/apps/com.micropythonos.about/META-INF/MANIFEST.JSON @@ -3,10 +3,10 @@ "publisher": "MicroPythonOS", "short_description": "Info about MicroPythonOS", "long_description": "Shows current MicroPythonOS version, MicroPython version, build date and other useful info..", -"icon_url": "https://apps.micropythonos.com/apps/com.micropythonos.about/icons/com.micropythonos.about_0.0.1_64x64.png", -"download_url": "https://apps.micropythonos.com/apps/com.micropythonos.about/mpks/com.micropythonos.about_0.0.1.mpk", +"icon_url": "https://apps.micropythonos.com/apps/com.micropythonos.about/icons/com.micropythonos.about_0.0.2_64x64.png", +"download_url": "https://apps.micropythonos.com/apps/com.micropythonos.about/mpks/com.micropythonos.about_0.0.2.mpk", "fullname": "com.micropythonos.about", -"version": "0.0.1", +"version": "0.0.2", "category": "development", "activities": [ { diff --git a/internal_filesystem/builtin/apps/com.micropythonos.about/assets/about.py b/internal_filesystem/builtin/apps/com.micropythonos.about/assets/about.py index 5bc7136d..62367b3c 100644 --- a/internal_filesystem/builtin/apps/com.micropythonos.about/assets/about.py +++ b/internal_filesystem/builtin/apps/com.micropythonos.about/assets/about.py @@ -18,4 +18,18 @@ class About(Activity): label3.set_text(f"sys.implementation: {sys.implementation}") label4 = lv.label(screen) label4.set_text(f"sys.platform: {sys.platform}") + try: + print("Trying to find out additional board info, not available on every platform...") + import machine + label5 = lv.label(screen) + label5.set_text("") # otherwise it will show the default "Text" if there's an exception below + label5.set_text(f"machine.freq: {machine.freq()}") + label6 = lv.label(screen) + label6.set_text(f"machine.unique_id(): {machine.unique_id()}") + label7 = lv.label(screen) + label7.set_text(f"machine.wake_reason(): {machine.wake_reason()}") + label8 = lv.label(screen) + label8.set_text(f"machine.reset_cause(): {machine.reset_cause()}") + except Exception as e: + print(f"Additional board info got exception: {e}") self.setContentView(screen)