Skip to content

Scanning list: RSSI for all cars, stable order, spinner, auto-stop - #100

Merged
dzid26 merged 12 commits into
mainfrom
work/scan-list
Oct 7, 2026
Merged

dzid26 merged 12 commits into
mainfrom
work/scan-list

Conversation

@dzid26

@dzid26 dzid26 commented Oct 6, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Part 1 of #98, the scan-list behavior. Owner spec items:

  • Unpaired cars show their advertised RSSI. The scan advert already carries it, so no connection is needed.
  • The list sorts by name (known cars first, then discovered ones) instead of by RSSI, so signal jitter can't shuffle the rows.
  • A single spinner in the status row replaces the Scanning: N Tesla(s) text, and the Stop button is gone. The pull pill now appears only while you're actually pulling.
  • A scan ends by itself 30 s after the last new car appears; each new car resets the timer.
  • Unpaired cars leave the list once they stop advertising, and disconnected connections are no longer carried over. List rows no longer show a Pair button; pairing is one tap away in the car view.
  • The log card is capped at a share of the list height.

Also fixed here: Back from Settings now returns to the cars list instead of reopening the last car. MainScreen left the composition while Settings was open, so its saved list/car selection was lost and the restore-last-car step ran again. A SaveableStateHolder in MainActivity keeps that state. This bug is also why the light-mode scan screenshot kept failing: the capture landed on the car view.

Part 2 (connect once to read the GATT name, cache it and close; reopen on tap; close on back) comes in a follow-up PR.

Type

  • Bug fix
  • Feature
  • Protocol / crypto change
  • Docs / CI / tooling
  • Refactor (no behavior change)

Testing

  • ./gradlew :core:test (CI)
  • ./gradlew :app:testDebugUnitTest (CI)
  • ./gradlew :app:lintDebug (CI)
  • Real car (describe what was tested) — not yet

Demo-car screenshots come from the PR screenshots workflow.

Checklist

  • Protocol changes ship test vectors; expected.txt regenerated, not hand-edited
  • No VINs, keys, or decrypted payloads in logs
  • Docs/master-plan updated where relevant
  • New source files carry SPDX-License-Identifier: AGPL-3.0-only

🤖 Generated with Claude Code

https://claude.ai/code/session_0129RzhbEE2cboMcYyZMuxqX

@github-actions

github-actions Bot commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

Screenshots

App screenshots: light and dark

Captured from the demo build at ccdc0fe.

@dzid26

dzid26 commented Oct 6, 2026

Copy link
Copy Markdown
Collaborator Author

Screenshots disagree. - Analyze them.

@dzid26
dzid26 marked this pull request as draft October 6, 2026 22:04
dzid26 added 2 commits October 7, 2026 00:06
Part 1 of #98. Unpaired cars show their advertised RSSI (the scan advert already carries it, no connection needed); the list sorts by name so RSSI jitter cannot shuffle rows; a spinner replaces the scanning text and the Stop button; a scan ends by itself 30 s after the last new car; and unpaired cars leave the list once they stop advertising (disconnected connections are no longer carried over). Name resolution and the unpaired connection lifecycle follow in part 2.
Take 02-scanning.png after the car flow, when the list shows the known car, so it matches 02-scanning-dark.png. The early capture showed raw pair addresses and a pull pill; the address wait stays as a gate.
@dzid26
dzid26 marked this pull request as ready for review October 6, 2026 23:44
@github-actions

github-actions Bot commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

Screenshots

App screenshots: light and dark

Captured from the demo build at 9114d53.

@dzid26

dzid26 commented Oct 7, 2026

Copy link
Copy Markdown
Collaborator Author

analyze screenshot, double spinners, Scanning... label on the spinner still shows up. New discovery - there is unnecessary pair button on Cars list car now.

@github-actions

github-actions Bot commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

Screenshots

App screenshots: light and dark

Captured from the demo build at e329c68.

