diff options
author | Daniel Friesel <derf@finalrewind.org> | 2019-03-13 14:59:16 +0100 |
---|---|---|
committer | Daniel Friesel <derf@finalrewind.org> | 2019-03-13 14:59:16 +0100 |
commit | 6326b0b4df2e158b839f607f506be6ce2972f1b5 (patch) | |
tree | ddd7a5501780526dd8560027dc027f5d27e888a9 /src | |
parent | b0f6217a794d3a7c1eb8cde6f20cd001f3318de9 (diff) |
msp430fr aspectc++ support
Diffstat (limited to 'src')
-rw-r--r-- | src/app/prototest/Makefile.inc | 4 | ||||
-rw-r--r-- | src/arch/msp430fr5969lp/arch.cc | 6 | ||||
-rw-r--r-- | src/arch/msp430fr5994lp/arch.cc | 6 |
3 files changed, 16 insertions, 0 deletions
diff --git a/src/app/prototest/Makefile.inc b/src/app/prototest/Makefile.inc index 957591a..a33fd48 100644 --- a/src/app/prototest/Makefile.inc +++ b/src/app/prototest/Makefile.inc @@ -1,3 +1,7 @@ +ifeq (${aspectc}, 1) + CXX_FLAGS += --Xweaver -asrc/app/prototest/prototest.ah --Xcompiler +endif + ifeq (${prototest_bench_energy}, 1) loop ?= 1 COMMON_FLAGS += -DPROTOTEST_BENCH_ENERGY diff --git a/src/arch/msp430fr5969lp/arch.cc b/src/arch/msp430fr5969lp/arch.cc index 1eb34b5..3f0eb3c 100644 --- a/src/arch/msp430fr5969lp/arch.cc +++ b/src/arch/msp430fr5969lp/arch.cc @@ -1,6 +1,10 @@ #include "arch.h" #include <msp430.h> +#ifdef __acweaving +#define __delay_cycles(x) +#endif + void Arch::setup(void) { WDTCTL = WDTPW | WDTHOLD; @@ -157,6 +161,7 @@ Arch arch; #include "driver/uptime.h" +#ifndef __acweaving __attribute__((interrupt(TIMER1_A1_VECTOR))) __attribute__((wakeup)) void handle_timer1_overflow() { if (TA1IV == 0x0e) { @@ -168,5 +173,6 @@ __attribute__((interrupt(TIMER1_A1_VECTOR))) __attribute__((wakeup)) void handle #endif } } +#endif #endif /* defined(WITH_LOOP) || defined(TIMER_S) */ diff --git a/src/arch/msp430fr5994lp/arch.cc b/src/arch/msp430fr5994lp/arch.cc index 1eb34b5..3f0eb3c 100644 --- a/src/arch/msp430fr5994lp/arch.cc +++ b/src/arch/msp430fr5994lp/arch.cc @@ -1,6 +1,10 @@ #include "arch.h" #include <msp430.h> +#ifdef __acweaving +#define __delay_cycles(x) +#endif + void Arch::setup(void) { WDTCTL = WDTPW | WDTHOLD; @@ -157,6 +161,7 @@ Arch arch; #include "driver/uptime.h" +#ifndef __acweaving __attribute__((interrupt(TIMER1_A1_VECTOR))) __attribute__((wakeup)) void handle_timer1_overflow() { if (TA1IV == 0x0e) { @@ -168,5 +173,6 @@ __attribute__((interrupt(TIMER1_A1_VECTOR))) __attribute__((wakeup)) void handle #endif } } +#endif #endif /* defined(WITH_LOOP) || defined(TIMER_S) */ |