From 43f5a713dbe874b871f5e9db33a0b08d03ccf453 Mon Sep 17 00:00:00 2001 From: Julian Oes Date: Tue, 15 Apr 2025 16:10:11 +1200 Subject: [PATCH 1/2] stm32_common: add timer 12 (#24680) --- platforms/nuttx/src/px4/stm/stm32_common/hrt/hrt.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/platforms/nuttx/src/px4/stm/stm32_common/hrt/hrt.c b/platforms/nuttx/src/px4/stm/stm32_common/hrt/hrt.c index ea903eaf4d..86d806b4f6 100644 --- a/platforms/nuttx/src/px4/stm/stm32_common/hrt/hrt.c +++ b/platforms/nuttx/src/px4/stm/stm32_common/hrt/hrt.c @@ -156,8 +156,17 @@ # if CONFIG_STM32_TIM11 # error must not set CONFIG_STM32_TIM11=y and HRT_TIMER=11 # endif +#elif HRT_TIMER == 12 +# define HRT_TIMER_BASE STM32_TIM12_BASE +# define HRT_TIMER_POWER_REG STM32_RCC_APB1ENR +# define HRT_TIMER_POWER_BIT RCC_APB1LENR_TIM12EN +# define HRT_TIMER_VECTOR STM32_IRQ_TIM12 +# define HRT_TIMER_CLOCK STM32_APB1_TIM12_CLKIN +# if CONFIG_STM32_TIM12 +# error must not set CONFIG_STM32_TIM12=y and HRT_TIMER=12 +# endif #else -# error HRT_TIMER must be a value between 1 and 11 +# error HRT_TIMER must be a value between 1 and 12 #endif /* From 9027dc146eb77045474b745b5c0e8101be350eb0 Mon Sep 17 00:00:00 2001 From: Pedro Roque Date: Tue, 15 Apr 2025 10:24:03 +0200 Subject: [PATCH 2/2] feat: add 6 DoF trajectory setpoints message * feat: add attitude to trajectory setpoints * feat: proposed new trajectory message for fully actuated vehicles * fix: moved to unversioned and changed naming scheme * feat: added space between translation and attitude control * fix: change cmakelists --- msg/CMakeLists.txt | 1 + msg/TrajectorySetpoint6dof.msg | 13 +++++++++++++ 2 files changed, 14 insertions(+) create mode 100644 msg/TrajectorySetpoint6dof.msg diff --git a/msg/CMakeLists.txt b/msg/CMakeLists.txt index e48e01ecfa..56e5523fbb 100644 --- a/msg/CMakeLists.txt +++ b/msg/CMakeLists.txt @@ -210,6 +210,7 @@ set(msg_files TelemetryStatus.msg TiltrotorExtraControls.msg TimesyncStatus.msg + TrajectorySetpoint6dof.msg TransponderReport.msg TuneControl.msg UavcanParameterRequest.msg diff --git a/msg/TrajectorySetpoint6dof.msg b/msg/TrajectorySetpoint6dof.msg new file mode 100644 index 0000000000..4374d1685e --- /dev/null +++ b/msg/TrajectorySetpoint6dof.msg @@ -0,0 +1,13 @@ +# Trajectory setpoint in NED frame +# Input to position controller. + +uint64 timestamp # time since system start (microseconds) + +# NED local world frame +float32[3] position # in meters +float32[3] velocity # in meters/second +float32[3] acceleration # in meters/second^2 +float32[3] jerk # in meters/second^3 (for logging only) + +float32[4] quaternion # unit quaternion +float32[3] angular_velocity # angular velocity in radians/second