← Back to Pull requests

Companion Power Optimizations and UI Support for XIAO NRF52 #1122

Closed
unknown closed this pull request without merging on Nov 26, 2025 11:11 UTC
View on GitHub
unknown unknown commented on Nov 20, 2025 10:28 UTC
Author

This is a collection of small changes that improve the power consumption for companion devices and adds UI (LED & user button) support for the XIAO NRF52 + Wio-SX1262.

The main change is calling RadioLibs PhysicalLayer::sleep() for all modules in case the system is powered off in the companion UI. This will ensure that the proper commands are sent to the module to put it into the lowest possible sleep mode. This results in very low power-off consumption and extended battery lifetime when powered-off, especially for NRF52-based companions.

Changes

Seeed SenseCAP T1000-E

Put radio into sleep mode if companion is powered off. This significantly reduces the power-off consumption and increases battery life.

RAK WisMesh Tag

Put radio into sleep mode if companion is powered off. This significantly reduces the power-off consumption and increases battery life.
Enable DC/DC regulator. This reduces power-on consumption and therefore increases battery life.
Enable blue status LED. This prevents an always-on LED and aligns the LED behavior with other devices like T1000.

Seeed XIAO NRF52 + Wio-SX1262

Enable UI for companions based on this hardware, so user button and status LED can be used.
Enable DC/DC regulator. This reduces power-on consumption by about 25% and therefore increases battery life.
Enable user button including low-power off state with about 15 µA of power consumption from the battery.
Fix status LED behavior for LED_STATE_ON=0 and enable status LED

Heltec T114

Put radio into sleep mode if companion is powered off. This significantly reduces the power-off consumption and increases battery life.
Enable DC/DC regulator. This reduces power-on consumption and therefore increases battery life.
Disable LED and GPS in power off state.
~Currently untested~

Diff: 232 lines (+174 / -58) across 2 files Reviewer: yarda Review duration: 8682m
All Vouch review confidence checks passed
Residual risk 0.15 = Change Risk (0.37) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.37 · 232 lines diff across 2 files
0.37
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
0.17
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
60%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size diff_size
0.326
Shallow Review Depth shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #1122"
general weight: 0.35
Reviewers
Assignees
Unassigned
Labels
risk: low confidence: 60.5% reviewed
Vouch Risk Breakdown
AI-powered review risk analysis
Change Risk
Change Risk · Model 1 (XGBoost)
Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
Score: 37.1% (MEDIUM) · Higher = larger blast radius
37.1%
Review Confidence
Review Confidence · Models 2 & 3
Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
Score: 60.5% · Lower = rushed or shallow review
60.5%
Residual Risk
Residual Risk · Core Equation
Residual = Change × (1 − Confidence)
Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
Score: 14.6% · Safe to merge
14.6%