The original scale value used to convert raw gyro value to q31 format is
incorrect. Updated to the correct value.
Signed-off-by: Yau-ming Leung <ymleung314@gmail.com>
- Implement event handling for AP and STA modes
- Enable configurations for security (PSK), aggregation,
and hidden PSK credentials
Signed-off-by: Arunmani Alagarsamy <arunmani.a@silabs.com>
- Adds support for configuring client maximum inactivity timeout.
- Adds support for bandwidth, It supports 20MHZ only.
- Adds support for setting the maximum number of clients and
hidden SSID mode by rebooting the NWP device.
Signed-off-by: Arunmani Alagarsamy <arunmani.a@silabs.com>
Replaced SL_SI91X_CLIENT_MODE and SL_SI91X_ACCESS_POINT_MODE with
WIFI_STA_MODE and WIFI_SOFTAP_MODE, respectively, for AP configuration
command intergration.
Signed-off-by: Arunmani Alagarsamy <arunmani.a@silabs.com>
This patch introduces validation checks to ensure Wi-Fi commands are
executed only when the device is in a valid operational mode.
- Restricts command execution if the device is not in an appropriate mode
- Prevents reconfiguring the device when it is already in an active state
- Enabled Advanced multiprobe setting as default.
Signed-off-by: Arunmani Alagarsamy <arunmani.a@silabs.com>
In order to prevent not serving all events that would clear the
interrupt line. This patch also removes FIFO servicing through
fetch/get APIs, as this is only exposed through streaming mode.
Signed-off-by: Luis Ubieda <luisf@croxel.com>
SEGGER Ozone J-Trace Code Profile identified iterations over daint value
as hot path. The iterations show at the very top of code profile because
full iteration happens whenever there is any activity on endpoint.
Optimize daint handling loops so only set bits are iterated over. While
this optimization depends on find_lsb_set() efficiency, it seems to be
worth it solely on the basis that quite often only few bits are set.
After a bit deeper analysis, I was suprised that on ARM Cortex-M33 the
find_lsb_set() approach is faster than naive iteration even if all bits
are set (which is extreme case because USB applications are unlikely to
use all 16 IN and 16 OUT endpoints simultaneously). This is due to fact
that there is only one conditional jump CBNZ and find_lsb_set() - 1
translates to RBIT + CLZ and then clearing the bit uses LSL.W + BIC.W.
Whereas the naive itation uses ADDS + CMP + BNE for the loop handling
and also has LSR.W + LSLS + BPL (+ ADD.W instruction on each iteration
to add 16 for OUT endpoints) for the continue check. Therefore the
optimized code on ARM Cortex-M33 is never worse than naive iteration.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
The pinctrl register bits need to be restored to GPIO mode
after we exit from certain low power modes. We cannot rely
on the pin function to default to GPIO.
Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
Add the PM handler. Reinitialize the DMA block in the
TURN_ON action, this is needed for some SoC's after the system
exits certain power modes.
Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
Previously, the TMP1075 driver only used the integer part (val1) of the
sensor_value when setting TLOW and THIGH thresholds. This limited the
precision of temperature threshold configuration and could be insufficient
in applications requiring fine-grained control.
This patch adds proper handling for the fractional part (val2) by encoding
it into bits [7:4] of the 12-bit temperature register according to the
TMP1075 datasheet. The decoding logic in get_threshold_attribute() is also
updated to recover the fractional value accurately.
Signed-off-by: Hank Wang <wanghanchi2000@gmail.com>
Select SERIAL_SUPPORT_INTERRUPT for uart_bt, this is required to have
the interrupt API available.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
Added the possibility of leaving the gpio-int property empty, in case
the corresponding pin is not connected.
Signed-off-by: Mirko Bottarelli <mirko.bottarelli@gmail.com>
Fix device initialisation, allowing for empty interrupt_gpios in the
dts, as suggested by the documentation.
Signed-off-by: Mirko Bottarelli <mirko.bottarelli@gmail.com>
Certain power modes lose state of the GPIO, hence we need to
reconfigure the interrupt GPIO. This is managed using pm_notifiers
Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
Make the vbus-limit-microamp property of npm1300-charger required and
change its range to reflect the one actually supported by the device.
Signed-off-by: Sergei Ovchinnikov <sergei.ovchinnikov@nordicsemi.no>
This makes SSD1327 use the new L8 display format.
It also fixes all displays that didnt support the undocumented
monochrome mode.
It also adds i2c and revamps the entire driver.
Signed-off-by: Camille BAUD <mail@massdriver.space>
Current code does not build on Cortex-M0, seems like it does not like
subs:
Error: instruction not supported in Thumb16 mode -- `subs r3,#1'
Adding a unified assembler language declaration in the snippet seems to
fix the problem, also add an M0+ board so this is tested in CI.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
DWC2 core sets DIEPCTL0 SNAK when SETUP packet is received. The CNAK bit
results in device sending NAK in response to IN token sent to EP0, but
it does not modify the TxFIFO in any way. The stale data in TxFIFO can
then lead to "FIFO space is too low" error. Solve the issue by disabling
and flushing IN endpoint 0 if previous control transfer did not finish.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Add missing curly braces in if/while/for statements.
This is a style guideline we have that was not enforced in CI. All
issues fixed here were detected by sonarqube SCA.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Add wsen_itds_2533020201601 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>
This dependency was always there but not explicitly defined.
By adding the explicit dependency it becomes more obvious
what is wrong when SPI is enabled but GPIO disabled.
This was found when building `samples/bluetooth/peripheral`
for `nrf54l15dk/nrf54l15/cpuapp` with `CONFIG_GPIO=n`.
Before we got:
- A linker error in `spi_nrfx_common.c` failing
to reference some nrfx_gpiote APIs.
- A linker error in `spi_nrfx_spim.c` failing to reference
the GPIO dts entry.
Now we will get a warning of that GPIO is not enabled
With this it becomes more obvious that SPI driver is enabled by
default because of the external flash mounted on the DK.
Signed-off-by: Rubin Gerritsen <rubin.gerritsen@nordicsemi.no>
SPI driver for Microchip MEC5 HAL based QSPI controller. QSPI
hardware supports full duplex, dual, and quad operation. MEC5
QSPI controller also includes three local DMA channels per
direction to off load firmware. The driver API supports full
or half-duplex. Due to QSPI hardware not supporting one wire
half-duplex, this driver supports full-duplex only. QSPI hardware
design requires it to control chip select and current hardware
supports up to two chip selects. Zephyr's SPI DT macros store the
child SPI device's reg properity as the "slave" member of the SPI
configuration structure. The driver uses the "slave" value as the
chip select. Additional timing settings specific to SPI flash devices
are in a new SPI device YAM file: "microchip,mec5-qspi-device.yaml"
which includes the standard "spi-device.yaml". If the new YAML is not
used, the QSPI controller will use default timing values for chip
select and I/O line taps.
Signed-off-by: Scott Worley <scott.worley@microchip.com>
Using pre-defined values displayed on datasheet's table 5-4 for
CMM Update Rates.
Please note that datasheet specifies these Update-Rates may have
up to 7% standard deviation, which may be significant for certain
applications.
Signed-off-by: Luis Ubieda <luisf@croxel.com>
This patch introduces rm3100 magnetometer sensor, with basic
support (only read-decode).
This driver has bus support for I2C.
Signed-off-by: Luis Ubieda <luisf@croxel.com>
On some series, use of Delay Block could be possible on OSPI device but
not on HSPI one (which uses this drivers).
As a quick fix check the presence of XSPI Delay Block by-pass
configuration bit instead of the Delay Block presence.
Note: This fix works because we don't have cases today where this driver
is used for OSPI and HSPI instances with mixed DLYB compatibility.
This may have to be reviewed one day and may require a more complex fix
with instantiable configuration, but this day may never come as well.
Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
Enables sleep mode (PM3) on RW61x. The driver
re-enables the wdt on wake-up based on the previous
configuration. Note that the wdt counter value always
resets to the max window value on wake-up
Signed-off-by: Alex Rodriguez <alejandro.rodriguezlimon@nxp.com>
There was a race condition where `lpspi_end_xfer` can be called multiple
times per transfer. There was the case where a TX interrupt gets
triggered without the RX interrupt being set, and TX finishes writing
its last byte. Then, `spi_context_rx_len_left() == 0` is true and
`lpspi_end_xfer` happens, but the RX interrupt is still active. Then,
when the RX interrupt happens, `lpspi_end_xfer` will get called again.
To fix that, the architecture was adjusted to only call `lpspi_end_xfer`
once no interrupts are active any more, and the disabling of the
interrupts gets used to signal the end of the TX and RX part.
Minor adjustments were necessary to use the interrupt enable signals for
this purpose; the TX irq handler had its internal order reversed,
otherwise it wasn't guaranteed that the physical transfer is finished
when we disable the interrupt.
Also, the code where the RX interrupt gets disabled had to be moved out
of the RX irq handler, because the RX interrupt also needs to be
disabled if RX is finished but no RX interrupt is currently active.
Signed-off-by: Martin Stumpf <finomnis@gmail.com>
Assertion checked whether pointer is NULL.
Assertion should check whether pointer is *not* NULL.
Fixed by changing check in assertion.
Signed-off-by: Frank Duerr <frank.duerr@ipvs.uni-stuttgart.de>
The NXP ENET driver used a mutex inside an ISR.
Since mutexes are not allowed in ISR, an assertion had been triggered.
The mutex is not required since a semaphore ensures sequential writing
(in ISR) and subsequent reading (after eth_wait_for_ptp_ts()).
Fixed by removing calls to mutex.
Signed-off-by: Frank Duerr <frank.duerr@ipvs.uni-stuttgart.de>
Add drivers/interrupt_controller/intc_nxp_pint/power.h abstracting
EnableDeepSleepIRQ and DisableDeepSleepIRQ invocations from
intc_nxp_pint.c. Modify intc_nxp_pint.c to use that file.
fsl_power.c and fsl_power.h can't be built on the
mimxrt685_evk/mimxrt685s/hifi4 target, so it's excluded from it in hal_nxp.
Signed-off-by: Vit Stanicek <vit.stanicek@nxp.com>
M2M devices like ISPs or PxP have two separate buffer queues, i.e.
incoming and outcoming queues. For each API, the driver needs to
distinguish on which queue it needs to take action.
Add video buffer type to support this kind of devices.
- get_caps(), set/get_format(), enqueue()/dequeue(): the buffer type
is embeded in the video_caps, video_format and video_buffer structs
- video_stream_start/stop() : buffer type needs is sent as a parameter
Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
The video endpoints are already described in the devicetree. The
video_endpoint_id parameter in each video API is not necessary and has
no usage. Drop it.
Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
When stopping, the framework calls driver's stop callback then driver's
flush callback. Hence, driver's flush callback does not need to call
stop callback again.
Signed-off-by: Phi Bang Nguyen <phibang.nguyen@nxp.com>
If an on-off service records an error while transitioning to the on
state, it stays in the error state and does not allow new requests
to be made until its state is reset. Add resetting of the services
associated with particular clock controllers so that requests can
be retried after failures.
Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
Due to source data pointer having no alignment constraint,
extra care needs to be taken when reading source data
as dword
Signed-off-by: Yonas Alizadeh <yonas.alizadeh@alfalaval.com>