The tmp116 sensor driver also supports tmp117 and tmp119. Therefore rename
to indicate that is supports a range of tmp devices.
Signed-off-by: Jeppe Odgaard <jeppe.odgaard@prevas.dk>
The osFlagsWaitAny option is not handled correctly. It returns once any
flag at all is set, whereas it is supposed to only return once one of
the flags specified in flags is set.
Signed-off-by: Utsav Munendra <utsavm@meta.com>
Support parsing and serializing of struct fields that are defined as a
char array.
Use the token JSON_TOK_STRING_BUF to parse and serialize a string for a
char array, for example:
struct foo {
const char *str;
char str_buf[30];
};
struct json_obj_descr foo_descr[] = {
JSON_OBJ_DESCR_PRIM(struct foo, str, JSON_TOK_STRING),
JSON_OBJ_DESCR_PRIM(struct foo, str_buf, JSON_TOK_STRING_BUF),
};
The struct 'json_obj_descr' now has an additional union member 'field'
to store the size of the struct field, which is used with the token
'JSON_TOK_STRING_BUF' to determine the element size.
Fixes: #65200
Signed-off-by: Christoph Winklhofer <cj.winklhofer@gmail.com>
Create a driver implementation for the battery charge controller
TI BQ25713.
It includes the ability to enable / disable the controller and also
to setup max current and voltage charge parameters at initialization
time but also at run time.
On the other hand, it is possible to assign / obtain input voltage
and current regulation.
Signed-off-by: Kiara Navarro <knavarro@paltatech.com>
Validate that a received LL_CIS_REQ is valid and reject if it is not
Fixes EBQ test failure in LL/CIS/PER/BI-07-C
Signed-off-by: Troels Nilsson <trnn@demant.com>
Update the JSON test cases to explicitly cast NAN and INFINITY to double
type to avoid implicit promotion.
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Add overlays required to run the test on:
- nrf54l09pdk/nrf54l09/cpuflpr,
- nrf54l20pdk/nrf54l20/cpuflpr.
Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
Enable nrf_grtc_timer test on:
- nrf54l09pdk/nrf54l09/cpuflpr and
- nrf54l20pdk/nrf54l20/cpuflpr.
Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
Add overlay required to run gpio_basic_api test on
- nrf54l09pdk/nrf54l09/cpuflpr and
- nrf54l20pdk/nrf54l20/cpuflpr.
Signed-off-by: Sebastian Głąb <sebastian.glab@nordicsemi.no>
Allow compiler optimizations to remove High-Speed handling code. Knowing
that maximum operating speed is Full-Speed allows to reduce bulk buffers
from 512 to 64 bytes. More RAM optimizations are possible but this
commit only gets the low hanging fruits.
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
Switching the intermediate file format from JSON to YAML has a very
significant benefit: the file is now loaded via yaml_load(), which
internally calls Python to parse the file into the JSON format that
CMake expects. This means that the file contents are now automatically
escaped properly for JSON; it is a huge improvement over the previous
implementation, which was escaping everything given as input to
to_yaml().
With the removal of the now-redundant call in to_yaml(), escaping is
applied exactly once per value or list, when it is passed to yaml_set().
This allows to convert the logic in zephyr_string(ESCAPE ...) to a more
robust "escape everything" approach.
These changes fix the handling of strings with backslashes and different
types of quotes passed either directly or via generator expression. The
existing tests are updated to cover these cases.
Two other small changes are made in this commit:
- a small check in internal_yaml_list_append() is removed, as the same
issue is already detected by the caller yaml_set() logic.
- the to_yaml() function is modified to initialize the YAML output
variable at the top level, which is the expected behavior. This
resulted in genex temp files sometimes having duplicate lines.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
Store strings in YAML as single-quoted entries to avoid issues with
special characters. This also fixes a quirk with the current test
suite where the quotes in the expected value are filtered out by the
YAML import.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
Up to now, the handling of type float was offloaded to the users of the
JSON utility, with the token JSON_TOK_FLOAT.
Improve handling of floating point types and support the types 'float'
and 'double' in a built-in way so that they can be directly parsed to
and serialized from variables (of type float or double).
The types are serialized in the shortest representation, either as a
decimal number or in scientific notation:
* float (with JSON_TOK_FLOAT_FP): encoded with maximal 9 digits
* double (with JSON_TOK_DOUBLE_FP): encoded with maximal 16 digits
* NaN, Infinity, -Infinity: encoded and decoded as:
{"nan_val":NaN,"inf_pos":Infinity,"inf_neg":-Infinity}
Enable the floating point functionality with the Kconfig option:
JSON_LIBRARY_FP_SUPPORT=y
It requires a libc implementation with support for floating point
functions: strtof(), strtod(), isnan() and isinf().
Fixes: #59412
Signed-off-by: Christoph Winklhofer <cj.winklhofer@gmail.com>
Loopback test requires this in order to properly execute half
transactions. Otherwise, testsuite fails.
It was overlooked when fixing #85894.
Signed-off-by: Luis Ubieda <luisf@croxel.com>
Both EXMIF and SPIS peripherals are claiming GPIO port 6 pin 0, but
with different CTRLSEL values. This will trigger a build error with
nrf-regtool 9.0.0 as it is not possible to apply this configuration
to hardware.
Fix the issue by disabling the EXMIF node that is enabled by default.
Signed-off-by: Håkon Amundsen <haakon.amundsen@nordicsemi.no>
Renamed the drv8424 stepper driver to indicate its support of the drv8424,
drv8425, drv8426, drv8434 and drv8436 stepper controllors. Also made the
microstep pins optional. All test files are renamed as well.
Signed-off-by: Jan Behrens <jan.behrens@navimatix.de>
Add bt_ccp_client_get_bearers that will return the bearers of
a client so that the application can always retrieve them if they
do not store them from the discovery callback.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
When only changes are in the "hostap" module the wifi build tests should
be run. Add the module tag to fix that.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
IPPROTO_RAW is not a valid protocol type for AF_PACKET sockets, which
should only use IEEE 802.3 protocol numbers. Therefore remove support
for this type of sockets.
As an alternative, users can use AF_PACKET/SOCK_DGRAM or
AF_INET(6)/SOCK_RAW, depending on the actual use case.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Register connection type along with family and protocol, so that it's
possible to differentiate between connection listening for raw IP
datagrams and TCP/UDP/other packets.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Private node identity advertisements must stop immediately when
ordered by PTS. To do so; adding enabled parameter to
btp_priv_node_id_get_cmd.
Signed-off-by: alperen sener <alperen.sener@nordicsemi.no>
Replace uses of OVERLAY_CONFIG with EXTRA_CONF_FILE
to follow the rest of Zephyr where OVERLAY_CONFIG was
deprecated in favor of EXTRA_CONF_FILE.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
The IT8xxx2 timer driver uses timer 7 and timer 8 to implement the alarm
timer and the top timer, respectively.
Signed-off-by: Yunshao Chiang <Yunshao.Chiang@ite.com.tw>
Introduce macro to check for valid microstep resolution in stepper api
Use this macro in tmc50xx driver. Stepper api tests adjusted in order to
accomodate the not implemented stepper api functions.
Signed-off-by: Jilay Pandya <jilay.pandya@outlook.com>
The calculation of the object size may be incorrect when the size of
a field is smaller than the struct alignment. When such a struct is
used in an array field, the decoded object contains wrong values.
The alignment influences the object size. For example the following
struct has a calculated object size of 8 bytes, however due to
alignment the real size of the struct is 12 bytes:
struct test_bool {
bool b1; /* offset 0, size 1 */
/* 3-byte padding */
int i1; /* offset 4, size 4 */
bool b2; /* offset 8, size 1 */
/* 3-byte padding */
};
This commit changes the object size calculation and computes the size
with the offset and size of the last field in the struct (rounded up
by the struct alignment).
Fixes: #85121
Signed-off-by: Christoph Winklhofer <cj.winklhofer@gmail.com>
Add gpio driver testcase support for kv260. The overlay will select the
PS gpio bank to be tested.
For running this testcase on kv260 PS gpio bank 3 has been chosen
because it is EMIO and design is required to connect pins together.
Signed-off-by: Paul Alvin <alvin.paulp@amd.com>
Add a babblesim test of the BT Tester doing a GAP smoke test
connecting 2 BT testers using BTP.
The purpose of this is to further increase the test coverage
of the BT Tester in CI, as it is only being built, and runtime
errors are typically not caught.
Signed-off-by: Emil Gydesen <emil.gydesen@nordicsemi.no>
Some files should be separated from the common folder to
each soc folder for future expansion of the chip.
Signed-off-by: Tim Lin <tim2.lin@ite.corp-partner.google.com>
The ADC and watchdog samples are not currently supported for the
non secure target of the nRF54L15 DK.
Add exclusions for these until they are supported.
Signed-off-by: Georgios Vasilakis <georgios.vasilakis@nordicsemi.no>