|
13 | 13 | along with this program. If not, see <http://www.gnu.org/licenses/>.
|
14 | 14 | */
|
15 | 15 |
|
| 16 | +#include "AP_RCTelemetry_config.h" |
| 17 | + |
| 18 | +#if HAL_CRSF_TELEM_ENABLED |
| 19 | + |
16 | 20 | #include "AP_CRSF_Telem.h"
|
17 | 21 | #include <AP_VideoTX/AP_VideoTX.h>
|
18 | 22 | #include <AP_HAL/utility/sparse-endian.h>
|
|
30 | 34 | #include <stdio.h>
|
31 | 35 | #include <AP_HAL/AP_HAL.h>
|
32 | 36 |
|
33 |
| -#if HAL_CRSF_TELEM_ENABLED |
| 37 | +#include <AP_VideoTX/AP_VideoTX.h> |
34 | 38 |
|
35 | 39 | #include <AP_Vehicle/AP_Vehicle_Type.h>
|
36 | 40 |
|
@@ -1270,7 +1274,7 @@ void AP_CRSF_Telem::calc_parameter() {
|
1270 | 1274 |
|
1271 | 1275 | _pending_request.frame_type = 0;
|
1272 | 1276 | _telem_pending = true;
|
1273 |
| -#endif |
| 1277 | +#endif // OSD_PARAM_ENABLED |
1274 | 1278 | }
|
1275 | 1279 |
|
1276 | 1280 | #if HAL_CRSF_TELEM_TEXT_SELECTION_ENABLED
|
@@ -1420,7 +1424,7 @@ void AP_CRSF_Telem::calc_text_selection(AP_OSD_ParamSetting* param, uint8_t chun
|
1420 | 1424 | _pending_request.frame_type = 0;
|
1421 | 1425 | _telem_pending = true;
|
1422 | 1426 | }
|
1423 |
| -#endif |
| 1427 | +#endif // HAL_CRSF_TELEM_TEXT_SELECTION_ENABLED |
1424 | 1428 |
|
1425 | 1429 | // write parameter information back into AP - assumes we already know the encoding for floats
|
1426 | 1430 | void AP_CRSF_Telem::process_param_write_frame(ParameterSettingsWriteFrame* write_frame)
|
@@ -1490,7 +1494,7 @@ void AP_CRSF_Telem::process_param_write_frame(ParameterSettingsWriteFrame* write
|
1490 | 1494 | default:
|
1491 | 1495 | break;
|
1492 | 1496 | }
|
1493 |
| -#endif |
| 1497 | +#endif // OSD_PARAM_ENABLED |
1494 | 1498 | }
|
1495 | 1499 |
|
1496 | 1500 | // get status text data
|
@@ -1649,4 +1653,4 @@ namespace AP {
|
1649 | 1653 | }
|
1650 | 1654 | };
|
1651 | 1655 |
|
1652 |
| -#endif |
| 1656 | +#endif // HAL_CRSF_TELEM_ENABLED |
0 commit comments