xous-core/apps
bunnie 6ec99fa7da add multi-line text editing support to TextEntry, and insertion points
TextEntry boxes can now specify "growable" as an option; if this
is set true, then, the fields within are considered to be multi-line
fields that can grow to fill the screen (even pushing lower ui
elements off the screen...); however a text line is limited to
256 characters so generally the overflow issue is hopefully rare-ish.

Left/right arrow keys conjure up an insertion point to allow for
deleting and inserting text in the middle of a field.

The main quirk is that if you enter text that causes a field to grow in
size, the overall dialog box can't grow any larger, so the text simply
overflows into the UI element above the current line, without limit.

Need to check for interactions with other elements that should
not be affected but it passes some simple test cases in `vault`.
2023-05-17 23:27:07 +08:00
..
ball bump version pins to absorb changes to svd2utra etc. 2023-05-03 23:11:12 +08:00
hello bump version pins to absorb changes to svd2utra etc. 2023-05-03 23:11:12 +08:00
mtxcli bump version pins to absorb changes to svd2utra etc. 2023-05-03 23:11:12 +08:00
repl bump version pins to absorb changes to svd2utra etc. 2023-05-03 23:11:12 +08:00
transientdisk bump version pins to absorb changes to svd2utra etc. 2023-05-03 23:11:12 +08:00
vault add multi-line text editing support to TextEntry, and insertion points 2023-05-17 23:27:07 +08:00
manifest.json apps/transientdisk: app to demonstrate userspace usb mass storage api 2023-01-26 19:31:40 +01:00
README.md Update README.md 2022-05-29 01:47:53 +08:00

Xous Apps and the Manifest Format

You can add apps to Xous by creating crates in this directory and adding them to the workspace.

  1. Create an app by adding its crate to this directory, perhaps by copying an existing template and giving it a new name. Don't forget to change the name of the app in the app's newapp/Cargo.toml file, as this is what the build system uses to refer to the app.
  2. Register the crate in the Workspace by editing the root ../Cargo.toml (one directory above this README), and adding the new app crate's path to the default-members and the members lists.
  3. Add an entry to manifest.json in this file so the build system can fold it into the system menus. Format documented below.
  4. Rebuild using cargo xtask app-image [app1] [app2] [...], where the appN are the names of the app crates you want to have built into your burnable Xous image.
  5. Burn your new xous.img file onto your device using tools/usb_update.py -k. You will likely need to set up some drivers or install some packages, please refer to the update guide for more details.

As of Xous 0.9.6, the OS takes up about half the available RAM (8 out of 16 MiB) for code + data. For smooth operation of the PDDB and other resources, we suggest leaving about 4MiB of free space, so apps should try to stay within the range of 4MiB in size.

Note that as of Xous 0.9.6, code is copied into RAM from FLASH, so a large portion of the RAM usage is actually the code. This may be addressed in future versions, but this would require a fairly major break with how code verification and updates are done.

manifest.json Format

Each entry for an app needs a record in manifest.json with this format:

    "app_crate_name": {
        "context_name": "freeform name",
        "menu_name": {
            "appmenu.app_name": {
                "en": "app name in english",
                "ja": "app name in japanese",
                "zh": "app name in chinese",
                "en-tts": "app name for the blind"
            }
        }
    },
  • All app names and descriptors must be unique across the build system
  • app_crate_name should be replaced with the name of your app as specified by the "package" name in the app's Cargo.toml file.
  • context_name is a reserved keyword and cannot be modified; its associated value ("freeform name" in this example) is a unique, free-from name that you give your app. There is a 64-character limit on this field.
  • menu_name is a reserved keyword and cannot be modified.
  • appmenu.app_name is the localization substitution string. This must be a unique name, and it s free-form. By convention, we use appname. as a prefix to the name of the app as described in the crate, but as long as it is unique nothing should break.
  • Within the the appmenu.app_name record are the localized names for your App. We suggest creating strings for every language supported by the system. If you don't know how to translate your name, just use the same name in the language of your preference. This will at least prevent builds from breaking in different languages.