aboutsummaryrefslogtreecommitdiffstats
path: root/src/avr/Kconfig
blob: efc8484a357187b942b4a316d9425d982a28eb9b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
# Kconfig settings for AVR processors

if MACH_AVR

config AVR_SELECT
    bool
    default y
    select HAVE_GPIO_ADC
    select HAVE_GPIO_SPI

config BOARD_DIRECTORY
    string
    default "avr"

choice
    prompt "Processor model"
    config MACH_atmega168
        bool "atmega168"
    config MACH_atmega644p
        bool "atmega644p"
    config MACH_at90usb1286
        bool "at90usb1286"
    config MACH_atmega1280
        bool "atmega1280"
    config MACH_atmega2560
        bool "atmega2560"
endchoice

config MCU
    string
    default "atmega168" if MACH_atmega168
    default "atmega644p" if MACH_atmega644p
    default "at90usb1286" if MACH_at90usb1286
    default "atmega1280" if MACH_atmega1280
    default "atmega2560" if MACH_atmega2560

choice
    prompt "Processor speed"
    config AVR_FREQ_8000000
        bool "8Mhz"
    config AVR_FREQ_16000000
        bool "16Mhz"
    config AVR_FREQ_20000000
        bool "20Mhz"
endchoice

config CLOCK_FREQ
    int
    default 8000000 if AVR_FREQ_8000000
    default 16000000 if AVR_FREQ_16000000
    default 20000000 if AVR_FREQ_20000000

config CLEAR_PRESCALER
    bool "Manually clear the CPU prescaler field at startup"
    default n
    help
         Some AVR chips ship with a "clock prescaler" that causes the
         chip to run at 1/8th speed. Enable this setting to clear the
         prescaler field at startup which will cause the chip to run
         without a clock divisor.

config AVR_CLKPR
    int
    default 0 if CLEAR_PRESCALER
    default -1

config AVR_STACK_SIZE
    int
    default 256 if MACH_atmega2560
    default 128

config AVR_WATCHDOG
    bool "Support for automated reset on watchdog timeout"
    default y
config AVR_USBSERIAL
    bool
    depends on MACH_at90usb1286
    default y
config AVR_SERIAL
    depends on !AVR_USBSERIAL
    bool
    default y
config SERIAL_BAUD
    depends on AVR_SERIAL
    int "Baud rate for serial port"
    default 250000
config SERIAL_BAUD_U2X
    depends on AVR_SERIAL
    bool "Use AVR Baud 2X mode"
    default y

endif