Skip to content

Commit 3bb94f5

Browse files
committed
fix RAMSTART, RAMSIZE, RAMEND for samd51 and same21
1 parent fa04386 commit 3bb94f5

File tree

1 file changed

+8
-2
lines changed
  • cores/arduino/avr

1 file changed

+8
-2
lines changed

cores/arduino/avr/io.h

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,14 @@
2525
#ifndef _IO_H_
2626
#define _IO_H_
2727

28-
#define RAMSTART (HMCRAMC0_ADDR)
29-
#define RAMSIZE (HMCRAMC0_SIZE)
28+
#ifdef HSRAM_ADDR
29+
#define RAMSTART (HSRAM_ADDR)
30+
#define RAMSIZE (HSRAM_SIZE)
31+
#else
32+
#define RAMSTART (HMCRAMC0_ADDR)
33+
#define RAMSIZE (HMCRAMC0_SIZE)
34+
#endif
35+
3036
#define RAMEND (RAMSTART + RAMSIZE - 1)
3137

3238
#endif

0 commit comments

Comments
 (0)