Since the driver knows how many samples it wants (because of the
watermark threshold), stick to that per event in order to facilitate
batches of N number of samples.
Signed-off-by: Luis Ubieda <luisf@croxel.com>
In order to allow the error-handling scheme to take action, instead
of crashing when asserts are enabled. Now possible since we have RTIO
error handling for streaming mode.
Signed-off-by: Luis Ubieda <luisf@croxel.com>
Similar pattern applied to other in-tree sensor drivers, where
preparing a set of SQEs for writing/reading on registers is a recurrent
syntax.
Signed-off-by: Luis Ubieda <luisf@croxel.com>
The IIS3DWB is a system-in-package featuring a 3-axis digital vibration
sensor with low noise over an ultrawide and flat frequency range.
The wide bandwidth, low noise, very stable and repeatable sensitivity,
together with the capability of operating over an extended temperature
range (up to +105 C), make the device particularly suitable for vibration
monitoring in industrial applications.
Datasheet: https://www.st.com/en/mems-and-sensors/iis3dwb.html
This driver is currently only supporting the polling-mode read_and_decode
APIs (both blocking and non-blocking).
This driver is based on stmemsc HAL i/f v2.9.1.
Signed-off-by: Armando Visconti <armando.visconti@st.com>
- Add the pdl-based version of the i2c driver for infineon devices
like the one found on the kit_psc3m5_evk board.
- In the pull request review it was decided that the
I2C_INFINEON_CAT1_ASYNC option was not needed. The driver would
always be interrupt driven. This meant that the existing driver
had to be updated as well.
Signed-off-by: Bill Waters <bill.waters@infineon.com>
The new nrf-802154 now has the updated API signatures. The migration
code is no longer needed.
Signed-off-by: Rafał Kuźnia <rafal.kuznia@nordicsemi.no>
Make the STM32 I2C transfer timeout configurable via Kconfig.
- Add CONFIG_I2C_STM32_TRANSFER_TIMEOUT_MSEC Kconfig symbol.
- Use this Kconfig value in both STM32 I2C drivers.
Tested on STM32WBA55CG.
Fixes: #95819
Signed-off-by: Pablo Bacho <pablobacho@gmail.com>
This IPM driver is not being used by SOF and is there simply for
a test which does not provide much additional value compared to
the existing host IPC tests. That IPM specific test has been
removed so there is no need to keep this driver in the tree.
This is in preparation to rewrite the host IPC driver to utilize
the IPC API. There is no need to maintain another driver that is
not being used in SOF.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Support reporting the reset cause for native_sim. The default is to
report POR (Power-On Reset). If CONFIG_NATIVE_SIM_REBOOT was enabled and
the system is rebooted using sys_reboot(), the reset cause is set to
SOFTWARE.
Signed-off-by: Tim Pambor <tim.pambor@codewrights.de>
This header file isn't required, and prevents the driver building for
the RISC-V based Hazard3 cores.
Signed-off-by: Andrew Featherstone <andrew.featherstone@gmail.com>
The RP2350 uses the Xh3irq interrupt controller, which supports nested
and prioritised interrupts. This adds initial support, configuring the
controller in 'direct' (non-vectored) mode.
Signed-off-by: Andrew Featherstone <andrew.featherstone@gmail.com>
There's no benefit to starting a subset of them, and this ensure that
everything is ready, regarless of RP2040 vs RP235xx, and whether the
Cortex-M33 or Hazard3 cores are in use in the latter case.
Signed-off-by: Andrew Featherstone <andrew.featherstone@gmail.com>
In case one defines an RGB led that is bigger than the led_rgb struct,
ws2812_gpio_update_rgb would overflow the buffer it writes to while
iterating. This could lead to crashes, as the code would also support
GRBW (as supposed in one comment).
As a 'proper' fix would require another buffer and therefore more
memory, I added a BUILD_ASSERT to ensure it does not compile.
Signed-off-by: Stefan Kraus <dev@stefankraus.org>
Due to the alias of ptr on pixels, one iterates over the same area
one reads from to set values. Therefore, if the strip is not 'RGB' but
GBR, one would overwrite the pixels 'r' value with the 'g' value in the
first loop, leading to a wrong read afterwards.
By writing to a temporary variable, we have a clean, unmodified copy
of the original values.
Additionally, this removes the dependency on 'LED_STRIP_RGB_SCRATCH',
as the scratch part (that masked most error cases) is not necessary
anymore.
Signed-off-by: Stefan Kraus <dev@stefankraus.org>
Move the TRNG peripheral enable from the clock/SoC init path to the
Espressif entropy driver init.
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
Smbus implementation for stm32 lacks of smbus_block_read(), so add the
functionality.
Fix some indentations.
Signed-off-by: Andrew Lewycky <alewycky@tenstorrent.com>
Signed-off-by: Sherry Li <xiaoruli@tenstorrent.com>
Return `enum wifi_conn_status` after failed connection attempt. Parse
`+CWJAP:` messages to get failure reason.
Signed-off-by: Marcin Niestroj <m.niestroj@emb.dev>
In several functions, the UART registers are accessed multiple times
through the `get_uart(dev)` inline function. This results in repeated
dereferencing of the device's base address.
This commit caches the UART register struct pointer in a local variable
`uart` at the beginning of each relevant function.
For registers where repeated access is not needed, the value is read once
into a temporary variable. Modifications, if any, are applied to
the temporary copy, and the result is written back once.
Signed-off-by: Pisit Sawangvonganan <pisit@ndrsolution.com>
Kconfig option UDC_DWC2_USBHS_VBUS_READY_TIMEOUT depends on services
exclusively available for nRF54H20, but the option can also be used for
nRF54LM20A, where there are no service dependencies, and VREG can be
accessed by the driver directly. Let depend the option on the SOC
series, as the controller can be used by the different CPUs on the SOC.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
Move macros derived from the VIRTIO specification to a shared include.
This change allows the VIRTIO standard definitions to be referenced
from outside the driver implementation.
The following definitions have also been added:
- VIRTIO_F_VERSION_1
- VIRTIO_F_ACCESS_PLATFORM
- VIRTIO_RING_F_INDIRECT_DESC
- VIRTIO_RING_F_EVENT_IDX
- VIRTQ_AVAIL_F_NO_INTERRUPT
- VIRTQ_USED_F_NO_NOTIFY
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Add the driver itself and Kconfig/CMakeLists/dts/bindings related to it.
Other files and libraries needed are in ST's dedicated folder
hal_stm32 (modules/hal/stm32).
Signed-off-by: Vincent Tardy <vincent.tardy@st.com>
This fixes system crashes in `i2s_buf_write`, because this function
internally calls `i2s_config_get`, which resulted in a NULL pointer on
stm32 i2s devices.
Signed-off-by: Titouan Christophe <titouan.christophe@mind.be>
Send "count" byte. The SMBus block write protocol requires this byte.
Use I2C_MSG_WRITE named flag instead of 0.
Signed-off-by: Andrew Lewycky <alewycky@tenstorrent.com>
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Add support for configuring I3C open-drain speed modes to handle
different timing requirements during bus initialization and operation.
Implementation:
- Fetch current controller configuration
- Invoke configure api inside bus_init to configure
I3C open-drain high period for proper bus
initialization and device compatibility.
The slow speed mode is essential for the first broadcast address
transmission to ensure visibility to all devices on the I3C bus,
particularly those in I2C mode that need to disable their spike
filters when switching to I3C mode. This requirement is specified
in "Table 49 I3C Basic Open Drain Timing Parameters" of the MIPI
ALLIANCE Specification for I3C Basic Version 1.2.
Signed-off-by: Shreehari HK <shreehari.hk@alifsemi.com>
This commit improves the I3C handling of open-drain
timing configurations with the following changes:
- Add OD minimum high_ns and low_ns DT properties
- Implement dw_i3c_init_scl_timing for runtime timing updates
- Initialize scl_od_min configuration from device tree
- Maintain backward compatibility with existing configurations
Requirement (MIPI Specification for I3C Basic v1.2 (16-Dec-2024),
Section 4.3.11.2 & Table 49):
- The MIPI I3C specification mandates different open-drain speeds during
bus initialization as defined in
"I3C Basic Open Drain Timing Parameters".
- The first broadcast address (7'h7E+W) must be transmitted at a slower
open-drain speed to ensure visibility to all devices on the I3C bus,
including legacy I2C devices. This slow speed (minimum 200ns Thigh)
allows I2C devices to properly detect the I3C mode transition and
disable their spike filters before switching to I3C mode. After the
initial broadcast, normal I3C open-drain speeds can be used for
regular operation.
Signed-off-by: Shreehari HK <shreehari.hk@alifsemi.com>
Add possibility to use the driver in configurations with disabled
multithreading. It may be useful in bootloaders, for example.
Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
Add possibility to use the driver in configurations with disabled
multithreading. It may be useful in bootloaders, for example.
Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
nRF53 series SoCs have a dedicated configurable audio PLL and the ability
to enable MCK bypass via a register value CONFIG.CLKCONFIG. This can
enable higher MCK/LRCK ratios that some I2S peripherals require the host
to generate. Allow an application developer to choose if they want to
initially look for a bypass ratio and, if found, enable bypass in the
NRFX driver. If not, the standard MCK calculation is conducted as normal.
Signed-off-by: Sean O'Connor <sean@standalone.tech>
When none of the configs is enabled, it will reports the following build
warning:
CMake Warning at zephyr/CMakeLists.txt:1096 (message):
No SOURCES given to Zephyr library: drivers__firmware__scmi__nxp
Excluding target from build.
Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com>
Use k_timepoint_t instead of k_timeout_t for absolute time to avoid
ambiguity and ensure the code works even when CONFIG_TIMEOUT_64BIT=n.
Signed-off-by: Cla Mattia Galliard <clamattia@gmail.com>
Refactor low power state handling to not tie to zephyr,disabling-states
and define it's own separate "low power states" property in DT instead.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
Invert property was not implemented and is now redundant with the flag
pwm-cell which is more flexible in case you want some IO to be inverted
and some not
Signed-off-by: Franck Duriez <franck.lucien.duriez@gmail.com>
# Conflicts:
# doc/releases/migration-guide-4.3.rst