Commit graph

3742 commits

Author SHA1 Message Date
Ioannis Karachalios
221c4d3e4d tests: pwm_loopback: Fix inverted pulse measurement deviation
For the inverted pulse measurements, that should reflect
the duty-cycle off interval, the 1% deviation in test_capture
should be adjusted so it reflects duty-cycle off.

Signed-off-by: Ioannis Karachalios <ioannis.karachalios.px@renesas.com>
2024-12-03 13:06:53 +01:00
Ioannis Karachalios
b1e863e3e7 tests: pwm_loopback: Capture disable omission issue
As per the PWM API definition, -EBUSY should be returned
when pwm_enable_capture is called and capturing
is already enabled. This commit deals with adding
a ztest_suite_before_t function that should disable
capturing at the end of a single test. Some tests, though,
such as test_pulse_capture, execute two sub-tests
and so, capturing is disabled in between. In fact, the omission
of pwm_disable_capture should not only result in aborting
a single test, but it can also raise system exception
due to invalid context. This is the case for
z_impl_pwm_capture_cycles where z_pwm_capture_cycles_callback
can be fired whilst the routine has already aborted and so
struct z_pwm_capture_cb_data data, defined within function
declaration, should not longer be valid.

Signed-off-by: Ioannis Karachalios <ioannis.karachalios.px@renesas.com>
2024-12-03 13:06:53 +01:00
Iacopo Moles
bd69ae46bc boards: waveshare: rp2040_zero: Initial support
This PR adds supports for Waveshare RP2040 Zero

Signed-off-by: Iacopo Moles <iacopo@icpmol.es>
2024-12-03 10:17:49 +01:00
Neil Chen
80361b8fe0 tests: dac: frdm_mcxa156: add dac test support
add frdm_mcxa156 defines in source

Signed-off-by: Neil Chen <cheng.chen_1@nxp.com>
2024-12-03 08:27:08 +01:00
Pieter De Gendt
9dd07da0a1 drivers: flash: Place API into iterable section
Add wrapper DEVICE_API macro to all flash_driver_api instances.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2024-12-02 22:08:48 +00:00
Pieter De Gendt
d0d8158280 tests: drivers: regulator: Test not implemented APIs with dummies
Instead of writing to existing fake APIs, use dummy devices with empty
APIs. This allows us to place APIs in ROM.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2024-12-02 22:08:41 +00:00
Pieter De Gendt
0668151a2f drivers: ipm: Place API into iterable section
Add wrapper DEVICE_API macro to all ipm_driver_api instances.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2024-12-02 22:07:08 +00:00
Manuel Argüelles
4ab9172c92 dts: bindings: rename nxp,imx-lpspi compatible
Rename "nxp,imx-lpspi" compatible to "nxp,lpspi" to remove the
device family from its name.

Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
2024-12-02 22:06:47 +00:00
Manuel Argüelles
dbd20bd039 dts: bindings: rename nxp,kinetis-wdog32 compatible
Rename "nxp,kinetis-wdog32" compatible to "nxp,wdog32" to remove the
device family from its name.

Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
2024-12-02 22:06:39 +00:00
Pieter De Gendt
a553af738d drivers: sensor: Place API into iterable section
Add wrapper DEVICE_API macro to all sensor_driver_api instances.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2024-12-02 22:04:55 +00:00
Piotr Kosycarz
91dfe8f076 tests: drivers: gpio: gpio_basic_api: restore support for nrf54l15 flpr
Missing after PDK->DK.

Signed-off-by: Piotr Kosycarz <piotr.kosycarz@nordicsemi.no>
2024-12-02 01:33:15 +01:00
Pieter De Gendt
122eb71dda tests: drivers: build_all: Add CMake linker test for ADC
Add a test case where CONFIG_CMAKE_LINKER_GENERATOR is enabled.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2024-11-29 14:50:40 +01:00
Francois Ramu
1680887051 tests: drivers: clock control stm32 adc device clock setting
Tests the ADC clock domain on the stm32g0 serie
Possible ADC clock sources are SYStem clock (default) or PLL_P.
No clock source HSI for the ADC tested here.

