Skip to content

Commit

Permalink
Copter: don't update harmonic notch if it is not compiled in
Browse files Browse the repository at this point in the history
compilation failure as the object doesn't exist
  • Loading branch information
peterbarker committed Jan 4, 2025
1 parent 1f57f16 commit 0c4d27a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions ArduCopter/rate_thread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -407,10 +407,12 @@ void Copter::rate_controller_thread()
*/
void Copter::rate_controller_filter_update()
{
#if AP_INERTIALSENSOR_HARMONICNOTCH_ENABLED
// update the frontend center frequencies of notch filters
for (auto &notch : ins.harmonic_notches) {
update_dynamic_notch(notch);
}
#endif // AP_INERTIALSENSOR_HARMONICNOTCH_ENABLED

// this copies backend data to the frontend and updates the notches
ins.update_backend_filters();
Expand Down

0 comments on commit 0c4d27a

Please sign in to comment.