2019-10-02 15:14:18 -03:00
|
|
|
cmake_minimum_required(VERSION 3.5.1)
|
|
|
|
|
2020-01-01 22:30:59 -04:00
|
|
|
project(mavsdk_tests CXX)
|
2019-10-02 15:14:18 -03:00
|
|
|
|
2020-01-01 22:30:59 -04:00
|
|
|
set(CMAKE_CXX_STANDARD 17)
|
|
|
|
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
|
|
|
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
|
2019-10-02 15:14:18 -03:00
|
|
|
|
2021-04-16 08:49:33 -03:00
|
|
|
file(READ MAVSDK_VERSION MAVSDK_VERSION)
|
|
|
|
string(STRIP ${MAVSDK_VERSION} MAVSDK_VERSION)
|
|
|
|
|
|
|
|
find_package(MAVSDK "${MAVSDK_VERSION}" REQUIRED)
|
2020-07-29 10:02:51 -03:00
|
|
|
find_package(Threads REQUIRED)
|
2019-10-24 06:32:03 -03:00
|
|
|
|
2020-01-01 22:30:59 -04:00
|
|
|
if(MAVSDK_FOUND)
|
|
|
|
add_executable(mavsdk_tests
|
|
|
|
test_main.cpp
|
|
|
|
autopilot_tester.cpp
|
2021-11-26 11:52:14 -04:00
|
|
|
autopilot_tester_failure.cpp
|
2023-01-18 04:34:56 -04:00
|
|
|
autopilot_tester_rtl.cpp
|
2023-10-20 08:37:54 -03:00
|
|
|
autopilot_tester_figure_eight.cpp
|
FollowMe : Replace First order target position filter with Second order position and velocity filter
Follow me : tidied second order filter implementation
Added velocity filtered info to uORB follow target status message, and rebase to potaito/new-follow-me-task
FollowMe : Rebasing and missing definition fixes on target position second order filter
Follow Me : Remove Alpha filter delay compensation code, since second order filter is used for pose filtering now
Followme : Remove unused target pose estimation update function
Follow Target : Added Target orientation estimation logic
Follow Target : Replaced offset vector based setpoint to rate controlled orbital angle control
Follow Target : Bug fixes and first working version of rate based control logic, still buggy
Follow Target : Added target orientation, follow angle, orbit angle value into follow_target_status uORB message for debugging
Follow Target : Fix orbit angle step calculation typo bug
Follow Target : Few more fixes
Follow Target : Few fixes and follow angle value logging bug fix
Follow Target : Added lowpass alpha filter for yaw setpoint filtering
Follow Target : Remove unused filter delay compensation param
Follow Target : Add Yaw setpoint filter initialization logic and bufix for when unwrap had an input of NAN angle value
Follow Target : Add Yaw setpoint filtering enabler parameter
Follow Target : Change Target Velocity Deadzone to 1.0 m/s, to accomodate walking speed of 1.5 m/s
Follow Target : Add Orbit Tangential Velocity calculation for velocity setpoint and logging uORB topics
Follow target : Fix indentation in yaw setpoint filtering logic
Follow Target : Fix Follow Target Estimator timeout logic bug that was making the 2nd order pose filter reset to raw value every loop
Follow Target : Remove debug printf statement for target pose filter reset check
Follow Target : Add pose filter natural frequency parameter for filter testing
Follow Target : Make target following side param selectable and add target pose filter natural frequency param description
Follow Target : Add Terrain following altitude mode and make 2D altitude mode keep altitude relative to the home position, instead of raw local position origin
Follow Target : Log follow target estimator & status at full rate for filter characteristics test
Follow Target : Implementing RC control user input for Follow Target control
Follow Target : edit to conform to updated unwrap_pi function
Follow Target : Make follow angle, distance and height RC command input configurable
Follow Target : Make Follow Target not interruptable by moving joystick in Commander
Follow Target : reconfigure yaw, pitch and roll for better user experience in RC adjusting configurations, and add angular rate limit taking target distance into account
Follow Target : Change RC channels used for adjustments and re-order header file for clarity
Follow Target : Fix Parameters custom parent macro, since using DEFINE_PARAMETERS alone misses the parameter updates of the parent class, FlightTask
Follow Target : Fix Orbit Tangential speed actually being angular rate bug, which was causing a phenomenon of drnoe getting 'dragged' towards the target velocity direction
Follow Target : Final tidying and refactoring for master merge - step 1
Add more comments on header file
Follow Target : tidy, remove unnecessary debug uORB elements from follow_target_status message
Follow Target : Turn off Yaw filtering by default
Follow Target : Tidy maximum orbital velocity calculation
Follow Target : add yaw setpoint filter time constant parameter for testing and fix NAV_FT_HT title
Follow Target : Add RC adjustment window logic to prevent drone not catching up the change of follow target parameters
Follow Target : fixes
Follow Target: PR tidy few edits remove, and update comments
Follow Target : apply comments and reviews
Follow Target : Edit according to review comments part 2
Follow Target : Split RC adjustment code and other refactors
- Splitted the RC adjustment into follow angle, height and distance
- Added Parameter change detection to reset the follow properties
- Added comments and removed yaw setpoint filter enabler logic
Follow Target : Modify orbit angle error bufferzone bug that was causing excessive velocity setpoints when setpoint catched up with raw orbit setpoint
Follow Target : Remove buffer zone velocity ramp down logic and add acceleration and rate limited Trajectory generation library for orbit angle and velocity setpoint
Follow Target : Remove internally tracked data from local scope function's parameters to simplify code
Follow Target : Fix to track unwrapped orbit angle, with no wrapping
Follow Target : Apply user adjustment deadzone to reduce sensitivity
Follow Target : Apply suggestions from PR review round 2 by @potaito
Revert submodule update changes, fall back to potaito/new-followme-task
Follow Target : [Debug] Expose max vel and acceleration settings as parameters, instead of using Multicopter Position Controller
's settings
Follow Target : Use matrix::isEqualF() function to compare floats
Follow Target : Add Acceleration feedback enabler parameter and Velocity ramp in initial commit for overshoot phenomenon improvement
Follow Target : Implement Velocity feed forward limit and debug logging values
Follow Target : Apply Velocity Ramp-in for Acceleration as well & Apply it to total velocity setpoint and not just orbit tangential velocity component
Follow Target : Don't set Acceleration setpoint if not commanded
Follow Target : Use Jerk limited orbit angle control. Add orbit angle tracking related uORB values"
Follow Target : Add Orbit Angle Setpoint Rate Tracking filter, to take into consideration for calculating velocity setpoint for trajectory generator for orbit angle
Revert "Follow Target : Add Orbit Angle Setpoint Rate Tracking filter, to take into consideration for calculating velocity setpoint for trajectory generator for orbit angle"
This reverts commit a3f48ac7652adb70baf3a2fed3ea34d77cbd6a70.
Follow Target : Take Unfiltered target velocity into acount for target course calculation to fix overshoot orbit angle 180 deg flip problem
Follow Target : Remove Yaw Filter since it doesn't make a big difference in yaw jitterness
Follow Target : Remove velocity ramp in control & remove debug values from follow_target_status.msg
Follow Target : Tidy Follow Target Status message logging code
Follow Target : Remove jerk and acceleration settings from Follow Target orbit trajectory generation
Follow Target : Change PublicationMulti into Publication, since topics published are single instances
Follow Target : Edit comments to reflect changes in the final revision of Follow Target
Follow Target : Apply incorrectly merged conflicts during rebase & update Sticks function usage for getThrottled()
Follow Target : Apply final review comments before merge into Alessandro's PR
Apply further changes from the PR review, like units
Use RC Sticks' Expo() function for user adjustments to decrease sensitivity around the center (0 value)
Update Function styles to lowerCamelCase
And make functions const & return the params, rather than modifying them
internally via pointer / reference
Specify kFollowPerspective enum as uint8_t, so that it can't be set to negative value when converted from the parameter 'FLW_TGT_FP'
Fix bug in updateParams() to reset internally tracked params if they actually changed.
Remove unnecessary comments
Fix format of the Follow Target code
Fix Follow Perspective Param metadata
follow-me: use new trajectory_setpoint msg
Convert FollowPerspective enum into a Follow Angle float value
1. Increases flexibility in user's side, to set any arbitrary follow
angle [deg]
2. Removes the need to have a dedicated Enum, which can be a hassle to
make it match MAVSDK's side
3. A step in the direction of adding a proper Follow Mode (Perspective)
mode support, where we can support kite mode (drone behaves as if it is
hovering & getting dragged by the target with a leash) or a constant
orbit angle mode (Drone always on the East / North / etc. side, for
cinematic shots)
Continue fixing Follow Target MAVSDK code to match MAVSDK changes
- Support Follow Angle configuration instead of Follow Direction
- Change follow position tolerance logic to use the follow angle
*Still work in progress!
Update Follow Me MAVSDK Test Code to match MAVSDK v2 spec
- Add RC Adjustment Test case
- Change follow direction logic to follow angle based logic completely
- Cleanup on variable names and comment on code
follow-me: disable SITL test
Need to update MAVSDK with the following PR:
https://github.com/mavlink/MAVSDK/pull/1770
SITL is failing now because the follow-me
perspectives are no longer defined the
same way in MAVSDK and in the flight task.
update copyright year
follow-me: mark uORB topics optional
Apply review comments
more copyright years
follow-me sitl test: simpler "state machine"
flight_mode_manager: exclude AutoFollowTarget and Orbit on flash contrained boards
Remove unnecessary follow_target_status message properties
- As it eats up FLASH and consumes uLog bandwidth
2022-02-25 10:58:35 -04:00
|
|
|
# follow-me needs a MAVSDK update:
|
|
|
|
# https://github.com/mavlink/MAVSDK/pull/1770
|
|
|
|
# autopilot_tester_follow_me.cpp
|
2021-11-26 11:52:14 -04:00
|
|
|
test_multicopter_control_allocation.cpp
|
|
|
|
test_multicopter_failure_injection.cpp
|
2020-06-11 09:18:09 -03:00
|
|
|
test_multicopter_failsafe.cpp
|
2020-07-31 04:45:12 -03:00
|
|
|
test_multicopter_mission.cpp
|
|
|
|
test_multicopter_offboard.cpp
|
|
|
|
test_multicopter_manual.cpp
|
2020-03-17 12:20:06 -03:00
|
|
|
test_vtol_mission.cpp
|
2023-10-20 08:37:54 -03:00
|
|
|
test_vtol_figure_eight.cpp
|
2023-10-23 04:34:26 -03:00
|
|
|
test_vtol_rtl.cpp
|
2023-07-19 06:29:28 -03:00
|
|
|
test_vtol_mission_wind.cpp
|
|
|
|
test_vtol_loiter_airspeed_failure_blockage.cpp
|
FollowMe : Replace First order target position filter with Second order position and velocity filter
Follow me : tidied second order filter implementation
Added velocity filtered info to uORB follow target status message, and rebase to potaito/new-follow-me-task
FollowMe : Rebasing and missing definition fixes on target position second order filter
Follow Me : Remove Alpha filter delay compensation code, since second order filter is used for pose filtering now
Followme : Remove unused target pose estimation update function
Follow Target : Added Target orientation estimation logic
Follow Target : Replaced offset vector based setpoint to rate controlled orbital angle control
Follow Target : Bug fixes and first working version of rate based control logic, still buggy
Follow Target : Added target orientation, follow angle, orbit angle value into follow_target_status uORB message for debugging
Follow Target : Fix orbit angle step calculation typo bug
Follow Target : Few more fixes
Follow Target : Few fixes and follow angle value logging bug fix
Follow Target : Added lowpass alpha filter for yaw setpoint filtering
Follow Target : Remove unused filter delay compensation param
Follow Target : Add Yaw setpoint filter initialization logic and bufix for when unwrap had an input of NAN angle value
Follow Target : Add Yaw setpoint filtering enabler parameter
Follow Target : Change Target Velocity Deadzone to 1.0 m/s, to accomodate walking speed of 1.5 m/s
Follow Target : Add Orbit Tangential Velocity calculation for velocity setpoint and logging uORB topics
Follow target : Fix indentation in yaw setpoint filtering logic
Follow Target : Fix Follow Target Estimator timeout logic bug that was making the 2nd order pose filter reset to raw value every loop
Follow Target : Remove debug printf statement for target pose filter reset check
Follow Target : Add pose filter natural frequency parameter for filter testing
Follow Target : Make target following side param selectable and add target pose filter natural frequency param description
Follow Target : Add Terrain following altitude mode and make 2D altitude mode keep altitude relative to the home position, instead of raw local position origin
Follow Target : Log follow target estimator & status at full rate for filter characteristics test
Follow Target : Implementing RC control user input for Follow Target control
Follow Target : edit to conform to updated unwrap_pi function
Follow Target : Make follow angle, distance and height RC command input configurable
Follow Target : Make Follow Target not interruptable by moving joystick in Commander
Follow Target : reconfigure yaw, pitch and roll for better user experience in RC adjusting configurations, and add angular rate limit taking target distance into account
Follow Target : Change RC channels used for adjustments and re-order header file for clarity
Follow Target : Fix Parameters custom parent macro, since using DEFINE_PARAMETERS alone misses the parameter updates of the parent class, FlightTask
Follow Target : Fix Orbit Tangential speed actually being angular rate bug, which was causing a phenomenon of drnoe getting 'dragged' towards the target velocity direction
Follow Target : Final tidying and refactoring for master merge - step 1
Add more comments on header file
Follow Target : tidy, remove unnecessary debug uORB elements from follow_target_status message
Follow Target : Turn off Yaw filtering by default
Follow Target : Tidy maximum orbital velocity calculation
Follow Target : add yaw setpoint filter time constant parameter for testing and fix NAV_FT_HT title
Follow Target : Add RC adjustment window logic to prevent drone not catching up the change of follow target parameters
Follow Target : fixes
Follow Target: PR tidy few edits remove, and update comments
Follow Target : apply comments and reviews
Follow Target : Edit according to review comments part 2
Follow Target : Split RC adjustment code and other refactors
- Splitted the RC adjustment into follow angle, height and distance
- Added Parameter change detection to reset the follow properties
- Added comments and removed yaw setpoint filter enabler logic
Follow Target : Modify orbit angle error bufferzone bug that was causing excessive velocity setpoints when setpoint catched up with raw orbit setpoint
Follow Target : Remove buffer zone velocity ramp down logic and add acceleration and rate limited Trajectory generation library for orbit angle and velocity setpoint
Follow Target : Remove internally tracked data from local scope function's parameters to simplify code
Follow Target : Fix to track unwrapped orbit angle, with no wrapping
Follow Target : Apply user adjustment deadzone to reduce sensitivity
Follow Target : Apply suggestions from PR review round 2 by @potaito
Revert submodule update changes, fall back to potaito/new-followme-task
Follow Target : [Debug] Expose max vel and acceleration settings as parameters, instead of using Multicopter Position Controller
's settings
Follow Target : Use matrix::isEqualF() function to compare floats
Follow Target : Add Acceleration feedback enabler parameter and Velocity ramp in initial commit for overshoot phenomenon improvement
Follow Target : Implement Velocity feed forward limit and debug logging values
Follow Target : Apply Velocity Ramp-in for Acceleration as well & Apply it to total velocity setpoint and not just orbit tangential velocity component
Follow Target : Don't set Acceleration setpoint if not commanded
Follow Target : Use Jerk limited orbit angle control. Add orbit angle tracking related uORB values"
Follow Target : Add Orbit Angle Setpoint Rate Tracking filter, to take into consideration for calculating velocity setpoint for trajectory generator for orbit angle
Revert "Follow Target : Add Orbit Angle Setpoint Rate Tracking filter, to take into consideration for calculating velocity setpoint for trajectory generator for orbit angle"
This reverts commit a3f48ac7652adb70baf3a2fed3ea34d77cbd6a70.
Follow Target : Take Unfiltered target velocity into acount for target course calculation to fix overshoot orbit angle 180 deg flip problem
Follow Target : Remove Yaw Filter since it doesn't make a big difference in yaw jitterness
Follow Target : Remove velocity ramp in control & remove debug values from follow_target_status.msg
Follow Target : Tidy Follow Target Status message logging code
Follow Target : Remove jerk and acceleration settings from Follow Target orbit trajectory generation
Follow Target : Change PublicationMulti into Publication, since topics published are single instances
Follow Target : Edit comments to reflect changes in the final revision of Follow Target
Follow Target : Apply incorrectly merged conflicts during rebase & update Sticks function usage for getThrottled()
Follow Target : Apply final review comments before merge into Alessandro's PR
Apply further changes from the PR review, like units
Use RC Sticks' Expo() function for user adjustments to decrease sensitivity around the center (0 value)
Update Function styles to lowerCamelCase
And make functions const & return the params, rather than modifying them
internally via pointer / reference
Specify kFollowPerspective enum as uint8_t, so that it can't be set to negative value when converted from the parameter 'FLW_TGT_FP'
Fix bug in updateParams() to reset internally tracked params if they actually changed.
Remove unnecessary comments
Fix format of the Follow Target code
Fix Follow Perspective Param metadata
follow-me: use new trajectory_setpoint msg
Convert FollowPerspective enum into a Follow Angle float value
1. Increases flexibility in user's side, to set any arbitrary follow
angle [deg]
2. Removes the need to have a dedicated Enum, which can be a hassle to
make it match MAVSDK's side
3. A step in the direction of adding a proper Follow Mode (Perspective)
mode support, where we can support kite mode (drone behaves as if it is
hovering & getting dragged by the target with a leash) or a constant
orbit angle mode (Drone always on the East / North / etc. side, for
cinematic shots)
Continue fixing Follow Target MAVSDK code to match MAVSDK changes
- Support Follow Angle configuration instead of Follow Direction
- Change follow position tolerance logic to use the follow angle
*Still work in progress!
Update Follow Me MAVSDK Test Code to match MAVSDK v2 spec
- Add RC Adjustment Test case
- Change follow direction logic to follow angle based logic completely
- Cleanup on variable names and comment on code
follow-me: disable SITL test
Need to update MAVSDK with the following PR:
https://github.com/mavlink/MAVSDK/pull/1770
SITL is failing now because the follow-me
perspectives are no longer defined the
same way in MAVSDK and in the flight task.
update copyright year
follow-me: mark uORB topics optional
Apply review comments
more copyright years
follow-me sitl test: simpler "state machine"
flight_mode_manager: exclude AutoFollowTarget and Orbit on flash contrained boards
Remove unnecessary follow_target_status message properties
- As it eats up FLASH and consumes uLog bandwidth
2022-02-25 10:58:35 -04:00
|
|
|
# test_multicopter_follow_me.cpp
|
2020-01-01 22:30:59 -04:00
|
|
|
)
|
|
|
|
|
|
|
|
target_link_libraries(mavsdk_tests
|
|
|
|
MAVSDK::mavsdk
|
2020-07-29 10:02:51 -03:00
|
|
|
${CMAKE_THREAD_LIBS_INIT}
|
2020-01-01 22:30:59 -04:00
|
|
|
)
|
|
|
|
|
2023-10-20 08:36:14 -03:00
|
|
|
target_include_directories(mavsdk_tests PUBLIC ${CMAKE_BINARY_DIR}/..)
|
|
|
|
|
2020-01-01 22:30:59 -04:00
|
|
|
target_compile_options(mavsdk_tests
|
2020-10-28 21:26:47 -03:00
|
|
|
PRIVATE
|
|
|
|
-Wall
|
|
|
|
-Wextra
|
|
|
|
-Werror
|
|
|
|
-Wno-error=deprecated-declarations
|
2020-01-01 22:30:59 -04:00
|
|
|
)
|
|
|
|
else()
|
|
|
|
message("MAVSDK C++ not found, skipping mavsdk_tests build..")
|
2019-12-24 05:58:21 -04:00
|
|
|
endif()
|