Skip to content

Takv2 geometry and other structures#891

Merged
caveman99 merged 10 commits intomasterfrom
takv2_geometry
Apr 14, 2026
Merged

Takv2 geometry and other structures#891
caveman99 merged 10 commits intomasterfrom
takv2_geometry

Conversation

@thebentern
Copy link
Copy Markdown
Contributor

Claude helped transcribe a lot of this tedious work

thebentern and others added 6 commits April 9, 2026 14:11
The typed geometry payloads added in c61fcb5 introduced a top-level
`message GeoPoint` for delta-encoded vertices in DrawnShape / RangeAndBearing
/ Route. That collides with the pre-existing `meshtastic.GeoPoint` in
device_ui.proto (an unrelated zoom/latitude/longitude type used by the
on-device map UI).

protoc alone doesn't catch the duplicate because the SDK's build only
compiles atak.proto in isolation, but Wire (used by Meshtastic-Android
to generate Kotlin classes for the whole meshtastic package) does, and
refuses to build atak.proto with:

  meshtastic/atak.proto needs to import meshtastic/device_ui.proto
    for field vertices ... in message meshtastic.DrawnShape

Rename the new type to CotGeoPoint — matches the existing CotType /
CotHow naming convention in atak.proto, keeps the meaning obvious, and
doesn't touch the device_ui schema or any caller of the old map-UI
GeoPoint. Field numbers and wire format are unchanged.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Expand the TAKPacketV2 payload_variant with three new typed messages at
tags 38/39/40, extend GeoChat with receipt fields, add 43 new CotType
enum entries (82-124), and add 3 DrawnShape.Kind / 5 Marker.Kind values
for types the previous rollout left on the cot_type_str fallback path.

- CasevacReport (tag 38): 9-line MEDEVAC with Precedence / HlzMarking /
  Security enums and equipment_flags / terrain_flags bitfields. Mirrors
  ATAK's <_medevac_> detail element; captures what the raw-detail
  fallback would otherwise drop (patient counts, zone marker, freq).
- EmergencyAlert (tag 39): typed record for b-a-o-* / b-a-g alerts,
  carries authoring_uid and cancel_reference_uid so modern receivers
  can handle the alert chain without XML parsing.
- TaskRequest (tag 40): t-s engagement / tasking record with Priority /
  Status enums, task_type / target_uid / assignee_uid / note fields.
  All strings capped tight so the worst case fits under the LoRa MTU.
- GeoChat (tag 31): append receipt_for_uid + receipt_type for b-t-f-d
  (delivered) and b-t-f-r (read) receipts riding on the existing chat
  slot — no new oneof case needed.
- CotType: +43 values covering a-f-G-E-V-A self PLI, the neutral-
  aircraft affiliation, the full 2525 quick-drop set (artillery /
  building / mine / ship / sniper / tank / troops / vehicle) across
  unknown / neutral / hostile / friendly affiliations, mission points
  (GOTO / IP / CP / OP), vehicle shapes, ellipse drawing, image
  marker, chat receipts, custom emergency, and tasking.
- DrawnShape.Kind: +Ellipse (8) / Vehicle2D (9) / Vehicle3D (10).
- Marker.Kind: +GoToPoint (8) / InitialPoint (9) / ContactPoint (10)
  / ObservationPost (11) / ImageMarker (12).
- atak.options: pool sizing for every new field. int_size:8 for byte
  counts and bitfields, max_size:12-48 for strings to keep the worst-
  case wire size under 237B.

All additions are append-only — proto3 unknown-field semantics
preserve wire compatibility for pre-update receivers.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Expand the TAKPacketV2 payload_variant with three new typed messages at
tags 38/39/40, extend GeoChat with receipt fields, add 43 new CotType
enum entries (82-124), and add 3 DrawnShape.Kind / 5 Marker.Kind values
for types the previous rollout left on the cot_type_str fallback path.

- CasevacReport (tag 38): 9-line MEDEVAC with Precedence / HlzMarking /
  Security enums and equipment_flags / terrain_flags bitfields.
- EmergencyAlert (tag 39): typed record for b-a-o-* / b-a-g alerts
  with authoring_uid and cancel_reference_uid.
- TaskRequest (tag 40): t-s engagement / tasking record with Priority
  / Status enums and target_uid / assignee_uid / note.
- GeoChat (tag 31): append receipt_for_uid + receipt_type for b-t-f-d
  / b-t-f-r receipts riding on the existing chat slot.
- CotType: +43 entries (82-124) for 2525 quick-drop, mission points,
  vehicle shapes, receipts, emergencies, and tasking.
- DrawnShape.Kind: +Ellipse (8) / Vehicle2D (9) / Vehicle3D (10).
- Marker.Kind: +GoToPoint (8) / InitialPoint (9) / ContactPoint (10)
  / ObservationPost (11) / ImageMarker (12).
- atak.options: pool sizing for every new field.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@thebentern thebentern requested a review from Copilot April 13, 2026 12:00
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 13, 2026

The latest Buf updates on your PR. Results from workflow pull-request / build (pull_request).

BuildFormatLintBreakingUpdated (UTC)
✅ passed✅ passed✅ passed✅ passedApr 14, 2026, 1:05 AM

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR expands the ATAK v2 protobuf schema to cover additional CoT event types and introduces structured (typed) payloads for geometry, markers, routes, emergencies, and tasking to reduce reliance on raw XML detail blobs.

Changes:

  • Added GeoChat receipt support (delivered/read) and expanded CotType coverage for additional ATAK quick-drop/pallet items.
  • Introduced new typed v2 payload messages (DrawnShape, Marker, RangeAndBearing, Route, CasevacReport, EmergencyAlert, TaskRequest) plus delta-encoded vertex type CotGeoPoint.
  • Updated nanopb .options to bound sizes/counts for the new message fields.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 6 comments.

File Description
meshtastic/atak.proto Adds new CoT enum values, new typed payload messages, and new fields for receipts and remarks in TAK v2 packets.
meshtastic/atak.options Adds nanopb sizing/count options for new typed payload messages (but missing one for the newly added remarks).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread meshtastic/atak.proto Outdated
Comment thread meshtastic/atak.proto Outdated
Comment thread meshtastic/atak.proto
Comment thread meshtastic/atak.proto
Comment thread meshtastic/atak.options
Comment thread meshtastic/atak.proto Outdated
thebentern and others added 3 commits April 13, 2026 19:57
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@thebentern
Copy link
Copy Markdown
Contributor Author

@copilot fix the formatting with buf format

Agent-Logs-Url: https://github.com/meshtastic/protobufs/sessions/b160fe5f-6cf4-46dd-80f3-d3cde088c5fb

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
Copy link
Copy Markdown
Contributor

Copilot AI commented Apr 14, 2026

@copilot fix the formatting with buf format

Done — ran buf format -w meshtastic/atak.proto and committed the result in c9ed7da.

@CLAassistant
Copy link
Copy Markdown

CLAassistant commented Apr 14, 2026

CLA assistant check
All committers have signed the CLA.

@caveman99 caveman99 merged commit 0e5eab1 into master Apr 14, 2026
2 checks passed
@caveman99 caveman99 deleted the takv2_geometry branch April 14, 2026 10:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants