diff options
author | Kevin O'Connor <kevin@koconnor.net> | 2018-10-01 22:30:58 -0400 |
---|---|---|
committer | Kevin O'Connor <kevin@koconnor.net> | 2018-10-01 22:30:58 -0400 |
commit | d348f0da8789889d29ac49b9e9823fedfbfdb69b (patch) | |
tree | 96f2e49f2c41844c3c89a7351edbb2a57716312c /src/avr | |
parent | 0820394e132888dd79689a68e918f17b500fa45f (diff) | |
download | kutter-d348f0da8789889d29ac49b9e9823fedfbfdb69b.tar.gz kutter-d348f0da8789889d29ac49b9e9823fedfbfdb69b.tar.xz kutter-d348f0da8789889d29ac49b9e9823fedfbfdb69b.zip |
avr: Allow the serial port to be selected on the atmega2560/1280
Allow the serial port to be selected on the atmega2560 and atmega1280
chips in Kconfig.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'src/avr')
-rw-r--r-- | src/avr/Kconfig | 27 |
1 files changed, 17 insertions, 10 deletions
diff --git a/src/avr/Kconfig b/src/avr/Kconfig index bef830c0..70115526 100644 --- a/src/avr/Kconfig +++ b/src/avr/Kconfig @@ -65,16 +65,6 @@ choice bool "8Mhz" endchoice -if MACH_atmega1284p - choice - prompt "Serial Port" - config AVR_SERIAL_UART0 - bool "UART0" - config AVR_SERIAL_UART1 - bool "UART1" - endchoice -endif - config CLOCK_FREQ int default 8000000 if AVR_FREQ_8000000 @@ -111,6 +101,21 @@ config AVR_SERIAL depends on !AVR_USBSERIAL bool default y +choice + depends on AVR_SERIAL + prompt "Serial Port" if MACH_atmega2560 || MACH_atmega1280 || MACH_atmega1284p + help + Select the serial device to use on the AVR chip. This is + almost always UART0. + config AVR_SERIAL_UART0 + bool "UART0" + config AVR_SERIAL_UART1 + bool "UART1" + config AVR_SERIAL_UART2 + bool "UART2" if MACH_atmega2560 || MACH_atmega1280 + config AVR_SERIAL_UART3 + bool "UART3" if MACH_atmega2560 || MACH_atmega1280 +endchoice config SERIAL_BAUD depends on AVR_SERIAL int "Baud rate for serial port" @@ -122,6 +127,8 @@ config SERIAL_BAUD_U2X config SERIAL_PORT int + default 3 if AVR_SERIAL_UART3 + default 2 if AVR_SERIAL_UART2 default 1 if MACH_at90usb1286 || MACH_at90usb646 || AVR_SERIAL_UART1 default 0 |