Step 2 — Return Old Battery¶
Purpose¶
The Return step captures the details of the customer's old (depleted) battery. The attendant scans, connects, and reads the battery's identity and remaining energy before recording the return.
Workflow¶
- Scan the QR code on the customer's old battery.
- Connect to the battery via Bluetooth Low Energy (BLE).
-
Read the battery's data from its BLE services:
BLE Service Data Read Description ATT (Attribute) Battery ID Unique identifier of the battery DTA (Data) Remaining energy Energy left in the battery (kWh) -
The app records the old battery ID and its remaining energy.
UI Behavior¶
- The scan area provides clear visual guidance for QR placement.
- Once connected via BLE, the battery ID and energy reading are displayed on screen.
- A confirmation indicator shows the battery has been successfully read and recorded.
- If the BLE connection drops, the app prompts the attendant to retry.
What Gets Recorded¶
| Field | Example |
|---|---|
| Old battery ID | BAT-2024-00451 |
| Remaining energy | 0.38 kWh |
These values are carried forward to Step 3 and Step 4 for cost calculation and review.
Error Handling¶
- QR code unreadable — retry scan or enter battery ID manually
- BLE connection failed — ensure Bluetooth is enabled and the battery is in range; retry connection
- Energy read timeout — the app retries automatically; if it persists, the attendant can re-scan
Actions¶
- Continue proceeds to Step 3 — New Battery Assignment
- Back returns to Step 1 — Customer Identification