From 4fb4d233e5590fbaf187397fe5e233903aaac37a Mon Sep 17 00:00:00 2001 From: David O'Connor Date: Fri, 9 Jun 2023 14:27:48 -0400 Subject: [PATCH 1/8] Added link stats packet --- ...nput.uavcan => 1140.RCInput - Copy.uavcan} | 0 dronecan/sensors/rc/1141.RCLinkStats.uavcan | 38 +++++++++++++++++++ 2 files changed, 38 insertions(+) rename dronecan/sensors/rc/{1140.RCInput.uavcan => 1140.RCInput - Copy.uavcan} (100%) create mode 100644 dronecan/sensors/rc/1141.RCLinkStats.uavcan diff --git a/dronecan/sensors/rc/1140.RCInput.uavcan b/dronecan/sensors/rc/1140.RCInput - Copy.uavcan similarity index 100% rename from dronecan/sensors/rc/1140.RCInput.uavcan rename to dronecan/sensors/rc/1140.RCInput - Copy.uavcan diff --git a/dronecan/sensors/rc/1141.RCLinkStats.uavcan b/dronecan/sensors/rc/1141.RCLinkStats.uavcan new file mode 100644 index 0000000..53862bc --- /dev/null +++ b/dronecan/sensors/rc/1141.RCLinkStats.uavcan @@ -0,0 +1,38 @@ +# +# This definition describes metadata and statistics for a RF control link. +# It provides information regarding a link's signal quality, as well as transmitter +# power, and antenna information. It accomodates single-radio, and dual-radio +# link architectures. It provides information for both uplink (control unit to airborne +# receiver), and downlink (airborne receiver to control unit) data. +# + +uint8 STATUS_RSSI_VALID = 1 # RSSI field is valid + +# Uplink - received signal strength (RSSI) for antennas 1 and 2 respectively. Ranges from +# -255 to 0. (An integer value of 100 means RSSI is -100dBm) +uint8 uplink_rssi_1 +uint8 uplink_rssi_2 + +# Link quality, on a scale from 0 to 255 - its precise definition may change basd on the link +# protocol used. Example: percentage of recent packets received correctly. With this example, +# 0 means no valid packets received recently; 255 means 100% of packets received recently are # valid. +uint8 uplink_link_quality + +# Signal-to-noise ratio. +int8 uplink_snr + +# Example: 1 for antenna 1, and 2 for antenna 2. Not applicable for single-antenna links. +uint8 active_antenna + +# This is an implementation-specific enum. May represent the OTA protocol used, +# and transmission rate. +uint8 rf_mode + +# This is an implementation-specific enum describing the current transmitter nominal +# power level. +uint8 uplink_tx_power + +# Statistics for downlink data, ie telemetry. +uint8 downlink_rssi +uint8 downlink_link_quality +int8 downlink_snr From 4726e556f647c06a76ad7beaae12978c66fd9fbb Mon Sep 17 00:00:00 2001 From: David O'Connor Date: Fri, 9 Jun 2023 14:29:02 -0400 Subject: [PATCH 2/8] Fixed error --- .../rc/{1140.RCInput - Copy.uavcan => 1140.RCInput.uavcan} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename dronecan/sensors/rc/{1140.RCInput - Copy.uavcan => 1140.RCInput.uavcan} (100%) diff --git a/dronecan/sensors/rc/1140.RCInput - Copy.uavcan b/dronecan/sensors/rc/1140.RCInput.uavcan similarity index 100% rename from dronecan/sensors/rc/1140.RCInput - Copy.uavcan rename to dronecan/sensors/rc/1140.RCInput.uavcan From da39c065ca79cce577e9647bb41f7728d1b42c8b Mon Sep 17 00:00:00 2001 From: David O'Connor Date: Tue, 20 Jun 2023 22:44:56 -0400 Subject: [PATCH 3/8] Change to LQ and RSSI descriptions --- dronecan/sensors/rc/1141.RCLinkStats.uavcan | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/dronecan/sensors/rc/1141.RCLinkStats.uavcan b/dronecan/sensors/rc/1141.RCLinkStats.uavcan index 53862bc..d342635 100644 --- a/dronecan/sensors/rc/1141.RCLinkStats.uavcan +++ b/dronecan/sensors/rc/1141.RCLinkStats.uavcan @@ -8,15 +8,12 @@ uint8 STATUS_RSSI_VALID = 1 # RSSI field is valid -# Uplink - received signal strength (RSSI) for antennas 1 and 2 respectively. Ranges from -# -255 to 0. (An integer value of 100 means RSSI is -100dBm) +# Uplink - received signal strength, in decibel-milliwatts (RSSI dBm) for antennas 1 and 2 respectively. +Ranges from # -255 to 0. (An integer value of 100 means RSSI is -100dBm) uint8 uplink_rssi_1 uint8 uplink_rssi_2 -# Link quality, on a scale from 0 to 255 - its precise definition may change basd on the link -# protocol used. Example: percentage of recent packets received correctly. With this example, -# 0 means no valid packets received recently; 255 means 100% of packets received recently are # valid. -uint8 uplink_link_quality +# Link quality, on a scale from 1 to 255. Is a proxy for packet loss. 0 means data is unavailable. 1 and 255 are mapped to 0% and 100% of packets received. # Signal-to-noise ratio. int8 uplink_snr From d84dd8ffdf9f585d5e484ea2052792dee7081f9b Mon Sep 17 00:00:00 2001 From: David O'Connor Date: Wed, 21 Jun 2023 08:49:51 -0400 Subject: [PATCH 4/8] More updates --- dronecan/sensors/rc/1141.RCLinkStats.uavcan | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/dronecan/sensors/rc/1141.RCLinkStats.uavcan b/dronecan/sensors/rc/1141.RCLinkStats.uavcan index d342635..d894e82 100644 --- a/dronecan/sensors/rc/1141.RCLinkStats.uavcan +++ b/dronecan/sensors/rc/1141.RCLinkStats.uavcan @@ -9,11 +9,12 @@ uint8 STATUS_RSSI_VALID = 1 # RSSI field is valid # Uplink - received signal strength, in decibel-milliwatts (RSSI dBm) for antennas 1 and 2 respectively. -Ranges from # -255 to 0. (An integer value of 100 means RSSI is -100dBm) +# Ranges from # -255 to 0. (An integer value of 100 means RSSI is -100dBm) uint8 uplink_rssi_1 uint8 uplink_rssi_2 # Link quality, on a scale from 1 to 255. Is a proxy for packet loss. 0 means data is unavailable. 1 and 255 are mapped to 0% and 100% of packets received. +uint8 uplink_link_quality # Signal-to-noise ratio. int8 uplink_snr @@ -29,7 +30,8 @@ uint8 rf_mode # power level. uint8 uplink_tx_power -# Statistics for downlink data, ie telemetry. +# Statistics for downlink data, ie telemetry. See their respective `uplink` fields for +# descriptions. uint8 downlink_rssi uint8 downlink_link_quality -int8 downlink_snr +int8 downlink_snr \ No newline at end of file From 21fc2642da6f0676a8921a9e7d01f4359e547755 Mon Sep 17 00:00:00 2001 From: David O'Connor Date: Wed, 21 Jun 2023 08:51:49 -0400 Subject: [PATCH 5/8] Added uplink active antenna --- dronecan/sensors/rc/1141.RCLinkStats.uavcan | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/dronecan/sensors/rc/1141.RCLinkStats.uavcan b/dronecan/sensors/rc/1141.RCLinkStats.uavcan index d894e82..09c2176 100644 --- a/dronecan/sensors/rc/1141.RCLinkStats.uavcan +++ b/dronecan/sensors/rc/1141.RCLinkStats.uavcan @@ -20,7 +20,7 @@ uint8 uplink_link_quality int8 uplink_snr # Example: 1 for antenna 1, and 2 for antenna 2. Not applicable for single-antenna links. -uint8 active_antenna +uint8 uplink_active_antenna # This is an implementation-specific enum. May represent the OTA protocol used, # and transmission rate. @@ -34,4 +34,5 @@ uint8 uplink_tx_power # descriptions. uint8 downlink_rssi uint8 downlink_link_quality -int8 downlink_snr \ No newline at end of file +int8 downlink_snr +uint8 downlink_active_antenna From 39f5713e57d2769db7030b102dbbf36b7af49f53 Mon Sep 17 00:00:00 2001 From: David O'Connor Date: Wed, 21 Jun 2023 08:53:42 -0400 Subject: [PATCH 6/8] Update --- dronecan/sensors/rc/1141.RCLinkStats.uavcan | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/dronecan/sensors/rc/1141.RCLinkStats.uavcan b/dronecan/sensors/rc/1141.RCLinkStats.uavcan index 09c2176..082930c 100644 --- a/dronecan/sensors/rc/1141.RCLinkStats.uavcan +++ b/dronecan/sensors/rc/1141.RCLinkStats.uavcan @@ -19,9 +19,6 @@ uint8 uplink_link_quality # Signal-to-noise ratio. int8 uplink_snr -# Example: 1 for antenna 1, and 2 for antenna 2. Not applicable for single-antenna links. -uint8 uplink_active_antenna - # This is an implementation-specific enum. May represent the OTA protocol used, # and transmission rate. uint8 rf_mode @@ -35,4 +32,8 @@ uint8 uplink_tx_power uint8 downlink_rssi uint8 downlink_link_quality int8 downlink_snr -uint8 downlink_active_antenna + +# Active antenna on transmitter and receiver. Example: 1 for antenna 1, and 2 for antenna 2. +# Not applicable for single-antenna links. +uint8 tx_active_antenna +uint8 Rx_active_antenna \ No newline at end of file From fbbf89d2e64e82e6b5b4e78ba3f5b4afe660d506 Mon Sep 17 00:00:00 2001 From: David O'Connor Date: Wed, 21 Jun 2023 22:12:05 -0400 Subject: [PATCH 7/8] typo --- dronecan/sensors/rc/1141.RCLinkStats.uavcan | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dronecan/sensors/rc/1141.RCLinkStats.uavcan b/dronecan/sensors/rc/1141.RCLinkStats.uavcan index 082930c..c048627 100644 --- a/dronecan/sensors/rc/1141.RCLinkStats.uavcan +++ b/dronecan/sensors/rc/1141.RCLinkStats.uavcan @@ -36,4 +36,4 @@ int8 downlink_snr # Active antenna on transmitter and receiver. Example: 1 for antenna 1, and 2 for antenna 2. # Not applicable for single-antenna links. uint8 tx_active_antenna -uint8 Rx_active_antenna \ No newline at end of file +uint8 rx_active_antenna \ No newline at end of file From 6cfa8b94d650a1b21f31f71f8d84c352fff03d6e Mon Sep 17 00:00:00 2001 From: David O'Connor Date: Thu, 22 Jun 2023 11:26:55 -0400 Subject: [PATCH 8/8] Added downlink rssi 2 --- dronecan/sensors/rc/1141.RCLinkStats.uavcan | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dronecan/sensors/rc/1141.RCLinkStats.uavcan b/dronecan/sensors/rc/1141.RCLinkStats.uavcan index c048627..86ff493 100644 --- a/dronecan/sensors/rc/1141.RCLinkStats.uavcan +++ b/dronecan/sensors/rc/1141.RCLinkStats.uavcan @@ -29,7 +29,8 @@ uint8 uplink_tx_power # Statistics for downlink data, ie telemetry. See their respective `uplink` fields for # descriptions. -uint8 downlink_rssi +uint8 downlink_rssi_1 +uint8 downlink_rssi_2 uint8 downlink_link_quality int8 downlink_snr