@dzid26
dzid26 marked this pull request as draft October 7, 2026 01:49
Owner review of the #100 sheet: the status-row spinner plus the pull pill showed two spinners, the pill kept its Scanning label, and the rows carried a Pair button. The pill now only appears while pulling and takes nullable labels (null on the list, kept on the car view); the list rows drop Pair entirely - pairing stays one tap away in the car view.
@github-actions

github-actions Bot commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

Analysis of the sheet at e329c68, item by item:

  • Double spinners: the new small spinner in the status row plus the pull-to-refresh pill, which hangs around for the whole scan because it follows state.scanning.
  • "Scanning…" label: that is the pull pill's refreshing label, same cause.
  • Pair button on the list row: the unpaired S1a2 row still shows it.

Fixed in 76ba99c: the pill now appears only while the finger is pulling and takes a null label on the list (spinner-only; the car view keeps its labels), the status row keeps the single spinner, and the list rows drop Pair entirely - pairing stays one tap away in the car view. New sheet coming from CI.

@dzid26
dzid26 marked this pull request as ready for review October 7, 2026 02:04
@dzid26
dzid26 marked this pull request as draft October 7, 2026 02:10
@github-actions

github-actions Bot commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

Screenshots

App screenshots: light and dark

Captured from the demo build at 76ba99c.

The drag-fraction gate alone did not hold on the phone: the pill lingered after release, so a scan still showed two spinners. Gate it on no scan running as well; the pill now only appears mid-drag before a scan starts.
@dzid26
dzid26 marked this pull request as ready for review October 7, 2026 02:13
@github-actions

github-actions Bot commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

Screenshots

App screenshots: light and dark

Captured from the demo build at 2384477.

@dzid26
dzid26 marked this pull request as draft October 7, 2026 02:19
The spinner replaced the cars/connected string; keep the text as-is and show the spinner at the row's end while scanning or discovering.
@dzid26
dzid26 marked this pull request as ready for review October 7, 2026 02:22
@dzid26
dzid26 marked this pull request as draft October 7, 2026 02:25
@github-actions

github-actions Bot commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

Screenshots

App screenshots: light and dark

Captured from the demo build at f0a46f3.

dzid26 added 2 commits October 7, 2026 03:33
In landscape the fixed 200dp log content left no room for the cars. The card now takes 30 percent of the available height (at least 96dp) with internal scrolling.
With auto-stop the deferred shot caught a static list. Pull once more before capturing so the spinner shows with the known car, matching the dark pass.
@dzid26
dzid26 marked this pull request as ready for review October 7, 2026 02:34
@github-actions

github-actions Bot commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

Screenshots

App screenshots: light and dark

Captured from the demo build at 88d25bd.

@dzid26
dzid26 marked this pull request as draft October 7, 2026 14:41
wait_for_text Demo Tesla also matches the car view and settings, so a missed BACK captured the wrong screen as 02-scanning.png. Require Cars too, which only the list shows; otherwise leave a scan-known debug dump.
@dzid26
dzid26 marked this pull request as ready for review October 7, 2026 14:46
The light-pass Settings step used a bare BACK, which can land on the car view and capture it as 05-settings.png. back_to_list now follows BACK with the car view's own All-cars button when needed, so the step starts from the list.
claude added 2 commits October 7, 2026 20:29
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0129RzhbEE2cboMcYyZMuxqX
MainScreen left the composition while Settings was open, so its saved
list/car selection was dropped and Back re-ran the restore-last-car step.
A SaveableStateHolder keeps that state across the round trip. This is also
why the light-pass scan shot failed: Back from Settings landed on the car
view instead of the list.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0129RzhbEE2cboMcYyZMuxqX
@github-actions

github-actions Bot commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

Screenshots

App screenshots: light and dark

Captured from the demo build at 9c2b951.

@dzid26
dzid26 merged commit d6974e1 into main Oct 7, 2026
4 checks passed
@dzid26
dzid26 deleted the work/scan-list branch October 7, 2026 20:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants