Skip to content

Commit

Permalink
Make UE backend compile (Pablo's instructions)
Browse files Browse the repository at this point in the history
  • Loading branch information
franreal committed Dec 4, 2019
1 parent 31a3b26 commit 604c542
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
4 changes: 3 additions & 1 deletion ual_backend_ue/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,9 @@ add_library(${PROJECT_NAME}
if(ENABLE_UAL_UE)
target_compile_definitions(${PROJECT_NAME} PUBLIC UAL_UE_COMPATIBILITY)
target_include_directories(${PROJECT_NAME} PUBLIC "/usr/local/include/AirSim")
target_link_libraries(${PROJECT_NAME} LINK_PUBLIC c++)
target_include_directories(${PROJECT_NAME} PUBLIC "/usr/local/include/AirSim/deps/rpclib/include")
target_include_directories(${PROJECT_NAME} PUBLIC "/usr/local/include/AirSim/deps/MavLinkCom/include")
target_include_directories(${PROJECT_NAME} PUBLIC "/usr/local/include/AirSim/deps/eigen3")
target_link_libraries(${PROJECT_NAME} LINK_PUBLIC AirLib)
target_link_libraries(${PROJECT_NAME} LINK_PUBLIC MavLinkCom)
target_link_libraries(${PROJECT_NAME} LINK_PUBLIC rpc)
Expand Down
6 changes: 3 additions & 3 deletions ual_backend_ue/src/ual_backend_ue.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ BackendUE::BackendUE() : Backend()
airsim_client_.enableApiControl(true);
airsim_client_.armDisarm(true);

state_ = LANDED_ARMED;
state_ = uav_abstraction_layer::State::LANDED_ARMED;

}

Expand Down Expand Up @@ -151,13 +151,13 @@ void BackendUE::takeOff(double _height) {
/// 666 TODO: Check altitude
airsim_client_.takeoffAsync()->waitOnLastTask();

state_ = FLYING_AUTO;
state_ = uav_abstraction_layer::State::FLYING_AUTO;
}

void BackendUE::land() {
airsim_client_.landAsync()->waitOnLastTask();

state_ = LANDED_ARMED;
state_ = uav_abstraction_layer::State::LANDED_ARMED;
}

void BackendUE::setVelocity(const Velocity& _vel) {
Expand Down

0 comments on commit 604c542

Please sign in to comment.