From 9b20228ffb37b7b94725e5f0fcb31b6649e73b2e Mon Sep 17 00:00:00 2001 From: Daniel Agar Date: Tue, 6 Dec 2022 10:45:30 -0500 Subject: [PATCH] boards: modalai_voxl2-io NuttX upgrade fixes and sync with px4-io-v2 --- .../modalai/voxl2-io/nuttx-config/nsh/defconfig | 17 ++++------------- .../voxl2-io/nuttx-config/scripts/script.ld | 1 - boards/modalai/voxl2-io/src/board_config.h | 4 ---- boards/modalai/voxl2-io/src/init.c | 4 +--- 4 files changed, 5 insertions(+), 21 deletions(-) diff --git a/boards/modalai/voxl2-io/nuttx-config/nsh/defconfig b/boards/modalai/voxl2-io/nuttx-config/nsh/defconfig index 037ad29f18..2fec96fb26 100644 --- a/boards/modalai/voxl2-io/nuttx-config/nsh/defconfig +++ b/boards/modalai/voxl2-io/nuttx-config/nsh/defconfig @@ -15,32 +15,26 @@ CONFIG_ARCH_CHIP="stm32" CONFIG_ARCH_CHIP_STM32=y CONFIG_ARCH_CHIP_STM32F100C8=y CONFIG_ARMV7M_USEBASEPRI=y +CONFIG_ARM_MPU_EARLY_RESET=y CONFIG_BOARD_LOOPSPERMSEC=2000 -CONFIG_C99_BOOL8=y CONFIG_DEBUG_FULLOPT=y CONFIG_DEBUG_SYMBOLS=y CONFIG_DEFAULT_SMALL=y CONFIG_DISABLE_MOUNTPOINT=y -CONFIG_DISABLE_MQUEUE=y -CONFIG_DISABLE_PTHREAD=y CONFIG_FDCLONE_DISABLE=y CONFIG_FDCLONE_STDIO=y CONFIG_HAVE_CXX=y CONFIG_HAVE_CXXINITIALIZE=y -CONFIG_IDLETHREAD_STACKSIZE=280 -CONFIG_MAX_TASKS=2 -CONFIG_MAX_WDOGPARMS=2 +CONFIG_IDLETHREAD_STACKSIZE=316 +CONFIG_INIT_ENTRYPOINT="user_start" +CONFIG_INIT_STACKSIZE=1100 CONFIG_MM_FILL_ALLOCATIONS=y CONFIG_MM_SMALL=y CONFIG_NAME_MAX=12 -CONFIG_NFILE_DESCRIPTORS=3 -CONFIG_NFILE_STREAMS=0 CONFIG_PREALLOC_TIMERS=0 -CONFIG_PREALLOC_WDOGS=1 CONFIG_RAM_SIZE=8192 CONFIG_RAM_START=0x20000000 CONFIG_RAW_BINARY=y -CONFIG_SDCLONE_DISABLE=y CONFIG_SERIAL_TERMIOS=y CONFIG_STACK_COLORATION=y CONFIG_START_DAY=30 @@ -65,6 +59,3 @@ CONFIG_USART3_RXBUFSIZE=64 CONFIG_USART3_RXDMA=y CONFIG_USART3_TXBUFSIZE=64 CONFIG_USEC_PER_TICK=1000 -CONFIG_USERMAIN_STACKSIZE=1100 -CONFIG_USER_ENTRYPOINT="user_start" -CONFIG_WDOG_INTRESERVE=0 diff --git a/boards/modalai/voxl2-io/nuttx-config/scripts/script.ld b/boards/modalai/voxl2-io/nuttx-config/scripts/script.ld index 7ad13773f0..c84215389d 100644 --- a/boards/modalai/voxl2-io/nuttx-config/scripts/script.ld +++ b/boards/modalai/voxl2-io/nuttx-config/scripts/script.ld @@ -72,7 +72,6 @@ SECTIONS *(.gcc_except_table) *(.gnu.linkonce.r.*) _etext = ABSOLUTE(.); - } > flash /* diff --git a/boards/modalai/voxl2-io/src/board_config.h b/boards/modalai/voxl2-io/src/board_config.h index 9ddfce0034..d69aee59b2 100644 --- a/boards/modalai/voxl2-io/src/board_config.h +++ b/boards/modalai/voxl2-io/src/board_config.h @@ -47,8 +47,6 @@ #include #include - - /****************************************************************************** * Definitions ******************************************************************************/ @@ -156,6 +154,4 @@ #define BOARD_NUM_IO_TIMERS 3 -#define BOARD_DISABLE_I2C_SPI - #include diff --git a/boards/modalai/voxl2-io/src/init.c b/boards/modalai/voxl2-io/src/init.c index 52dfc5d7f8..1e432eb71f 100644 --- a/boards/modalai/voxl2-io/src/init.c +++ b/boards/modalai/voxl2-io/src/init.c @@ -32,7 +32,7 @@ ****************************************************************************/ /** - * @file px4iov2_init.c + * @file init.c * * PX4FMU-specific early startup code. This file implements the * stm32_boardinitialize() function that is called during cpu startup. @@ -84,11 +84,9 @@ __EXPORT void stm32_boardinitialize(void) { - /* configure GPIOs */ /* Set up for sensing HW */ - stm32_configgpio(GPIO_SENSE_PC14_DN); stm32_configgpio(GPIO_SENSE_PC15_UP);