Commit graph

59128 commits

Author SHA1 Message Date
Alan Carvalho de Assis
a94dddabb9 boards/imxrt: Add ARCX Socket Grid board
This commit add support to ARCX Socket Grid board powered
by iMXRT-1052 MCU.

Signed-off-by: Alan C. Assis <acassis@gmail.com>
2025-07-28 11:13:07 -03:00
lipengfei28
5eea680e44 documentation/arm64/imx9: add imx95 support
Signed-off-by: lipengfei28 <lipengfei28@xiaomi.com>
2025-07-28 09:58:02 -03:00
lipengfei28
99103b79c5 boards/arm64/imx9: add imx95 support
Signed-off-by: lipengfei28 <lipengfei28@xiaomi.com>
2025-07-28 09:58:02 -03:00
lipengfei28
44016fbe77 arch/arm64/imx9: add imx95 support
Signed-off-by: lipengfei28 <lipengfei28@xiaomi.com>
2025-07-28 09:58:02 -03:00
Matteo Golin
b0760dceb6 drivers/sensors/l86xxx: Use uORB GNSS lower-half
Changes the implementation of the L86xxx driver to use the
gnss_lowerhalf driver implementation, simplifying this driver's logic.
It also fixes the `read_line` function which would early return on `\r`,
as well as adding some retries for response checking and better mutex
locking.

Signed-off-by: Matteo Golin <matteo.golin@gmail.com>
2025-07-28 10:46:55 +02:00
Rodrigo Sim
a8ac255386 boards/arm/stm32f401rc-rs485: Add support to MAX31855 and MAX6675
This commit adds support for MAX31855 and MAX6675 thermocouple
sensors on the STM32F401RC-RS485 board via SPI1. It also updates
the board documentation accordingly.

Signed-off-by: Rodrigo Sim <rcsim10@gmail.com>
2025-07-27 10:04:03 -03:00
Rodrigo Sim
80e1f70832 boards/arm/stm32f4discovery: Add support to HX711 ADC
This commit adds support for the HX711 ADC in the STM32F4-Discovery
board and updates the board documentation accordingly.

Signed-off-by: Rodrigo Sim <rcsim10@gmail.com>
2025-07-27 17:43:19 +08:00
Côme VINCENT
596a425066 nucleo-h743zi: Add ADC2 support and expand ADC channel list
- Added support for ADC2 initialization and registration.
- Defined new ADC2 channels and corresponding pin mappings.
- Expanded ADC1 channel list and updated pin mappings.
- Updated board.h with additional ADC channel definitions.
- Ensured all ADCs are properly initialized and registered.

- Tested by opening and reading /dev/adc0 and /dev/adc1, checking
  that the correct values are read.

Signed-off-by: Côme VINCENT <44554692+comejv@users.noreply.github.com>
2025-07-26 10:02:32 -03:00
kywwilson11
4995c836f3 arch/arm/stm32h5: Add DMA Support to STM32H5 Serial Driver
Style fixes.
2025-07-26 20:57:26 +08:00
Côme VINCENT
ec64401c62 docs: Add Nix flake development environment guide
This commit introduces a new guide in  that details how to set up a reproducible development environment for NuttX using Nix flakes.

The guide covers:
- Prerequisites for using Nix flakes.
- Steps to enter the NuttX development shell.
- Benefits of using the Nix flake (reproducibility, simplified onboarding, dependency management).
- An overview of the  contents.

A link to this new guide has also been added in index.rst to ensure discoverability.

Signed-off-by: Côme VINCENT <44554692+comejv@users.noreply.github.com>
2025-07-26 20:55:29 +08:00
Côme VINCENT
92be21982d tools/nix: Add Nix flake for reproducible dev environment
This commit introduces a Nix flake (flake.nix and flake.lock) to provide
a reproducible development shell for NuttX using Nix and flakes.

- Adds a devShell with all required build tools and dependencies for NuttX,
  including CMake, Ninja, GNU Make, clang-tools, ARM toolchain, and other
  utilities (automake, bison, flex, genromfs, gettext, gperf, kconfig-frontends,
  libelf, expat, gmp, isl, libmpc, mpfr, ncurses, zlib, kconfiglib).
- Uses flake-utils to support multiple platforms.
- Sets up a shell hook to enable CMake compile commands and provide a welcome
  message.
- Based on nixpkgs `nixos-unstable` for up-to-date packages.

Purpose:
- Simplifies onboarding and ensures a consistent build environment across
  contributors.
- Reduces "works on my machine" issues by pinning dependencies.

Tested by running `nix develop` and building NuttX on x86_64-linux.

No impact on runtime or target builds; this only affects developer tooling.

For more details, see the new flake.nix file.

