Commit graph

16700 commits

Author SHA1 Message Date
Guillaume Ranquet
31510fb3bf drivers: dac: Add support for MAX22017 DAC
The MAX22017 is a two-channel industrial-grade software-configurable
analog output device that can be used in either voltage or current output
mode.

Signed-off-by: Guillaume Ranquet <granquet@baylibre.com>
2025-01-21 07:07:33 +01:00
Emil Gydesen
b361c9589f tests: Bluetooth: BAP: Add verification of receive state for the BA
The broadcast assistant will now validate the content of the
received receive states.

Some modifications were done to the tests to properly
pass these new validations.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-01-20 23:45:48 +00:00
Alberto Escolar Piedras
64d4fcd8cb tests/subsys/lorawan/frag_decoder: Change random seed
These tests are quite sensitive to the exact random sequence.
After a change of the native_sim entropy generation 2 of them
started failing. Let's set a random seed which avoids the failure.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2025-01-20 20:55:48 +01:00
Alberto Escolar Piedras
1ce3898832 tests pipe_api: Fix unitialized variable warning
Fix so the compiler does not throw a warning thinking that those
buffers may be used unitialized inside k_pipe_write/read().

Note clang does not the array size being of a variable size and
initialized as it throws a
"error: variable length array folded to constant array as an extension"

The issue was discovered with with gcc 14.2

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2025-01-20 20:55:18 +01:00
Aksel Skauge Mellbye
e4164963f2 boards: silabs: Add xG29-RB4412A radio board
Add radio board for EFR32MG29 device.

Signed-off-by: Aksel Skauge Mellbye <aksel.mellbye@silabs.com>
2025-01-20 16:34:50 +01:00
Krzysztof Chruściński
eda1b3f8f5 tests: drivers: gpio: gpio_basic_api: Add nrf54l09pdk support
Add overlay for nrf54l09pdk/nrf54l09/cpuapp target.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2025-01-20 16:28:14 +01:00
Tom Hughes
b35c3a64a5 tests: lib: smf: Add missing equals
When building with clang and -Wno-gnu it complains about the missing
equals:

tests/lib/smf/src/test_lib_hierarchical_5_ancestor_smf.c:415:8: error:
use of GNU 'missing =' extension in designator
[-Werror,-Wgnu-designator]

[P05] SMF_CREATE_STATE(p05_entry, p05_run, p05_exit, NULL, NULL),
      ^
      =

tests/lib/smf/src/test_lib_hierarchical_5_ancestor_smf.c:416:8: error:
use of GNU 'missing =' extension in designator
[-Werror,-Wgnu-designator]

[P04] SMF_CREATE_STATE(p04_entry, p04_run, p04_exit, &test_states[P05],
      ^                NULL),
      =

tests/lib/smf/src/test_lib_hierarchical_5_ancestor_smf.c:417:8: error:
use of GNU 'missing =' extension in designator
[-Werror,-Wgnu-designator]

[P03] SMF_CREATE_STATE(p03_entry, p03_run, p03_exit, &test_states[P04],
      ^                NULL),
      =

tests/lib/smf/src/test_lib_hierarchical_5_ancestor_smf.c:418:8: error:
use of GNU 'missing =' extension in designator
[-Werror,-Wgnu-designator]

[P02] SMF_CREATE_STATE(p02_entry, p02_run, p02_exit, &test_states[P03],
      ^                NULL),
      =

tests/lib/smf/src/test_lib_hierarchical_5_ancestor_smf.c:419:8: error:
use of GNU 'missing =' extension in designator
[-Werror,-Wgnu-designator]

[P01] SMF_CREATE_STATE(p01_entry, p01_run, p01_exit, &test_states[P02],
      ^                NULL),
      =

Signed-off-by: Tom Hughes <tomhughes@chromium.org>
2025-01-20 16:27:10 +01:00
Emil Gydesen
7d24771edc tests: Bluetooth: CSIP: Change the rs values of CSIP tests
Instead of using rs=1,2,3 and 4 we make it 10, 20, 30, 40 as the
other values could cause some connection issues.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-01-20 16:26:47 +01:00
Emil Gydesen
0e9a3e0e6c tests: Bluetooth: Audio: Use ext adv for all connectable adv
Most specs require the use of extended advertising, and most
tests used legacy advertising.

Implement a common function to create and start an extended
advertising set to reduce code duplication.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-01-20 16:26:47 +01:00
Piotr Krzyzanowski
09d5b9d80f tests: pwm: pwm_gpio_loopback: add nrf platforms
Add Nordic platforms and rename the defines
to avoid redefining a nrf driver internal symbols

