10-26-2020, 05:27 AM
(10-25-2020, 10:43 AM)arkharim Wrote: I'm developing a watchface based on your analog and chrono24 watchfaces . My goal is develop a configurable clock that allows the user customize the watchface using a settings page (not implemented).
I'd also like to be able to offer customizable watch faces but I don't personally think a configurable clock is the right way to handle supporting multiple watch faces. A large monolithic clock app risks making it difficult for users to provide a new watch face. Large apps only be loaded into FLASH whilst small apps can be loaded into RAM allowing the app to be loaded without having to recompile the whole firmware.
The system is currently designed such that the first app on wasp.system.quick_ring is special and will automatically be switched to when the display turns off due to inactivity (unless the current app asks for this not to happen). The result is that watch face will be displayed by default the next time the watch is activated. This is the only difference between a watch face and any other app. To change the default watch face then the users's main.py (or a settings app) can simply do something like: wasp.manager.quick_ring[0] = NewWatchApp() .
On other words rather than having a configurable clock app I think it is better to have several single watch face applications and to modify the system manager to offer better ways to enumerate the applications that are available.
Please don't be discouraged by anything here. I'm keen to see new watch faces and have started to merge faces from other developers into the wasp-os repo! I just think it is better for each watch face to be a separate app.
PS I spent some time this weekend simplifying and commenting the existing digital clock app (which has been requested by others who want to code their own watch faces). I've not pushed it yet because it needs a little more testing but there are some fairly significant simplifications (the code to handle lazy redraw is not a lot clearer).