Signed-off-by: Côme VINCENT <44554692+comejv@users.noreply.github.com>
2025-07-26 20:55:29 +08:00
YAMAMOTO Takashi
0f73f92ffc add esp32s3-devkit:mbedtls kconfig
Note: CONFIG_LIBC_RAND_ORDER=2 is a workaround for
https://github.com/apache/nuttx/issues/16760

Signed-off-by: YAMAMOTO Takashi <yamamoto@midokura.com>
2025-07-25 21:29:11 +08:00
makejian
ac54fe8875 crypto/cryptosoft: fix aadlen used uninitialized warning
Signed-off-by: makejian <makejian@xiaomi.com>
2025-07-25 08:59:53 -03:00
YAMAMOTO Takashi
69bcbfb207 esp32s3_extraheaps.c: add a missing include for xtensa_imm_initialize
Signed-off-by: YAMAMOTO Takashi <yamamoto@midokura.com>
2025-07-25 15:51:38 +08:00
Matteo Golin
da72df9ab6 drivers/sensors/l86xxx: Fix kernel crashes on failed registration
Sometimes this driver will boot when the serial port is of the wrong
baud rate, and it cannot set the correct baud rate or verify
communication. This commit prevents registration if any settings fail to
be set, and also prevents the kernel thread from setting the L86 to
enabled (this is done only by the uORB upper half).

Signed-off-by: Matteo Golin <matteo.golin@gmail.com>
2025-07-25 10:48:55 +08:00
Jorge Guzman
b78b870d68 tools/nxstyle.c: Updating white list to xedge example
Update nxstyle whitelist to allow MixedCase
identifiers used by the Xedge (Barracuda App Server) example.

  The following prefixes were added to g_white_prefix[]:
  - Ba
  - Thread
  - LThread
  - Http
  - Disk
  - Xedge

  The following exact identifiers were added to g_white_content_list[]:
  - baGetUnixTime
  - baParseDate
  - setDispExit
  - xedgeInitDiskIo
  - xedgeOpenAUX
  - platformInitDiskIo
  - ltMgr
  - Lt

Signed-off-by: Jorge Guzman <jorge.gzm@gmail.com>
2025-07-24 11:37:16 -03:00
Windsor Schmidt
6bbc8c701a documentation: spelling and grammar fixes 2025-07-24 14:44:02 +08:00
kywwilson11
cbd033ae90 arch/arm/stm32h5: Initial Driver for STM32H5 Digital Temperature Sensor (DTS)
- Committing initial code for DTS. Missing ISR. Works for PCLK1. Cannot get to work for LSE.
- Pushing everything. Working with LSE now.
- Many fixes. Fixed interrupt setting. Added data structures.
- Changed interrupt handling. Removed FARs. Added Kconfig options for selecting interrupts.
- Updated info and formatting.
- Formatting fixes.
- Formatting.
- Changed iten to regval.
- Removed Triggger
- Formatting fixes per Pull request.
- Changed private_types to have stm32_ prefix. Used depends on for DTS Kconfig Menu. Fixed formatting per PR.
- Fixed spacing of function prototypes.
- Fixed indent on line
- Added documentation for STM32H5 and Nucleo-H563ZI regarding DTS. Also added GPDMA support to STM32H5 documentation (previous PR). Made stm32_dts.c more modular. stm32_dts_activate is now much more readable. Added comments/descriptions to private functions. Lastly, added a nucleo-h563zi:dts configuration.
2025-07-23 15:08:02 +08:00
simbit18
b5ef0871d9 build.yml: Excludes the workflow if the file is AUTHORS
CI does not compile everything for a simple modification of the AUTHORS file.

Signed-off-by: simbit18 <simbit18@gmail.com>
2025-07-23 02:26:45 +08:00
Martin Vajnar
150854c6f2 ESP_PCNT: add high and low limit Kconfig options
Signed-off-by: Martin Vajnar <martin.vajnar@gmail.com>
2025-07-22 13:09:02 -03:00
simbit18
d7a05dfcc6 drivers/segger: Add a kconfig to override Segger SystemView target sources version
update:
    CMakeLists.txt
    Make.defs
    Kconfig

It allows the same version of SystemView target sources to be used for CMake and Make, to avoid discrepancies in the future.

Signed-off-by: simbit18 <simbit18@gmail.com>
2025-07-22 23:21:31 +08:00
Filipe Cavalcanti
bbdb75b1f7 documentation: update documentation for MCUBoot on Espressif devices
Updates MCUBoot documentation and usage example.

