Skip to content

Commit

Permalink
Copter: Change the range of the preprocessor
Browse files Browse the repository at this point in the history
  • Loading branch information
muramura committed Jun 2, 2024
1 parent eb8eeba commit debdc3d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions ArduCopter/Copter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -446,8 +446,6 @@ bool Copter::has_ekf_failsafed() const
return failsafe.ekf;
}

#endif // AP_SCRIPTING_ENABLED

// returns true if vehicle is landing. Only used by Lua scripts
bool Copter::is_landing() const
{
Expand All @@ -460,6 +458,8 @@ bool Copter::is_taking_off() const
return flightmode->is_taking_off();
}

#endif // AP_SCRIPTING_ENABLED

bool Copter::current_mode_requires_mission() const
{
#if MODE_AUTO_ENABLED == ENABLED
Expand Down
3 changes: 2 additions & 1 deletion ArduCopter/Copter.h
Original file line number Diff line number Diff line change
Expand Up @@ -686,9 +686,10 @@ class Copter : public AP_Vehicle {
// lua scripts use this to retrieve EKF failsafe state
// returns true if the EKF failsafe has triggered
bool has_ekf_failsafed() const override;
#endif // AP_SCRIPTING_ENABLED

bool is_landing() const override;
bool is_taking_off() const override;
#endif // AP_SCRIPTING_ENABLED
void rc_loop();
void throttle_loop();
void update_batt_compass(void);
Expand Down

0 comments on commit debdc3d

Please sign in to comment.