Allows snippets to be placed in a predictable order into the linker
script. This is useful for data that must be placed at a particular
location.
Signed-off-by: Øyvind Rønningstad <oyvind.ronningstad@nordicsemi.no>
When using LLVM/Clang, it complains about memcpy() being
casted to (void *):
warning: expression result unused; should this cast be to 'void'? [-Wunused-value]
So change those to (void) instead as the return of memcpy()
is not used anyway.
Signed-off-by: Daniel Leung <daniel.leung@intel.com>
Add the green LED on the back of the reel_board to the device tree and
add PWM support for the front RGB LED.
Signed-off-by: Henrik Brix Andersen <hebad@vestas.com>
Algorithm for freeing strdup buffers was only checking if argument
matches address within strdup buffer pool and was attempting freeing
even if format specifier was different than string.
Added fix where also format specifier is checked.
Extended logger test to verify correctness of function which searches
for string format specifiers within a string.
Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
Extended test to pass address within strdup buffer but with
different format specifier (not string). That should not trigger
string buffer freeing. If it does system may collapse (e.g. cortex-m0
may use unaligned access).
Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
Fix clock setup for stm32 f3, l4, wb and g4 series.
The macro __LL_ADC_COMMON_INSTANCE() is called without argument, which
leads to a compile error. Fix by passing adc parameter.
Signed-off-by: Thomas Schmid <tom@lfence.de>
Add at86rf233 dts binding to enable IEEE 802.15.4 driver. The driver is
managed by sercom-4 at chip level.
see: SAM-R21_G.pdf section: 5.2 Internal Multiplexed Signals
Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
Enable ETHERNET_HW_TX_CHKSUM_OFFLOAD, ETHERNET_HW_RX_CHKSUM_OFFLOAD,
ETHERNET_AUTO_NEGOTIATION_SET and the equivalent driver configuration
in eth_mcux driver.
Autonegoitiation was done at driver initialization.
Signed-off-by: Andrei Gansari <andrei.gansari@nxp.com>
This is needed when a board needs to be reset using an external commands
or tools that are not part of the flash command. For example, power
reset or by poking a GPIO header on the board using external wiring.
add post_flash/pre_flash to the platform section in the hardware map.
For example:
- available: true
connected: true
id: OSHW000032254e4500128002ab98002784d1000097969900
platform: reel_board
post_script: /tmp/post_flash.sh
pre_script: /tmp/pre_flash.sh
product: DAPLink CMSIS-DAP
runner: pyocd
serial: /dev/ttyACM11
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Adds a Shell Module for retrieving Sensor data. The following commands
were added:
sensor - Device commands
Options:
-h, --help :Show command help.
Subcommands:
get :<device_name> [chanel_idx]
list :List configured sensors
list_channels :<device_name>
Signed-off-by: Diego Sueiro <diego.sueiro@gmail.com>
It is supported to have a zephyr module that does not have a
module.yml, but zephyr_module.py does not support it and will drop
such modules.
To fix this we add support in zephyr_module.py.
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
All docs are treated equally in the search results. The built-in search
system knows to emphasize hits in titles and object names, but could use
some help understating hits in non-definitive docs. In particular, hits
to docs in the /boards, /samples, and /reference/kconfig docs are often
not as important as hits in other docs, so let's push them later in the
search result output.
We can tweak the search results scoring (and thereby the order of
display) via the ``html_search_scorer`` setting in ``conf.py`` along
with a piece of JavaScript to adjust the result score.
Fixes: #16935
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
According to the I2C spec, the SDA signal must be
stable as long as the SCL signal is high (which
means it can change only when clock is low).
This commit reworks clock signal handling
in such a way that all reads are done
when SCL is high and SDA is stable.
Signed-off-by: Mateusz Holenko <mholenko@antmicro.com>
This commit consolidates the meaning of WDT_DISABLE_AT_BOOT option as
"disabling watchdog at Zephyr system startup for the SoCs that enable
the watchdog by default after reset", and makes this default to y in
order to prevent unintentional processor reset by the watchdog when
not explicitly configured and fed by the application.
Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
The current GIC driver implementation only supports the GIC-400, which
implements the GICv2 interface.
This commit refactors the GIC driver to support multiple GIC versions
and adds GICv1 interface support (GICv1 and GICv2 interfaces are very
similar).
Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
The current GIC configuration scheme is designed to support only one
specific type and version of GIC (i.e. GIC-400 that implements the
GICv2 interface).
This commit adds a set of GIC version configuration symbols that can
be selected by the SoC configuration to specify which version of GIC
interface is implemented in the SoC.
Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
Due to flipped logic is_irq_locked function was returning true then
interrupts were unlocked. Because of that CONFIG_LOG_BLOCK_IN_THREAD
feature was not working correctly and wasn't locking thread context
when log message buffer pool was empty.
Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
nrf51 and nrf52 by default was enabling temperature sensor if sensor
API was enabled. It was causing code size increase even when
temperature sensor was not touched by anyone. Removed default enabling
of temperature sensor for both series.
Signed-off-by: Krzysztof Chruscinski <krzysztof.chruscinski@nordicsemi.no>
Define a binding for the Aosong DHT family of temperature/humidity
sensors. Remove the Kconfig settings, and update the driver to use
devicetree information.
Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
To get testing coverage after the fix in the previous commit.
Co-authored-by: Armando Visconti <armando.visconti@st.com>
Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
DT_INST_0_ST_LPS22HH_CS_GPIO_CONTROLLER should be
DT_INST_0_ST_LPS22HH_CS_GPIOS_CONTROLLER, which is the name generated by
gen_defines.py.
Discovered while working on unrelated removing of special-casing for
clocks.
Co-authored-by: Armando Visconti <armando.visconti@st.com>
Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
By this commit user gets possibility to register USB
device satutus callback. This callback represents device state
and is added so user could know what happend to USB device.
Callback is registered by providing it to usb_enable()
USB api is extended by this callback handler.
Samples using using USB are by default provide no callback
and the usb_enable() is called with NULL parameter.
Status callback registered by hid class is deleted as now
USB device has global callback for all classes within device.
Signed-off-by: Emil Obalski <emil.obalski@nordicsemi.no>
The purpose of this commit is to prevent user from
calling usb_enable() twice from different contexes.
If for example user configures composite device with hid
and USB uart console (CONFIG_USB_UART_CONSOLE=y)
then introduced mutex will prevent from calling
usb_enable twice and thus lead to undefined behaviour of
usb driver controller.
usb_enable shall always be called once as it refers to usb driver
and for now only one USB driver instance is supported in Zephyr.
This mechanism ensures that.
Signed-off-by: Emil Obalski <emil.obalski@nordicsemi.no>
Some drivers may be unable to write less than 4 bytes. Increase the
test to use at least 4 bytes and refactor so the logic is no longer
explicitly size-dependent.
Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
Currently most SPI NOR serial flash devices are accessed through the
spi-nor flash driver, but there are pending enhancements that will
access these devices through other driver implementations. Several of
the descriptive properties of the flash memories are common regardless
of the interface selected. Pull those out to a separate yaml file to
be included into the bindings for interface-specific node descriptions.
Also revise the documentation to note that the jedec,spi-nor
compatible depends on a commands set compatible with the Micron M25P80
serial nor flash; there is no JEDEC standard for these commands.
These devices do generally provide descriptive structures defined by
JESD216, but currently Zephyr doesn't make use of these structures.
The JEDEC CFI standard previously referenced in the description is not
relevant to these devices.
Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
MX25R64 supports maximum 33 MHz clock for READ operations in
high-performance mode. The previous 80 MHz speed should have been
8 MHz and was for DSPI/QSPI operations.
Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
We have an open request to make the help for the -t option a little
easier. Try to do that without adding too much length to the short
help.
Fixes: #16202
Signed-off-by: Martí Bolívar <marti.bolivar@nordicsemi.no>
For the following devicetree, view 'nested' as being on the bus.
Previously, only 'node' was considered to be on the bus.
some-bus {
compatible = "foo,bus-controller";
node {
nested {
compatible = "foo,device-on-bus";
};
};
};
In practice, this means that a 'bus:' key in the binding for
'foo,bus-controller' will now get matched up to an 'on-bus:' key in the
binding for 'foo,device-on-bus'.
Change the meaning of Node.bus and add two new attributes Node.on_bus
and Node.bus_node, with these meanings:
Node.bus:
The bus type (as a string) if the node is a bus controller, and
None otherwise
Node.on_bus:
The bus type (as a string) if the node appears on a bus, and None
otherwise. The bus type is determined from the closest parent
that's a bus controller.
Node.bus_node:
The node for the bus controller if the node appears on a bus, and
None otherwise
It's a bit redundant to have both Node.bus_node and Node.on_bus, since
Node.on_bus is the same as Node.bus_node.bus, but Node.on_bus is pretty
handy to save some None checks.
Also update gen_defines.py to use Node.on_bus and Node.bus_node instead
of Node.parent wherever the code deals with buses.
Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>