fix(takserver): emit *:-1:stcp contact endpoint so directed TAK-Talk/GeoChat routes over the mesh#5661
Merged
Merged
Conversation
…GeoChat routes over the mesh; SDK v0.5.1 The reconstructed contact endpoint (0.0.0.0:4242:tcp) made ATAK treat mesh peers as directly reachable, so directed messages (TAK-Talk <marti>, GeoChat to a callsign) were delivered to a dead address instead of the Meshtastic server stream and never hit the mesh — broadcast PLI was unaffected. Use the TAK 'reply via this server' endpoint *:-1:stcp (DEFAULT_TAK_ENDPOINT) and bump TAKPacket-SDK to 0.5.1, which fixes the same default in the SDK's CotXmlBuilder. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
jamesarich
approved these changes
May 29, 2026
thebentern
added a commit
that referenced
this pull request
May 30, 2026
The mesh can hand the bridge the same logical CoT event multiple times (a packet relayed over several LoRa paths, or a sender that retransmits), which made ATAK surface doubled chat / TAK-Talk messages. Add a small TTL cache (CotDeliveryDedup) keyed by the exact, already-normalized CoT XML and gate handleV2Packet on it: an identical event within the window is dropped, while genuine updates (new PLI position, moved marker, …) differ in content and pass through. Confined to the single meshPacketFlow collector coroutine, so no locking. Complements the *:-1:stcp endpoint fix (#5661) — that lets the TAK client dedupe cross-transport copies by uid; this stops the bridge from emitting its own duplicates. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Directed TAK-Talk (
<marti>) and directed GeoChat never reach the mesh — only broadcast PLI does. Field captures (CoT Explorer + logcat) show ATAK never hands the directed CoT to the Meshtastic TAK server: everyRAW CoT IN (TCP …)is a PLI, while a composed TAK-Talk simply never appears.Root cause
The reconstructed contact endpoint was
0.0.0.0:4242:tcp(a dead direct-TCP address), so ATAK treats mesh peers as directly reachable and tries to deliver directed messages to that address instead of replying down the Meshtastic server stream. Broadcast PLI is endpoint-agnostic, hence the asymmetry (position works, directed chat/voice doesn't).Fix
*:-1:stcp(matches real ATAK server-relayed contacts) viaDEFAULT_TAK_ENDPOINT.takpacket-sdkto 0.5.1, which fixes the same default in the SDK'sCotXmlBuilderacross all five bindings.__serverdestinationkeeps the authentic0.0.0.0:4242:tcpform.Notes
:core:takserver:jvmTestgreen against SDK 0.5.1 (mavenLocal).org.meshtastic:takpacket-sdk:0.5.1finishes publishing to Maven Central (SDK release in progress) — it goes green automatically once the artifact is available.🤖 Generated with Claude Code