Remove the previous guard logic and use a proper CMake
`exclude` rule to prevent `cxx-oot-build` from being
included when building projects with CMake.
* Ensures OOT test project is not pulled into normal apps.
* Keeps CI and export tests isolated from regular builds.
Signed-off-by: trns1997 <trns1997@gmail.com>
This commit adds CMUX (GSM 07.10) protocol support to netutils.
CMUX allows multiplexing multiple virtual serial connections
over a single physical serial link.
Changes include:
- CMUX protocol implementation
- CRC table for frame validation
- Basic frame handling
Signed-off-by: Halysson <halysson1007@gmail.com>
Add the source content for the out-of-tree build test
under `apps/testing/cxx-oot-build`. This supports the
new CI check in NuttX to prevent regressions in the
`make export` workflow.
The test project provides:
* Sample OOT build structure.
* Integration with exported `nuttx-export`.
* Verification of successful build and link.
Signed-off-by: trns1997 <trns1997@gmail.com>
This commit marks the end of my GSoC 2025 project in the NuttX section.
All changes:
- Silicon Heaven protocol (SHV) implementation:
The library is cloned from github.com/silicon-heaven/shv-libs4c
and compiled here. The library has out-of-the-box support
for NuttX and possibly all posix systems.
The library is compiled with CONFIG_SHV_LIBS4C_PLATFORM define
set to "nuttx". The library's dependancy is Pavel Pisa's ULUT
and originates from Michal Lenc's GSoC.
- examples/shv-nxboot-updater:
An example which constructs a SHV tree with which you can perform
firmware updates using a SHV "file node". The file node wraps
around NXBoot's update partition.
The application also allows for NXBoot confirmation of the images.
This application is to be meant used as a "background service",
started before any apps, possibly using rcS. The tree is allocated
as GAVL (see below).
- examples/shv-test:
An example which constructs a SHV tree and gives the user
the ability to choose which type of construction should be used,
either:
- GAVL: dynamic SHV tree allocation encapsulated within
an AVL tree.
- GSA: dynamic SHV tree allocation encapsulated within
a continuous array with binary search
- GSA_STATIC: SHV tree is defined as static const, this means
all the data structures are placed in .rodata.
Extremely beneficial for embedded systems,
as .rodata is located in flash and embedded
systems usually have more flash than sram,
thus reducing sram usage. The downside is that
the definitions are rather tedious, but can
be automated in case of some code generation
(like in pysimCoder).
All of it is places in a continuous array with
binary search.
Signed-off-by: Stepan Pressl <pressl.stepan@gmail.com>
The NSH exits when a command exits with a non-zero status, even if the "e" flag is not set.
This error does not exist in NSH scripts.
Without this patch:
nsh> sh -c "set -e; mkdir /test; echo $?"
nsh: /test: mkdir failed: 17
nsh> sh -c "set +e; mkdir /test; echo $?"
nsh: /test: mkdir failed: 17
nsh> rm /test
nsh> sh -c "set +e; mkdir /test; echo $?"
0
With this patch:
nsh> sh -c "set -e; mkdir /test; echo $?"
nsh: /test: mkdir failed: 17
nsh> sh -c "set +e; mkdir /test; echo $?"
nsh: /test: mkdir failed: 17
1
nsh> rm /test
nsh> sh -c "set +e; mkdir /test; echo $?"
0
Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
- Put sercon and serdis in separate source files, so that the main
functions can be compiled in also in kernel build.
- Don't store the ttyacm handle in the application, it is stored
in kernel side in case of the system_cdcacm
Signed-off-by: Jukka Laitinen <jukka.laitinen@tii.ae>
Fix format string not appropriate warning for cause.flag.
nsh_syscmds.c: In function 'cmd_reset_cause':
nsh_syscmds.c:513:24: error: format '%lu' expects argument of type 'long unsigned int', but argument 4 has type 'uint32_t' {aka 'unsigned int'} [-Werror=format=]
513 | nsh_output(vtbl, "%s(%lu)\n",
| ^~~~~~~~~~~
514 | g_resetcause[cause.cause], cause.flag);
| ~~~~~~~~~~
| |
| uint32_t {aka unsigned int}
Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
Previously `dd` clobbered its output by writing status messages (e.g.
transfer statistics) to stdout.
Now all status messages are written to stderr.
Signed-off-by: Lars Kruse <devel@sumpfralle.de>
Add a new config: NSH_BUILTIN_AS_COMMAND.
Provide a new implementation for nsh_builtin
when CONFIG_NSH_BUILTIN_APPS_AS_COMMAND is enabled.
Signed-off-by: Chengdong Wang <wangchengdong@lixiang.com>
Update NimBLE to the latest master. This includes fixing the debug log control,
which was broken since:
da4e2f0f12
The debug log was always enable and it wasn't possible to disable it.
Signed-off-by: raiden00pl <raiden00@railab.me>
This commit implements the loopback mode for the i2schar example
application. This mode - available only when both RX and TX are
enabled - allows the user to test the I2S buses when the TX pin is
connected to the RX pin. This is done by pre-filling a buffer with
known data (additionally, it checks the peripheral's data width to
format the data in the buffer accordingly) and passing it for both
the transmitter and the receiver threads. This buffer is written to
the TX and the received buffer is compared to the known buffer.
Signed-off-by: Tiago Medicci <tiago.medicci@espressif.com>
Following steps led to incorrect behavior:
- upload update image
- restart device and perform the update
- upload the same update image again without confirming
This led to the unwanted confirm of the update image. This change
ensures the update image is not confirmed by uploading the same
image to the update slot. The correct behavior is to perform revert
to the last stable image if this occurs.
Signed-off-by: Michal Lenc <michallenc@seznam.cz>
Although I personally prefer the former, at least one reviewer
preferred the latter. I coundn't find project-wide preferences.
Anyway, this is not important for me.
Signed-off-by: YAMAMOTO Takashi <yamamoto@midokura.com>
while this is not a goal for this repository,
it's convenient for me (hopefully for some others too)
to be able to build this for other platforms.
an obvious downside is to have a few more ifdefs.
tested with:
```
/opt/wasi-sdk-25.0/bin/clang -Wall -Oz -s -o dd.wasm dd_main.c
```
Signed-off-by: YAMAMOTO Takashi <yamamoto@midokura.com>
Add a new example that shows how to read a sample from
an ADS7046 ADC sensor registered on the SPI bus.
Signed-off-by: Niccolò Maggioni <nicco.maggioni+nuttx@gmail.com>
Add a new example that shows how to read the temperature from a
TMP112 sensor registered on the I2C bus.
Signed-off-by: Niccolò Maggioni <nicco.maggioni+nuttx@gmail.com>
rebinding (T2) time from DHCP packet.
According to RFC 2131, T1 and T2 times play a critical role in lease
management in DHCP clients.
Signed-off-by: nuttxs <zhaoqing.zhang@sony.com>
Add parent process ID support for command ps,
get from "/proc/<PID>/group/status:Parent".
For example
nsh> sh
nsh> ps
PID PPID GROUP CPU PRI POLICY TYPE NPX STATE EVENT SIGMASK STACK COMMAND
... ...
3 0 3 --- 100 RR Task - Waiting Signal 0000000000000000 0008136 nsh_main
... ...
9 3 9 0 100 RR Task - Running 0000000000000000 0004064 sh
nsh> sleep 100 &
sh [10:100]
nsh> ps
PID PPID GROUP CPU PRI POLICY TYPE NPX STATE EVENT SIGMASK STACK COMMAND
... ...
3 0 3 --- 100 RR Task - Waiting Signal 0000000000000000 0008136 nsh_main
... ...
9 3 9 0 100 RR Task - Running 0000000000000000 0004064 sh
10 9 10 --- 100 RR Task - Waiting Signal 0000000000000000 0004040 sh -c sleep
Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
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>
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>
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>
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>
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>
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.