* feat(protobufs): sync to firmware-current and consume workspace package Sync the vendored .proto sources to firmware-current (v2.7.25+48), regenerate the v2 TS bindings, and consume the workspace @meshtastic/protobufs (workspace:*) in place of the stale JSR 2.7.20 — finishing the monorepo migration (core was already workspace:*). Includes the one required breaking-change fix: admin nodedb_reset changed int32 to bool, so resetNodes() now sends value: true. * build(protobufs): vendor generated bindings for workspace consumers The package is consumed via workspace:* — its exports point at the TS source, which imports ./dist/meshtastic/*_pb.ts — so the generated output must exist at build time. CI builds web/core with no codegen step and the runners have no buf CLI, so the bindings are vendored here (kept gitignored; lint/format skip them). Regenerate with: pnpm --filter @meshtastic/protobufs gen * fix(protobufs): clean script removes the actual generated output dir buf writes bindings to packages/ts/dist, but clean was removing a non-existent root dist — so it never cleaned stale output. Addresses Copilot review feedback. * refactor: move web app packages/web -> apps/web Aligns the web app with the apps/web layout (matching the Vercel web-test Root Directory and the SDK-migration direction). Pure directory move plus root config: pnpm-workspace (adds apps/*), vitest projects, root tsconfig reference, and the pr/release-web/nightly workflows. vercel.json moved with the app. Build + 36 validation tests green. * feat: config fields, module pages, key verification, telemetry capture Incorporates the firmware-current feature work onto the protobuf foundation: new config fields (Display message bubbles; LoRa fem_lna_mode + serial_hal_only; Telemetry air_quality_screen_enabled); 4 new ModuleConfig pages (TrafficManagement, StatusMessage, TAK, RemoteHardware); the manual Key Verification flow (sendKeyVerification + ClientNotificationDialog stages + Verify Key button); live telemetry capture (nodeDB addDeviceMetrics) and admin hardening (toggleMutedNode, graceful PortNum default); plus the sdk-preview ConfigEditor demo and store/config tests. Build + lint + format + 131 tests green. * chore: drop #1062 (unsaved-change-detection) to match upstream revert #1062 was merged to main by accident (per @danditomaso) and is being reverted. Reverse-applied its diff here via 3-way so #1097 stays consistent with where main is headed, while keeping the feature changes layered on the same files (deviceStore/changeRegistry). Build + 131 tests + lint + format green. * fix(nodes): clean up SNR display in node table and map popup SNR is a ratio measured in dB, not dBm (which is absolute power); the node table and map popup both mislabeled it and crammed three values together: '0dBm/50%/50raw'. The trailing '%/raw' pair was the same heuristic ((snr+10)*5) shown twice — once clamped, once not. Render SNR in dB rounded to one decimal, color-coded by a 0-100% signal-quality heuristic (green/yellow/red), with the quality percentage as a muted secondary. Drop the redundant raw value. Adds unit.db; this matches the existing SNRTooltip, which already renders dB.
286 lines
8.5 KiB
Protocol Buffer
286 lines
8.5 KiB
Protocol Buffer
syntax = "proto3";
|
|
|
|
package meshtastic;
|
|
|
|
option csharp_namespace = "Meshtastic.Protobufs";
|
|
option go_package = "github.com/meshtastic/go/generated";
|
|
option java_outer_classname = "Portnums";
|
|
option java_package = "org.meshtastic.proto";
|
|
option swift_prefix = "";
|
|
|
|
/*
|
|
* For any new 'apps' that run on the device or via sister apps on phones/PCs they should pick and use a
|
|
* unique 'portnum' for their application.
|
|
* If you are making a new app using meshtastic, please send in a pull request to add your 'portnum' to this
|
|
* master table.
|
|
* PortNums should be assigned in the following range:
|
|
* 0-63 Core Meshtastic use, do not use for third party apps
|
|
* 64-127 Registered 3rd party apps, send in a pull request that adds a new entry to portnums.proto to register your application
|
|
* 256-511 Use one of these portnums for your private applications that you don't want to register publically
|
|
* All other values are reserved.
|
|
* Note: This was formerly a Type enum named 'typ' with the same id #
|
|
* We have change to this 'portnum' based scheme for specifying app handlers for particular payloads.
|
|
* This change is backwards compatible by treating the legacy OPAQUE/CLEAR_TEXT values identically.
|
|
*/
|
|
enum PortNum {
|
|
/*
|
|
* Deprecated: do not use in new code (formerly called OPAQUE)
|
|
* A message sent from a device outside of the mesh, in a form the mesh does not understand
|
|
* NOTE: This must be 0, because it is documented in IMeshService.aidl to be so
|
|
* ENCODING: binary undefined
|
|
*/
|
|
UNKNOWN_APP = 0;
|
|
|
|
/*
|
|
* A simple UTF-8 text message, which even the little micros in the mesh
|
|
* can understand and show on their screen eventually in some circumstances
|
|
* even signal might send messages in this form (see below)
|
|
* ENCODING: UTF-8 Plaintext (?)
|
|
*/
|
|
TEXT_MESSAGE_APP = 1;
|
|
|
|
/*
|
|
* Reserved for built-in GPIO/example app.
|
|
* See remote_hardware.proto/HardwareMessage for details on the message sent/received to this port number
|
|
* ENCODING: Protobuf
|
|
*/
|
|
REMOTE_HARDWARE_APP = 2;
|
|
|
|
/*
|
|
* The built-in position messaging app.
|
|
* Payload is a Position message.
|
|
* ENCODING: Protobuf
|
|
*/
|
|
POSITION_APP = 3;
|
|
|
|
/*
|
|
* The built-in user info app.
|
|
* Payload is a User message.
|
|
* ENCODING: Protobuf
|
|
*/
|
|
NODEINFO_APP = 4;
|
|
|
|
/*
|
|
* Protocol control packets for mesh protocol use.
|
|
* Payload is a Routing message.
|
|
* ENCODING: Protobuf
|
|
*/
|
|
ROUTING_APP = 5;
|
|
|
|
/*
|
|
* Admin control packets.
|
|
* Payload is a AdminMessage message.
|
|
* ENCODING: Protobuf
|
|
*/
|
|
ADMIN_APP = 6;
|
|
|
|
/*
|
|
* Compressed TEXT_MESSAGE payloads.
|
|
* ENCODING: UTF-8 Plaintext (?) with Unishox2 Compression
|
|
* NOTE: The Device Firmware converts a TEXT_MESSAGE_APP to TEXT_MESSAGE_COMPRESSED_APP if the compressed
|
|
* payload is shorter. There's no need for app developers to do this themselves. Also the firmware will decompress
|
|
* any incoming TEXT_MESSAGE_COMPRESSED_APP payload and convert to TEXT_MESSAGE_APP.
|
|
*/
|
|
TEXT_MESSAGE_COMPRESSED_APP = 7;
|
|
|
|
/*
|
|
* Waypoint payloads.
|
|
* Payload is a Waypoint message.
|
|
* ENCODING: Protobuf
|
|
*/
|
|
WAYPOINT_APP = 8;
|
|
|
|
/*
|
|
* Audio Payloads.
|
|
* Encapsulated codec2 packets. On 2.4 GHZ Bandwidths only for now
|
|
* ENCODING: codec2 audio frames
|
|
* NOTE: audio frames contain a 3 byte header (0xc0 0xde 0xc2) and a one byte marker for the decompressed bitrate.
|
|
* This marker comes from the 'moduleConfig.audio.bitrate' enum minus one.
|
|
*/
|
|
AUDIO_APP = 9;
|
|
|
|
/*
|
|
* Same as Text Message but originating from Detection Sensor Module.
|
|
* NOTE: This portnum traffic is not sent to the public MQTT starting at firmware version 2.2.9
|
|
*/
|
|
DETECTION_SENSOR_APP = 10;
|
|
|
|
/*
|
|
* Same as Text Message but used for critical alerts.
|
|
*/
|
|
ALERT_APP = 11;
|
|
|
|
/*
|
|
* Module/port for handling key verification requests.
|
|
*/
|
|
KEY_VERIFICATION_APP = 12;
|
|
|
|
/*
|
|
* Module/port for handling primitive remote shell access.
|
|
*/
|
|
REMOTE_SHELL_APP = 13;
|
|
|
|
/*
|
|
* Provides a 'ping' service that replies to any packet it receives.
|
|
* Also serves as a small example module.
|
|
* ENCODING: ASCII Plaintext
|
|
*/
|
|
REPLY_APP = 32;
|
|
|
|
/*
|
|
* Used for the python IP tunnel feature
|
|
* ENCODING: IP Packet. Handled by the python API, firmware ignores this one and pases on.
|
|
*/
|
|
IP_TUNNEL_APP = 33;
|
|
|
|
/*
|
|
* Paxcounter lib included in the firmware
|
|
* ENCODING: protobuf
|
|
*/
|
|
PAXCOUNTER_APP = 34;
|
|
|
|
/*
|
|
* Store and Forward++ module included in the firmware
|
|
* ENCODING: protobuf
|
|
* This module is specifically for Native Linux nodes, and provides a Git-style
|
|
* chain of messages.
|
|
*/
|
|
STORE_FORWARD_PLUSPLUS_APP = 35;
|
|
|
|
/*
|
|
* Node Status module
|
|
* ENCODING: protobuf
|
|
* This module allows setting an extra string of status for a node.
|
|
* Broadcasts on change and on a timer, possibly once a day.
|
|
*/
|
|
NODE_STATUS_APP = 36;
|
|
|
|
/*
|
|
* Provides a hardware serial interface to send and receive from the Meshtastic network.
|
|
* Connect to the RX/TX pins of a device with 38400 8N1. Packets received from the Meshtastic
|
|
* network is forwarded to the RX pin while sending a packet to TX will go out to the Mesh network.
|
|
* Maximum packet size of 240 bytes.
|
|
* Module is disabled by default can be turned on by setting SERIAL_MODULE_ENABLED = 1 in SerialPlugh.cpp.
|
|
* ENCODING: binary undefined
|
|
*/
|
|
SERIAL_APP = 64;
|
|
|
|
/*
|
|
* STORE_FORWARD_APP (Work in Progress)
|
|
* Maintained by Jm Casler (MC Hamster) : jm@casler.org
|
|
* ENCODING: Protobuf
|
|
*/
|
|
STORE_FORWARD_APP = 65;
|
|
|
|
/*
|
|
* Optional port for messages for the range test module.
|
|
* ENCODING: ASCII Plaintext
|
|
* NOTE: This portnum traffic is not sent to the public MQTT starting at firmware version 2.2.9
|
|
*/
|
|
RANGE_TEST_APP = 66;
|
|
|
|
/*
|
|
* Provides a format to send and receive telemetry data from the Meshtastic network.
|
|
* Maintained by Charles Crossan (crossan007) : crossan007@gmail.com
|
|
* ENCODING: Protobuf
|
|
*/
|
|
TELEMETRY_APP = 67;
|
|
|
|
/*
|
|
* Experimental tools for estimating node position without a GPS
|
|
* Maintained by Github user a-f-G-U-C (a Meshtastic contributor)
|
|
* Project files at https://github.com/a-f-G-U-C/Meshtastic-ZPS
|
|
* ENCODING: arrays of int64 fields
|
|
*/
|
|
ZPS_APP = 68;
|
|
|
|
/*
|
|
* Used to let multiple instances of Linux native applications communicate
|
|
* as if they did using their LoRa chip.
|
|
* Maintained by GitHub user GUVWAF.
|
|
* Project files at https://github.com/GUVWAF/Meshtasticator
|
|
* ENCODING: Protobuf (?)
|
|
*/
|
|
SIMULATOR_APP = 69;
|
|
|
|
/*
|
|
* Provides a traceroute functionality to show the route a packet towards
|
|
* a certain destination would take on the mesh. Contains a RouteDiscovery message as payload.
|
|
* ENCODING: Protobuf
|
|
*/
|
|
TRACEROUTE_APP = 70;
|
|
|
|
/*
|
|
* Aggregates edge info for the network by sending out a list of each node's neighbors
|
|
* ENCODING: Protobuf
|
|
*/
|
|
NEIGHBORINFO_APP = 71;
|
|
|
|
/*
|
|
* ATAK Plugin
|
|
* Portnum for payloads from the official Meshtastic ATAK plugin
|
|
*/
|
|
ATAK_PLUGIN = 72;
|
|
|
|
/*
|
|
* Provides unencrypted information about a node for consumption by a map via MQTT
|
|
*/
|
|
MAP_REPORT_APP = 73;
|
|
|
|
/*
|
|
* PowerStress based monitoring support (for automated power consumption testing)
|
|
*/
|
|
POWERSTRESS_APP = 74;
|
|
|
|
/*
|
|
* LoraWAN Payload Transport
|
|
* ENCODING: compact binary LoRaWAN uplink (10-byte RF metadata + PHY payload) - see LoRaWANBridgeModule
|
|
*/
|
|
LORAWAN_BRIDGE = 75;
|
|
|
|
/*
|
|
* Reticulum Network Stack Tunnel App
|
|
* ENCODING: Fragmented RNS Packet. Handled by Meshtastic RNS interface
|
|
*/
|
|
RETICULUM_TUNNEL_APP = 76;
|
|
|
|
/*
|
|
* App for transporting Cayenne Low Power Payload, popular for LoRaWAN sensor nodes. Offers ability to send
|
|
* arbitrary telemetry over meshtastic that is not covered by telemetry.proto
|
|
* ENCODING: CayenneLLP
|
|
*/
|
|
CAYENNE_APP = 77;
|
|
|
|
/*
|
|
* ATAK Plugin V2
|
|
* Portnum for payloads from the official Meshtastic ATAK plugin using
|
|
* TAKPacketV2 with zstd dictionary compression.
|
|
*/
|
|
ATAK_PLUGIN_V2 = 78;
|
|
|
|
/*
|
|
* GroupAlarm integration
|
|
* Used for transporting GroupAlarm-related messages between Meshtastic nodes
|
|
* and companion applications/services.
|
|
*/
|
|
GROUPALARM_APP = 112;
|
|
|
|
/*
|
|
* Private applications should use portnums >= 256.
|
|
* To simplify initial development and testing you can use "PRIVATE_APP"
|
|
* in your code without needing to rebuild protobuf files (via [regen-protos.sh](https://github.com/meshtastic/firmware/blob/master/bin/regen-protos.sh))
|
|
*/
|
|
PRIVATE_APP = 256;
|
|
|
|
/*
|
|
* ATAK Forwarder Module https://github.com/paulmandal/atak-forwarder
|
|
* ENCODING: libcotshrink
|
|
*/
|
|
ATAK_FORWARDER = 257;
|
|
|
|
/*
|
|
* Currently we limit port nums to no higher than this value
|
|
*/
|
|
MAX = 511;
|
|
}
|