Signed-off-by: Piotr Krzyzanowski <piotr.krzyzanowski@nordicsemi.no>
2025-01-20 16:26:21 +01:00
Samuel Chee
d8a1fd93e0 boards: arm: mps2: Add support for mps2/an500 in FVP
Added support for an500 in fvp.
Qualifier to build and run is mps2/an500.

Signed-off-by: Samuel Chee <samche01@arm.com>
2025-01-20 11:15:32 +01:00
Samuel Chee
bbe1f260a2 boards: arm: mps2: Add support for mps2/an386 in fvp
Added a support for new mps2 board an386 to enable testing with ARM FVP.
Qualifier to build/run application with board is mps2/an386.

Signed-off-by: Samuel Chee <samche01@arm.com>
2025-01-20 11:15:32 +01:00
Samuel Chee
8d6d4de79d boards: arm: mps2: Add support for mps2/an383
Added new mps2 board an383 to enable testing with ARM FVP.
Qualifier to build/run is mps2/an383

Signed-off-by: Samuel Chee <samche01@arm.com>
2025-01-20 11:15:32 +01:00
Yangbo Lu
ef7a0a481f tests: drivers: spi: support spi_loopback for imx95_evk m7
Added support for spi_loopback for imx95_evk m7.

Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
2025-01-20 09:21:00 +01:00
Hou Zhiqiang
c47bfa84a8 tests: counter_basic_api: add imx95 evk support
Add i.MX 95 EVK support for counter_basic_api test application.

Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
2025-01-20 02:58:28 +00:00
Vinayak Kariappa Chettimada
490da9ec96 tests: bsim: Bluetooth: Workaround overlapping ACL in BAP broadcast sink
Workaround by using `-start_offset` to ensure that the ACL
established does not overlap the sink being established.

The behavior between nrf52_bsim and nrf54l15bsim is
different where in the two device are starting to
advertising at the same time in nrf54l15bsim where as
there is an offset already in nrf52_bsim test.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2025-01-18 10:03:41 +01:00
Vinayak Kariappa Chettimada
31863fd8e3 tests: bsim: Bluetooth: nrRF53/54L: Throughput and multiple_id testing
Enable throughput and multiple_id testing on nRF5340bsim and
nrf54l15bsim.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
2025-01-18 10:03:41 +01:00
Raffael Rostagno
713375a51f tests: drivers: ledc_pwm: Add test cases
Add test cases to include coverage for ESP32 HS channels.

Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
2025-01-18 02:36:05 +01:00
Dat Nguyen Duy
82b3e2fc78 boards: s32z2xxdc2: add support PWM eMIOS
Add support PWM eMIOS for s32z2xxdc2 board. There is no LED
on-board dedicated for PWM, so no sample is supported. Only
enabling some pwm tests

Signed-off-by: Dat Nguyen Duy <dat.nguyenduy@nxp.com>
2025-01-18 02:32:50 +01:00
Dat Nguyen Duy
e72af321d5 drivers: emios_pwm: do not configure period, duty and polarity at boot
Removing period, duty and polarity configuration from
channel devicetree. At boot time, only minimal setup like
pinctrl, prescaler, etc should be initialized. PWM signal
is produced by using pwm_set* API

Also after this change, PWM period, duty are changed at the
next counter period boundary

Signed-off-by: Dat Nguyen Duy <dat.nguyenduy@nxp.com>
2025-01-18 02:32:50 +01:00
Måns Ansgariusson
0572f1f098 tests: Update tests to use new k_pipe API
Update tests to use the reworked k_pipe API.

Signed-off-by: Måns Ansgariusson <Mansgariusson@gmail.com>
2025-01-17 19:43:44 +01:00
Måns Ansgariusson
6782c5381d tests: kernel: pipe: Add new test cases for pipe API rework
This commit adds new test cases for the pipe API rework.
* basic.c: Sanity check for pipe operations.
* concurrency.c: Test pipe operations with multiple threads.
* stress.c: Test pipe operations under stress conditions.

And moves the old pipe test cases to the deprecated folder.

Signed-off-by: Måns Ansgariusson <Mansgariusson@gmail.com>
2025-01-17 19:43:44 +01:00
Sebastian Głąb
8f83267f9a tests: boards: nrf: hwinfo: Add test for reset cause on nrf54*
Add test that checks reset cause reported by HWINFO.

Check that hwinfo_get_supported_reset_cause() returns
expected value.

Check that hwinfo_get_reset_cause() correctly detects:
- RESET_PIN,
- RESET_SOFTWARE,
- RESET_WATCHDOG.