Signed-off-by: Francois Ramu <francois.ramu@st.com>
2024-11-29 14:50:29 +01:00
Gerard Marull-Paretas
9465610d9f samples, tests: lora: remove CONFIG_SPI|GPIO=y
This is no longer needed, drivers selects SPI and GPIO as needed.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-11-28 20:53:11 +01:00
Benedikt Schmidt
760210f39d drivers: fpga: separate drivers of iCE40 for SPI and GPIO bitbang
Separate the current driver for the FPGA iCE40 into two different ones.
One implements only the SPI load mode, the other one only the GPIO
bitbang mode.

Signed-off-by: Benedikt Schmidt <benedikt.schmidt@embedded-solutions.at>
2024-11-28 15:39:33 +00:00
Piotr Kosycarz
5ae4f11c93 tests: drivers: enable more tests for nrf54l10 and nrf54l05
counter_basic_api, i2s_api, i2s_speed, uart_async_api

Signed-off-by: Piotr Kosycarz <piotr.kosycarz@nordicsemi.no>
2024-11-28 09:42:58 +01:00
Michał Stasiak
02bb624c31 tests: drivers: watchdog: disable DCACHE for nRF54H20dk
Disabled data caching for nRF54H20dk in wdt_basic_api test.
It caused variables stored in noinit section to be cached,
resulting in reset loop.

Signed-off-by: Michał Stasiak <michal.stasiak@nordicsemi.no>
2024-11-27 10:38:52 -05:00
Jilay Pandya
719cd2639c drivers: stepper: refactor set_actual_position to set_reference_position
This commit refactos set_actual_position to set_reference_position.
stepper_set_reference_position is more apt in regards to what this func
actually does

Signed-off-by: Jilay Pandya <jilay.pandya@outlook.com>
2024-11-27 10:29:47 +01:00
Gerson Fernando Budke
cffb66f5c6 drivers: rtc: sam: Add platform on API test coverage
The #81456 fixed the driver issue related to issue #81454. This add
the RTC configurations on sam_v71_xult board to enable test coverage.

Fixes #81454

Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
2024-11-27 08:17:37 +01:00
TOKITA Hiroshi
b16b161d1f tests: drivers: build_all: Add a build_all test for usb
The test targets the following devices at this time.

- diodes,pi3usb9201
- maxim,max3421e_spi

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
2024-11-26 15:44:52 -05:00
Dat Nguyen Duy
56cd16efbd dts: nxp: s32ze: add devicetree node for code RAM
Add devicetree node for code RAM, code RAM can be accessed
over AIXM bus or AXIF bus. Code access via AXIF interface
provides the best optimal performance

Signed-off-by: Dat Nguyen Duy <dat.nguyenduy@nxp.com>
2024-11-26 15:43:45 -05:00
Dmitrii Golovanov
19ae672026 tests: drivers: sensor: Don't duplicate output
Don't duplicate the test's output running it on `native_sim` after
`LOG_BACKEND_NATIVE_POSIX` was enabled by default (bd9836be8c)

Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
2024-11-26 15:41:33 -05:00
Krzysztof Chruściński
eae3891303 tests: drivers: uart: uart_elementary: Add runtime PM configuration
Add configuration that uses device runtime PM.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2024-11-26 10:36:21 +00:00
Anas Nashif
b207035851 tests: add integration_platforms and misc optimizations
Add integration_platforms to many tests that use platform_allow to
manage scope of pull_request CI.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2024-11-26 00:12:07 +01:00
Jerzy Kasenberg
1d4b1ade43 tests: drivers: spi: Fix nrf52840 overlay
spi-max-frequency was missing in overlay

Now it's set to 8 MHz as per datasheet

