Commit graph

8499 commits

Author SHA1 Message Date
Jorge Guzman
c19c2a71f3 netutils/xedge: refactor Makefile to use git clone instead of zip downloads
Previous zip-based approach was failing in CI environment. Changed to use
git clone with specific commit hashes to resolve CI build issues.

Signed-off-by: Jorge Guzman <jorge.gzm@gmail.com>
2025-08-02 10:00:20 -03:00
George Poulios
caefd0de9f tee/libteec, examples/optee_gp: Fix cmake build
Top level:
 - 'tee' subdirectory added to top-level CMakeLists.txt

tee/libteec:
 - BINARY_PREFIX defined PUBLIC to make it accessible to consumer
   apps
 - added missing DEBUGLEVEL definitions

examples/optee_gp:
 - added missing dependency to libteec

Signed-off-by: George Poulios <gpoulios@census-labs.com>
2025-08-02 09:59:21 -03:00
George Poulios
3ee6fdaf99 tee/libteec: Remove downloaded zip file on distclean
Initially, leaving the .zip around seemed like a good idea to
avoid re-downloading often. But it turns out deleting downloaded
packages during distclean is standard practice and some CI
scripts depend on the git local copy being clean, including
ignored files.

Change also CMakeLists.txt to download the zip instead of the
tarball.

Signed-off-by: George Poulios <gpoulios@census-labs.com>
2025-08-02 09:59:21 -03:00
Tim Hardisty
7506c026fa nxboot/loader: Fix boot progress calculation.
This patch corrects a mathematical error in the progress reporting function which
caused incorrect percentage progress calculations.

Signed-off-by: Tim Hardisty <timh@jti.uk.com>
2025-07-30 22:25:54 +08:00
makejian
08fdbb03bb mbedtls-alt: aligned alternative implementation return value with mbedtls
mbedtls interfaces overwritten by nuttx crypto driver, change return value of mbedtls interfaces from return value of nuttx crypto driver into starndard return value of mbedtls

Signed-off-by: makejian <makejian@xiaomi.com>
2025-07-30 15:41:50 +08:00
jingfei
4ecdb92e61 examples/mtdpart:Register MTD devices using the mtd_register method
1. 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. The new method is
   now changed to register_mtddriver

2. Some code for space release and deregistration has been added,
   and certain error handling methods have been updated.
2025-07-30 10:10:34 +08:00
Michal Lenc
8fbba09895 boot/nxboot/loader/boot.c: copy partition with blocksize large writes
The previous logic MAX(info_from.blocksize, info_where.blocksize) was
incorrect. The most effective access with by writing the entire
size of the block, therefore just decide the size based on the
target page size.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2025-07-28 18:21:46 +02:00
Michal Lenc
beacf792fa boot/nxboot/loader/flash.c: open partition with O_DIRECT flag
There is no need to use buffers in a bootloader. We expect a sequential
access, therefore we just need to erase the erase page before writing
to it for the first time, which is something FTL layer already takes
care of.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2025-07-28 18:21:46 +02:00
RTL
2de49b8b22 examples/xedge_demo: Add Xedge IoT Toolkit with BAS integration
Add support for Xedge, an embedded software toolkit for IoT applications
 using Lua scripting with HTTP(S), WebSockets, MQTT, and device I/O.

* netutils/xedge: Dependency manager that downloads BAS library
  and BAS-Resources, generates XedgeZip.c during build

* examples/xedge_demo: Complete example showing Xedge integration
  with HTTP server, Lua runtime, and SNTP time synchronization

Signed-off-by: Jorge Guzman <jorge.gzm@gmail.com>
2025-07-25 09:19:10 -03:00
Theodore Karatapanis
72668d7234 tee/optee_supplicant: Added optee supplicant
Support for extracting (from libteec), patching and compiling
optee_client/tee-supplicant by NuttX apps. Defaults to version
4.6.0 (same as the current libteec).

Enabled with:
CONFIG_OPTEE_SUPPLICANT=y
CONFIG_LIBTEEC=y

And the following for the nuttx kernel:

CONFIG_ALLOW_BSD_COMPONENTS=y
CONFIG_FS_ANONMAP=y
CONFIG_DEV_OPTEE_SMC=y
CONFIG_DEV_OPTEE_SUPPLICANT=y

The version of the supplicant needs to match the libteec version
since the patch to be applied might fail otherwise. If the versions
differ the build will be aborted.

More info:
 - https://github.com/OP-TEE/optee_client
 - https://optee.readthedocs.io/en/latest/architecture/secure_storage.html

Signed-off-by: Theodore Karatapanis <tkaratapanis@census-labs.com>
2025-07-25 17:31:12 +08:00
SPRESENSE
5e704891d9 netutils/esp8266: Add a function for finalization.
Add a function for finalization so that it can be used repeatedly.

Signed-off-by: SPRESENSE <41312067+SPRESENSE@users.noreply.github.com>
2025-07-22 15:04:36 +02:00
SPRESENSE
549836600c netutils/esp8266: Add to get channel from access points
Fix bug that channel retrieved by lesp_list_access_points is undefined.

