Diagnostics & errors
Android Java SDK: Diagnostics & errors
Diagnostics & errors
Record the actual Android delivery version, OS, device model and failing operation, then inspect typed exceptions, device state and health().
| Symptom | Check and action |
|---|---|
| Gradle resolution failure or missing R8 classes | Use the complete Maven delivery, dependencies and repositories; rebuild release |
| Missing native library | Confirm arm64-v8a device and delivered ARM64 libraries in the APK |
| USB permission failure | Wait for the system result, recheck hasPermission, let the user reselect/authorize |
| Unsupported CDC ACM or multiple ports | Provide a matching custom SerialTransport |
| Invalid or ambiguous selection | Specify port, name and side; fix InvalidArgumentException or AmbiguousSelectionException |
| Empty latest | Confirm start/runtime, wait for first data, inspect connected/stale/lastError |
| Pose but no skeleton | Check delivered algorithms, pre-start skeleton selection and capture/calibration |
| Capture waits indefinitely | Render current plan/progress and submit the matching requestId and allowed action |
| Frozen UI | Move construction, runtime, join, close and calibration waits off the main thread |
Exceptions and health
SDK errors extend QnBotException. Fix inputs for InvalidArgumentException, order for LifecycleException, stop reusing handles for ClosedHandleException, refine selection for AmbiguousSelectionException, and check device/session state for CommandRejectedException. Do not hide invalid input or closed handles behind retries.
Health provides ok, warningCount, errorCount, lastError, devices, runtimeOverrun and topicCallbackError. Preserve corresponding logs/state when escalation is needed. Reproduce physical-headset or USB hotplug problems in the relevant product environment.