aboutsummaryrefslogtreecommitdiffstats
path: root/demos/various
diff options
context:
space:
mode:
Diffstat (limited to 'demos/various')
-rw-r--r--demos/various/RT-ARM7-GENERIC/Makefile32
-rw-r--r--demos/various/RT-ARM7-GENERIC/ch.ld43
2 files changed, 23 insertions, 52 deletions
diff --git a/demos/various/RT-ARM7-GENERIC/Makefile b/demos/various/RT-ARM7-GENERIC/Makefile
index 4244d8c9f..88509cc81 100644
--- a/demos/various/RT-ARM7-GENERIC/Makefile
+++ b/demos/various/RT-ARM7-GENERIC/Makefile
@@ -35,7 +35,7 @@ endif
# If enabled, this option allows to compile the application in THUMB mode.
ifeq ($(USE_THUMB),)
- USE_THUMB = yes
+ USE_THUMB = no
endif
# Enable this if you want to see the full log while compiling.
@@ -105,16 +105,32 @@ PROJECT = ch
# Imported source files and paths
CHIBIOS = ../../..
+# Startup files.
+include $(CHIBIOS)/os/common/ports/ARM/compilers/GCC/mk/startup_lpc214x.mk
+# HAL-OSAL files (optional).
+#include $(CHIBIOS)/os/hal/hal.mk
+#include $(CHIBIOS)/os/hal/ports/LPC/LPC214x/platform.mk
+#include $(CHIBIOS)/os/hal/boards/OLIMEX_LPC_P2148/board.mk
+#include $(CHIBIOS)/os/hal/osal/rt/osal.mk
+# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/rt/ports/ARM/compilers/GCC/mk/port_generic.mk
+# Other files (optional).
+#include $(CHIBIOS)/test/rt/test.mk
# Define linker script file here
-LDSCRIPT= ch.ld
+LDSCRIPT= $(STARTUPLD)/LPC2148.ld
# C sources that can be compiled in ARM or THUMB mode depending on the global
# setting.
-CSRC = $(PORTSRC) \
+CSRC = $(STARTUPSRC) \
$(KERNSRC) \
+ $(PORTSRC) \
+ $(OSALSRC) \
+ $(HALSRC) \
+ $(PLATFORMSRC) \
+ $(BOARDSRC) \
+ $(TESTSRC) \
main.c
# C++ sources that can be compiled in ARM or THUMB mode depending on the global
@@ -142,13 +158,11 @@ TCSRC =
TCPPSRC =
# List ASM source files here
-ASMSRC = $(PORTASM)
+ASMSRC = $(STARTUPASM) $(PORTASM) $(OSALASM)
-# List of the standard inclusion directories.
-INCDIR = $(PORTINC) $(KERNINC)
-
-# Make this point to your armparams.h header.
-INCDIR += $(CHIBIOS)/os/common/ports/ARM/devices/LPC214x
+INCDIR = $(STARTUPINC) $(KERNINC) $(PORTINC) $(OSALINC) \
+ $(HALINC) $(PLATFORMINC) $(BOARDINC) $(TESTINC) \
+ $(CHIBIOS)/os/various
#
# Project, sources and paths
diff --git a/demos/various/RT-ARM7-GENERIC/ch.ld b/demos/various/RT-ARM7-GENERIC/ch.ld
deleted file mode 100644
index 8b2521c20..000000000
--- a/demos/various/RT-ARM7-GENERIC/ch.ld
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-*/
-
-/*
- * LPC2148 memory setup.
- */
-MEMORY
-{
- flash : org = 0x00000000, len = 512k - 12k
- ram0 : org = 0x40000200, len = 32k - 0x200 - 288
- ram1 : org = 0x00000000, len = 0
- ram2 : org = 0x00000000, len = 0
- ram3 : org = 0x00000000, len = 0
- ram4 : org = 0x00000000, len = 0
- ram5 : org = 0x00000000, len = 0
- ram6 : org = 0x00000000, len = 0
- ram7 : org = 0x00000000, len = 0
-}
-
-/* RAM region to be used for stacks. This stack accommodates the processing
- of all exceptions and interrupts*/
-REGION_ALIAS("STACKS_RAM", ram0);
-
-/* RAM region to be used for data segment.*/
-REGION_ALIAS("DATA_RAM", ram0);
-
-/* RAM region to be used for BSS segment.*/
-REGION_ALIAS("BSS_RAM", ram0);
-
-INCLUDE rules.ld