aboutsummaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorPiotr Esden-Tempski2010-01-22 12:04:40 +0100
committerPiotr Esden-Tempski2010-01-22 12:47:35 +0100
commit3a4f36d80f2a8fd93727fc6d024b48f0a7511c9f (patch)
treeafe35b7bca1c5dff14c8a7dfa1af7436673c05c9 /examples
parentd167b6c9e96357d75f854184cf6a334104f32a7e (diff)
Moved all examples to a board specific folder.
Diffstat (limited to 'examples')
-rw-r--r--examples/Makefile28
-rw-r--r--examples/STM32-H103/Makefile51
-rw-r--r--examples/STM32-H103/fancyblink/Makefile (renamed from examples/fancyblink/Makefile)2
-rw-r--r--examples/STM32-H103/fancyblink/README (renamed from examples/fancyblink/README)0
-rw-r--r--examples/STM32-H103/fancyblink/fancyblink.c (renamed from examples/fancyblink/fancyblink.c)0
-rw-r--r--examples/STM32-H103/fancyblink/fancyblink.ld (renamed from examples/fancyblink/fancyblink.ld)0
-rw-r--r--examples/STM32-H103/miniblink/Makefile (renamed from examples/miniblink/Makefile)2
-rw-r--r--examples/STM32-H103/miniblink/README (renamed from examples/miniblink/README)0
-rw-r--r--examples/STM32-H103/miniblink/miniblink.c (renamed from examples/miniblink/miniblink.c)0
-rw-r--r--examples/STM32-H103/miniblink/miniblink.ld (renamed from examples/miniblink/miniblink.ld)0
-rw-r--r--examples/STM32-H103/usart/Makefile (renamed from examples/usart/Makefile)2
-rw-r--r--examples/STM32-H103/usart/README (renamed from examples/usart/README)0
-rw-r--r--examples/STM32-H103/usart/usart.c (renamed from examples/usart/usart.c)0
-rw-r--r--examples/STM32-H103/usart/usart.ld (renamed from examples/usart/usart.ld)0
14 files changed, 62 insertions, 23 deletions
diff --git a/examples/Makefile b/examples/Makefile
index d0f25f3..4defad2 100644
--- a/examples/Makefile
+++ b/examples/Makefile
@@ -1,7 +1,7 @@
##
## This file is part of the libopenstm32 project.
##
-## Copyright (C) 2009 Uwe Hermann <uwe@hermann-uwe.de>
+## Copyright (C) 2010 Piotr Esden-Tempski <piotr@esden.net>
##
## This program is free software: you can redistribute it and/or modify
## it under the terms of the GNU General Public License as published by
@@ -25,27 +25,15 @@ ifneq ($(V),1)
Q := @
endif
-all: miniblink fancyblink usart
+all: STM32-H103
-miniblink:
- @printf " BUILD miniblink\n"
- $(Q)$(MAKE) -C miniblink
-
-fancyblink:
- @printf " BUILD fancyblink\n"
- $(Q)$(MAKE) -C fancyblink
-
-usart:
- @printf " BUILD usart\n"
- $(Q)$(MAKE) -C usart
+STM32-H103:
+ @printf " BUILD STM32-H103 examples\n"
+ $(Q)$(MAKE) -C STM32-H103
clean:
- @printf " CLEAN miniblink\n"
- $(Q)$(MAKE) -C miniblink clean
- @printf " CLEAN fancyblink\n"
- $(Q)$(MAKE) -C fancyblink clean
- @printf " CLEAN usart\n"
- $(Q)$(MAKE) -C usart clean
+ @printf " CLEAN STM32-H103 examples\n"
+ $(Q)$(MAKE) -C STM32-H103 clean
-.PHONY: miniblink fancyblink usart clean
+.PHONY: STM32-H103 clean
diff --git a/examples/STM32-H103/Makefile b/examples/STM32-H103/Makefile
new file mode 100644
index 0000000..d0f25f3
--- /dev/null
+++ b/examples/STM32-H103/Makefile
@@ -0,0 +1,51 @@
+##
+## This file is part of the libopenstm32 project.
+##
+## Copyright (C) 2009 Uwe Hermann <uwe@hermann-uwe.de>
+##
+## This program is free software: you can redistribute it and/or modify
+## it under the terms of the GNU General Public License as published by
+## the Free Software Foundation, either version 3 of the License, or
+## (at your option) any later version.
+##
+## This program is distributed in the hope that it will be useful,
+## but WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+## GNU General Public License for more details.
+##
+## You should have received a copy of the GNU General Public License
+## along with this program. If not, see <http://www.gnu.org/licenses/>.
+##
+
+# Do not print "Entering directory ...".
+## MAKEFLAGS += --no-print-directory
+
+# Be silent per default, but 'make V=1' will show all compiler calls.
+ifneq ($(V),1)
+Q := @
+endif
+
+all: miniblink fancyblink usart
+
+miniblink:
+ @printf " BUILD miniblink\n"
+ $(Q)$(MAKE) -C miniblink
+
+fancyblink:
+ @printf " BUILD fancyblink\n"
+ $(Q)$(MAKE) -C fancyblink
+
+usart:
+ @printf " BUILD usart\n"
+ $(Q)$(MAKE) -C usart
+
+clean:
+ @printf " CLEAN miniblink\n"
+ $(Q)$(MAKE) -C miniblink clean
+ @printf " CLEAN fancyblink\n"
+ $(Q)$(MAKE) -C fancyblink clean
+ @printf " CLEAN usart\n"
+ $(Q)$(MAKE) -C usart clean
+
+.PHONY: miniblink fancyblink usart clean
+
diff --git a/examples/fancyblink/Makefile b/examples/STM32-H103/fancyblink/Makefile
index e2bc0db1..0d19fda 100644
--- a/examples/fancyblink/Makefile
+++ b/examples/STM32-H103/fancyblink/Makefile
@@ -27,7 +27,7 @@ OBJCOPY = $(PREFIX)-objcopy
OBJDUMP = $(PREFIX)-objdump
# Uncomment this line if you want to use the installed (not local) library.
# TOOLCHAIN_DIR = `dirname \`which $(CC)\``/../$(PREFIX)
-TOOLCHAIN_DIR = ../..
+TOOLCHAIN_DIR = ../../..
CFLAGS = -O0 -g -Wall -Wextra -I$(TOOLCHAIN_DIR)/include -fno-common \
-mcpu=cortex-m3 -mthumb
LDSCRIPT = $(BINARY).ld
diff --git a/examples/fancyblink/README b/examples/STM32-H103/fancyblink/README
index 706e07e..706e07e 100644
--- a/examples/fancyblink/README
+++ b/examples/STM32-H103/fancyblink/README
diff --git a/examples/fancyblink/fancyblink.c b/examples/STM32-H103/fancyblink/fancyblink.c
index 910255b..910255b 100644
--- a/examples/fancyblink/fancyblink.c
+++ b/examples/STM32-H103/fancyblink/fancyblink.c
diff --git a/examples/fancyblink/fancyblink.ld b/examples/STM32-H103/fancyblink/fancyblink.ld
index 0445bab..0445bab 100644
--- a/examples/fancyblink/fancyblink.ld
+++ b/examples/STM32-H103/fancyblink/fancyblink.ld
diff --git a/examples/miniblink/Makefile b/examples/STM32-H103/miniblink/Makefile
index 803b007..db85a8c 100644
--- a/examples/miniblink/Makefile
+++ b/examples/STM32-H103/miniblink/Makefile
@@ -27,7 +27,7 @@ OBJCOPY = $(PREFIX)-objcopy
OBJDUMP = $(PREFIX)-objdump
# Uncomment this line if you want to use the installed (not local) library.
# TOOLCHAIN_DIR = `dirname \`which $(CC)\``/../$(PREFIX)
-TOOLCHAIN_DIR = ../..
+TOOLCHAIN_DIR = ../../..
CFLAGS = -O0 -g -Wall -Wextra -I$(TOOLCHAIN_DIR)/include -fno-common \
-mcpu=cortex-m3 -mthumb
LDSCRIPT = $(BINARY).ld
diff --git a/examples/miniblink/README b/examples/STM32-H103/miniblink/README
index a0fc0ee..a0fc0ee 100644
--- a/examples/miniblink/README
+++ b/examples/STM32-H103/miniblink/README
diff --git a/examples/miniblink/miniblink.c b/examples/STM32-H103/miniblink/miniblink.c
index 7584acb..7584acb 100644
--- a/examples/miniblink/miniblink.c
+++ b/examples/STM32-H103/miniblink/miniblink.c
diff --git a/examples/miniblink/miniblink.ld b/examples/STM32-H103/miniblink/miniblink.ld
index 0445bab..0445bab 100644
--- a/examples/miniblink/miniblink.ld
+++ b/examples/STM32-H103/miniblink/miniblink.ld
diff --git a/examples/usart/Makefile b/examples/STM32-H103/usart/Makefile
index 8593399..432446d 100644
--- a/examples/usart/Makefile
+++ b/examples/STM32-H103/usart/Makefile
@@ -27,7 +27,7 @@ OBJCOPY = $(PREFIX)-objcopy
OBJDUMP = $(PREFIX)-objdump
# Uncomment this line if you want to use the installed (not local) library.
# TOOLCHAIN_DIR = `dirname \`which $(CC)\``/../$(PREFIX)
-TOOLCHAIN_DIR = ../..
+TOOLCHAIN_DIR = ../../..
CFLAGS = -O0 -g -Wall -Wextra -I$(TOOLCHAIN_DIR)/include -fno-common \
-mcpu=cortex-m3 -mthumb
LDSCRIPT = $(BINARY).ld
diff --git a/examples/usart/README b/examples/STM32-H103/usart/README
index 59d1d89..59d1d89 100644
--- a/examples/usart/README
+++ b/examples/STM32-H103/usart/README
diff --git a/examples/usart/usart.c b/examples/STM32-H103/usart/usart.c
index 922ec89..922ec89 100644
--- a/examples/usart/usart.c
+++ b/examples/STM32-H103/usart/usart.c
diff --git a/examples/usart/usart.ld b/examples/STM32-H103/usart/usart.ld
index 0445bab..0445bab 100644
--- a/examples/usart/usart.ld
+++ b/examples/STM32-H103/usart/usart.ld