5
0
mirror of https://github.com/ArduPilot/ardupilot synced 2025-01-05 15:38:29 -04:00

AP_HAL: move from HAL_NO_GCS to HAL_GCS_ENABLED

This commit is contained in:
Peter Barker 2021-08-18 21:42:17 +10:00 committed by Peter Barker
parent 1bd62362a4
commit 1976b2b859
2 changed files with 10 additions and 3 deletions
libraries/AP_HAL

View File

@ -1,12 +1,15 @@
#include "GPIO.h"
#include <AP_HAL/AP_HAL.h>
#if defined(HAL_NO_GCS) || defined(HAL_BOOTLOADER_BUILD)
#define GCS_SEND_TEXT(severity, format, args...)
#else
#ifndef HAL_BOOTLOADER_BUILD
#include <GCS_MAVLink/GCS.h>
#endif
#ifndef GCS_SEND_TEXT
#define GCS_SEND_TEXT(severity, format, args...)
#endif
extern const AP_HAL::HAL& hal;
bool AP_HAL::PWMSource::set_pin(int16_t new_pin, const char *subsystem)

View File

@ -8,6 +8,8 @@
#include <GCS_MAVLink/GCS.h>
#include "packetise.h"
#if HAL_GCS_ENABLED
/*
return the number of bytes to send for a packetised connection
*/
@ -68,3 +70,5 @@ uint16_t mavlink_packetise(ByteBuffer &writebuf, uint16_t n)
return n;
}
#endif // HAL_BOOTLOADER_BUILD
#endif // HAL_GCS_ENABLED