Check that reset cause can be cleared
with hwinfo_clear_reset_cause().

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
2025-01-17 16:36:09 +01:00
Joakim Andersson
7faafda9e7 tests: kernel: Test endian-specific buffer convert and copy functions
Test endian-specific buffer convert and copy functions.

Signed-off-by: Joakim Andersson <joerchan@gmail.com>
2025-01-17 13:56:33 +01:00
Joakim Andersson
2cee01678a test: drivers: modem: Add unit test for modem socket
Add unit test for modem socket context handling.

Signed-off-by: Joakim Andersson <joerchan@gmail.com>
2025-01-17 13:54:34 +01:00
Håvard Reierstad
fe923670a9 Bluetooth: Host: bsim: Refactor common files
This commit deals mainly with bsim tests which have `common.c/h` files.
It does the following changes:
* Use functionality from the `babbelkit` library for common functions
  related to flags, test progression (failing, passing etc.) and
  synchronization between two devices. Locally defined equivalents are
  removed.
* Remove the `common.c/h` containing only functionality that is provided
  by the `babblekit` library.
* Remove the `test_pre_init_f` and `test_tick_f` functions (commonly
  implemented as `test_init` and `test_tick`) from the modified tests.
  These functions are not needed as they were only used to fail the test
  if a device didn't complete the test within a certain time frame. This
  is already handled by the `sim_length` argument used in the test
  scripts.
* Changes use of `atol` to `strtol` as the prior is against Zephyr
  coding guidelines.

Signed-off-by: Håvard Reierstad <haavard.reierstad@nordicsemi.no>
2025-01-17 13:41:50 +01:00
Georgios Vasilakis
37c23deea1 tests: kernel: Increase MAX_THREAD_BYTES to 6
Increase the MAX_THREAD_BYTES from 5->6 to accomodate
for devices with an increased number of threads in the
tests schedule_api and dynamic_thread_stack.

Signed-off-by: Georgios Vasilakis <georgios.vasilakis@nordicsemi.no>
2025-01-17 10:42:10 +01:00
Fin Maaß
b10781ba45 arch: common: be able to use ROM_START_OFFSET on RISCV
be able to use ROM_START_OFFSET on RISCV.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
2025-01-17 09:07:45 +01:00
Qiang Zhang
97f4838953 samples: drivers/i2s: Support i2s example for NXP frdm_mcxn947
Support i2s example for NXP frdm_mcxn947

Signed-off-by: Qiang Zhang <qiang.zhang_6@nxp.com>
2025-01-17 02:13:01 +01:00
Sebastian Głąb
153f5b6382 samples: boards: nordic: coresight_stm: Fix nrfutil trace command
Latest version of nrfutil trace doesn't support setting
uart baudrate.
Remove --baudrate {baudrate_val} from command that executes nrfutil.

Also, combine pytest script for:
- samples.boards.nordic.coresight_stm,
- tests.boards.nrf.coresight_stm,
to minimize code duplication (fix compliance check R0801).

Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
2025-01-16 22:56:13 +01:00
Piotr Radecki
65f767f0e5 net: lib http: Added tests for Content-Range to http parser.
Three tests has been added for Content-Range functionality in http
parser:
- test_content_range_supplied: Checks if parser handles range correctly.
- test_content_range_asterisk_total: Checks if parser interprets
astersk as no total size supplied.
- test_double_content_range_error: Checks if parser rejects header with
repeated Content-Range field.

Signed-off-by: Piotr Radecki <piotr.radecki@jrdltd.co.uk>
2025-01-16 22:55:51 +01:00
Parthiban Veerasooran
70b84d58b3 tests: drivers: build_all: ethernet: update lan865x build test
- Remove PLCA paramaters from lan865x SPI device description.
- Add MDIO and internal PHY device description along with PLCA
  parameters in the PHY node.

Signed-off-by: Parthiban Veerasooran <parthiban.veerasooran@microchip.com>
2025-01-16 22:45:03 +01:00
Stine Akredalen
724d32cd7c Bluetooth: host: Add overlays for bsim tests
Removed similar prj.conf files and added overlays instead to avoid
duplicate code.
Renamed some test files for consistency.

Signed-off-by: Stine Akredalen <stine.akredalen@nordicsemi.no>
2025-01-16 22:44:27 +01:00
Krzysztof Chruściński
5e2b9980bc tests: kernel: timer: timer_behavior: Reduce tick frequency(nrf54l09pdk)
Test test_one_tick_timer_train was failing due not being able to
 execute enough 1 tick timeouts. Decrease system ticks frequency
 to make the test pass.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2025-01-16 22:40:16 +01:00
Peter Mitsis
1e87400bea tests: thread_apis: Add custom unmapped address
Adds a custom unmapped address for qemu_cortex_r5.

