diff options
author | Keith Packard <keithp@keithp.com> | 2011-10-11 18:45:51 -0600 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2011-10-11 18:57:32 -0600 |
commit | b80f8ffb61566cbd134c399ea6ccf9290075490b (patch) | |
tree | a10eee548278b66fd1901a6ba8d25a9069872313 | |
parent | f1573a752425121d4c6a14285f1eb0fef3a8bea5 (diff) |
altos/avr: Must leave space for init stack in ram
The stack used during system initialization lives at the top of RAM,
so leave some space for that.
Signed-off-by: Keith Packard <keithp@keithp.com>
-rw-r--r-- | src/util/check-avr-mem | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/util/check-avr-mem b/src/util/check-avr-mem index c73edbd1..7956f0aa 100644 --- a/src/util/check-avr-mem +++ b/src/util/check-avr-mem @@ -2,8 +2,10 @@ nm "$@" | grep ' N _end' | awk '{ iram = strtonum("0x" $1) % 0x10000; -if ( iram > 0xaff) { - printf ("%d bytes of ram more than %d available\n", iram, 0xaff); +if ( iram > 0xacf) { + printf ("%d bytes of ram more than %d available\n", iram, 0xacf); exit(1); -} else - exit(0); }' +} else { + printf("%d bytes of ram\n", iram); + exit(0); +} }' |