aboutsummaryrefslogtreecommitdiff
path: root/example-fsm-55
diff options
context:
space:
mode:
authorNIIBE Yutaka <gniibe@fsij.org>2016-05-31 11:49:01 +0900
committerNIIBE Yutaka <gniibe@fsij.org>2016-05-31 11:49:01 +0900
commit3a4e1f2bd59a5185e638a2552c64344d78e0f54f (patch)
treea25424f8b4264ab8c8485b5c086102061e885e4d /example-fsm-55
parent421fd8019b31386c6e689753cf0a2ff35bd2af50 (diff)
Cleanup of sys and its macro
Diffstat (limited to 'example-fsm-55')
-rw-r--r--example-fsm-55/Makefile10
-rw-r--r--example-fsm-55/hacker-emblem.ld10
-rw-r--r--example-fsm-55/reset.c (renamed from example-fsm-55/sys.c)4
3 files changed, 12 insertions, 12 deletions
diff --git a/example-fsm-55/Makefile b/example-fsm-55/Makefile
index c1f04e9..f09fc20 100644
--- a/example-fsm-55/Makefile
+++ b/example-fsm-55/Makefile
@@ -5,16 +5,16 @@ PROJECT = hacker-emblem
CHOPSTX = ..
LDSCRIPT= hacker-emblem.ld
-CSRC = sys.c hh.c
+CSRC = reset.c hh.c
# Hacker Emblem and "Happy Hacking!" demonstration
-# CSRC = sys.c hh.c
+# CSRC = reset.c hh.c
# Debian logo demonstration
-# CSRC = sys.c debian-logo.c
+# CSRC = reset.c debian-logo.c
# "Hiroshi & Ayumi with Tulip" demonstration
-# CSRC = sys.c hiroshi-ayumi.c
+# CSRC = reset.c hiroshi-ayumi.c
###################################
CROSS = arm-none-eabi-
@@ -36,7 +36,7 @@ board.h:
@echo Please make a symbolic link \'board.h\' to a file in ../board;
@exit 1
-sys.c: board.h
+reset.c: board.h
distclean: clean
rm -f board.h
diff --git a/example-fsm-55/hacker-emblem.ld b/example-fsm-55/hacker-emblem.ld
index 407a981..852e458 100644
--- a/example-fsm-55/hacker-emblem.ld
+++ b/example-fsm-55/hacker-emblem.ld
@@ -1,11 +1,11 @@
/*
* ST32F0 memory setup.
*/
-__main_stack_size__ = 0x0100; /* Exception handlers */
-__process0_stack_size__ = 0x0100; /* Main program */
-__process1_stack_size__ = 0x0100; /* first thread program */
-__process2_stack_size__ = 0x0100; /* second thread program */
-__process3_stack_size__ = 0x0100; /* third thread program */
+__main_stack_size__ = 0x0100; /* Idle+Exception handlers */
+__process0_stack_size__ = 0x0100; /* Main program */
+__process1_stack_size__ = 0x0100; /* first thread program */
+__process2_stack_size__ = 0x0100; /* second thread program */
+__process3_stack_size__ = 0x0100; /* third thread program */
MEMORY
{
diff --git a/example-fsm-55/sys.c b/example-fsm-55/reset.c
index 2b7784f..6b7d842 100644
--- a/example-fsm-55/sys.c
+++ b/example-fsm-55/reset.c
@@ -1,5 +1,5 @@
/*
- * sys.c - No system routines, but only RESET handler for STM32F030.
+ * reset.c - No system routines, but only RESET handler for STM32F030.
*
* Copyright (C) 2015 Flying Stone Technology
* Author: NIIBE Yutaka <gniibe@fsij.org>
@@ -70,7 +70,7 @@ typedef void (*handler)(void);
extern uint8_t __main_stack_end__;
handler vector[] __attribute__ ((section(".vectors"))) = {
- (handler)&__main_stack_end__,
+ (handler)(&__main_stack_end__ - 32),
reset,
nmi, /* nmi */
hard_fault, /* hard fault */