diff --git a/libraries/AP_OpenDroneID/AP_OpenDroneID.cpp b/libraries/AP_OpenDroneID/AP_OpenDroneID.cpp index f43289d248380..1d6d500e58cfa 100644 --- a/libraries/AP_OpenDroneID/AP_OpenDroneID.cpp +++ b/libraries/AP_OpenDroneID/AP_OpenDroneID.cpp @@ -27,10 +27,11 @@ * and DroneCAN */ -#include "AP_OpenDroneID.h" +#include "AP_OpenDroneID_config.h" #if AP_OPENDRONEID_ENABLED +#include "AP_OpenDroneID.h" #include #include #include diff --git a/libraries/AP_OpenDroneID/AP_OpenDroneID.h b/libraries/AP_OpenDroneID/AP_OpenDroneID.h index 735bf358c7688..ef74577698880 100644 --- a/libraries/AP_OpenDroneID/AP_OpenDroneID.h +++ b/libraries/AP_OpenDroneID/AP_OpenDroneID.h @@ -27,14 +27,8 @@ #pragma once -#include #include "AP_OpenDroneID_config.h" -#ifndef AP_OPENDRONEID_ENABLED -// default to off. Enabled in hwdef.dat -#define AP_OPENDRONEID_ENABLED 0 -#endif - #if AP_OPENDRONEID_ENABLED #include