diff --git a/platforms/nuttx/CMakeLists.txt b/platforms/nuttx/CMakeLists.txt index d4e299293e33..feeb309cc4a3 100644 --- a/platforms/nuttx/CMakeLists.txt +++ b/platforms/nuttx/CMakeLists.txt @@ -63,6 +63,7 @@ list(APPEND nuttx_libs if (CONFIG_NET) list(APPEND nuttx_libs nuttx_net) + target_link_libraries(nuttx_fs INTERFACE nuttx_net) endif() if (NOT LD_SCRIPT) diff --git a/platforms/nuttx/NuttX/nuttx b/platforms/nuttx/NuttX/nuttx index e3b5b667aee1..0ffe7ce8f6f7 160000 --- a/platforms/nuttx/NuttX/nuttx +++ b/platforms/nuttx/NuttX/nuttx @@ -1 +1 @@ -Subproject commit e3b5b667aee16a699ecd6605f2d2a4adc6e95c17 +Subproject commit 0ffe7ce8f6f78190c714e6daa866f73ce271a5bd diff --git a/platforms/nuttx/nuttx-configs/av-x-v1/nsh/defconfig b/platforms/nuttx/nuttx-configs/av-x-v1/nsh/defconfig index caa46066d084..f416f9fb6385 100644 --- a/platforms/nuttx/nuttx-configs/av-x-v1/nsh/defconfig +++ b/platforms/nuttx/nuttx-configs/av-x-v1/nsh/defconfig @@ -325,7 +325,7 @@ CONFIG_STM32F7_DMA2=y # CONFIG_STM32F7_DSIHOST is not set # CONFIG_STM32F7_DMA2D is not set # CONFIG_STM32F7_JPEG is not set -# CONFIG_STM32F7_ETHMAC is not set +CONFIG_STM32F7_ETHMAC=y # CONFIG_STM32F7_FMC is not set # CONFIG_STM32F7_HASH is not set # CONFIG_STM32F7_I2C1 is not set @@ -441,6 +441,28 @@ CONFIG_STM32F7_DMACAPABLE=y # # CONFIG_STM32F7_ADC_NO_STARTUP_CONV is not set # CONFIG_STM32F7_ADC1_DMA is not set + +# +# Ethernet MAC configuration +# +CONFIG_STM32F7_PHYADDR=0 +# CONFIG_STM32F7_PHYINIT is not set +# CONFIG_STM32F7_MII is not set +CONFIG_STM32F7_AUTONEG=y +CONFIG_STM32F7_PHYSR=31 +CONFIG_STM32F7_PHYSR_ALTCONFIG=y +CONFIG_STM32F7_PHYSR_ALTMODE=0x1C +CONFIG_STM32F7_PHYSR_10HD=0x4 +CONFIG_STM32F7_PHYSR_100HD=0x8 +CONFIG_STM32F7_PHYSR_10FD=0x14 +CONFIG_STM32F7_PHYSR_100FD=0x18 +# CONFIG_STM32F7_ETH_PTP is not set +CONFIG_STM32F7_RMII=y +# CONFIG_STM32F7_RMII_MCO1 is not set +# CONFIG_STM32F7_RMII_MCO2 is not set +CONFIG_STM32F7_RMII_EXTCLK=y +# CONFIG_STM32F7_ETHMAC_HPWORK is not set +CONFIG_STM32F7_ETHMAC_LPWORK=y # CONFIG_ARCH_TOOLCHAIN_IAR is not set CONFIG_ARCH_TOOLCHAIN_GNU=y @@ -778,6 +800,55 @@ CONFIG_MTD_BYTE_WRITE=y # CONFIG_MTD_SST39FV is not set # CONFIG_MTD_W25 is not set # CONFIG_EEPROM is not set +CONFIG_NETDEVICES=y + +# +# General Ethernet MAC Driver Options +# +# CONFIG_NETDEV_LOOPBACK is not set +CONFIG_NETDEV_TELNET=y +CONFIG_TELNET_RXBUFFER_SIZE=256 +CONFIG_TELNET_TXBUFFER_SIZE=256 +# CONFIG_ARCH_HAVE_NETDEV_STATISTICS is not set +# CONFIG_NETDEV_LATEINIT is not set + +# +# External Ethernet MAC Device Support +# +# CONFIG_NET_DM90x0 is not set +# CONFIG_ENC28J60 is not set +# CONFIG_ENCX24J600 is not set +# CONFIG_NET_SLIP is not set +# CONFIG_NET_FTMAC100 is not set + +# +# External Ethernet PHY Device Support +# +# CONFIG_ARCH_PHY_INTERRUPT is not set +# CONFIG_ETH0_PHY_NONE is not set +# CONFIG_ETH0_PHY_AM79C874 is not set +# CONFIG_ETH0_PHY_KS8721 is not set +# CONFIG_ETH0_PHY_KSZ8041 is not set +# CONFIG_ETH0_PHY_KSZ8051 is not set +# CONFIG_ETH0_PHY_KSZ8061 is not set +# CONFIG_ETH0_PHY_KSZ8081 is not set +# CONFIG_ETH0_PHY_KSZ90x1 is not set +# CONFIG_ETH0_PHY_DP83848C is not set +CONFIG_ETH0_PHY_LAN8720=y +# CONFIG_ETH0_PHY_LAN8740 is not set +# CONFIG_ETH0_PHY_LAN8740A is not set +# CONFIG_ETH0_PHY_LAN8742A is not set +# CONFIG_ETH0_PHY_DM9161 is not set +CONFIG_ETH1_PHY_NONE=y +# CONFIG_ETH1_PHY_AM79C874 is not set +# CONFIG_ETH1_PHY_KS8721 is not set +# CONFIG_ETH1_PHY_KSZ8041 is not set +# CONFIG_ETH1_PHY_KSZ8051 is not set +# CONFIG_ETH1_PHY_KSZ8081 is not set +# CONFIG_ETH1_PHY_KSZ90x1 is not set +# CONFIG_ETH1_PHY_DP83848C is not set +# CONFIG_ETH1_PHY_LAN8720 is not set +# CONFIG_ETH1_PHY_DM9161 is not set CONFIG_PIPES=y CONFIG_DEV_PIPE_MAXSIZE=1024 CONFIG_DEV_PIPE_SIZE=70 @@ -947,9 +1018,122 @@ CONFIG_SYSLOG_CONSOLE=y # # Networking Support # -# CONFIG_ARCH_HAVE_NET is not set -# CONFIG_ARCH_HAVE_PHY is not set -# CONFIG_NET is not set +CONFIG_ARCH_HAVE_NET=y +CONFIG_ARCH_HAVE_PHY=y +CONFIG_NET=y +# CONFIG_NET_PROMISCUOUS is not set + +# +# Driver buffer configuration +# +CONFIG_NET_ETH_MTU=1500 +CONFIG_NET_ETH_TCP_RECVWNDO=536 +CONFIG_NET_GUARDSIZE=2 + +# +# Link layer support +# +CONFIG_NET_ETHERNET=y +# CONFIG_NET_LOOPBACK is not set +# CONFIG_NET_TUN is not set +# CONFIG_NET_USRSOCK is not set + +# +# Network Device Operations +# +CONFIG_NETDEV_IOCTL=y +CONFIG_NETDEV_PHY_IOCTL=y + +# +# Internet Protocol Selection +# +CONFIG_NET_IPv4=y +# CONFIG_NET_IPv6 is not set +# CONFIG_NET_IPFORWARD is not set + +# +# Socket Support +# +CONFIG_NSOCKET_DESCRIPTORS=8 +CONFIG_NET_NACTIVESOCKETS=16 +CONFIG_NET_SOCKOPTS=y +CONFIG_NET_SOLINGER=y + +# +# Raw Socket Support +# +# CONFIG_NET_PKT is not set + +# +# Unix Domain Socket Support +# +# CONFIG_NET_LOCAL is not set + +# +# TCP/IP Networking +# +CONFIG_NET_TCP=y +# CONFIG_NET_TCP_NO_STACK is not set +# CONFIG_NET_TCPURGDATA is not set +CONFIG_NET_TCP_CONNS=8 +CONFIG_NET_MAX_LISTENPORTS=20 +CONFIG_NET_TCP_READAHEAD=y +CONFIG_NET_TCP_WRITE_BUFFERS=y +CONFIG_NET_TCP_NWRBCHAINS=8 +CONFIG_NET_TCP_RECVDELAY=0 +CONFIG_NET_TCPBACKLOG=y +# CONFIG_NET_SENDFILE is not set + +# +# UDP Networking +# +CONFIG_NET_UDP=y +# CONFIG_NET_UDP_NO_STACK is not set +CONFIG_NET_UDP_CHECKSUMS=y +CONFIG_NET_UDP_CONNS=8 +CONFIG_NET_BROADCAST=y +CONFIG_NET_UDP_READAHEAD=y + +# +# IEEE 802.15.4 socket support +# + +# +# ICMP Networking Support +# +CONFIG_NET_ICMP=y +CONFIG_NET_ICMP_PING=y +# CONFIG_NET_IGMP is not set + +# +# ARP Configuration +# +CONFIG_NET_ARP=y +CONFIG_NET_ARPTAB_SIZE=16 +CONFIG_NET_ARP_MAXAGE=120 +CONFIG_NET_ARP_IPIN=y +CONFIG_NET_ARP_SEND=y +CONFIG_ARP_SEND_MAXTRIES=5 +CONFIG_ARP_SEND_DELAYMSEC=20 + +# +# User-space networking stack API +# +# CONFIG_NET_ARCH_INCR32 is not set +# CONFIG_NET_ARCH_CHKSUM is not set +# CONFIG_NET_STATISTICS is not set +# CONFIG_NET_HAVE_STAR is not set + +# +# Network Topologies +# + +# +# Routing Table Configuration +# +CONFIG_NET_ROUTE=y +CONFIG_NET_MAXROUTES=4 +CONFIG_NET_HOSTNAME="px4" # # Crypto API @@ -981,6 +1165,7 @@ CONFIG_FS_FATTIME=y # CONFIG_FAT_FORCE_INDIRECT is not set CONFIG_FAT_DMAMEMORY=y CONFIG_FAT_DIRECT_RETRY=y +# CONFIG_NFS is not set # CONFIG_FS_NXFFS is not set CONFIG_FS_ROMFS=y # CONFIG_FS_TMPFS is not set @@ -995,6 +1180,8 @@ CONFIG_FS_PROCFS_REGISTER=y # CONFIG_FS_PROCFS_EXCLUDE_PROCESS is not set # CONFIG_FS_PROCFS_EXCLUDE_UPTIME is not set # CONFIG_FS_PROCFS_EXCLUDE_MOUNTS is not set +# CONFIG_FS_PROCFS_EXCLUDE_NET is not set +# CONFIG_FS_PROCFS_EXCLUDE_ROUTE is not set # CONFIG_FS_PROCFS_EXCLUDE_MTD is not set # CONFIG_FS_PROCFS_EXCLUDE_PARTITIONS is not set # CONFIG_FS_UNIONFS is not set @@ -1017,7 +1204,11 @@ CONFIG_GRAN_INTR=y # # Common I/O Buffer Support # -# CONFIG_MM_IOB is not set +CONFIG_MM_IOB=y +CONFIG_IOB_NBUFFERS=24 +CONFIG_IOB_BUFSIZE=196 +CONFIG_IOB_NCHAINS=8 +CONFIG_IOB_THROTTLE=0 # # Audio Support @@ -1129,14 +1320,21 @@ CONFIG_ARCH_HAVE_TLS=y # # Network-Related Options # -# CONFIG_LIBC_IPv4_ADDRCONV is not set # CONFIG_LIBC_IPv6_ADDRCONV is not set -# CONFIG_LIBC_NETDB is not set +CONFIG_LIBC_NETDB=y # # NETDB Support # # CONFIG_NETDB_HOSTFILE is not set +CONFIG_NETDB_DNSCLIENT=y +CONFIG_NETDB_DNSCLIENT_ENTRIES=8 +CONFIG_NETDB_DNSCLIENT_NAMESIZE=32 +CONFIG_NETDB_DNSCLIENT_LIFESEC=3600 +CONFIG_NETDB_DNSCLIENT_MAXRESPONSE=96 +# CONFIG_NETDB_RESOLVCONF is not set +CONFIG_NETDB_DNSSERVER_NOADDR=y +# CONFIG_NETDB_DNSSERVER_IPv4 is not set # CONFIG_LIBC_IOCTL_VARIADIC is not set CONFIG_LIB_SENDFILE_BUFSIZE=512 @@ -1182,12 +1380,14 @@ CONFIG_BUILTIN_PROXY_STACKSIZE=1024 # Examples # # CONFIG_EXAMPLES_APA102 is not set +# CONFIG_EXAMPLES_BRIDGE is not set # CONFIG_EXAMPLES_CCTYPE is not set # CONFIG_EXAMPLES_CHAT is not set # CONFIG_EXAMPLES_CONFIGDATA is not set # CONFIG_EXAMPLES_CPUHOG is not set # CONFIG_EXAMPLES_CXXTEST is not set # CONFIG_EXAMPLES_DHCPD is not set +# CONFIG_EXAMPLES_DISCOVER is not set # CONFIG_EXAMPLES_ELF is not set # CONFIG_EXAMPLES_FLOWC is not set # CONFIG_EXAMPLES_FSTEST is not set @@ -1203,6 +1403,7 @@ CONFIG_BUILTIN_PROXY_STACKSIZE=1024 # CONFIG_EXAMPLES_MODBUS is not set # CONFIG_EXAMPLES_MOUNT is not set # CONFIG_EXAMPLES_MTDPART is not set +# CONFIG_EXAMPLES_NETTEST is not set CONFIG_EXAMPLES_NSH=y # CONFIG_EXAMPLES_NSH_CXXINITIALIZE is not set # CONFIG_EXAMPLES_NULL is not set @@ -1232,14 +1433,18 @@ CONFIG_EXAMPLES_NSH=y # CONFIG_EXAMPLES_SMP is not set # CONFIG_EXAMPLES_STAT is not set # CONFIG_EXAMPLES_TCPECHO is not set +# CONFIG_EXAMPLES_TELNETD is not set # CONFIG_EXAMPLES_THTTPD is not set # CONFIG_EXAMPLES_TIFF is not set # CONFIG_EXAMPLES_TOUCHSCREEN is not set +# CONFIG_EXAMPLES_UDPBLASTER is not set +# CONFIG_EXAMPLES_UDP is not set # CONFIG_EXAMPLES_UNIONFS is not set # CONFIG_EXAMPLES_USBSERIAL is not set # CONFIG_EXAMPLES_WATCHDOG is not set # CONFIG_EXAMPLES_WEBSERVER is not set # CONFIG_EXAMPLES_XBC_TEST is not set +# CONFIG_EXAMPLES_XMLRPC is not set # # File System Utilities @@ -1278,11 +1483,24 @@ CONFIG_EXAMPLES_NSH=y # # CONFIG_NETUTILS_CHAT is not set # CONFIG_NETUTILS_CODECS is not set +# CONFIG_NETUTILS_DHCPC is not set +# CONFIG_NETUTILS_DHCPD is not set +# CONFIG_NETUTILS_DISCOVER is not set # CONFIG_NETUTILS_ESP8266 is not set # CONFIG_NETUTILS_FTPC is not set +# CONFIG_NETUTILS_FTPD is not set # CONFIG_NETUTILS_JSON is not set +CONFIG_NETUTILS_NETLIB=y +# CONFIG_NETUTILS_NTPCLIENT is not set +# CONFIG_NETUTILS_PPPD is not set # CONFIG_NETUTILS_SMTP is not set +# CONFIG_NETUTILS_TELNETC is not set +CONFIG_NETUTILS_TELNETD=y +# CONFIG_NETUTILS_TFTPC is not set # CONFIG_NETUTILS_THTTPD is not set +# CONFIG_NETUTILS_WEBCLIENT is not set +# CONFIG_NETUTILS_WEBSERVER is not set +# CONFIG_NETUTILS_XMLRPC is not set # # NSH Library @@ -1307,6 +1525,8 @@ CONFIG_NSH_BUILTIN_APPS=y # # Disable Individual commands # +# CONFIG_NSH_DISABLE_ADDROUTE is not set +# CONFIG_NSH_DISABLE_ARP is not set # CONFIG_NSH_DISABLE_BASENAME is not set # CONFIG_NSH_DISABLE_CAT is not set # CONFIG_NSH_DISABLE_CD is not set @@ -1315,6 +1535,7 @@ CONFIG_NSH_BUILTIN_APPS=y # CONFIG_NSH_DISABLE_DATE is not set # CONFIG_NSH_DISABLE_DD is not set # CONFIG_NSH_DISABLE_DF is not set +# CONFIG_NSH_DISABLE_DELROUTE is not set # CONFIG_NSH_DISABLE_DIRNAME is not set # CONFIG_NSH_DISABLE_ECHO is not set # CONFIG_NSH_DISABLE_EXEC is not set @@ -1324,7 +1545,7 @@ CONFIG_NSH_BUILTIN_APPS=y # CONFIG_NSH_DISABLE_HELP is not set # CONFIG_NSH_DISABLE_HEXDUMP is not set # CONFIG_NSH_DISABLE_IFCONFIG is not set -CONFIG_NSH_DISABLE_IFUPDOWN=y +# CONFIG_NSH_DISABLE_IFUPDOWN is not set # CONFIG_NSH_DISABLE_KILL is not set # CONFIG_NSH_DISABLE_LOSETUP is not set CONFIG_NSH_DISABLE_LOSMART=y @@ -1338,14 +1559,17 @@ CONFIG_NSH_DISABLE_LOSMART=y # CONFIG_NSH_DISABLE_MOUNT is not set # CONFIG_NSH_DISABLE_MV is not set # CONFIG_NSH_DISABLE_MW is not set +# CONFIG_NSH_DISABLE_NSLOOKUP is not set # CONFIG_NSH_DISABLE_PRINTF is not set # CONFIG_NSH_DISABLE_PS is not set CONFIG_NSH_DISABLE_PSSTACKUSAGE=y +# CONFIG_NSH_DISABLE_PING is not set # CONFIG_NSH_DISABLE_PUT is not set # CONFIG_NSH_DISABLE_PWD is not set CONFIG_NSH_DISABLE_REBOOT=y # CONFIG_NSH_DISABLE_RM is not set # CONFIG_NSH_DISABLE_RMDIR is not set +# CONFIG_NSH_DISABLE_ROUTE is not set # CONFIG_NSH_DISABLE_SET is not set # CONFIG_NSH_DISABLE_SH is not set CONFIG_NSH_DISABLE_SHUTDOWN=y @@ -1397,10 +1621,50 @@ CONFIG_NSH_FATMOUNTPT="/tmp" # Console Configuration # CONFIG_NSH_CONSOLE=y -# CONFIG_NSH_ALTCONDEV is not set CONFIG_NSH_ARCHINIT=y -# CONFIG_NSH_LOGIN is not set + +# +# Networking Configuration +# +CONFIG_NSH_NETINIT=y +# CONFIG_NSH_NETLOCAL is not set +CONFIG_NSH_NETINIT_THREAD=y +CONFIG_NSH_NETINIT_THREAD_STACKSIZE=1568 +CONFIG_NSH_NETINIT_THREAD_PRIORITY=80 + +# +# IP Address Configuration +# + +# +# IPv4 Addresses +# +CONFIG_NSH_IPADDR=0xc0a8560c +CONFIG_NSH_DRIPADDR=0xc0a85601 +CONFIG_NSH_NETMASK=0xffffff00 +# CONFIG_NSH_DNS is not set +# CONFIG_NSH_NOMAC is not set +CONFIG_NSH_MAX_ROUNDTRIP=20 + +# +# Telnet Configuration +# +CONFIG_NSH_TELNET=y +CONFIG_NSH_TELNETD_PORT=23 +CONFIG_NSH_TELNETD_DAEMONPRIO=100 +CONFIG_NSH_TELNETD_DAEMONSTACKSIZE=2048 +CONFIG_NSH_TELNETD_CLIENTPRIO=100 +CONFIG_NSH_TELNETD_CLIENTSTACKSIZE=2048 +CONFIG_NSH_IOBUFFER_SIZE=512 +CONFIG_NSH_LOGIN=y # CONFIG_NSH_CONSOLE_LOGIN is not set +CONFIG_NSH_TELNET_LOGIN=y +CONFIG_NSH_LOGIN_FIXED=y +# CONFIG_NSH_LOGIN_PLATFORM is not set +CONFIG_NSH_LOGIN_USERNAME="px4" +CONFIG_NSH_LOGIN_PASSWORD="px4" +CONFIG_NSH_LOGIN_FAILDELAY=0 +CONFIG_NSH_LOGIN_FAILCOUNT=3 # # NxWidgets/NxWM @@ -1417,12 +1681,16 @@ CONFIG_HAVE_CXXINITIALIZE=y # # CONFIG_SYSTEM_CLE is not set # CONFIG_SYSTEM_CUTERM is not set +# CONFIG_SYSTEM_DHCPC_RENEW is not set # CONFIG_SYSTEM_FLASH_ERASEALL is not set # CONFIG_SYSTEM_FREE is not set # CONFIG_SYSTEM_HEX2BIN is not set # CONFIG_SYSTEM_HEXED is not set # CONFIG_SYSTEM_I2CTOOL is not set # CONFIG_SYSTEM_INSTALL is not set +# CONFIG_SYSTEM_MDIO is not set +# CONFIG_SYSTEM_NETDB is not set +# CONFIG_SYSTEM_NTPC is not set # CONFIG_SYSTEM_RAMTEST is not set CONFIG_READLINE_HAVE_EXTMATCH=y CONFIG_SYSTEM_READLINE=y @@ -1433,6 +1701,8 @@ CONFIG_READLINE_ECHO=y # CONFIG_SYSTEM_SUDOKU is not set # CONFIG_SYSTEM_SYSTEM is not set # CONFIG_SYSTEM_TEE is not set +# CONFIG_SYSTEM_TELNET_CHATD is not set +# CONFIG_SYSTEM_TELNET_CLIENT is not set # CONFIG_SYSTEM_UBLOXMODEM is not set # CONFIG_SYSTEM_VI is not set # CONFIG_SYSTEM_ZMODEM is not set