Skip to content

Commit ffb02a5

Browse files
committed
fix(android): stabilize realtime talk connection state
1 parent 4656275 commit ffb02a5

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

apps/android/app/src/main/java/ai/openclaw/app/NodeRuntime.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -515,7 +515,7 @@ class NodeRuntime(
515515
context = appContext,
516516
scope = scope,
517517
session = operatorSession,
518-
isConnected = { operatorConnected },
518+
isConnected = { _isConnected.value },
519519
onBeforeSpeak = { micCapture.pauseForTts() },
520520
onAfterSpeak = { micCapture.resumeAfterTts() },
521521
).also { speaker ->
@@ -622,7 +622,7 @@ class NodeRuntime(
622622
context = appContext,
623623
scope = scope,
624624
session = operatorSession,
625-
isConnected = { operatorConnected },
625+
isConnected = { _isConnected.value },
626626
onBeforeSpeak = { micCapture.pauseForTts() },
627627
onAfterSpeak = { micCapture.resumeAfterTts() },
628628
onStoppedByRelay = { finishTalkModeAfterRelayClose() },

apps/android/app/src/main/java/ai/openclaw/app/voice/TalkModeManager.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -578,7 +578,7 @@ class TalkModeManager internal constructor(
578578
while (true) {
579579
realtimeSessionId?.let { return@withTimeout it }
580580
val status = _statusText.value
581-
if (!_isEnabled.value && status.startsWith("Talk failed")) {
581+
if (!_isEnabled.value && status != "Off") {
582582
throw IllegalStateException(status)
583583
}
584584
delay(100L)

0 commit comments

Comments
 (0)