From c1c66fb487113acbd4b2b7a722c3782d5a962e08 Mon Sep 17 00:00:00 2001 From: Daniel Thompson Date: Sat, 10 Oct 2020 14:04:44 +0100 Subject: [PATCH] boards: Introduce a shared manifest for all 240x240 devices This also adds the Fibonaci Clock, Haiku viewer and the Game of Life to the manifest. They are *not* registered by default at this point since, although we can currently spare the internal flash space there is more competition for RAM so we have to trade off out-of-the-box convenience with keeping as much RAM as possible for users to do "cool things". Given the zen of wasp-os is to try to make is as easy as possible for users to become coders we currently favour reserving the space for the cool things (and implicitly encouraging them to write a couple of lines of python to enable the bonus applications. Signed-off-by: Daniel Thompson --- wasp/boards/k9/manifest.py | 23 ++++++----------------- wasp/boards/manifest_240x240.py | 25 +++++++++++++++++++++++++ wasp/boards/p8/manifest.py | 23 ++++++----------------- wasp/boards/pinetime/manifest.py | 23 ++++++----------------- 4 files changed, 43 insertions(+), 51 deletions(-) create mode 100644 wasp/boards/manifest_240x240.py diff --git a/wasp/boards/k9/manifest.py b/wasp/boards/k9/manifest.py index 1c1d7e2..c160c21 100644 --- a/wasp/boards/k9/manifest.py +++ b/wasp/boards/k9/manifest.py @@ -1,18 +1,14 @@ # SPDX-License-Identifier: LGPL-3.0-or-later # Copyright (C) 2020 Daniel Thompson +import os, sys + +sys.path.append(os.path.dirname(os.getcwd())) +import manifest_240x240 + freeze('.', 'watch.py', opt=3) -freeze('../..', +freeze('../..', manifest_240x240.manifest + ( - 'apps/clock.py', - 'apps/flashlight.py', - 'apps/heart.py', - 'apps/launcher.py', - 'apps/pager.py', - 'apps/settings.py', - 'apps/steps.py', - 'apps/stopwatch.py', - 'apps/testapp.py', 'boot.py', 'draw565.py', 'drivers/bma421.py', @@ -23,17 +19,10 @@ freeze('../..', 'drivers/st7789.py', 'drivers/touch.py', 'drivers/vibrator.py', - 'fonts/__init__.py', - 'fonts/clock.py', - 'fonts/sans24.py', - 'fonts/sans28.py', - 'fonts/sans36.py', 'gadgetbridge.py', - 'icons.py', 'ppg.py', 'shell.py', 'wasp.py', - 'widgets.py', ), opt=3 ) diff --git a/wasp/boards/manifest_240x240.py b/wasp/boards/manifest_240x240.py new file mode 100644 index 0000000..6bf88c8 --- /dev/null +++ b/wasp/boards/manifest_240x240.py @@ -0,0 +1,25 @@ +# SPDX-License-Identifier: LGPL-3.0-or-later +# Copyright (C) 2020 Daniel Thompson +"""Shared manifest for applications that work well on a 240x240 display.""" + +manifest = ( + 'apps/clock.py', + 'apps/flashlight.py', + 'apps/gameoflife.py', + 'apps/haiku.py', + 'apps/heart.py', + 'apps/launcher.py', + 'apps/pager.py', + 'apps/settings.py', + 'apps/steps.py', + 'apps/stopwatch.py', + 'apps/fibonacci_clock.py', + 'apps/testapp.py', + 'fonts/__init__.py', + 'fonts/clock.py', + 'fonts/sans24.py', + 'fonts/sans28.py', + 'fonts/sans36.py', + 'icons.py', + 'widgets.py', +) diff --git a/wasp/boards/p8/manifest.py b/wasp/boards/p8/manifest.py index 3a525e1..9243d77 100644 --- a/wasp/boards/p8/manifest.py +++ b/wasp/boards/p8/manifest.py @@ -1,18 +1,14 @@ # SPDX-License-Identifier: LGPL-3.0-or-later # Copyright (C) 2020 Daniel Thompson +import os, sys + +sys.path.append(os.path.dirname(os.getcwd())) +import manifest_240x240 + freeze('.', 'watch.py', opt=3) -freeze('../..', +freeze('../..', manifest_240x240.manifest + ( - 'apps/clock.py', - 'apps/flashlight.py', - 'apps/heart.py', - 'apps/launcher.py', - 'apps/pager.py', - 'apps/settings.py', - 'apps/steps.py', - 'apps/stopwatch.py', - 'apps/testapp.py', 'boot.py', 'draw565.py', 'drivers/bma421.py', @@ -23,17 +19,10 @@ freeze('../..', 'drivers/signal.py', 'drivers/st7789.py', 'drivers/vibrator.py', - 'fonts/__init__.py', - 'fonts/clock.py', - 'fonts/sans24.py', - 'fonts/sans28.py', - 'fonts/sans36.py', 'gadgetbridge.py', - 'icons.py', 'ppg.py', 'shell.py', 'wasp.py', - 'widgets.py', ), opt=3 ) diff --git a/wasp/boards/pinetime/manifest.py b/wasp/boards/pinetime/manifest.py index 3a525e1..9243d77 100644 --- a/wasp/boards/pinetime/manifest.py +++ b/wasp/boards/pinetime/manifest.py @@ -1,18 +1,14 @@ # SPDX-License-Identifier: LGPL-3.0-or-later # Copyright (C) 2020 Daniel Thompson +import os, sys + +sys.path.append(os.path.dirname(os.getcwd())) +import manifest_240x240 + freeze('.', 'watch.py', opt=3) -freeze('../..', +freeze('../..', manifest_240x240.manifest + ( - 'apps/clock.py', - 'apps/flashlight.py', - 'apps/heart.py', - 'apps/launcher.py', - 'apps/pager.py', - 'apps/settings.py', - 'apps/steps.py', - 'apps/stopwatch.py', - 'apps/testapp.py', 'boot.py', 'draw565.py', 'drivers/bma421.py', @@ -23,17 +19,10 @@ freeze('../..', 'drivers/signal.py', 'drivers/st7789.py', 'drivers/vibrator.py', - 'fonts/__init__.py', - 'fonts/clock.py', - 'fonts/sans24.py', - 'fonts/sans28.py', - 'fonts/sans36.py', 'gadgetbridge.py', - 'icons.py', 'ppg.py', 'shell.py', 'wasp.py', - 'widgets.py', ), opt=3 )