Add support for runtime and devicetree configuration of themocouple
type, ADC resolution, filter coefficient and cold junction temperature
resolution. Extend device specific sensor channels to include cold
junction temperature, delta tempereature, hot junction temperature and
raw ADC values while still maintaining backwards compability with the
existing SENSOR_CHAN_AMBIENT_TEMP channel.
Signed-off-by: Thomas Schmid <tom@lfence.de>
These macros provide a way to get the `mount-point` value from
an fstab entry:
- FSTAB_ENTRY_DT_MOUNT_POINT
- FSTAB_ENTRY_DT_INST_MOUNT_POINT
Signed-off-by: James Roy <rruuaanng@outlook.com>
Introduce a streaming APIs for ADC devices.
Two new APIs are added to the adc_driver_api: submit and get_decoder.
Added decoder following APIs: get_frame_count, get_size_info, decode,
has_trigger.
Supported triggers are:
- ADC_TRIG_DATA_READY
- ADC_TRIG_FIFO_WATERMARK
- ADC_TRIG_FIFO_FULL
Supported operations to be done on trigger:
- include - whatever data is associated with the trigger
- nop - do nothing with data associated with the trigger
- drop - clear data associated with the trigger
Some changes to the linker scripts were needed to add decoder APIs.
Signed-off-by: Vladislav Pejic <vladislav.pejic@orioninc.com>
net_if.h and net_pkt.h are 2 headers required by lldp.h
as it needs to know net_if and net_pkt structs.
Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
The config PM_S2RAM_CUSTOM_MARKING is not an optional config for a
user to select, it is required by some soc implementations of S2RAM,
in which case it must be selected by the soc.
Refactor the configuration to be HAS_PM_S2RAM_CUSTOM_MARKING, and
make the currently only soc which needs it select it. Then update
samples which previously had to select this option for this soc.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
ti_dmtimer.h contains mask definitions only used internally by the
driver. Make it a private header.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Add missing const on `struct rtio_iodev *iodev`
sensor_reconfigure_read_iodev(), sensor_stream(),
and sensor_read(), all pass iodev to functions
which accepts struct rtio_iodev as const.
These functions should also be marked const.
Signed-off-by: Anthony Williams <anthony289478@gmail.com>
Convert `gethostname()` from a static inline wrapper to a normal function
with regular linkage.
This change was prompted mainly as housekeeping for #95811, but a
secondary reason was to make this a linkable symbol so that the API works
at a binary level as well (which could be provided by the toolchain as
well).
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
Include `<zephyr/toolchain.h>` to get access to `ARG_UNUSED()` and include
`<zephyr/sys/util.h>` to get access to `MAX()`.
Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
- Add a new counter driver implementation based on the PDL for
Infineon CAT1B devices. This enables support for hardware
counters on the PSC3M5 platform.
- Add IFX_TCPWM_Counter_DeInit and IFX_TCPWM_Counter_Init
macros to include/zephyr/drivers/timer/ifx_tcpwm.h
and sort all of the macros in that file
Signed-off-by: Yurii Lozynskyi <yurii.lozynskyi@infineon.com>
- Remove per-object AON macros and replace with explicit KEEP entries
referencing libish_aontask.a for .text/.rodata/.data/.bss.
- Introduce __ish_aon_start / __ish_aon_end linker symbols.
- Rename GROUP from AON to ISH_AON for clarity.
It's not good to specify source file names in linker script.
Signed-off-by: Dong Wang <dong.d.wang@intel.com>
A few straightforward cleanups to existing documentation to improve
coverage and properly hide internal macros.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
The API documentation for the disconnected() callback warns that
the listener can't assume that the corresponding connection object
has been freed and may me available to the application.
The recommendations given to still start a new connection
or connectable advertiser are outdated or misleading:
- "start connectable advertising": the options that "will attempt
to resume the advertiser under some conditions" are deprecated
since Zephyr 4.0 (BT_LE_ADV_OPT_CONNECTABLE and related)
- "using k_work_submit()": assuming everything will be fine
when the work is actually processed is not reliable
- "increase CONFIG_BT_MAX_CONN": setting BT_MAX_CONN to N+1
when planning N simultaneous connections is a work-around
that users may have gotten used to (despite its footprint),
but there is no longer any reason to advise it
Stop documenting creating new connections or restarting advertising
from the disconnected() callback and instead recommend relying
on recycled() for these use cases.
Signed-off-by: Christophe Dufaza <chris@openmarl.org>
The API documentation for the recycled() callback predates [1],
and still warns users to "treat this callback as an ISR",
although it now runs on the system workqueue thread,
as does disconnected().
"Making Bluetooth API calls" to "re-start connectable advertising or
scanning" should no longer be "strongly discouraged".
On the contrary, we can emphasize that this is the right event
to listen for to initiate operations that will try to re-allocate
a freed connection object.
Mention that BT_MAX_CONN configures the size of the connection pool.
Refs:
- [1] efb5d83: Bluetooth: Host: Defer `conn.recycled()` to the syswq
Signed-off-by: Christophe Dufaza <chris@openmarl.org>
Extract the user pipe setup and claim/release logic so that it can be
re-used by other software modules, if the AT shell is not used. Ideally
the chat instance would live within the `modem_at_user_pipe.c` and be
handed out by `modem_at_user_pipe_claim`, but the current chat API
doesn't make this possible.
Signed-off-by: Jordan Yates <jordan@embeint.com>
Add valid pin configurations boilerplate for SF32LB52x. All valid
configurations will be added in a follow-up commit.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Add bindings for the SF32LB52X SoCs PINMUX peripheral. Note that
SF32LB56X SoCs contain a compatible IP (not others, where HPSYS_CFG is
not required), so if SF32LB56X support is added, binding could be
adjusted to reflect 52x/56x support.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Initial driver for SF32LB SoCs. This driver is incomplete, but allows
to configure the system for a minimal boot.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
The k_event event is only used if CONFIG_PM_DEVICE_RUNTIME_ASYNC is
selected, but EVENTS is selected, and the k_event included in the
struct pm_device if CONFIG_PM_DEVICE_RUNTIME is selected.
Correct to only include event and EVENTS if
CONFIG_PM_DEVICE_RUNTIME_ASYNC is selected. This saves us 1
struct event per PM DEVICE.
Signed-off-by: Bjarki Arge Andreasen <bjarki.andreasen@nordicsemi.no>
This aims to implement a packet forwarding mechanism between
DNS resolver and applications that install a callback, letting
DNS resolver know that received UDP packet is also required by an
application.
Signed-off-by: Cristian Bulacu <cristian.bulacu@nxp.com>
SDRAM1 / SDRAM2 / PSRAM sections were being referenced in order to make
them accessible for the framebuffer. This is now addressed via the
mechanism provided by Zephyr hence this is no more necessary.
Signed-off-by: Alain Volmat <alain.volmat@foss.st.com>
remove CONFIG_LIBSBC_ENCODER and CONFIG_LIBSBC_DECODER from sbc.h, then
include the required heders files path defaultly to fix building errors.
Signed-off-by: Mark Wang <yichang.wang@nxp.com>
Add support for enabling and configuring the self-test mode of the
LIS2DH accelerometer through a dedicated sensor attribute.
Signed-off-by: Arthur Gay <arthur.gay@marshmallow.kids>
Add two helper functions to convert power management states between
enum and string:
- pm_state_to_string()
- pm_state_from_string()
Signed-off-by: Yongxu Wang <yongxu.wang@nxp.com>
Added helper function to get scope of an IPv6 address. Also added raw
variant which uses plain uint8_t buffer.
Signed-off-by: Cristian Bulacu <cristian.bulacu@nxp.com>
Add code handling the pllsai. It is similar to the pllsai1
pllsai2 which can be found on some other socs, except, depending
on the socs the fact that pllsai source can be or not common with
other plls and moreover it can also have additional DIV_DIVQ
and DIV_DIVR additional dividers.
Choice is made to add PLLSAI instead of add further support to
PLLSAI1, in order to stick to the proper naming of the PLLs.
Signed-off-by: Alain Volmat <alain.volmat@foss.st.com>
RX26T MCU uses a clock source marcos with different value
compared to the previous, this commit add new one
Signed-off-by: Quy Tran <quy.tran.pz@renesas.com>
This change introduces a set of C preprocessor macros to determine the
maximum value from a list of 1 to 10 arguments.
The main macro `MAX_FROM_LIST(...)` dispatches to specialized `MAX_N`
macros (where N is from 1 to 10) based on the number of arguments
provided. This is achieved using a common variadic macro technique
involving a helper macro `GET_MAX_MACRO` to count the arguments and
select the appropriate implementation.
The `MAX_N` macros are defined recursively using the ternary operator
`?:` to perform comparisons.
This provides a compile-time mechanism to find the maximum value within
a small set of numbers.
Signed-off-by: Firas Sammoura <fsammoura@google.com>
A few documentation comments in os_mgmt.h were not using the proper
"javadoc-style" comments.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>