mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-02-21 23:33:57 -04:00
AP_HAL_AVR: conditionally build AVR specific helper code
This commit is contained in:
parent
54bab59066
commit
562b6a20c9
@ -1,3 +1,5 @@
|
||||
#include <AP_HAL.h>
|
||||
#if (CONFIG_HAL_BOARD == HAL_BOARD_APM1 || CONFIG_HAL_BOARD == HAL_BOARD_APM2)
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <avr/interrupt.h>
|
||||
@ -44,3 +46,4 @@ extern "C" ISR(TIMER5_CAPT_vect) {
|
||||
ISRRegistry::_registry[ISR_REGISTRY_TIMER5_CAPT]();
|
||||
}
|
||||
|
||||
#endif
|
||||
|
@ -28,6 +28,8 @@
|
||||
|
||||
/* $Id: ftoa_engine.S,v 1.3 2009/04/01 23:11:00 arcanum Exp $ */
|
||||
|
||||
#include <AP_HAL_Boards.h>
|
||||
#if CONFIG_HAL_BOARD == HAL_BOARD_APM1 || CONFIG_HAL_BOARD == HAL_BOARD_APM2
|
||||
#ifndef __DOXYGEN__
|
||||
|
||||
#include "macros.inc"
|
||||
@ -529,4 +531,5 @@ __ftoa_engine:
|
||||
.size .L_base10, . - .L_base10
|
||||
|
||||
.end
|
||||
#endif /* !__DOXYGEN__ */
|
||||
#endif /* !__DOXYGEN__ */
|
||||
#endif
|
||||
|
@ -29,6 +29,9 @@
|
||||
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
POSSIBILITY OF SUCH DAMAGE. */
|
||||
|
||||
#include <AP_HAL_Boards.h>
|
||||
#if CONFIG_HAL_BOARD == HAL_BOARD_APM1 || CONFIG_HAL_BOARD == HAL_BOARD_APM2
|
||||
|
||||
/*
|
||||
macros.inc - macros for use in assembler sources
|
||||
|
||||
@ -363,3 +366,4 @@
|
||||
#endif
|
||||
#endif
|
||||
.endm
|
||||
#endif
|
||||
|
@ -1,3 +1,5 @@
|
||||
#include <AP_HAL_Boards.h>
|
||||
#if CONFIG_HAL_BOARD == HAL_BOARD_APM1 || CONFIG_HAL_BOARD == HAL_BOARD_APM2
|
||||
|
||||
#include <avr/io.h>
|
||||
#include "pins_arduino_mega.h"
|
||||
@ -275,3 +277,4 @@ const uint8_t PROGMEM digital_pin_to_timer_PGM[] = {
|
||||
NOT_ON_TIMER , // PK 7 ** 69 ** A15
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@ -29,6 +29,8 @@
|
||||
/* $Id: ultoa_invert.S 1944 2009-04-01 23:12:20Z arcanum $ */
|
||||
|
||||
#ifndef __DOXYGEN__
|
||||
#include <AP_HAL_Boards.h>
|
||||
#if CONFIG_HAL_BOARD == HAL_BOARD_APM1 || CONFIG_HAL_BOARD == HAL_BOARD_APM2
|
||||
|
||||
#include "macros.inc"
|
||||
#include "ntz.h"
|
||||
@ -214,3 +216,5 @@ __ultoa_invert:
|
||||
.end
|
||||
|
||||
#endif /* !__DOXYGEN__ */
|
||||
#endif
|
||||
|
@ -38,7 +38,9 @@
|
||||
/* $Id: vfprintf.c,v 1.18.2.1 2009/04/01 23:12:06 arcanum Exp $ */
|
||||
|
||||
|
||||
#include <avr/pgmspace.h>
|
||||
#include <AP_HAL.h>
|
||||
#if CONFIG_HAL_BOARD == HAL_BOARD_APM1 || CONFIG_HAL_BOARD == HAL_BOARD_APM2
|
||||
#include <AP_Progmem.h>
|
||||
#include <stdarg.h>
|
||||
#include <string.h>
|
||||
|
||||
@ -519,3 +521,5 @@ void vprintf (AP_HAL::Print *s, unsigned char in_progmem, const char *fmt, va_li
|
||||
}
|
||||
} /* for (;;) */
|
||||
}
|
||||
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user