Signed-off-by: Filipe Cavalcanti <filipe.cavalcanti@espressif.com>
2025-07-22 10:55:08 -03:00
Filipe Cavalcanti
3468c8e0cf arch/risc-v: change offset for SPI Flash on Espressif devices
Signed-off-by: Filipe Cavalcanti <filipe.cavalcanti@espressif.com>
2025-07-22 10:55:08 -03:00
Filipe Cavalcanti
8c932b50fb boards/risc-v: fixes SPI Flash for MCUBoot usage
Adds partitions required for MCUBoot usage and a sample defconfig.

Signed-off-by: Filipe Cavalcanti <filipe.cavalcanti@espressif.com>
2025-07-22 10:55:08 -03:00
Filipe Cavalcanti
a7cd6bb401 arch/xtensa: add E-Fuse support on ESP32S2
Adds support for e-fuse on ESP32S2 and fixes a gitignore issue.

Signed-off-by: Filipe Cavalcanti <filipe.cavalcanti@espressif.com>
2025-07-22 10:55:08 -03:00
Filipe Cavalcanti
3f8cde728d boards/xtensa: fixes SPI Flash for MCUBoot usage
Fixes partitions for MCUBoot usage.

Signed-off-by: Filipe Cavalcanti <filipe.cavalcanti@espressif.com>
2025-07-22 10:55:08 -03:00
SPRESENSE
664277039e arch: cxd56xx: Fix bug that causes wake-up by unused gpio interrupt
Set level high for unused interrupt trigger to avoid waking up from cold sleeping.

Signed-off-by: SPRESENSE <41312067+SPRESENSE@users.noreply.github.com>
2025-07-22 16:21:26 +08:00
guanyi
ac5b38c9e5 arch/sim: avoid host-call being interrupted before getting errno
Sim use coroutine base on one thread in host to do switch context. but if we allow switch context with in one API (host-API and errno get), maybe the switch context from coroutine cause re-enter host-API call. Make the errno get behavior not work as expected.

Signed-off-by: guanyi3 <guanyi3@xiaomi.com>
2025-07-21 19:19:05 -03:00
jingfei
db54331479 drivers/fs:Always use register_mtddriver() to register the MTD device (patch2)
This is a supplement to the patch:1936126210a56b6d1b033d6d940669413dd6e1b0

Due to the automatic wrapping of MTD devices during the
open() process, the legacy registration methods
ftl_initialize() and bchdev_register() are no longer
required for MTD device registration for user code.

So we have adjusted the registration method for MTD devices
in nuttx/boards, replacing the previous approach using
ftl_initialize()  with register_mtddriver().
2025-07-21 15:15:30 -03:00
xuxin19
956a50bb7d cmake(bugfix):add missing c++ toolchain search path
when libcxx or uClib++ is not selected, we use the default NUTTX cxx

Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2025-07-21 19:21:02 +08:00
chao an
9e53aab5b3 xtensa/isa: fix build break if compiler without ISA - XCHAL_HAVE_THREADPTR support
common/xtensa_context.S: Assembler messages:
common/xtensa_context.S:134: Error: invalid register number (231) for 'rur' instruction
common/xtensa_context.S:283: Error: invalid register number (231) for 'wur' instruction
clang-10: error: Xtensa-as command failed with exit code 1 (use -v to see invocation)
make[1]: *** [Makefile:143: xtensa_context.o] Error 1
make[1]: *** Waiting for unfinished jobs....

