mirror of
https://github.com/dz0ny/meshcore-sar.git
synced 2026-08-12 00:40:28 +00:00
feat: Enhance BLE connection strength indicator with RSSI display and adjust spacing
This commit is contained in:
@@ -574,7 +574,7 @@ class _HomeScreenState extends State<HomeScreen>
|
|||||||
Row(
|
Row(
|
||||||
mainAxisSize: MainAxisSize.min,
|
mainAxisSize: MainAxisSize.min,
|
||||||
children: [
|
children: [
|
||||||
// BLE connection strength indicator
|
// BLE connection strength indicator with RSSI
|
||||||
Icon(
|
Icon(
|
||||||
Icons.bluetooth_connected,
|
Icons.bluetooth_connected,
|
||||||
color: deviceInfo.signalRssi != null
|
color: deviceInfo.signalRssi != null
|
||||||
@@ -582,7 +582,17 @@ class _HomeScreenState extends State<HomeScreen>
|
|||||||
: Colors.grey,
|
: Colors.grey,
|
||||||
size: 16,
|
size: 16,
|
||||||
),
|
),
|
||||||
const SizedBox(width: 8),
|
const SizedBox(width: 4),
|
||||||
|
if (deviceInfo.signalRssi != null)
|
||||||
|
Text(
|
||||||
|
'${deviceInfo.signalRssi}dBm',
|
||||||
|
style: TextStyle(
|
||||||
|
fontSize: 12,
|
||||||
|
color: _getSignalColor(deviceInfo.signalRssi!),
|
||||||
|
fontWeight: FontWeight.w500,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
const SizedBox(width: 12),
|
||||||
// Battery indicator
|
// Battery indicator
|
||||||
if (deviceInfo.batteryPercent != null) ...[
|
if (deviceInfo.batteryPercent != null) ...[
|
||||||
Icon(
|
Icon(
|
||||||
|
|||||||
Reference in New Issue
Block a user