Signed-off-by: Jerzy Kasenberg <jerzy.kasenberg@codecoup.pl>
2024-11-25 17:43:48 +01:00
Jerzy Kasenberg
75d3f45d5a tests: drivers: spi: spi_slave: Fix memory corruption
This fixes memory corruption of delayable work when
tests executes unsupported function.

When test (e.g. only_rx_in_chunks) is executed it starts
delayed work for master functionality (with 10 ms delay).
Later when slave function is tried and reports that
function is unsupported, test is terminated (task ends)
but work is still scheduled.

When next test starts it clears work that is already
scheduled:

static void before(void *not_used)
{
	ARG_UNUSED(not_used);

	memset(&tdata, 0, sizeof(tdata));

this leads to memory corruption and system work queue
tries to remove work but it never does since head/next
pointers are zeroed at that time.

This just adds after function that cancels work
regardless if it was scheduled or not.

Signed-off-by: Jerzy Kasenberg <jerzy.kasenberg@codecoup.pl>
2024-11-25 17:43:48 +01:00
TOKITA Hiroshi
b7badee6aa tests: drivers: build_all: audio: Add config for st,mpxxdtyy
Add configuration to add `st,mpxxdtyy` to build test.

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
2024-11-25 12:16:53 +01:00
TOKITA Hiroshi
0bc0dd7767 tests: drivers: build_all: audio: Add i2c-devices to build test
Add build tests for the following devices.

- ti,tas6422dac
- ti,tlv320dac

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
2024-11-25 12:16:53 +01:00
Carles Cufi
b06bf51459 boards: nrf54l15dk: Enable tests and samples for the L05 and L10
This is a follow-up to 21475774fc,
extending the number of tests and samples that use the new L05 and L10.

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2024-11-25 10:08:07 +01:00
Pieter De Gendt
bf2db7afc0 python: Format and sort imports
ruff check --select I001 --fix applied to all python files that had
this as only issue.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2024-11-25 10:07:13 +01:00
Khoa Nguyen
8d7ae89c23 tests: drivers: spi: Support test spi_loopback for RA6, RA4, RA2
Add overlay and add config to support test spi_loopback for:
ek_ra6m1, ek_ra6m2, ek_ra6m3, ek_ra6m4, ek_ra6m5, ek_ra6e2,
fpb_ra6e1, fpb_ra6e2, ek_ra4w1, ek_ra4m2, ek_ra4m3, ek_ra4e2,
ek_ra2a1.

Signed-off-by: Tri Nguyen <tri.nguyen.wj@bp.renesas.com>
Signed-off-by: Thao Luong <thao.luong.uw@renesas.com>
Signed-off-by: Khoa Nguyen <khoa.nguyen.xh@renesas.com>
2024-11-25 01:02:35 +01:00
Dominik Ermel
021ef9e5c3 tests/flash/common: Set test device size for NRF platforms
Set expected size for nrf platforms.

Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
2024-11-23 15:30:10 +01:00
Dominik Ermel
a6ef37ca8e drivers/flash/spi_nor: Add flash_get_size API call
The commit adds implementation of flash_get_size.

Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
2024-11-23 15:30:10 +01:00
Dominik Ermel
c03f256fba tests/drivers/flash: Add test case for flash_get_size
Add flash_get_size commit and Kconfig option for test to set the
expected size of device.

Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
2024-11-23 15:30:10 +01:00
Dominik Ermel
852c992da5 tests/drivers/flash_api: Flash API tests
The commit adds test for flash_get_size.

Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
2024-11-23 15:30:10 +01:00
Daniel DeGrasse
c565c2c6f6 drivers: mipi-dbi: use string for mipi-mode property
Use a string for the mipi-mode property over an integer value, as this
significantly improves the readability of the MIPI DBI device binding.

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2024-11-23 02:01:47 +01:00
Erwan Gouriou
555d97ea3d tests: drivers: flash: common: Remove stm32 specific test
It's same test as "default", but more restrictive target wise.

Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
2024-11-22 17:43:54 +01:00
Erwan Gouriou
201a0b6ba9 test: drivers: flash: common: Copied size can't exceed page.size
flash_copy() is performed on a page.size span but following flash_read()
verification step is performed on EXPECTED_SIZE length (512).

This doesn't work on devices where page.size is lower than EXPECTED_SIZE,
such as STM32L1 where page size is 256.

To fix this, perform verification on the smalest value between page.size
and EXPECTED_SIZE.

Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
2024-11-22 17:43:54 +01:00
Alberto Escolar Piedras
9c386cab93 tests uart_pm: Enable for nrf54l15bsim
Enable this test in the simulated nrf5340 and provide
an appropriate overlay.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-11-22 11:34:30 +01:00
Alberto Escolar Piedras
eec736355c tests uart_mix_fifo_poll: Enable for nrf54l15bsim
Enable this test in the simulated nrf54l15 and provide
an appropriate overlay.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-11-22 11:34:30 +01:00
Alberto Escolar Piedras
dd2f4117e3 tests uart_async_api: Enable in nrf54l15bsim//cpuapp
Enable this test in the simulated nrf54l15 by providing
an appropriate overlay.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
2024-11-22 11:34:30 +01:00
Mahesh Mahadevan
21d0a3b699 tests: pwm: Add support for SCTimer PWM on FRDM-MCXN947
Add overlay files to enable test of PWM over SCTimer.

Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2024-11-21 19:22:07 -05:00
Krzysztof Chruściński
f235ddb2cf tests: drivers: uart: async_api: Add uart120 instance to nrf54h20dk
Add second instance to be tested on nrf54h20dk. uart120 is a fast UARTE
which works on fixed pin locations. It is not available for cpuppr core.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2024-11-21 20:12:13 +01:00
Krzysztof Chruściński
d2b69a4ec7 tests: drivers: uart: async_api: Rework for multi instance
Rework the test to be able to run on multiple instances.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2024-11-21 20:12:13 +01:00
Krzysztof Chruściński
bc007fd53b tests: drivers: uart: async_api: Add missing static keyword
Multiple variable in the test were missing static keyword.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2024-11-21 20:12:13 +01:00
Benedikt Schmidt
53ae195f0d drivers: fpga: replace runtime checks with buildtime asserts in iCE40
Replace NULL checks for the set and clear registers with BUILD_ASSERTs
in the iCE40 device instantiation.

Signed-off-by: Benedikt Schmidt <benedikt.schmidt@embedded-solutions.at>
2024-11-21 20:11:47 +01:00
Carles Cufi
21475774fc boards: nordic: nRF54L15DK: Add basic support for the L05 and L10 ICs
The nRF54L05 and nRF54L10 are identical to the nRF54L15 except for their
memory sizes. Add support for emulating those ICs on the nRF54L15DK.
This commit only adds support for the main application core. Support for
the FLPR core may be added later.

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2024-11-21 09:26:38 +01:00
Carles Cufi
e78832034f soc: nordic: Introduce the nRF54L05 and nRF54L10
These two new ICs are variants of the nRF54L15 with different memory
sizes:

- nRF54L05: 500KB RRAM, 96KB RAM
- nRF54L10: 1022KB RRAM, 192KB RAM
- nRF54L15: 1524KB RRAM, 256KB RAM

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2024-11-21 09:26:38 +01:00
Mara Furland
30fa48558e boards: qorvo: add DWM3001CDK support
Add support for the decawave DWM3001C board from qorvo

Signed-off-by: Mara Furland <mara@fur.land>
2024-11-20 10:16:58 +00:00
Jakub Wasilewski
8e881959a4 boards: hifive_unmatched: add support for S7 and U74 targets
Add `hifive_unmatched//s7` (earlier selected by default, using
`hifive_unmatched`) and `hifive_unmatched//u74` targets.

Define work-area for other 4 cores in openocd.cfg

Update twister platform white/black lists, to support new targets

Signed-off-by: Jakub Wasilewski <jwasilewski@internships.antmicro.com>
Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
2024-11-20 10:15:03 +00:00