Signed-off-by: SPRESENSE <41312067+SPRESENSE@users.noreply.github.com>
2025-07-22 15:04:36 +02:00
SPRESENSE
e61ee7981d netutils/esp8266: Fix bug to get gateway address
Fix bug to get gateway address.

Signed-off-by: SPRESENSE <41312067+SPRESENSE@users.noreply.github.com>
2025-07-22 15:04:36 +02:00
SPRESENSE
5429191ab0 netutils/esp8266: Fix nxstyle
Fix nxstyle.

Signed-off-by: SPRESENSE <41312067+SPRESENSE@users.noreply.github.com>
2025-07-22 15:04:36 +02:00
SPRESENSE
8b4a015f07 netutils/esp8266: Fix compile error
Fix compile error.

Signed-off-by: SPRESENSE <41312067+SPRESENSE@users.noreply.github.com>
2025-07-22 15:04:36 +02:00
Tiago Medicci
c83e17c083 interpreters/python: Fix symbol collision with list_length function
NuttX implements a function with the same name which may end up
being included whenever `CONFIG_MM_KERNEL_HEAP` is set. To avoid
it, insert a prefix to it on Python's implementation.

Please note that the other patches had their metadata updated too.
2025-07-22 14:18:23 +08:00
wangmingrong1
3f823f9f25 kasantest: -fno-builtin is enabled by default
The strlen function called by kasantest will be optimized by the compiler, and the strlen function implemented in NX will not be called. Adding -fno-builtin can solve the problem.

Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com>
2025-07-18 22:42:25 +08:00
wangjianyu3
f34ae4587a system/gdbstub: Add depends of LIB_GDBSTUB
in function `gdbstub_main':
undefined reference to `gdb_state_init'
undefined reference to `gdb_process'
undefined reference to `gdb_state_uninit'

Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
2025-07-18 22:42:03 +08:00
Kevin Witteveen (MartiniMarter)
6bca3c2ca2 Add JPEG compressor support to Makefile
Before this PR only the decompressor files were added to the Makefile.
Now all the required compressor files are added.
Decompression and compression tested on STM32H7 with 1:8 JPEG scaling.

Signed-off-by: Kevin Witteveen (MartiniMarter) <kevinwit1999@gmail.com>
2025-07-17 13:54:22 +08:00
Eren Terzioglu
f3e1985b1e games/snake: Change consolekey magic numbers with ASCII macros
Change consolekey magic numbers with ascii values to make it more understandable

Signed-off-by: Eren Terzioglu <eren.terzioglu@espressif.com>
2025-07-16 10:32:16 +08:00
Eren Terzioglu
9ea3fc6995 games/snake: Fix terminal issue after returning back from snake game
Fix terminal issue after returning back from game

Signed-off-by: Eren Terzioglu <eren.terzioglu@espressif.com>
2025-07-16 10:32:16 +08:00
Filipe Cavalcanti
d27d6e635f examples/mcuboot: add example to update from binary in local storage
This example makes it possible to use a binary from local storage for MCUBoot update.
It copies the binary file to the secondary slot instead of downloading from a remote URL.
Can be used to update from a SD Card, for example.

Signed-off-by: Filipe Cavalcanti <filipe.cavalcanti@espressif.com>
2025-07-16 09:49:45 +08:00
Alan Carvalho de Assis
a7e4a2a30e examples/keyboard: Fix compilation warning
Replace %d with %PRIu32 to avoid warning convered in error on CI.

Signed-off-by: Alan C. Assis <acassis@gmail.com>
2025-07-15 06:12:21 +08:00
nuttxs
dfeeef41ed netutils/dhcpc/dhcpc.c:Implement a dedicated interface to send
DHCPRELEASE, According to RFC 2131 section 3.1, DHCPRELEASE is
used by a client to relinquish a network address and cancel any
remaining lease time

Signed-off-by: nuttxs <zhaoqing.zhang@sony.com>
2025-07-14 15:49:29 -03:00
Petro Karashchenko
227d3ec35b netutils/nanopb: fix unpack step for MACOS
Currently NANOPB_UNPACK step in Makefile uses nanopb binary name with
hardcoded suffix '-linux-x86' that is not suitable for MACOS x86.
This commit replaces the hardcoded nanopb binary name with name that
is derived from NANOPB_NAME variable that reflects the nanopb binary
that is selected based on host OS selected in the build system

Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2025-07-14 15:48:08 -03:00
simbit18
29c88356e9 [CI] build.yml: fix ERROR: Dangerous symbolic link path was ignored
add Command Line Switch -snld

-snld ->  allow extracting of denagerous symbolic links.

https://sourceforge.net/p/sevenzip/discussion/45798/thread/187ce54fb0/

Signed-off-by: simbit18 <simbit18@gmail.com>
2025-07-13 07:05:09 +08:00
Eren Terzioglu
8b121eb138 games/match4: Add new match4 game
Add match4 game support

Signed-off-by: Eren Terzioglu <eren.terzioglu@espressif.com>
2025-07-12 08:38:32 -03:00
Niccolò Maggioni
0c680bcb8e system/coredump: Fix missing loglevel to logmask conversion.
The current setlogmask call used in the coredump app specifies a raw log level
instead of a bitmask, and this causes wrong evaluations later on when that value
is checked against a mask. Therefore the LOG_UPTO macro is added for conversion.

