Skip to content

[Accessories] 3 - Calibrate live ground clearance #478

Description

@KacperKozak

Parent

#475

What to build

Open the ground-clearance configuration screen by tapping its accessory row in the Board selector's Accessories section. Keep live readings and automatic calibration saving on that detail screen. Settings → Sensors is spike prior art, not the intended navigation.

Deliver the ToF-only reading path with explicit status, accepted rates, live display, measurement standby, and automatically saved calibration. No tilt actuation in this slice. Firmware actually stops continuous measurement when demand expires; opening/closing the screen changes preview demand through native configuration.

Type: AFK. Complexity: high. Blocked by: 2. Stories: 7–10, 13–14, 19, 26.

Likely files

Implementation hints

  • The parent PRD includes the complete protocol and product-design snapshots. Local docs may not yet exist on the implementation branch; materialize them from the parent when needed.
  • PR Vescape Sensors: BLE link to the ESP32 sensor module #441 is prior art at commit 91ebeaf0fdf3daa8a8151314048de9e663b9149c; paths marked PR Vescape Sensors: BLE link to the ESP32 sensor module #441 are absent from the planning checkout.
  • Paths prefixed vescape-accessories: belong to vescape-app/vescape-accessories. Coordinate both repositories for firmware/app protocol changes.
  • Keep native Android/iOS contracts aligned with parity links. Reuse native lifecycle and storage contracts; JS renders state and sends intents.

Acceptance criteria

  • Open the ground-clearance configuration screen by tapping its accessory row in the Board selector's Accessories section. Keep live readings and automatic calibration saving on that detail screen. Settings → Sensors is spike prior art, not the intended navigation.

  • readings show centimetres.

  • invalid data never becomes maximum distance.

  • near/far/direction/strength save when complete and valid.

  • settings survive restart.

  • unconfigured state is explained.

  • leaving the screen while not riding stops measurements but preserves BLE.

  • ultrasonic code is removed.

  • fresh-session sampling is covered.

Blocked by

Related

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:accessoriesAccessory discovery, protocol, configuration, and Board bindingsarea:dbTouches database / persistent storagearea:nativeTouches native side (modules/vesc-ble, Swift/Kotlin)complexity:highCritical paths, subtle correctness, native pipelines. Use opus.enhancementNew feature or requestready-for-agentFully specified, ready for an AFK agent

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions