Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Local device mesh stats container #560

Merged
merged 1 commit into from
Aug 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion meshtastic/telemetry.options
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,7 @@
# https://jpa.kapsi.fi/nanopb/docs/reference.html#proto-file-options

*EnvironmentMetrics.iaq int_size:16
*EnvironmentMetrics.wind_direction int_size:16
*EnvironmentMetrics.wind_direction int_size:16

*LocalStats.num_online_nodes int_size:16
*LocalStats.num_total_nodes int_size:16
48 changes: 48 additions & 0 deletions meshtastic/telemetry.proto
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,49 @@ message AirQualityMetrics {
optional uint32 particles_100um = 12;
}

/*
* Local device mesh statistics
*/
message LocalStats {
/*
* How long the device has been running since the last reboot (in seconds)
*/
uint32 uptime_seconds = 1;
/*
* Utilization for the current channel, including well formed TX, RX and malformed RX (aka noise).
*/
float channel_utilization = 2;
/*
* Percent of airtime for transmission used within the last hour.
*/
float air_util_tx = 3;

/*
* Number of packets sent
*/
uint32 num_packets_tx = 4;

/*
* Number of packets received good
*/
uint32 num_packets_rx = 5;

/*
* Number of packets received that are malformed or violate the protocol
*/
uint32 num_packets_rx_bad = 6;

/*
* Number of nodes online (in the past 2 hours)
*/
uint32 num_online_nodes = 7;

/*
* Number of nodes total
*/
uint32 num_total_nodes = 8;
}

/*
* Types of Measurements the telemetry module is equipped to handle
*/
Expand Down Expand Up @@ -259,6 +302,11 @@ message Telemetry {
* Power Metrics
*/
PowerMetrics power_metrics = 5;

/*
* Local device mesh statistics
*/
LocalStats local_stats = 6;
}
}

Expand Down