Switch the default MCUBoot FW Update mode from Swap & Scratch
to more preferable Swap & Move for the rest of NXP MCUs.
Other NXP MCU platforms have been already switched.
Delete the scratch partition. Save RAM & ROM.
Slot 0 has one additional sector, for use with
the swap move algorithm.
Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
Update generation comment for NXP board pin control files, to point
users to the current pin control scripting files in NXP's HAL. Note that
these files have not been regenerated- the script name simply has
changed, so update these references to avoid confusion.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
This is coming from devicetree and corrosponds to what we have in the
dts/bindings/vendor-prefixes.txt file.
This will allow for static filtering, especially with twister, i.e. no
need to build anything to know the vendor of a board
All of the vendor data was extracted automatically from the devicetree,
so some platforms might not have the right vendor or no vendor at all
right now, we need to fix some of the DTS information or do this
manually to get this 100% correct. But we are close.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Add gpio-keys codes for all boards. These are mostly INPUT_KEY_0 and so
on but I've used some more specific ones where it was obvious that
there's something else on the boards.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
Now that timer drivers are enabled based on devicetree we can
remove any cases of them getting enabled by *_defconfig files.
Signed-off-by: Kumar Gala <galak@kernel.org>
The boards folder uses ~142.8 MB, being the largest in the repository.
This is due mostly to board images, which are in most cases not
optimized for web content. This patch tries to address this problem by
converting all pictures to JPEG (quality 75) and by adjusting its size
up to 750 px (the width of the documentation content). Images that
specified a fixed width in rst files are converted down to that value
instead.
With this patch, folder goes down to ~53.5 MB from 142.8 MB (-~63%).
Note that this patch introduces a new set of binary files to git
history, though (bad).
The process has been automated using this quickly crafted Python script:
```python
from pathlib import Path
import re
import subprocess
def process(doc, image, image_jpeg, size):
subprocess.run(
(
f"convert {image}"
"-background white -alpha remove -alpha off -quality 75"
f"-resize {size}\> {image_jpeg}"
),
shell=True,
check=True,
cwd=doc.parent,
)
if image != image_jpeg:
(doc.parent / image).unlink()
for doc in Path(".").glob("boards/**/*.rst"):
with open(doc) as f:
content = ""
image = None
for line in f:
m = re.match(r"^(\s*)\.\. (image|figure):: (.*)$", line)
if m:
if image:
process(doc, image, image_jpeg, size)
image = Path(m.group(3))
if image.suffix not in (".jpg", ".jpeg", ".png"):
content += line
image = None
continue
image_jpeg = image.parent / (image.stem + ".jpg")
size = 750
content += (
f"{m.group(1)}.. {m.group(2)}:: {image_jpeg}\n"
)
elif image:
m = re.match(r"\s*:height:\s*[0-9]+.*$", line)
if m:
continue
m = re.match(r"\s*:width:\s*([0-9]+).*$", line)
if m:
size = min(int(m.group(1)), size)
continue
content += line
if line == "\n":
process(doc, image, image_jpeg, size)
image = None
else:
content += line
with open(doc, "w") as f:
f.write(content)
```
Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
We now 'select I2C' and/or SPI bus in Kconfig in the sensor driver
Kconfig's so there is no need to have boards do the following:
config I2C
default y if SENSOR
config SPI
default y if SENSOR
Signed-off-by: Kumar Gala <galak@kernel.org>
Set accel0 alias for all boards with the FXOS8700 and compatible
accelerometer to use by the accel_polling sample.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@fujitsu.com>
For all boards that have a magnetometer devicetree alias, configure the
appropriate bus (I2C or SPI) default to be enabled when the sensor
driver class is enabled. This will simplify enabling the magn_polling
sample application for these boards (and using the magnetometer in
general) because it will eliminate the need to add a bunch of
board-specific configuration overlays to the application.
Signed-off-by: Maureen Helm <maureen.helm@intel.com>
Sets a magnetometer devicetree alias for all boards that contain the
FXOS8700 sensor to enable the magn_polling sample application.
Signed-off-by: Maureen Helm <maureen.helm@intel.com>
In order to bring consistency in-tree, migrate all boards code to the
new prefix <zephyr/...>. Note that the conversion has been scripted,
refer to zephyrproject-rtos#45388 for more details.
Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
Remove pinmux file where possible, and remove all pinmux driver usage
where file cannot be removed. All kinetis boards no longer use pinmux
driver.
Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
If more information is required on anything, one should look at
documentation, no point to add a specific comment about it.
Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
USB devicetree nodes in Zephyr have different names,
mostly derived from the designations in data sheets.
Add zephyr_udc0 (USB device controller) nodelabel to
specific USB node to allow generic USB sample to be build.
Follow up on commit b4242a8 ("boards: add USB node aliases")
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
Adds arduino_spi to the list of supported features for all NXP boards
that define an arduino_spi node in their device tree. This enables
twister to select these boards for tests or samples the depend on this
feature.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Remove board code and a few associated samples/tests that explicitly
call pinmux_pin_set() to set a given pin as GPIO. This is handled as
part of gpio_mcux_configure() so we don't need to do it again.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
Add pinctrl-0 properties for configuration of peripherals like UARTs,
I2C, SPI, FTMs, etc. These settings are based on what is defined in
the board/pinmux.c file.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
There's no obvious reason that PTC11 should be as a GPIO pin when SPI0
is being utilized. As such remove this pin setting.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
The chipselect is wired to PTC4 and is SPI0_PCS0. Fix pinmux.c and
board docs to correctly reflect this.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
Add dts files for the specific chip instances that are used on the
boards in prep of having pin data in devicetree. The pin data will
be specific to the given chip instance so we need to distinguish
unique chips for the same SoC as the pin mux will differ.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
Remove SPI_[0-8] and SPI_[0-8]_OP_MODES Kconfig symbols as no driver
uses them anymore. We also cleanup board and sample code to remove
use of these symbols.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
Switch to use DEVICE_DT_GET instead of device_get_binding for pinmux
device. As part of this change drop the "label" property from
the pinmux devicetree node and update the binding and dts files to
reflect that.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
Provide the arduino_i2c node name from i2c_0.
Provide pinmux for frdm_stbc_agm01.
The frdm_stbc_agm01 supplies access to an FXOS8700 and FXAS21002.
when using frdm_stbc_agm01 with frdm_k22f, the FXAS21002 sample
sensor project can be utilized and the FXOS8700 sample sensor
project utilizes the shield's FXOS8700.
Signed-off-by: Ryan Holleran <rhollerar@gmail.com>
Now that device_api attribute is unmodified at runtime, as well as all
the other attributes, it is possible to switch all device driver
instance to be constant.
A coccinelle rule is used for this:
@r_const_dev_1
disable optional_qualifier
@
@@
-struct device *
+const struct device *
@r_const_dev_2
disable optional_qualifier
@
@@
-struct device * const
+const struct device *
Fixes#27399
Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
The OPENSDA_FW and LPCLINK_FW cmake variables are remnants of pre-west
days where we used an environment variable to set the desired debug host
tool, such as jlink or pyocd, based on which debug probe firmware was
loaded on the board. We now have two possible ways to do this, neither
of which requires the nxp-specific OPENSDA_FW or LPCLINK_FW variables:
1. Set standardized cmake runner variables when generating the build
system:
$ west build -- -DBOARD_FLASH_RUNNER=jlink -DBOARD_DEBUG_RUNNER=jlink
2. Use the west "--runner" argument with the debug and flash commands:
$ west debug -r jlink
Remove the now unnecessary OPENSDA_FW ond LPCLINK_FW variables and
update board documentation accordingly.
A few boards (frdm_kw41z, hexiwear_k64, mimxrt10{20,50,60,64}_evk)
reordered pyocd.board.cmake and jlink.board.cmake includes to preserve
the default runner when OPENSDA_FW was not explicitly set.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Conditionalizes i2c pinmuxes on CONFIG_I2C for all nxp boards (kinetis,
lpc, and imx families) to avoid possible conflicts between peripherals.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Conditionalizes spi pinmuxes on CONFIG_SPI for all nxp boards (kinetis,
lpc, and imx families) to avoid possible conflicts between peripherals.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Conditionalizes serial pinmuxes on CONFIG_SERIAL for all nxp boards
(kinetis, lpc, and imx families) to avoid possible conflicts between
peripherals.
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
Several reviewers agreed that DT_HAS_NODE_STATUS_OKAY(...) was an
undesirable API for the following reasons:
- it's inconsistent with the rest of the DT_NODE_HAS_FOO names
- DT_NODE_HAS_FOO_BAR_BAZ(node) was agreed upon as a shorthand
for macros which are equivalent to
DT_NODE_HAS_FOO(node) && DT_NODE_HAS_BAR(node) &&
- DT_NODE_HAS_BAZ(node), and DT_HAS_NODE_STATUS_OKAY is an odd duck
- DT_NODE_HAS_STATUS(..., okay) was viewed as more readable anyway
- it is seen as a somewhat aesthetically challenged name
Replace all users with DT_NODE_HAS_STATUS(..., okay), which is
semantically equivalent.
This is mostly done with sed, but a few remaining cases were done by
hand, along with whitespace, docs, and comment changes. These special
cases include the Nordic SOC static assert files.
Signed-off-by: Martí Bolívar <marti.bolivar@nordicsemi.no>
The Kconfig I2C_[0-9] sybmols don't have any meaning for the majority of
SoCs. The drivers doesn't utilize them and no sample or test code does
either so we can remove setting them in board Kconfig.defconfig files.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
Rename DT_HAS_NODE to DT_HAS_NODE_STATUS_OKAY so the semantics are
clear. As going forward DT_HAS_NODE will report if a NODE exists
regardless of its status.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
The Kconfig PWM_[0-3] sybmols don't have any meaning for kinetis family
SoCs. The driver doesn't utilize them and no sample or test code does
either so we can remove setting them in board Kconfig.defconfig files.
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>