diff options
author | Daniel Friesel <derf@finalrewind.org> | 2020-12-09 18:02:30 +0100 |
---|---|---|
committer | Daniel Friesel <derf@finalrewind.org> | 2020-12-09 18:02:30 +0100 |
commit | 0eee4b0b160f15c27da9291e92477df04c02e8c0 (patch) | |
tree | 2e9df48d4309ea29eb14630d67f5918fac621a6c /src/arch | |
parent | 8f1b5c41f85b3f610edcd1f61a4302c56aef2dbc (diff) |
arduino nano: add cpu frequency to kconfig
Diffstat (limited to 'src/arch')
-rw-r--r-- | src/arch/arduino-nano/Kconfig | 9 | ||||
-rw-r--r-- | src/arch/arduino-nano/Makefile.inc | 4 |
2 files changed, 13 insertions, 0 deletions
diff --git a/src/arch/arduino-nano/Kconfig b/src/arch/arduino-nano/Kconfig index 071c18a..ab25a8f 100644 --- a/src/arch/arduino-nano/Kconfig +++ b/src/arch/arduino-nano/Kconfig @@ -1,6 +1,15 @@ # Copyright 2020 Daniel Friesel # # SPDX-License-Identifier: CC0-1.0 + +config arch_arduino_nano_cpufreq +int "CPU Frequency" +#!accept [62500, 125000, 250000, 500000, 1000000, 2000000, 4000000, 8000000, 16000000] +range 62500 16000000 +default 16000000 +help + Assumes an externel 16MHz crystal to be present + config arch_arduino_nano_driver_adc bool "ADC (Analog-Digital-Converter)" select meta_driver_adc diff --git a/src/arch/arduino-nano/Makefile.inc b/src/arch/arduino-nano/Makefile.inc index e524027..2365cfd 100644 --- a/src/arch/arduino-nano/Makefile.inc +++ b/src/arch/arduino-nano/Makefile.inc @@ -13,6 +13,10 @@ ifdef CONFIG_arch_arduino_nano_mega168 BAUD = 19200 endif +ifdef CONFIG_arch_arduino_nano_cpufreq + cpu_freq = ${CONFIG_arch_arduino_nano_cpufreq} +endif + cpu_freq ?= 16000000 COMMON_FLAGS += -Werror=overflow |