Signed-off-by: chao an <anchao.archer@bytedance.com>
2025-07-21 12:56:31 +02:00
Filipe Cavalcanti
7807109524 tools/ci: temporarily disable test of esp32-devkitc:nxlooper
Signed-off-by: Filipe Cavalcanti <filipe.cavalcanti@espressif.com>
2025-07-18 14:55:52 -03:00
Michal Lenc
e96ef8abe3 drivers/ioexpander/icjx.c: reconfigure icjx after undervoltage
According to a reference manual, VCC and VDD undervoltage
and VDD burst leads to the reset of all registers.
Therefore we have to reconfigure the expander to make
it functional again.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2025-07-18 12:08:39 -03:00
wangmingrong1
cbdc1a4108 toolchain/arm/clang: fix nuttx_find_toolchain_lib function error
Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com>
2025-07-18 22:37:36 +08:00
wangmingrong1
359c65543c tools/ci: Compile mps3-an547/gcov with clang using cmake in ci
armv8m ci:
1. use makefile clang: /arm/mps/mps3-an547/configs/clang,CONFIG_ARM_TOOLCHAIN_CLANG
2. use cmake clang: CMAKE,mps3-an547:gcov

Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com>
2025-07-18 22:37:36 +08:00
wangmingrong1
5f5eeda55a compiler-rt/cmake: Fix compilation error
The target is wrong

Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com>
2025-07-18 22:37:36 +08:00
wangmingrong1
d3dd43cb59 arch/arm32v8m/cmake: Fix clang's error in specifying cfg and target
1. -target should be in front, otherwise clang will not be able to find the corresponding libgcc.a
2. When using clang++ compiler to link, you also need to specify the corresponding arch, otherwise ld.lld will report an error due to arch mismatch.

Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com>
2025-07-18 22:37:36 +08:00
simbit18
be0057c928 ci/platforms/darwin_arm64.sh: bump Xtensa ESP32|S2|S3 toolchain
Bump Xtensa esp-14.2.0_20241119
2025-07-18 22:36:29 +08:00
simbit18
5b3c5ac667 ci/platforms/darwin.sh: bump Xtensa ESP32|S2|S3 toolchain
Bump Xtensa esp-14.2.0_20241119
2025-07-18 22:36:29 +08:00
simbit18
47c6ed0b23 ci/platforms/msys2.sh: bump Xtensa ESP32|S2|S3 toolchain
Bump Xtensa esp-14.2.0_20241119
2025-07-18 22:36:29 +08:00
simbit18
26c36f243a ci/platforms/ubuntu.sh: bump Xtensa ESP32|S2|S3 toolchain
Bump Xtensa esp-14.2.0_20241119
2025-07-18 22:36:29 +08:00
simbit18
983c832572 ci/platforms/linux.sh: bump Xtensa ESP32|S2|S3 toolchain
Bump Xtensa esp-14.2.0_20241119
2025-07-18 22:36:29 +08:00
nuttxs
d1fababfc5 arch/xtensa: esp32(s3)_async_op() using nxsem_wait(), threads may
return early due to signal interruption (EINTR). This makes the
main thread think the async operation is done, but the background
worker thread is still running—risking access to freed memory,
race conditions, crashes or undefined behavior.

Using nxsem_wait_uninterruptible():the main thread waits until the
worker thread finishes, preventing these issues.

Signed-off-by: nuttxs <zhaoqing.zhang@sony.com>
2025-07-18 22:34:13 +08:00
Windsor Schmidt
1e6289b543 style: fix spelling in documentation 2025-07-18 15:21:08 +08:00
wangmingrong1
1bdbf0effd toolchain/arm64/cmake: Corrected the writing of arm64 cmake search library
Align the writing style of arm cmake, and each compiler defines its own find library
function, otherwise use the default

Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com>
2025-07-17 19:17:55 +08:00
Filipe Cavalcanti
bc8ce393cb documentation: update docs on SDMMC for ESP32C3|C6|H2
Adds sdmmc_spi defconfig documentation for ESP32C3, ESP32C6 and ESP32H2 boards.

Signed-off-by: Filipe Cavalcanti <filipe.cavalcanti@espressif.com>
2025-07-16 10:24:21 -03:00
Filipe Cavalcanti
bd18bda0d7 boards/risc-v: add SDMMC defconfigs for ESP32C3|C6|H2
Adds defconfig to support SDMMC over SPI for esp32c3-generic, esp32c6-devkitc,
esp32c6-devkitm and esp32h2-devkit.

Signed-off-by: Filipe Cavalcanti <filipe.cavalcanti@espressif.com>
2025-07-16 10:24:21 -03:00
Filipe Cavalcanti
6f19c59d26 boards/risc-v: add support for SD Card over SPI on ESP32-C3|C6|H2
Add board support for SD Card over SPI for ESP32C3, ESP32C6 and ESP32H2.

Signed-off-by: Filipe Cavalcanti <filipe.cavalcanti@espressif.com>
2025-07-16 10:24:21 -03:00
chao an
7352e8ebfa arm64/qemu: decouple qemu board from chip
decouple qemu board from chip to support custom boards

Signed-off-by: chao an <anchao.archer@bytedance.com>
2025-07-16 10:12:57 -03:00
George Poulios
589c0e13b8 drivers/misc/optee: Cache coherency when MMU is disabled
When the MMU is disabled (CONFIG_ARCH_USE_MMU=n) the
data passed back and forth with the TEE needs to be
synced from/to the cache, otherwise we get random data
in either world.

Fix this by cleaning before a call and invalidating after.
This has to be done both on the optee msg arg, and the shm
buffers therein. Cleaning and invalidating the page list
used to describe non-contiguous shm buffers did not seem
mandatory in my tests, but common sense says that it should
be, so we do that too.

This fix does not apply to the optee msg arg of the socket
transport (optee_socket.c), as that one _should_ be handled
by the socket send/recv methods. It does apply to all shm
buffers though, regardless of transport.

Signed-off-by: George Poulios <gpoulios@census-labs.com>
2025-07-16 15:35:00 +08:00