This commit enhances the bootloader capabilities. The image's header
is extended with header version, size, platform identifier and
pointer to optional next header. CRC32 now includes part of
the header in its calculation as well.
The change also avoids having two different magics for image uploaded
over programmer and update image. Both these images have the same
magic and this magic is changed internally by the bootloader's logic.
The change is needed because image with standard magic is automatically
considered as a confirmed image (uploaded with programmer).
The current implementation avoids tails at all, therefore the user
application uploading the image does not have to erase the tail before
new upload. The image is considered as confirmed if it has standard
magic or its recovery is present. This means the bootloader has to
erase the header of the update image after the update is done (to
avoid update loop and to mark the image as unstable). This page is
written back during the confirmation.
This is a breaking change, but necessary for the future development
of the bootloader. The added header version field will allow to
add minor/major updates while keeping the backwards compatibility.
Signed-off-by: Michal Lenc <michallenc@seznam.cz>
Co-authored-by: Pavel Pisa <pisa@fel.cvut.cz>
Co-authored-by: Karel Koci <cynerd@email.cz>
Summary:
In function 'performance_gettime',
inlined from 'hpwork_performance' at osperf.c:245:10:
osperf.c:123:3: error: 'result.end' may be used uninitialized [-Werror=maybe-uninitialized]
123 | up_perf_convert(result->end - result->start, &ts);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
osperf.c: In function 'hpwork_performance':
osperf.c:228:29: note: 'result.end' was declared here
228 | struct performance_time_s result;
| ^~~~~~
CC: audio/lib_buffer.c
CC: common/arm64_initialize.c
CC: builtin/lib_builtin_getname.c
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
Summary:
In the case of slow overall system response (such as when MM_KASAN is turned on), the nxevent case work thread will not be executed and will be switched back to the main thread, so that the event does not get the expected result and the case fails.
By adjusting the thread priority, the work thread can be scheduled to avoid the expected result failure
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
Without the -q (--quiet) option, the program outputs the thread
stats every 100ms, which is compatible with the original
rt-tests/cyclictest utility.
Signed-off-by: Stepan Pressl <pressl.stepan@gmail.com>
In the previous changes to the apps/testing folder, I added an extra slash in the make.defs of uclibcxx, atomic.
Signed-off-by: tengshuangshuang <tengshuangshuang@xiaomi.com>
the included changes are:
```shell
spacetanuki% git log --pretty=oneline v65.0.0..v66.0.0
b0e100a4ebd666f02b2bb9222d402a9f399a740b (tag: v66.0.0) wapm.toml: bump the version
7604b9b896d7f48c46e484f560bbc679a87b0241 LICENSE: new year
c674c030025aab4cac94962328ae69590c5f1367 test/spectest.wat: update to match the spec harness
a5cf6bda2b2e022775d4d2d54aa11afc2e1295c2 test/fetch-spec-test.sh: update wasm-spec-test
c97f2d8e9e19d586d46b5db48a0582f374796d12 test/prepare-spec-test.sh: bump https://github.com/WebAssembly/multi-memory
b5f75600df812c421855ab7008b13113658af1c4 test/prepare-spec-test.sh: bump https://github.com/WebAssembly/spec version
1bfdc750dc18d085ac739a629b8b12b7ed9d9f6b escape.c: fix an integer overflow issue, especially on 32-bit archs
e15be49961d32e1878bfea399fd9cd609ff94045 escape.c: fix a comment
spacetanuki%
```
for nuttx-apps, only the escape.c fix is important.
Signed-off-by: YAMAMOTO Takashi <yamamoto@midokura.com>
Despite the existence of the patch in benchmarks/rt-tests,
this commit adds the NuttX Official cyclictest utility.
The main difference is the introduction of different
waiting methods next to POSIX clock_nanosleep:
- The thread can wait for a g_waitsem, posted by board_timerhook()
if CONFIG_SYSTEMTICK_HOOK is defined.
Since the semaphore is only one, only one thread can wait.
- The thread can wait for a Timer Device to timeout.
The timer's timeout determines the waiting time of the thread.
Since the timer is only one, again, only one thread can wait.
The user can measure the elapsed time using clock_gettime
or the timer device itself. The different waiting and measuring
methods were introduced because NuttX, by default, does not
offer fine measuring capabilities using POSIX time functions
(as of Feb 25).
Signed-off-by: Stepan Pressl <pressl.stepan@gmail.com>
The debugpoint program has an option "-l" which requires an argument,
which means the optstring to getopt() should be "l:".
Signed-off-by: chenxiaoyi <chenxiaoyi@xiaomi.com>
fix Relative file path does not match actual file.
EOL Conversion -> Unix (LF)
Adding the message header to the Kconfig file
Signed-off-by: simbit18 <simbit18@gmail.com>
This commit add include necessary when we enable network debug feature using ppp feature.
Signed-off-by: Felipe Moura de Oliveira <moura.fmo@gmail.com>
fix this error
make[3] *** /nuttxspace/nuttx/apps/testing/irtest: No such file or directory. Stop.
error due to this change
apps/testing: Move irtest/sensortest/resmonitor/monkey to apps/system #2976
Signed-off-by: simbit18 <simbit18@gmail.com>
embedlog.h were residing in include/system path, but has been
moved to include/logging. This causes psmq to not be able to
find <embedlog.h> include, which results in compilation error
Signed-off-by: Michał Łyszczek <michal.lyszczek@bofc.pl>
The PR https://github.com/apache/nuttx-apps/pull/2974 first moved
it to `testing/sched/cpuload` and the Make.defs was adjusted
accordingly. However, during the review process, it was moved to
`system/cpuload` folder, but its Make.defs wasn't updated. This
commit fixes it.
Signed-off-by: Tiago Medicci <tiago.medicci@espressif.com>
This commit also adds the check for the `__NuttX__` macro to the
patch file that allows setting an attribute to the `_PyRuntime`
structure. The `__NuttX__` macro is guaranteed to be present when
building any application for NuttX.
fix crash if:
CONFIG_SCHED_WAITPID=n
CONFIG_SCHED_CHILD_STATUS=y
The old signal will be restored only when sigaction is saved to avoid invaild access.
Signed-off-by: chao an <anchao.archer@bytedance.com>
This change prevents users from trying to use the `uorb_listener`
application without having floating point printing enabled on systems
that do not have an FPU (systems with FPUs have `LIBC_FLOATINGPOINT`)
enabled by default. Solution dicussed and agreed in:
https://github.com/apache/nuttx/issues/15599.
This application test the libc's `wcstombs` function for different
len sizes (bigger than the converted string, exactly the size of
it and smaller than it).
This wrapper application checks if the Python's modules are already
mounted (and mounts them, if not), sets the necessary environment
variables and, then, runs the Python interpreter.
The `Setup.local` and the `config.site` files are used by Python's
build system to, respectively, enable or disable Python's modules
and set/unset available functions in the target system. These files
are now set according to NuttX's configs, enabling or disabling
Python's features according to the configs set on NuttX.
By setting a specific region for the `_PyRuntime` structure, it is
possible to move it to the external memory, for instance, freeing
the internal memory (this structure occupies around 140KiB).
Summary:
- Added a basic Slint example for NuttX, demonstrating how to integrate Slint UI framework with Rust on NuttX
- Includes a simple UI with a counter and touchscreen input handling
- Provides CMake, Kconfig, and Makefile configurations for building the example
Impact:
- Introduces a new example showcasing Slint UI framework usage on NuttX
- Enables developers to explore Rust-based UI development on embedded systems
- Demonstrates integration with NuttX framebuffer and touchscreen drivers
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
Summary:
- Added support for x86 and x86_64 architectures in the Rust build system
- Updated `nuttx_rust_target_triple` function in `cmake/nuttx_add_rust.cmake` to handle x86 and x86_64 target triples
- Updated `RUST_TARGET_TRIPLE` macro in `tools/Rust.mk` to include x86 and x86_64 target triples
Impact:
- Enables Rust crate compilation for x86 and x86_64 platforms
- No functional changes for existing architectures (ARM, RISC-V, etc.)
- Improves platform compatibility and expands Rust support in NuttX
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>