File tree Expand file tree Collapse file tree 7 files changed +135
-0
lines changed Expand file tree Collapse file tree 7 files changed +135
-0
lines changed Original file line number Diff line number Diff line change @@ -8,6 +8,7 @@ zephyr_sources_ifdef(CONFIG_SOC_SERIES_SAMD21 soc_samd2x.c)
88zephyr_sources_ifdef(CONFIG_SOC_SERIES_SAMR21 soc_samd2x.c)
99
1010zephyr_sources_ifdef(CONFIG_SOC_SERIES_SAMD51 soc_samd5x.c)
11+ zephyr_sources_ifdef(CONFIG_SOC_SERIES_SAME51 soc_samd5x.c)
1112zephyr_sources_ifdef(CONFIG_SOC_SERIES_SAME54 soc_samd5x.c)
1213
1314zephyr_include_directories(.)
Original file line number Diff line number Diff line change 1+ # Kconfig - Atmel SAME51 MCU series configuration options
2+ #
3+ # Copyright (c) 2019 ML!PA Consulting GmbH
4+ # SPDX-License-Identifier: Apache-2.0
5+
6+ if SOC_SERIES_SAME51
7+
8+ config SOC_SERIES
9+ string
10+ default "same51"
11+
12+ config SOC_PART_NUMBER
13+ string
14+ default "same51j18a" if SOC_PART_NUMBER_SAME51J18A
15+ default "same51j19a" if SOC_PART_NUMBER_SAME51J19A
16+ default "same51j20a" if SOC_PART_NUMBER_SAME51J20A
17+ default "same51n19a" if SOC_PART_NUMBER_SAME51N19A
18+ default "same51n20a" if SOC_PART_NUMBER_SAME51N20A
19+
20+ config NUM_IRQS
21+ int
22+ default 137
23+
24+ config SYS_CLOCK_HW_CYCLES_PER_SEC
25+ int
26+ default 120000000
27+
28+ endif # SOC_SERIES_SAME51
Original file line number Diff line number Diff line change 1+ # Kconfig - Atmel SAME51 MCU series
2+ #
3+ # Copyright (c) 2019 ML!PA Consulting GmbH
4+ # SPDX-License-Identifier: Apache-2.0
5+
6+ config SOC_SERIES_SAME51
7+ bool "Atmel SAME51 MCU"
8+ select CPU_CORTEX_M4
9+ select SOC_FAMILY_SAM0
10+ select CPU_CORTEX_M_HAS_SYSTICK
11+ select CPU_CORTEX_M_HAS_VTOR
12+ select ASF
13+ help
14+ Enable support for Atmel SAME51 Cortex-M4F microcontrollers.
Original file line number Diff line number Diff line change 1+ # Kconfig - Atmel SAME51 MCU series
2+ #
3+ # Copyright (c) 2019 ML!PA Consulting GmbH
4+ # SPDX-License-Identifier: Apache-2.0
5+
6+ choice
7+ prompt "Atmel SAME51 MCU Selection"
8+ depends on SOC_SERIES_SAME51
9+
10+ config SOC_PART_NUMBER_SAME51J18A
11+ bool "SAME51J18A"
12+
13+ config SOC_PART_NUMBER_SAME51J19A
14+ bool "SAME51J19A"
15+
16+ config SOC_PART_NUMBER_SAME51J20A
17+ bool "SAME51J20A"
18+
19+ config SOC_PART_NUMBER_SAME51N19A
20+ bool "SAME51N19A"
21+
22+ config SOC_PART_NUMBER_SAME51N20A
23+ bool "SAME51N20A"
24+
25+ endchoice
Original file line number Diff line number Diff line change 1+ /*
2+ * Copyright (c) 2019 ML!PA Consulting GmbH
3+ *
4+ * SPDX-License-Identifier: Apache-2.0
5+ */
6+
7+ /* SoC level DTS fixup file */
8+
9+ #define DT_FLASH_DEV_NAME DT_ATMEL_SAM0_NVMCTRL_0_LABEL
10+
11+ #define CONFIG_ENTROPY_NAME DT_ATMEL_SAM0_TRNG_0_LABEL
12+
13+ #define DT_NUM_IRQ_PRIO_BITS DT_ARM_V7M_NVIC_E000E100_ARM_NUM_IRQ_PRIORITY_BITS
14+
15+ /* End of SoC Level DTS fixup file */
Original file line number Diff line number Diff line change 1+ /* linker.ld - Linker command/script file */
2+
3+ /*
4+ * Copyright (c) 2017 Google LLC.
5+ * SPDX-License-Identifier: Apache-2.0
6+ */
7+
8+ #include < arch/arm/cortex_m/scripts/linker.ld>
Original file line number Diff line number Diff line change 1+ /*
2+ * Copyright (c) 2019 ML!PA Consulting GmbH
3+ *
4+ * SPDX-License-Identifier: Apache-2.0
5+ */
6+
7+ #ifndef _ATMEL_SAME51_SOC_H_
8+ #define _ATMEL_SAME51_SOC_H_
9+
10+ #ifndef _ASMLANGUAGE
11+
12+ #define DONT_USE_CMSIS_INIT
13+
14+ #include <zephyr/types.h>
15+
16+ #if defined(CONFIG_SOC_PART_NUMBER_SAME51J18A )
17+ #include <same51j18a.h>
18+ #elif defined(CONFIG_SOC_PART_NUMBER_SAME51J19A )
19+ #include <same51j19a.h>
20+ #elif defined(CONFIG_SOC_PART_NUMBER_SAME51J20A )
21+ #include <same51j20a.h>
22+ #elif defined(CONFIG_SOC_PART_NUMBER_SAME51N19A )
23+ #include <same51n19a.h>
24+ #elif defined(CONFIG_SOC_PART_NUMBER_SAME51N20A )
25+ #include <same51n20a.h>
26+ #else
27+ #error Library does not support the specified device.
28+ #endif
29+
30+ #endif /* _ASMLANGUAGE */
31+
32+ #include "sercom_fixup_samd5x.h"
33+ #include "tc_fixup_samd5x.h"
34+
35+ #define SOC_ATMEL_SAM0_OSC32K_FREQ_HZ 32768
36+
37+ /** Processor Clock (HCLK) Frequency */
38+ #define SOC_ATMEL_SAM0_HCLK_FREQ_HZ CONFIG_SYS_CLOCK_HW_CYCLES_PER_SEC
39+ /** Master Clock (MCK) Frequency */
40+ #define SOC_ATMEL_SAM0_MCK_FREQ_HZ SOC_ATMEL_SAM0_HCLK_FREQ_HZ
41+ #define SOC_ATMEL_SAM0_GCLK0_FREQ_HZ SOC_ATMEL_SAM0_MCK_FREQ_HZ
42+ #define SOC_ATMEL_SAM0_GCLK2_FREQ_HZ 48000000
43+
44+ #endif /* _ATMEL_SAME51_SOC_H_ */
You can’t perform that action at this time.
0 commit comments