Skip to content
Snippets Groups Projects
Commit 8cb8987b authored by Mark Charlebois's avatar Mark Charlebois Committed by Lorenz Meier
Browse files

Use DriverFramework as a PX4 module (#4415)


* Use DriverFramework as a PX4 module

Targets wanting to use DriverFramework must add

   lib/DriverFramework/framework

to their config file.

Signed-off-by: default avatarMark Charlebois <charlebm@gmail.com>

* Removed spurious code

No need to add if check before for loop

Signed-off-by: default avatarMark Charlebois <charlebm@gmail.com>

* Added DriverFramework to NuttX configs

Added lib/DriverFramework/firmware to nuttx configs

Signed-off-by: default avatarMark Charlebois <charlebm@gmail.com>

* Updated src/lib/DriverFramework

* Removed DF_TARGET and __DF_${OS} defines

These are now handled inside DriverFramework

Signed-off-by: default avatarMark Charlebois <charlebm@gmail.com>

* Updated DriverFramework

Signed-off-by: default avatarMark Charlebois <charlebm@gmail.com>

* Restored __DF_${OS}

The include files in DriverFramwork need to know the target OS.

Signed-off-by: default avatarMark Charlebois <charlebm@gmail.com>
parent 23a9af90
No related branches found
No related tags found
No related merge requests found
Showing
with 21 additions and 14 deletions
......@@ -150,16 +150,6 @@ list(GET config_args 1 BOARD)
list(GET config_args 2 LABEL)
set(target_name "${OS}-${BOARD}-${LABEL}")
if("${OS}" STREQUAL "posix")
if (APPLE)
set(DF_TARGET darwin)
else()
set(DF_TARGET linux)
endif()
else()
set(DF_TARGET ${OS})
endif()
message(STATUS "${target_name}")
# switch to ros CMake file if building ros
......@@ -333,12 +323,11 @@ execute_process(COMMAND cmake -E make_directory ${ep_base}/Install/include)
#=============================================================================
# DriverFramework Drivers
#
#message("ADDING DRIVERS")
set(df_driver_libs)
foreach(driver ${config_df_driver_list})
add_subdirectory(src/lib/DriverFramework/drivers/${driver})
list(APPEND df_driver_libs df_${driver})
message("adding driver: ${driver}")
message("Adding DF driver: ${driver}")
endforeach()
#=============================================================================
......@@ -361,8 +350,6 @@ endforeach()
add_subdirectory(src/firmware/${OS})
add_subdirectory(src/lib/DriverFramework/framework/src)
#add_dependencies(df_driver_framework nuttx_export_${CONFIG}.stamp)
if (NOT "${OS}" STREQUAL "nuttx")
endif()
......
......@@ -130,6 +130,7 @@ set(config_module_list
lib/terrain_estimation
lib/runway_takeoff
lib/tailsitter_recovery
lib/DriverFramework/framework
platforms/nuttx
# had to add for cmake, not sure why wasn't in original config
......
......@@ -43,6 +43,7 @@ set(config_module_list
lib/external_lgpl
lib/geo
lib/conversion
lib/DriverFramework/framework
platforms/nuttx
# had to add for cmake, not sure why wasn't in original config
......
......@@ -115,6 +115,7 @@ set(config_module_list
lib/terrain_estimation
lib/runway_takeoff
lib/tailsitter_recovery
lib/DriverFramework/framework
platforms/nuttx
# had to add for cmake, not sure why wasn't in original config
......
......@@ -124,6 +124,7 @@ set(config_module_list
lib/terrain_estimation
lib/runway_takeoff
lib/tailsitter_recovery
lib/DriverFramework/framework
platforms/nuttx
# had to add for cmake, not sure why wasn't in original config
......
......@@ -123,6 +123,7 @@ set(config_module_list
lib/terrain_estimation
lib/runway_takeoff
lib/tailsitter_recovery
lib/DriverFramework/framework
platforms/nuttx
# had to add for cmake, not sure why wasn't in original config
......
......@@ -125,6 +125,7 @@ set(config_module_list
lib/terrain_estimation
lib/runway_takeoff
lib/tailsitter_recovery
lib/DriverFramework/framework
platforms/nuttx
# had to add for cmake, not sure why wasn't in original config
......
......@@ -55,6 +55,7 @@ set(config_module_list
lib/terrain_estimation
lib/runway_takeoff
lib/tailsitter_recovery
lib/DriverFramework/framework
platforms/common
platforms/posix/px4_layer
......
......@@ -33,6 +33,7 @@ set(config_module_list
lib/geo
lib/geo_lookup
lib/conversion
lib/DriverFramework/framework
platforms/common
platforms/posix/px4_layer
......
......@@ -56,6 +56,7 @@ set(config_module_list
lib/terrain_estimation
lib/runway_takeoff
lib/tailsitter_recovery
lib/DriverFramework/framework
platforms/common
platforms/posix/px4_layer
......
......@@ -35,6 +35,7 @@ set(config_module_list
lib/geo
lib/geo_lookup
lib/conversion
lib/DriverFramework/framework
platforms/common
platforms/posix/px4_layer
......
......@@ -9,6 +9,8 @@ set(config_module_list
modules/uORB
lib/DriverFramework/framework
platforms/posix/px4_layer
platforms/posix/work_queue
......
......@@ -29,6 +29,7 @@ set(config_module_list
lib/geo
lib/geo_lookup
lib/conversion
lib/DriverFramework/framework
platforms/common
platforms/posix/px4_layer
......
......@@ -44,4 +44,5 @@ set(config_module_list
lib/terrain_estimation
lib/runway_takeoff
lib/tailsitter_recovery
lib/DriverFramework/framework
)
......@@ -53,4 +53,5 @@ set(config_module_list
lib/terrain_estimation
lib/runway_takeoff
lib/tailsitter_recovery
lib/DriverFramework/framework
)
......@@ -62,6 +62,7 @@ set(config_module_list
lib/terrain_estimation
lib/runway_takeoff
lib/tailsitter_recovery
lib/DriverFramework/framework
examples/px4_simple_app
)
......
......@@ -62,6 +62,7 @@ set(config_module_list
lib/terrain_estimation
lib/runway_takeoff
lib/tailsitter_recovery
lib/DriverFramework/framework
examples/px4_simple_app
)
......
......@@ -61,6 +61,7 @@ set(config_module_list
lib/terrain_estimation
lib/runway_takeoff
lib/tailsitter_recovery
lib/DriverFramework/framework
examples/px4_simple_app
)
......
......@@ -25,6 +25,7 @@ set(config_module_list
lib/external_lgpl
lib/geo
lib/geo_lookup
lib/DriverFramework/framework
)
set(config_extra_builtin_cmds
......
......@@ -74,6 +74,7 @@ set(config_module_list
lib/terrain_estimation
lib/runway_takeoff
lib/tailsitter_recovery
lib/DriverFramework/framework
#
# QuRT port
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment