The Holyiot YJ-16019 board is a small, coin cell driven board based on
the Nordic Semiconductors nRF52832. It provides one LED and one push
button.
Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
Zephyr implementation of OpenThreads utilsFlashErasePage platform
function did not disable flash protection before calling `flash_erase`
function. This resulted in an error instead of actual flash erase on
platforms that properly implement flash write protection.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
This reverts commit bd24b31139.
While the test case failure described in #14186 is associated with the
cycle-based busy-wait implementation, that test is fragile, and fails
less frequently once the incongruence between ticks-per-second and the
32 KiHz RTC clock are resolved. It also assumes that the system clock
is more stable than the infrastructure underlying the the busy-wait
implementation, which is not necessarily true.
The gross inaccuracies in the standard busy-wait on Nordic described in
issue #11626 justify restoring the custom solution.
As this applies to all Nordic devices, move the setting to the top-level
Kconfig.defconfig.
See: https://github.com/zephyrproject-rtos/zephyr/issues/11626#issuecomment-487243369
Signed-off-by: Peter A. Bigot <pab@pabigot.com>
The default system clock on all Nordic devices is based on a 32 KiHz
(2^15 Hz) timer. Scheduling ticks requires that deadlines be specified
with a timer counter that aligns to a system clock. With the Zephyr
default 100 clocks-per-sec configuration this results in 100 ticks every
32700 ticks of the cycle timer. This reveals two problems:
* The uptime clock misrepresents elapsed time because it runs 0.208%
(68/32768) faster than the best available clock;
* Calculation of timer counter compare values often requires an integer
division and multiply operation to produce a value that's a multiple
of clock-ticks-per-second.
Integer division on the Cortex-M1 nRF51 is done in software with a
(value-dependent) algorithm with a non-constant runtime that can be
significant. This can produce missed Bluetooth deadlines as discussed
in upstream #14577 and others.
By changing the default divisor to one that evenly divides the 2^15
clock rate the time interrupts are disabled to manage timers is
significantly reduced, as is the error between uptime and real time. Do
this at the top level, moving SYS_CLOCK_HW_CYCLES_PER_SEC there as well
since the two parameters are related.
Note that the central_hr configuration described in upstream #13610 does
not distinguish latency due to timer management from other
irq_block/spinlock regions, and the maximum observed latency will still
exceed the nominal 10 us allowed maximum. However this does occur
much less frequently than changing the timer deadline which can happen
multiple times per tick.
Signed-off-by: Peter A. Bigot <pab@pabigot.com>
Inside function test_net_pkt_basics_of_rw result of function call
net_pkt_read_be16 is not checked which might result performance
of the program and cause errors.
Coverity-CID 198003
Fixes#15776
Signed-off-by: Maksim Masalski <maxxliferobot@gmail.com>
Making a clean slate for a pylint test in CI.
'_' is a common name for non-problematic unused variables in Python.
pylint knows not to flag it.
Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
Szymon is no longer actively looking at Bluetooth code, whereas Joakim
from Nordic has been assigned for Bluetooth host support.
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
This is a follow up to commit 0eaa5e53a3.
`HAL_SW_SWITCH_RADIO_ENABLE_S2_PPI_BASE` is a base number for two PPI
channels, so two bits need to be marked in the used channel bit mask.
Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
This make use of NET_IF_NO_AUTO_START flag so Bluetooth interfaces are
not automatically enabled after initialized.
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Fix calling bt_gatt_foreach_attr with start handle parameter set
to last static attribute handle.
Signed-off-by: Mariusz Skamra <mariusz.skamra@codecoup.pl>
The approved trademark name is Wi-Fi so update references to WiFi and
other spellings to Wi-Fi in documentation and Kconfig help strings.
(Note that use of spelling variatios of "wifi" in module names, CONFIG
names, link names and such are untouched.)
https://www.wi-fi.org/
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
Within the past few days, an update to the Ubuntu 18.04 toolchain has
begun emitting code sections during link that are messing with our
stub generation. They are appearing in the 32 bit stub link despite
not being defined in the single object file, and (worse) being
included in the output segment (i.e. at the start of the bootloader
entry point!) despite not being specifically included by the linker
script. I don't understand this behavior at all, and it appears to be
directly contrary to the way the linker is documented.
Marc Herbert discovered this was down to gcc being called with
--enable-default-pie, so -no-pie works to suppress this behavior and
restore the default. And it's correct: we aren't actually generating
a position independent executable, even if we don't understand why the
linker script is being disregarded (to include sections we don't
include). See discussion in the linked github issue.
Fixes#15877
Signed-off-by: Andy Ross <andrew.j.ross@intel.com>
k_stack_alloc_init() was creating a buffer that was 4 times
too small to support the requested number of entries, since
each entry in a k_stack is a u32_t.
Fixes: #15911
Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
Moves the flash memory definitions from Kconfig to device tree for the
rv32m1 ri5cy and zero-riscy cores.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Moves the sram memory definitions from Kconfig to device tree for the
rv32m1 ri5cy and zero-riscy cores.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
The west build --help output no longer fits in a single page. Move
details and examples into the documentation, so the -h output doesn't
require scrolling around.
Signed-off-by: Marti Bolivar <marti.bolivar@nordicsemi.no>
Analogously to the Make options with the same names, these print the
commands which would have run without running them.
Signed-off-by: Marti Bolivar <marti.bolivar@nordicsemi.no>
Adjust them so "west build -v" prints ZEPHYR_BASE and any CMake
commands, but none of the other more esoteric bits of information.
Signed-off-by: Marti Bolivar <marti.bolivar@nordicsemi.no>
This can be used to override the default CMake generator
permanently. Its values are the same as those acceptable to cmake's -G
option.
Signed-off-by: Marti Bolivar <marti.bolivar@nordicsemi.no>
Try to make the language simpler. Introduce each example with a
paragraph that says "To <DO XYZ>" to make them easier to find.
Move the config options to the documentation for that command to make
them easier to find.
Add some more examples for use cases we've gotten questions about.
Signed-off-by: Marti Bolivar <marti.bolivar@nordicsemi.no>
- Respect the BOARD environment setting.
- Don't require --force if the board can't be figured out: it might be
set in CMakeLists.txt, for example. Instead, downgrade to a warning
which can be disabled with "west config build.board_warn false".
- Add a build.board configuration option used as a final BOARD fallback
after CACHED_BOARD (in the CMake cache), --board (command line), and
BOARD (environment).
- Keep the config docs up to date.
Signed-off-by: Marti Bolivar <marti.bolivar@nordicsemi.no>
- This script didn't get fixed when cmake.py was renamed zcmake, so it
won't run; fix that.
- Change the default format string to '{name}' to keep things simple
- Flake8 lint
Signed-off-by: Marti Bolivar <marti.bolivar@nordicsemi.no>
Adds a new argument to the openocd runner to optionally specify the
config file. Updates the rv32m1_vega board to use different openocd
config files for the ri5cy and zero-riscy cores.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Introduces a new rv32m1_vega board configuration for the zero-riscy
core. It assumes that the soc has been reconfigured with openocd to boot
to the zero-riscy core instead of the ri5cy core.
Refactors the board-level device tree so the ri5cy and zero-riscy
configurations share common definitions for the led, button, and sensor
nodes.
Tested with:
- samples/hello_world
- samples/synchronization
- samples/basic/blinky
- samples/basic/button
- samples/sensor/fxos8700
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Refactors peripheral addresses, clocks, and compatibles from the ri5cy
core dtsi into a common soc dtsi, then attaches interrupts in
core-specific dtsi files.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
The zero-riscy core on the rv32m1 soc does not implement hardware loop
extensions and thus should not enable RISCV_SOC_CONTEXT_SAVE, however it
does still need access to the EVENTx_INTPTPENDCLEAR symbol which comes
from GEN_SOC_OFFSET_SYMS().
Split out the soc offset symbols into a separate config so we can enable
them without enabling soc context saving.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Both the ri5cy and zero-riscy cores in the rv32m1 soc use the same
source clock, so we don't need to conditionalize
SYS_CLOCK_HW_CYCLES_PER_SEC on the ri5cy core.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
CI always runs after new PRs are merged into master. Report failures to
mailing list to get more attention if master fails to build.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Due to a protracted merge of:
5e38ed9320
the naming for the HAL_SW_SWITCH_RADIO_ENABLE_S2_PPI changed
semnatics, now requiring use of
HAL_SW_SWITCH_RADIO_ENABLE_S2_PPI_BASE.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
Implement OpenThreads frame pending bit management on top of the Zephyrs
radio driver API. This allows for proper Sleepy End Devices handling
from the parent side.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Implement newly introduced `configure` API for nRF 802154 radio driver.
Increase maximum number of slots for Frame Pending bit information in
the radio driver.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
License link provided in stm32cube abstract packages was not
reflecting the actual license in use for these packages.
Update the link to BSD 3-Clause official.
Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
The stm32_min_dev board blue/black variant support USB device,
but the usb node removed by merge PR #15245, so add it back.
Signed-off-by: Harry Jiang <explora26@gmail.com>