oxmc b8dd826ddd Add baseline Florisboard IME fallback, fix config_apk_url README default
Device never set a default IME when enable_configapk_service=false or
no config APK was installed yet, even though Florisboard is always
baked into the ROM independent of the config APK. applyBaselineDefaults()
runs unconditionally before the config-APK-gated block and only sets
Florisboard if no default IME is already set and the package exists.

README's config_apk_url row claimed the default was empty; it's actually
the hardcoded oxmc.me URL. Documented the OTA skip-if-default behavior.
2026-10-20 02:24:26 -07:00
2025-08-21 01:11:21 -07:00
2025-08-21 01:11:21 -07:00

Config Provisioner

A privileged system app that provisions PawletOS devices on first boot.

How it works

On BOOT_COMPLETED, the provisioner reads /vendor/etc/config_provisioner/vendor.cfg (or falls back to built-in defaults) and does four things:

  1. Baseline defaults — applied unconditionally, before anything below, regardless of enable_configapk_service or whether a config APK is installed. Currently: if no default IME is set, falls back to Florisboard (baked into the ROM via the manifest, not the config APK) so the device never boots keyboardless. A config APK that sets its own default IME still overrides this.
  2. Config APK — if enable_configapk_service=true, reads settings and APNs from the pre-installed config APK and applies them.
  3. Device provisioned — sets DEVICE_PROVISIONED and USER_SETUP_COMPLETE according to device_provisioned.
  4. Setup wizard — enables or disables setup wizard packages according to enable_setupwizard.

On USER_PRESENT (after the screen is first unlocked), if enable_configapk_service=true and config_apk_url is set, it downloads an updated config APK and re-applies settings.

Control keys

These three keys drive the core behaviour. All have built-in defaults so the device auto-provisions correctly even with no vendor.cfg present.

Key Default Description
enable_configapk_service true Apply settings/APNs from the config APK and check for OTA config updates.
device_provisioned true Mark the device as provisioned (DEVICE_PROVISIONED=1, USER_SETUP_COMPLETE=1). Set false to leave setup incomplete.
enable_setupwizard false false = disable setup wizard packages. true = leave them enabled.

Supporting keys

Key Default Description
config_apk_package app.pawlet.config Package name of the pre-installed config APK.
config_apk_url https://oxmc.me/apis/aosp/data/default-config.apk URL to download an updated config APK on unlock. Only used as the actual OTA trigger if vendor.cfg sets it to something other than this default — leaving it at the default (or empty) disables OTA config updates, since boot-time provisioning already reads the pre-installed config APK directly without downloading anything.
vendor_id default_vendor Identifier logged during provisioning.
network_timeout 30000 Download timeout in milliseconds.
ota_check_interval_ms 86400000 Minimum time between OTA config update checks (default: 24 h).

Keys can also be set via system properties (persist.configprovisioner.<key>), which are used as a fallback when the config file is absent or the key is missing.

Example vendor.cfg

enable_configapk_service=true
device_provisioned=true
enable_setupwizard=false
config_apk_package=app.pawlet.config
config_apk_url=https://oxmc.me/apis/aosp/data/default-config.apk

Config APK format

The config APK provides:

  • res/xml/settings.xml — <secure>, <system>, or <global> tags with name/value attributes. Wrap in <if> to apply conditionally by manufacturer, brand, model, sdk, sdk_min, sdk_max, form_factor (phone/tablet/tv/flip), or feature.
  • res/xml/apns.xml or assets/apns/*.xml — APN entries inserted into the telephony provider (duplicates are skipped).

Permissions

  • CHANGE_COMPONENT_ENABLED_STATE — disable setup wizard packages
  • WRITE_SECURE_SETTINGS — write USER_SETUP_COMPLETE / DEVICE_PROVISIONED
  • INSTALL_PACKAGES — install downloaded config APK
  • WRITE_APN_SETTINGS — insert APN entries

License

GNU General Public License v3.0 — see LICENSE.

S
Description
No description provided
Readme GPL-3.0
72 KiB
Languages
Java 100%