Fixes #79627

Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
2025-01-16 22:40:00 +01:00
Peter Mitsis
faef1ac9b6 tests: thread_apis: Make unmapped address configurable
Although many platforms may have an unmapped address in common,
this address will not be the same for all platforms. This commit
makes such an address configurable to get better coverage.

Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
2025-01-16 22:40:00 +01:00
Emil Gydesen
ed7c606cf8 tests: Bluetooth: Audio: Remove netcore logs from nrf53 BSIM
Removes the use of the debug.conf file when building the
tests for the nRF5340, as that will also enable logs and will
log every message between the two cores, making the logs very
verbose.

Copy the lines from debug.conf that we do want to keep
into the bsim specific conf file, and stop using the debug.conf
file.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-01-16 22:39:09 +01:00
Dmitrii Golovanov
ae90679f88 tests: benchmarks: thread_metric: Record measurements
Extentd 'benchmark.thread_metric' (tests/benchmarks/thread_metric)
test suite to collect benchmark measurements in Twister reports
as recordings parsed from the test's output: time period values
as well as errors.

Additionally, each test is executed until it makes at least 3
measurements to estimate variance.

Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
2025-01-16 22:38:51 +01:00
Dmitrii Golovanov
e63a513a93 tests: Adjust to Twister changes in recording feature
Adjust testcase.yaml files to changes in Twister schema which
now allows multiple recording patterns ('record: regex:').

Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
2025-01-16 22:38:51 +01:00
Emil Gydesen
9c5ed3b18f tests: Bluetooth: TMAP: Add missing FAIL if register fails
If the register fails it would just return, instead of failing
the test.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-01-16 22:38:40 +01:00
Jukka Rissanen
71911eb041 tests: net: arp: Use documentation IP address space
Use the 192.0.2/24 address space reserved for documentation.
No functional changes by this commit.

Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
2025-01-16 22:37:28 +01:00
Jukka Rissanen
2f10d7d816 net: ethernet: Set the ptype by the caller in send
Instead of setting the upper protocol type in ethernet_send()
by checking the protocol type bits, use the ptype that is already
set by the caller. This allows new protocol types to be supported
and makes the system extensible.

Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
2025-01-16 22:37:28 +01:00
Jilay Pandya
5c0b85d00f drivers: sensor: adltc2990 expose functions to public api
This commit replaces a hack where is_busy status of adltc2990 was
checked by fetching SENSOR_CHAN_ALL with a dedicated function
expose adltc2990_trigger_measurement function to public api

Signed-off-by: Jilay Pandya <jilay.pandya@outlook.com>
2025-01-16 22:36:30 +01:00
Wajdi ELMuhtadi
01d9861d71 drivers: sensor: wsen_pdus_25131308XXXXX: add sensor driver
Add wsen_pdus_25131308XXXXX driver with
the corrected name and compatibility with
the hal update as well as added new features..

Signed-off-by: Wajdi ELMuhtadi <wajdi.elmuhtadi@we-online.com>
2025-01-16 22:35:47 +01:00
Robert Lubos
7c50c0231c tests: net: http_server: core: Add tests for Server Error reply
Add tests cases verifying that the server replies with HTTP 500 Internal
Server Error reply in case of processing error.

Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
2025-01-16 14:52:10 +01:00
Robert Lubos
d32b21381b tests: net: http_server: core: Add tests for Method Not Allowed reply
Add tests cases verifying that the server replies with HTTP 405 Method
Not Allowed reply in case the client tries to access the resource with a
method it does not allow.

Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
2025-01-16 14:52:10 +01:00
Krzysztof Chruściński
9c91b38f8f tests: drivers: uart: mix_fifo_poll: Fix for nrf54h20dk//cpurad
Add check for status okay for dut2. Compilation was failing if dut2
existed but was disabled.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2025-01-15 19:08:54 +01:00
Chaitanya Tata
7532e73b40 tests: wifi: configs: Add a test for disable of advanced features
This feature is handy to free up some memory, so, make sure it always
builds.

Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
2025-01-15 19:06:22 +01:00
Emil Gydesen
eff93d268a Bluetooth: BAP: Add common capability check
Instead of having 2 separate and non-equal checks for
capabilities in ASCS and the Broadcast Sink, there is now
a single function in pacs.c that performs the
check.

This reduces code size and makes it easier to maintain.

Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
2025-01-15 19:04:31 +01:00
Jianxiong Gu
eefbed2184 tests: drivers: Add RT1715 driver
Add a build test to verify richtek,rt1715 driver builds correctly.

Signed-off-by: Jianxiong Gu <jianxiong.gu@outlook.com>
2025-01-15 19:03:27 +01:00