summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2021-02-25tools: wasptool: Fix binary downloads for a specific special caseDaniel Thompson
Currently if the binary file being downloaded contains single quote characters then it gets wrapped differently by repr() so we have to add additional cases to strip the wrapper. Fix this the "obvious" way... where by "obvious" I mean almost anything but. Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-02-21steplogger: Add iterator to allow UI to read the dataDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-02-21steplogger: Introduce code to perform data loggingDaniel Thompson
The code is not yet enabled by default but it can be tested by adding custom code to an interested user's main.py . Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-02-21tools: wasptool: Additional adoption of the run_command wrapperDaniel Thompson
run_command has particular benefits for handle_binary_download() because we can greatly simplify the code to handle running repr() on the target. Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-02-21tool: wasptool: Add a free memory reporting toolDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-02-21tools: wasptool: Better REPL integrationDaniel Thompson
Add a run_command method for the "console". This allows running a command on the target and capturing the result. Normally this is handled using REPLWrapper but that doesn't work well with the NUS console because local echo gets in the way. Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-02-21tools: wasptool: Add push/pull commandsDaniel Thompson
--push is very similar to --binary --upload but handles directories differently. --pull allows us to copy binary files from the target. Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-02-20README: Update the intro after a redraft for the release announcementDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-02-20TODO: Finalize v0.4 changelogDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-02-20TODO: Describe goals for 0.5Daniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-02-20docs: install: Document the binary releasesDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-02-20st7789: Fix incorrect variable name in ST7789_SPIs. __init__ docstring.Piotr Tworek
The data signal pin name is dc, not cs. Signed-off-by: Piotr Tworek <tworaz@tworaz.net>
2021-02-20Added Docker setup to build wasp-os.Shuhao Wu
This should make it a bit easier for people to contribute. Also fixed the documentations on how to setup on Debian, as certain recommended packages don't exist. Signed-off-by: Shuhao Wu <shuhao@shuhaowu.com>
2021-02-20apps: settings: Clamp the dates a little more tightlyDaniel Thompson
Currently a couple of down presses on the year results in the time being set to some time in 2099. The micropython date logic does not support dates this far in the future and throws an exception. Adopt a simple fix that should be OK for the next 39 years ;-) . Reported-by: Christopher Peters <me@christopherp.de> Fixes: #167 Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-02-11docs: install: Fix typo in apt-get line for busterDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-02-06simulator: test: Add Draw565.bounding_box unit testsDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-02-05drivers: draw565: Added bounding_box() function that returns the size of a ↵kozova1
string. This function returns a tuple of (width, height) of the string, as it would appear if used in draw.string() Signed-off-by: kozova1 <mug66kk@gmail.com>
2021-02-04draw565: Fix an out-by-one error in _bounding_boxDaniel Thompson
Currently we add an extra blank pixel to the end of the string but this is not required. Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-02-04apps: testapp: Ensure we test centred stringsDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-02-03apps: settings: Added labels to the datesIsaiah Grace
Signed-off-by: Isaiah Grace <isaiah@graces.com>
2021-02-03install: Correct the wasptool dependenciesDaniel Thompson
Fixes: a1b1502d926d ("install: Include the wasptool dependencies in the install guide") Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-30install: Include the wasptool dependencies in the install guideDaniel Thompson
Fixes: #159 Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-18apps: musicplayer: Adopt GfxButton and use it for trace fwd/backDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-18widgets: Add a button with a graphical iconDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-17drivers: st7789: Further reduce allocations during set_window()Daniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-17drivers: st7789: Pre-allocate a memoryviewDaniel Thompson
Reduce the cost of slicing the linebuffer by pre-allocating a memoryview. Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-17drivers: st7789: Optimize set_window()Daniel Thompson
For small graphical items (line drawing, font glyphs) the performance of the set_window() method is critical. Emit native code for this function and optimize the SPI write_cmd() method to avoid memory allocation. This give a performance boost of a little over 15% for (24pt) font rendering and 30% for line drawing. Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-17draw565: Optimize string drawingDaniel Thompson
Avoid needless bouncing the chip select when drawing glyphs. This improved performance by around 15% for 24pt fonts. Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-17docs: appguide: Document how to upload pre-compiled filesDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-16docs: install: Clarify watch mode during updatesDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-15Disallow swipes while confirmation prompt is displayedGeorge Griffin
Signed-off-by: George Griffin <george@menomnom.com>
2021-01-15system: Move free memory capture into the switch methodDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-13simulator: test_qa: Update to match latest policyDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-13docs: Move all applications out of the reference guideDaniel Thompson
The auto-generated application docs isn't really worthy of the reference guide. There's too many methods described as "draws the screen" and this simply doesn't add anything over the template application includes in the application writer's guide. Move everything over into the Application Library. Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-13simulator: test_qa: Add some basic docstring testsDaniel Thompson
This one picked up a lot of inconsistancy so the changes here are pretty big. Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-12simulator: test_qa: Check that apps are includes in the libraryDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-12simulator: test_qa: Add some simply QA tests for app screenshotsDaniel Thompson
Add tests to make sure every app has a screenshot... and fix the problems picked up by the new tests! Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-12docs: Add a link to the latest videoDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-12apps: settings: Allow date and time to be set on the watchDaniel Thompson
Currently many first-time users excitedly install wasp-os and then struggle to set the time using the various BLE based methods (REPL, wasptool, GadgetBridge, etc). This results in "is there another way to set the time" being *the* frequently asked question. Whilst getting the BLE tools is highly recommened to get the best from wasp-os we can delivery a better out-of-the-box experience for first time users is we provide on board date/time setting. Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-12widgets: Clarity whether spinner max is inclusive or exclusiveDaniel Thompson
Currently the spinner uses exclusive max when wrapping from low to high and inclusive max when wrapping from high to low. Fix this by adopting *inclusive* max everywhere. The call sites are similarly confused. Fix this! Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-12docs: Normalize the timer app screenshotDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-12docs: Update calculator screenshotDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-12system: Fix app unregister functionChristianRomberg
Replace undefined 'instanceof' with 'isinstance' Signed-off-by: Christian Romberg <distjubo@gmail.com>
2021-01-10apps: software: Fix some scrolling bugsDaniel Thompson
Currently the number of pages is (acidentally) hardcoded where it need not be and the scroll directions aren't right as soon as we go beyond two pages (where scroll up and down are equivalent actions). Fix both. Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-10apps: play2048: Optimized the icon a littleDaniel Thompson
wasp-os uses a rather eccentric "2-bit" RLE encoding which works best when there are only three colors (and black) in a single line. Modify the screenshot slightly to allow it to be encoded with fewer palette updated.
2021-01-10apps: play2048: Add the 2048 game applicationMiguel Rochefort
2048 is a popular sliding block puzzle game in which tiles are combined to make the number 2048. It's one of the few games that are enjoyable to play on such a small form factor. This started as a port of a TkInter implementation of the 2048 game. I implemented all of the TkInter APIs used by the game and it worked on wasp-os without any code change in the game. However, the performance was very poor and it consumed too much RAM. I have since reimplemented the whole game from scratch and managed to achieve acceptable performance, although more improvements could still be made. Because names in Python can't start with numbers, I had some trouble naming things. The module is called "ttfe" (two-thousand-forty-eight), the class name is Play2048App, and the software.py entry is "Play 2048". Signed-off-by: Miguel Rochefort <miguelrochefort@gmail.com> [daniel@redfelineninja.org.uk: Renamed the python filename, normalized the screenshot and included the app in the docs] Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-10widgets: ConfirmationView: Restore default fontMiguel Rochefort
The title will render with the last font used, and this isn't always right for the ConfirmationView. Setting the font explicitly solves that issue. Signed-off-by: Miguel Rochefort <miguelrochefort@gmail.com>
2021-01-10simulator: tests: Update after renaming the stopwatch appDaniel Thompson
Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-10apps: timer: Add a countdown timer applicationWolfgang Ginolas
Signed-off-by: Wolfgang Ginolas <wolfgang.ginolas@gwif.eu> [daniel@redfelineninja.org.uk: squashed into a single commit, rebase to latest master, integrate with the Software application and rename the screenshots to match the application name] Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
2021-01-10docs: Add some main.py examplesDaniel Thompson
These still need to be integrated into the generated documentation but there were included in the most recent wasp-os video so let's get them into the source code. Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>