Signed-off-by: Niccolò Maggioni <nicco.maggioni+nuttx@gmail.com>
2025-07-09 09:54:40 +02:00
SPRESENSE
0037868ff0 examples/nximage: Rename program name to nximage
The original name is nxhello, which duplicates in examples/nxhello.

Signed-off-by: SPRESENSE <41312067+SPRESENSE@users.noreply.github.com>
2025-07-09 09:28:57 +02:00
Tim Hardisty
e6a335ded0 Fix Compiler warnings 2025-07-03 10:42:11 +08:00
Tim Hardisty
8c9e126f91 netutils/thttpd-fix-broken-CGI-and-fixup-Kconfig 2025-07-03 10:42:11 +08:00
wangjianyu3
c3e628c45a nshlib/md5: Support reading from standard input
Sometimes users may want to calculate the MD5 of part of a file(e.g. check
partition contents for debug after flashing, size of which may be greater
than image). This can be done with the "dd" command and pipes, the "md5"
command just needs to support reading from standard input. For example:
`dd if=/dev/virtblk0 bs=512 count=1 | md5`.

Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
2025-07-02 10:59:40 -03:00
Eren Terzioglu
ecd7b84871 games/snake: Enchacements for snake game
Add high score feature into snake game

Signed-off-by: Eren Terzioglu <eren.terzioglu@espressif.com>
2025-07-02 10:16:04 -03:00
Tang Meng
971a7374d6 examples/i2schar: fix spelling mistakes 2025-06-27 21:42:02 +08:00
Alan Carvalho de Assis
63c86438fb apps/can: Replace fprintf with dprint
This modification will remove the dependency on
CONFIG_FILE_STREAM, useful for small devices.

Signed-off-by: Alan C. Assis <acassis@gmail.com>
2025-06-27 09:41:29 +08:00
Jean THOMAS
c7b395e7da system/settings: Add spaces after each switch 'case' 2025-06-26 13:22:47 -03:00
Jean THOMAS
4be82876e4 system/settings: general code cleaning
* Remove duplicate checks, use switch/case whenever possible
* Remove assertions just before if () condition checking the exact
  same thing
* Replace if (condition) assert(0) with assert(condition)

Signed-off-by: Jean THOMAS <jean@lambdaconcept.com>
2025-06-26 13:22:47 -03:00
wangmingrong1
92c490579d gcov: Output mode judgment is implemented in the kernel layer
Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com>
2025-06-26 23:48:01 +08:00
wangmingrong1
dfbaedd5c2 gcov: Refactoring the implementation framework of gcov
All implementations of gcov are sunk to the kernel implementation
1. Support three dump modes: serial port output, single file output, standard output

Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com>
2025-06-26 23:48:01 +08:00
wangmingrong1
25d43c65db apps/gcov: Alloc to strip 0
Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com>
2025-06-26 23:48:01 +08:00
Jean THOMAS
bb508520f1 system/settings: fix assertion triggered by uninitialized variables
Fix non-NULL pointer assertion in `get_setting()` caused by
uninitialized pointer variables.

Signed-off-by: Jean THOMAS <jean@lambdaconcept.com>
2025-06-26 19:23:02 +08:00
wangjianyu3
c4ff19a7e4 system/fastboot: fix typos of response error log
Fix typos of sparse header comments and download/upload response error log.

Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
2025-06-25 10:01:27 +02:00
wangjianyu3
9df322d938 system/fastboot: add disconn for usb transport
Disconnect usbdev when deinit USB transport.

Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
2025-06-25 10:01:27 +02:00
wangjianyu3
4b5af957ac system/fastboot: remove interest and close epoll
Remove fds from the interest list and close epoll if need.

Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
2025-06-25 10:01:27 +02:00
Xiang Xiao
ee33688aca Fix /.github/ISSUE_TEMPLATE/001_bug_report.yml:122: Intertial ==> Inertial
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2025-06-24 22:19:00 +08:00
Brennan Ashton
f97274611f docs: Include released 10.x and 11.x versions under security policy.
Fixes #7514
2025-06-24 22:19:00 +08:00
Abdelatif Guettouche
f1b78948db .github/SECURITY.md: Fix a typo.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2025-06-24 22:19:00 +08:00
Brennan Ashton
b6f554c3e2 Add project GitHub Security Policy page
Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
2025-06-24 22:19:00 +08:00
Xiang Xiao
433765bbc8 .github/linters: Ignore E704 warning
since black and flake8 disagree on code style:
https://github.com/pyvista/pyvista/issues/5591

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2025-06-24 22:19:00 +08:00
xuxingliang
23d5abeb76 tools: make isort and black formatters to work together
Config multi line output to mode 3, so isort and black can agree with
each other:
```
3 - Vertical Hanging Indent

from third_party import (
    lib1,
    lib2,
    lib3,
    lib4,
)
```

Signed-off-by: xuxingliang <xuxingliang@xiaomi.com>
2025-06-24 22:19:00 +08:00