From 09be56454a2f2a3b406fe7cf33b28dfc4b252c7c Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Thu, 1 May 2025 11:01:14 +1000 Subject: [PATCH 1/2] added GlobalTime message allowing peripherals access to global time stamp without direct GPS access --- dronecan/protocol/344.GlobalTime.uavcan | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 dronecan/protocol/344.GlobalTime.uavcan diff --git a/dronecan/protocol/344.GlobalTime.uavcan b/dronecan/protocol/344.GlobalTime.uavcan new file mode 100644 index 0000000..09a20f3 --- /dev/null +++ b/dronecan/protocol/344.GlobalTime.uavcan @@ -0,0 +1,5 @@ +# +# provide global timestamp, time since 1/1/1970 in microseconds +# should only be broadcast once a reliable time base (GPS or equivalent) is known +# +uavcan.Timestamp timestamp From 84021200a0c522030ebe8a176ace52f9fee1aca9 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Thu, 1 May 2025 11:01:58 +1000 Subject: [PATCH 2/2] added BatteryTag message for battery tag peripherals permanently attached to batteries --- .../equipment/power/20500.BatteryTag.uavcan | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 ardupilot/equipment/power/20500.BatteryTag.uavcan diff --git a/ardupilot/equipment/power/20500.BatteryTag.uavcan b/ardupilot/equipment/power/20500.BatteryTag.uavcan new file mode 100644 index 0000000..8ddd89f --- /dev/null +++ b/ardupilot/equipment/power/20500.BatteryTag.uavcan @@ -0,0 +1,24 @@ +# +# Battery tag information. This is broadcast by a battery tag device +# permanently attached to a battery to record the lifecycle of the battery +# + +# vendor supplied serial number +uint32 serial_number + +# number of cycles this battery has been through. Criteria for +# defining a cycle is vendor specific +uint32 num_cycles + +# number of hours that this battery has been running when +# vehicle is in an armed state +float32 armed_hours + +# battery capacity in milliAmpHours +uint32 battery_capacity_mAh + +# time of first use of battery with vehicle armed, in minutes since 1/1/1970 +uint32 first_use_mins + +# time of most recent change to armed state, in minutes since 1/1/1970 +uint32 last_arm_time_mins