diff --git a/CODEOWNERS b/CODEOWNERS index 0678f5309f..ec50aac245 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -98,6 +98,7 @@ /boards/arm/qemu_cortex_a53/ @carlocaione /boards/arm/qemu_cortex_r*/ @stephanosio /boards/arm/qemu_cortex_m*/ @ioannisg +/boards/arm/quick_feather/ @kowalewskijan @kgugala /boards/arm/xmc45_relax_kit/ @parthitce /boards/arm/sam4e_xpro/ @nandojve /boards/arm/sam4s_xplained/ @fallrisk diff --git a/boards/arm/quick_feather/CMakeLists.txt b/boards/arm/quick_feather/CMakeLists.txt new file mode 100644 index 0000000000..907a7cd5b5 --- /dev/null +++ b/boards/arm/quick_feather/CMakeLists.txt @@ -0,0 +1,6 @@ +# Copyright (c) 2020 Antmicro +# SPDX-License-Identifier: Apache-2.0 + +zephyr_library_include_directories(${ZEPHYR_BASE}/drivers) +zephyr_library_sources(board.c) +zephyr_include_directories(.) diff --git a/boards/arm/quick_feather/Kconfig b/boards/arm/quick_feather/Kconfig new file mode 100644 index 0000000000..c06e73df40 --- /dev/null +++ b/boards/arm/quick_feather/Kconfig @@ -0,0 +1,10 @@ +# Quick Feather board + +# Copyright (c) 2020 Antmicro +# SPDX-License-Identifier: Apache-2.0 + +config BOARD_INIT_PRIORITY + int + default KERNEL_INIT_PRIORITY_DEFAULT + help + Board initialization priority. diff --git a/boards/arm/quick_feather/Kconfig.board b/boards/arm/quick_feather/Kconfig.board new file mode 100644 index 0000000000..e85b49bc4e --- /dev/null +++ b/boards/arm/quick_feather/Kconfig.board @@ -0,0 +1,8 @@ +# Quick Feather board + +# Copyright (c) 2020 Antmicro +# SPDX-License-Identifier: Apache-2.0 + +config BOARD_QUICK_FEATHER + bool "QuickLogic Quick Feather target" + depends on SOC_EOS_S3 diff --git a/boards/arm/quick_feather/Kconfig.defconfig b/boards/arm/quick_feather/Kconfig.defconfig new file mode 100644 index 0000000000..cf328e50b1 --- /dev/null +++ b/boards/arm/quick_feather/Kconfig.defconfig @@ -0,0 +1,11 @@ +# QuickLogic Quick Feather board + +# Copyright (c) 2020 Antmicro +# SPDX-License-Identifier: Apache-2.0 + +if BOARD_QUICK_FEATHER + +config BOARD + default "quick_feather" + +endif # BOARD_QUICK_FEATHER diff --git a/boards/arm/quick_feather/board.c b/boards/arm/quick_feather/board.c new file mode 100644 index 0000000000..3a729aa66b --- /dev/null +++ b/boards/arm/quick_feather/board.c @@ -0,0 +1,24 @@ +/* + * Copyright (c) 2020 Antmicro + * + * SPDX-License-Identifier: Apache-2.0 + */ + +#include +#include +#include + +static int eos_s3_board_init(const struct device *arg) +{ + ARG_UNUSED(arg); + + /* IO MUX setup for UART */ + eos_s3_io_mux(UART_TX_PAD, UART_TX_PAD_CFG); + eos_s3_io_mux(UART_RX_PAD, UART_RX_PAD_CFG); + + IO_MUX->UART_rxd_SEL = UART_RX_SEL; + + return 0; +} + +SYS_INIT(eos_s3_board_init, PRE_KERNEL_1, CONFIG_BOARD_INIT_PRIORITY); diff --git a/boards/arm/quick_feather/board.h b/boards/arm/quick_feather/board.h new file mode 100644 index 0000000000..857a6edd03 --- /dev/null +++ b/boards/arm/quick_feather/board.h @@ -0,0 +1,19 @@ +/* + * Copyright (c) 2020 Antmicro + * + * SPDX-License-Identifier: Apache-2.0 + */ + +#ifndef __INC_BOARD_H +#define __INC_BOARD_H + +#include + +#define UART_TX_PAD 44 +#define UART_TX_PAD_CFG UART_TXD_PAD44 +#define UART_RX_PAD 45 +#define UART_RX_PAD_CFG UART_RXD_PAD45 + +#define UART_RX_SEL UART_RXD_SEL_PAD45 + +#endif /* __INC_BOARD_H */ diff --git a/boards/arm/quick_feather/quick_feather.dts b/boards/arm/quick_feather/quick_feather.dts new file mode 100644 index 0000000000..d393fc62e2 --- /dev/null +++ b/boards/arm/quick_feather/quick_feather.dts @@ -0,0 +1,30 @@ +/* + * Copyright (c) 2020 Antmicro + * + * SPDX-License-Identifier: Apache-2.0 + */ + +/dts-v1/; +#include + +/ { + model = "QuickLogic Quick Feather board"; + compatible = "quicklogic,eos_s3"; + + chosen { + zephyr,sram = &sram0; + zephyr,console = &uart0; + zephyr,shell-uart = &uart0; + zephyr,uart-pipe = &uart0; + }; + +}; + +&cpu0 { + clock-frequency = <61440000>; +}; + +&uart0 { + status = "okay"; + current-speed = <115200>; +}; diff --git a/boards/arm/quick_feather/quick_feather.yaml b/boards/arm/quick_feather/quick_feather.yaml new file mode 100644 index 0000000000..7f92a190b6 --- /dev/null +++ b/boards/arm/quick_feather/quick_feather.yaml @@ -0,0 +1,12 @@ +identifier: quick_feather +name: QuickLogic Quick Feather +type: mcu +arch: arm +toolchain: + - zephyr + - gnuarmemb + - xtools +testing: + ignore_tags: + - net + - bluetooth diff --git a/boards/arm/quick_feather/quick_feather_defconfig b/boards/arm/quick_feather/quick_feather_defconfig new file mode 100644 index 0000000000..360c5fee9e --- /dev/null +++ b/boards/arm/quick_feather/quick_feather_defconfig @@ -0,0 +1,28 @@ +# Copyright (c) 2020 Antmicro +# SPDX-License-Identifier: Apache-2.0 + +CONFIG_ARM_MPU=n +CONFIG_SOC_EOS_S3=y +CONFIG_BOARD_QUICK_FEATHER=y + +# system clock +CONFIG_SYS_CLOCK_HW_CYCLES_PER_SEC=61440000 +CONFIG_CORTEX_M_SYSTICK=y + +# console +CONFIG_SERIAL=y +CONFIG_CONSOLE=y +CONFIG_PRINTK=y +CONFIG_UART_CONSOLE=y + +# misc +CONFIG_BOOT_BANNER=y + +# EOS S3 Configuartion Manager copies software from external flash to MCU +# memory using preconfigured DMA and execute it there. +# Thus we do not use flash directly. + +CONFIG_XIP=n +CONFIG_FLASH=n +CONFIG_FLASH_SIZE=0 +CONFIG_FLASH_BASE_ADDRESS=0x0