Commit graph

190 commits

Author SHA1 Message Date
Maureen Helm 9039d6fd6e samples: nvs: Use depends_on to select platforms
Removes the platform whitelist, leaving just the depends_on/supported
pattern to select which platforms the sample can run on.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2018-08-25 07:13:56 -07:00
Carles Cufi 957262e37d build: Replace GCC ARM Embedded with GNU Arm Embedded
The old GCC ARM Embedded website on launchpad
(https://launchpad.net/gcc-arm-embedded) has been superseeded by the new
GNU Arm Embedded one
(https://developer.arm.com/open-source/gnu-toolchain/gnu-rm).

This also means a change of name from "GCC" to "GNU". Reflect this in
the enviroment variables so that the proper term is used henceforth.

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2018-08-09 13:57:55 +02:00
Michael Scott 01745c3844 boards: arm: frdm_k64f: add settings to use WNC-M14A2A LTE-M modem
These settings enable use of the WNC-M14A2A LTE-M modem as the default
network interface instead of ethernet.

They include the following settings when MODEM_WNCM14A2A is selected:
- UART 2 setup
- Avoid ETH_0 setup due to pin conflicts
- DTS addition for WNC-M14A2A
- Kconfig settings for modem driver

Signed-off-by: Michael Scott <mike@foundries.io>
2018-08-06 10:43:46 +03:00
Michael Scott d917f23959 boards: arm: k64f: add settings for UART_2
UART_2 can be used with an LTE-M modem shield for FRDM_K64F.

Let's add settings for it.

Signed-off-by: Michael Scott <mike@foundries.io>
2018-08-06 10:43:46 +03:00
Arjun Warty f5569a9dd3 frdm_k64f: dts: Addition of a Flash Partion
Addition of a Flash partition to the 'frdm_k64f.dts' file in the
currently existing 'Application Area' (Partition Location: 0x0001e000
Partition Size:0x00002000). This partitioned area can be used as a FCB
for Bluetooth and other applications.

Signed-off-by: Arjun Warty <arjun.warty@nxp.com>
2018-07-16 09:56:24 -05:00
Alex Tereschenko 3c1a78ea0d cmake: replace PROJECT_SOURCE_DIR with ZEPHYR_BASE
Both variables were used (with the same value) interchangeably
throughout CMake files and per the discussion in GH issue,
ZEPHYR_BASE is preferred.

Also add a comment with explanation of one vs. the other.

Tested by building hello_world for several boards ensuring no errors.

Fixes #7173.

Signed-off-by: Alex Tereschenko <alext.mkrs@gmail.com>
2018-06-18 15:25:55 -04:00
Johann Fischer 547128e328 boards: frdm_k64f: add USB comment to documentation
Add USB comment to documentation.

Signed-off-by: Johann Fischer <j.fischer@phytec.de>
2018-05-30 11:23:39 -05:00
Ulf Magnusson a3128e6a2c boards: defconfig: Consistently quote string defaults
In preparation for introducing a warning.

Unquoted string defaults work through a quirk of Kconfig (undefined
symbols get their name as their string value), but look confusing. It's
done inconsistently now too.

Suggested by Kumar Gala.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2018-05-26 19:17:48 -04:00
Maureen Helm c976dbb233 boards: Document watchdog driver support on k64, kw2xd boards
Updates documentation for the frdm_k64f, hexiwear_k64, and usb_kw24d512
boards to reflect that they now support a watchdog driver. Updates the
board yamls similarly for sanitycheck.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2018-05-17 15:00:55 -05:00
Johann Fischer 45156f6e71 samples: cdc_acm: enable sanitycheck for Kinetis boards
Enable sanitycheck for FRDM-K64F and USB-KW24D512 boards

Signed-off-by: Johann Fischer <j.fischer@phytec.de>
2018-05-17 07:00:49 -05:00
Johann Fischer d8cd119562 dts: arm: nxp: use DT to configure USBD on Kinetis SoC
Add DT and fixup files to configure USB device driver on
Kinetis SoC K64F and KW24D512.

Signed-off-by: Johann Fischer <j.fischer@phytec.de>
2018-05-17 07:00:49 -05:00
Maureen Helm 0d1beb2f9e boards: dts: Add mcr20a bindings and fix networking samples
Adds dts bindings for the mcr20a wireless transceiver. The frdm_k64f
board supports the mcr20a via an Arduino shield, therefore the dts node
is added to the board dts. The kw2xd is a SiP and thus the mcr20a dts
node is added to the soc dts.

The networking samples using prj_frdm_k64f_mcr20a.conf have been broken
since the refactoring of the mcux gpio driver to dts in commit
4e8f29f319. The sample is now fixed.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2018-05-10 15:43:42 -05:00
Maureen Helm ae2a9b0f3e boards: Select HAS_DTS_SPI_DEVICE on kinetis boards
Selects the config HAS_DTS_SPI_DEVICE on all kinetis boards that support
the mcux dspi driver.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2018-05-10 15:43:42 -05:00
Maureen Helm cae9074492 spi: Refactor mcux dspi driver to use dts
Get the driver name, base address, irq number, and irq priority from
dts.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2018-05-10 15:43:42 -05:00
Maureen Helm 90ac25f736 boards: dts: Add fxos8700 interrupt bindings and fix sensor sample
Adds dts bindings for the fxos8700 interrupt pins to all boards that
have this sensor. The frdm_k64f and hexiwear_k64 connect both sensor
interrupt pins to the mcu, but the frdm_kw41z connects only one.

The fxos8700 driver is currently only aware of one sensor interrupt pin,
therefore the routing of INT1 or INT2 to the driver is handled in each
board's dts.fixup.

The fxos8700 sample application has been broken since the refactoring of
the mcux gpio driver to dts in commit
4e8f29f319. The sample is now fixed.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2018-05-10 15:43:42 -05:00
Maureen Helm f64657e881 frdm_k64f: Fix pin name typos in the board doc
The frdm_k64f board document incorrectly listed spi signals on PTCD
pins, which don't exist. They should be on PTD pins.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2018-05-08 14:44:01 -05:00
Erwan Gouriou a27c0ede12 dts/st: dtc v1.4.6 warnings: #address-cells/#size-cells without "ranges"
To prepare to upcoming dtc v1.4.6, fix warnings in dts files.

This commit addresses the following warning:
"unnecessary #address-cells/#size-cells without "ranges" or child
"reg" property in /gpio_keys".

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
2018-04-24 14:46:48 -05:00
Maureen Helm c627de1f87 boards: Move led and button definitions to dts for kinetis boards
Adds led and button dts nodes to all kinetis boards and removes the
now unused preprocessor macros from board.h.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2018-04-20 08:54:11 -05:00
Kumar Gala c542c0e33e boards: dts: Cleanup aliases
Underscore ('_') isn't a valid char for alias names based on the device
tree spec.  Newer dtc compilers flag this as a warning so lets clean it
up.  Replaced '_' with '-' to keep things simple.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-04-12 04:03:46 -05:00
Anas Nashif 2ee6dff77b boards: fix yaml syntax and reduce indentation
Minor indentation fix

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2018-04-09 22:55:20 -04:00
Kumar Gala 5ac590a316 arch: arm: Add one hardware platform to default testing
The arm qemu platform has limitiations as we get into more complicated
features like userspace support.  Add one hardware platform to catch
issues in sanitycheck for development of such features.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-03-05 12:35:27 -05:00
Marti Bolivar 527e5dabe7 boards: dts: replace comments with links to documentation
Let's point users at the latest documentation on flash
partitions from each of the board files, rather than duplicating some
of the information in it.

Signed-off-by: Marti Bolivar <marti@opensourcefoundries.com>
2018-02-22 18:52:42 +01:00
Kumar Gala 340bc66f24 dts: nxp: Refactor k64 dts.fixup into arch/arm/soc
Move common SoC dts.fixup defines into
arch/arm/soc/nxp_kinetis/k6x/dts.fixup so we remove duplication in the
boards and only have board specific defines in
boards/arm/<FOO>/dts.fixup.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-02-21 11:38:36 -06:00
Maureen Helm e27673a2f4 frdm_k64f: Add sensor dts nodes and fixups
Adds dts nodes and fixups for the fxos8700 sensor to the frdm_k64f
board. Tested with samples/sensor/fxos8700

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2018-01-31 10:17:58 -06:00
Maureen Helm d41fe91e65 boards: arm: Configure jlink flash runner on nxp boards
Now that the jlink runner supports the flash command, set
BOARD_FLASH_RUNNER when the OpenSDA or LPCLink debug adapter is
programmed with jlink firmware.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2018-01-29 23:15:16 -05:00
Maureen Helm dfdf5e37e1 boards: Move default pinmux enable to <board>_defconfig
Most boards enable the pinmux by default by setting CONFIG_PINMUX=y in
<board>_defconfig, but several boards did it in Kconfig.defconfig
instead. Several code reviews, such as #5043, have suggested using a
select in Kconfig.board to enable the pinmux, however this caused
warnings:

warning: (BOARD_LPCXPRESSO54114) selects PINMUX which has unmet direct
dependencies (BOARD_FRDM_K64F || BOARD_FRDM_KL25Z || BOARD_FRDM_KW41Z ||
BOARD_HEXIWEAR_K64 || BOARD_USB_KW24D512 || BOARD_GALILEO)

Fix how these boards enable the pinmux so they are more consistent with
other boards.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2018-01-18 11:40:56 -06:00
Carles Cufi 7d764b35f3 cmake: Use path-corrected version of ZEPHYR_BASE
Instead of accessing the environment variable ZEPHYR_BASE every time we
require accessing the source code root, use an intermediate variable
that has OS path separators correctly set to '/' to avoid issues on
Windows.

Note: This removes the ZEPHYR_SOURCE_DIR CMake variable. External
applications using that will need to change to use the new ZEPHYR_BASE
variable.

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2018-01-11 14:59:03 -05:00
Vakul Garg aded95b888 eth: mcux: Enable ETH_MCUX_0 conditionally
ETH_MCUX_0 needs to be turned on when CONFIG_NET_L2_ETHERNET is enabled.
If CONFIG_NET_L2_ETHERNET is disabled (e.g. when configured for 6loble),
then ETH_MCUX_0 should remain disabled.

Signed-off-by: Vakul Garg <vakul.garg@nxp.com>
2018-01-02 13:33:18 -05:00
Marti Bolivar 7a3462de7a scripts: runner: use arguments, not environment vars
The various runners (flash/debug scripts) use environment variables to
take arguments. This is legacy behavior which is not desirable.

Use command line arguments instead.

Note: this leaves more general environment variables with publicly
      documented behavior in place for now, for compatibility, e.g.:

      ZEPHYR_FLASH_OVER_DFU, OPENSDA_FW, ESP_IDF_PATH, PYOCD_DAPARG

For example, when using dfu-util to flash arduino_101, instead of
setting DFUUTIL_PID, DFUUTIL_ALT, and DFUUTIL_IMG environment
variables, have the script invocation look like this:

  python3 .../zephyr_flash_debug.py dfu-util flash \
          [common arguments omitted] \
          --pid=8087:0aba --alt=x86_app \
          --img=.../build/zephyr/zephyr.bin

Make similar changes for other runners (openocd, etc.) and
targets (debug, debugserver).

To implement this in the scripts:

  - have the individual scripts/support/runner/some-runner.py files
    register their own command line arguments

  - teach them to construct instances from arguments, not the
    environment

  - have zephyr_flash_debug.py request runners to register command
    line argument parsers, and handle arguments

In the build system:

  - add a new board_runner_args() extension function that board.cmake
    files can use to add to the zephyr_flash_debug.py command line

  - adjust cmake/flash/CMakeLists.txt to invoke with arguments

  - add new helper include files for each runner (like
    boards/common/dfu-util.board.cmake, etc.), which add default
    options as needed and then add on overrides from
    board_runner_args() calls

  - update board.cmake files to use the new includes and extension

This implied some tweaking when using openocd to make the CMake string
escaping and unescaping work properly.

Signed-off-by: Marti Bolivar <marti@opensourcefoundries.com>
2017-12-15 09:57:30 -05:00
Marti Bolivar e33ec242fd scripts: refactor flash/debug scripts to remove "shell"
The Python-based runners have replaced the old shell scripts. Refactor
the build system accordingly:

- FLASH_SCRIPT is now BOARD_FLASH_RUNNER
- DEBUG_SCRIPT is now BOARD_DEBUG_RUNNER

The values, rather than being the names of files, are now the names of
runners in scripts/support/runner. They are still short, descriptive
names like "openocd", "jlink", "em-starterkit", etc.

Adjust the zephyr_flash_debug.py call and runner internals
accordingly. Have each runner class report a name and the commands it
can handle. This lets us move some boilerplate from each do_run()
method into the common run() routine, and enables further improvements
in future patches.

The handles_command() method is temporary, and will be replaced by a
more general mechanism for describing runner capabilities in a
subsequent patch. The initial use case for extending this is to add
device tree awareness to the runners.

To try to avoid user confusion, abort the configuration if an
xxx_SCRIPT is defined.

Signed-off-by: Marti Bolivar <marti@opensourcefoundries.com>
2017-12-15 09:57:30 -05:00
Marti Bolivar f0c95919b0 doc: boards: arm: convert make to cmake
Unify documentation formatting and use zephyr-app-commands where
applicable.

Signed-off-by: Marti Bolivar <marti@opensourcefoundries.com>
2017-11-10 18:35:50 -05:00
Sebastian Bøe f0346bfac0 flash: Change type of FLASH_SCRIPT_ENV_VARS
The old way of constructing FLASH_SCRIPT_ENV_VARS was corrupting the
values that were passed to the flasher. This new method is the
standard way of creating a dictionary/hashmap in CMake and does not
suffer from the same problem.

This fixes
https://github.com/zephyrproject-rtos/zephyr/issues/4844#event-1334599401

Signed-off-by: Sebastian Boe <sebastian.boe@nordicsemi.no>
2017-11-10 07:54:54 -05:00
Kumar Gala ef912810d3 dts: Move dts files into board dirs
Move the dts files into the board dir so that board ports can be more
standalone.  This will allow us at some point to have board ports
outside of the tree.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2017-11-09 14:23:41 -06:00
Kumar Gala 09c63b373a dts: Move fixup files into board dirs
Move the dts fixup files into the board dir so that board ports can be
more standalone.  This will allow us at some point to have board ports
outside of the tree.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2017-11-09 14:23:41 -06:00
Sebastian Bøe 0829ddfe9a kbuild: Removed KBuild
Signed-off-by: Sebastian Boe <sebastian.boe@nordicsemi.no>
2017-11-08 20:00:22 -05:00
Sebastian Bøe 12f8f76165 Introduce cmake-based rewrite of KBuild
Introducing CMake is an important step in a larger effort to make
Zephyr easy to use for application developers working on different
platforms with different development environment needs.

Simplified, this change retains Kconfig as-is, and replaces all
Makefiles with CMakeLists.txt. The DSL-like Make language that KBuild
offers is replaced by a set of CMake extentions. These extentions have
either provided simple one-to-one translations of KBuild features or
introduced new concepts that replace KBuild concepts.

This is a breaking change for existing test infrastructure and build
scripts that are maintained out-of-tree. But for FW itself, no porting
should be necessary.

For users that just want to continue their work with minimal
disruption the following should suffice:

Install CMake 3.8.2+

Port any out-of-tree Makefiles to CMake.

Learn the absolute minimum about the new command line interface:

$ cd samples/hello_world
$ mkdir build && cd build
$ cmake -DBOARD=nrf52_pca10040 ..

$ cd build
$ make

PR: zephyrproject-rtos#4692
docs: http://docs.zephyrproject.org/getting_started/getting_started.html

Signed-off-by: Sebastian Boe <sebastian.boe@nordicsemi.no>
2017-11-08 20:00:22 -05:00
Paul Sokolovsky 960708d517 board: frdm_k64f, frdm_kw41z, frdm_kl25z: Define LED1
To make more cross-board samples work.

Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
2017-11-07 12:24:29 -06:00
Anas Nashif 95a8b20c9f boards: add supported features
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2017-10-17 08:55:38 -04:00
Kumar Gala 54933b3833 i2c: mcux: Remove usage of CONFIG_I2C_x_DEFAULT_CFG
Stop using CONFIG_I2C_x_DEFAULT_CFG to get the initial value.  Since we
only support master mode we always default to it for initial config and
we get the bitrate from the device tree.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2017-08-16 10:03:34 -05:00
Maureen Helm 469ddab780 pwm: Remove k64-specific driver and k20_sim.h
Now that we have an mcux shim driver, remove the old k64-specific
driver. Also remove include/drivers/k20_sim.h, since the old
k64-specific driver was the only thing left using it.

Jira: ZEP-2025

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-08-09 18:13:29 -04:00
Maureen Helm f458b399b0 frdm_k64f: Enable ftm driver instance and pins
If the ftm driver is enabled, use an instance routed to the Arduino
header and configure the pinmux accordingly. Unlike the hexiwear_k64,
the pins routed to the RGB led cannot be muxed as ftm channels.

Jira: ZEP-2025

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-08-09 18:13:29 -04:00
Johan Hedberg 2975ca0754 Bluetooth: Kconfig: Rename CONFIG_BLUETOOTH_* to CONFIG_BT_*
The API name space for Bluetooth is bt_* and BT_* so it makes sense to
align the Kconfig name space with this. The additional benefit is that
this also makes the names shorter. It is also in line with what Linux
uses for Bluetooth Kconfig entries.

Some Bluetooth-related Networking Kconfig defines are renamed as well
in order to be consistent, such as NET_L2_BLUETOOTH.

Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2017-08-09 11:14:19 +03:00
Anas Nashif 56d88584db boards: support feature classes in yaml
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2017-08-02 07:31:22 -04:00
Kumar Gala 0e7067c6be arm: dts: cleanup uart related Kconfig options
Now that we generate BLUETOOTH_UART_ON_DEV_NAME, UART_PIPE_ON_DEV_NAME,
and BLUETOOTH_MONITOR_ON_DEV_NAME Kconfig defines for dts enabled
platforms add those into the appropriate dts files and remove from the
various board/Kconfig.defconfig files.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2017-07-25 12:23:20 -05:00
Maureen Helm afff3df786 frdm_k64f: Select flash/debug scripts based on OpenSDA firmware
Adds a new variable to define which OpenSDA firmware is on the board,
and selects the default flash/debug scripts accordingly.

Sets the default to daplink since the flashing and debugging examples in
the board document were written to use pyocd.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-07-19 14:28:08 -05:00
Kumar Gala 563f8f1464 i2c: mcux: Convert to supporting device tree
Update the MCUX I2C driver and related platforms to get their I2C
information from the device tree.  We also updated a few of the sensor
drivers found on the FRDM & Hexiwear boards to get their I2C bus name
from the device tree instead of directly from Kconfig.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2017-07-19 14:28:08 -05:00
Maureen Helm 4d7d09bc84 frdm_k64f: Enable adc driver instance and pins
Enables a usable adc driver instance based on the board design and
configures the pinmux to enable the SoC's PTB10 pin, which is routed to
the Arduino header A2 pin. Updates the board documentation to reflect
that the board now supports an adc driver.

Jira: ZEP-1396

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-07-19 14:28:08 -05:00
Anas Nashif f131e9f6ea boards: mark boards with built-in networking support
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2017-07-06 10:34:41 -05:00
Anas Nashif a4a9553422 boards: frdm_k64f: enable ethernet for networking
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2017-07-05 12:43:13 -04:00
Kumar Gala bced2e8a63 board: frdm_k64f: allow overriding default debug/flash scripts
As there are multiple ways to flash or debug (pyOCD or openOCD) allow
the user to override the default.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2017-06-23 15:05:10 -05:00
Anas Nashif 458d217398 update: board names
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2017-06-21 20:56:53 -04:00
Anas Nashif 295897c191 boards: add board meta-data
Add board metadata to be consumed by the sanitycheck script to provide
better matching with testcases and to test based on features declated in
the board files.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2017-06-21 20:56:53 -04:00
David B. Kinder fffb5d9c90 eoc: move non-board docs from boards TOC list
A couple of docs were created in previous PRs with board support
information common to a few boards.  Move these to a new section
for "Board Support Tools".  (I debated about hiding them completely
but decided it would still be useful to have these tool docs appear
in the table of contents, just not embedded with the supported boards
docs.)

Moved these board tools docs over to the doc/ folder and out of
boards/ and removed these pages from the navigation index.

JIRA: ZEP-2285

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2017-06-17 07:07:28 -04:00
Andrew Boie ef2e463493 frdm_k64f: default to pyocd.sh for flashing/debug
The wiki directions indicate that this script should be used,
and openocd.sh doesn't even work. Switch to pyocd.sh by default.

Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
2017-06-08 13:49:36 -05:00
Maureen Helm c3321b5918 doc: Update NXP board docs for pyOCD and Segger J-Link
Now that NXP boards support 'make flash' and 'make debug' via pyOCD and
Segger J-Link, update all the NXP board docs accordingly. Adds a new
generalized OpenSDA document so certain details don't have to be
repeated for every OpenSDA board.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-05-19 10:06:48 -04:00
Vincenzo Frascino adf0bf90b6 arm: soc: nxp k6x: Add Initial support for NXP MPU
This patch adds initial MPU support to NXP K6x family.
The boot configuration prevents the following security issues:
* Prevent to read at an address that is reserved in the memory map.
* Prevent to write into the boot Flash/ROM.
* Prevent from running code located in SRAM.

This driver has been tested on FRDM-K64F.

Change-Id: I907168fff0c6028f1c665f1d3c224cbeec31be32
Signed-off-by: Vincenzo Frascino <vincenzo.frascino@linaro.org>
2017-05-16 09:28:06 -05:00
Kumar Gala 26811defc7 arm: dts: Cleanup HAS_DTS
Now that all ARM platforms have a device tree we can move selecting of
HAS_DTS up and remove any !HAS_DTS cases, as well as setting in all the
defconfigs.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2017-05-15 13:22:54 -04:00
Maureen Helm f49e199c27 scripts: Add flash and debug support using pyOCD on NXP boards
Adds a new debug support script using pyOCD and configures most NXP
boards so they can use it. frdm_kw41z is the one exception because pyOCD
doesn't yet support kw41z. Tested with pyOCD v0.8.0 and the latest
DAPLink firmware for each board.

Introduces two new environment variables, PYOCD_FLASHTOOL and
PYOCD_GDBSERVER, that allow you to set custom paths to the pyOCD tools.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-05-15 13:22:54 -04:00
Maureen Helm c16ad344e9 scripts: Add support for 'make debug' using Segger JLink on NXP boards
Adds a new debug support script using Segger JLink and configures all
NXP boards so they can use it. Tested with Segger JLink GDB server
V6.14b and OpenSDA v2.1 firmware.

Change-Id: Ia1b297d9c93d21db61379e22f27ae54cda3ad461
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-05-15 13:22:54 -04:00
David B. Kinder 2f41cb8329 doc: misspelling and UTF-8 fixes
More general spelling fixes, and cleaning up stray UTF-8 characters
such as curly-quotes, em- and en-dashes.  Use replacement strings
for |reg| and |trade|.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2017-05-09 20:15:49 -04:00
Kumar Gala 117f24f458 arm: dts: Remove !HAS_DTS Kconfig bits
For the SoCs in which all the boards for that platform are using dts we
can remove the Kconfig bits that are now coming from device tree.

Change-Id: Iccf4c84beb83fa1c516b6166f94de37b4a0162ae
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2017-04-04 17:55:13 -05:00
Marcus Shawcroft bbada2de50 eth/mcux: Add basic PHY support.
Add basic PHY management sufficient to detect link up, link down and
auto negotiated link speed / duplex.  The PHY driver is implemented as
a state machine that executed in the system work queue.  The
implementation is non blocking, using the MII interrupt to capture the
completion of read and write events.

This PHY management should be fairly generic. In the future, it may be
beneficial to pull this code out as a standalone PHY driver for use
with other ethernet drivers.

JIRA: ZEP-1674

Change-Id: I3dcb5c14982ef4b40591fcf10d84840b8a2558e5
Signed-off-by: Marcus Shawcroft <marcus.shawcroft@arm.com>
2017-02-14 08:30:34 +02:00
Andy Gross 4192dcc6bc dts: arm: Kinetis: Add FRDM_K64F support
This patch adds DTS support for the FRDM_K64F board.  The defconfig
enables the DTS usage and the FRDM K64F specific DTS file provides the
differences from the base Kinetis DTS definitions.

A fixup file is provided to map the generated configuration information
to the driver consumers.  The fixup file will be removed once the
drivers are modified to handle the newly generated information.

Change-Id: Ib0ada28faff6a30e8b40eba5c5853e9018ae5fcb
Signed-off-by: Andy Gross <andy.gross@linaro.org>
2017-02-10 18:13:59 +00:00
Andy Gross ddce7dea40 dts: arm: Kinetis: Add base support for Kinetis
This patch adds DTS support and related files for the NXP Kinetis
platform.  The DTS files contain the base definitions for the hardware
nodes on Kinetis platforms.  The YAML files provide the definitions of
the contents of the DTS nodes.

The Kconfig changes were put in place to allow for the conversion of
existing drivers.  Once those drivers are modified, the Kconfig options
that are replaced by the DTS information will be removed.

Change-Id: If110fffa99c0b12471cf2df206da6687277e4756
Signed-off-by: Andy Gross <andy.gross@linaro.org>
2017-02-10 18:13:59 +00:00
Wojciech Bober 573774a9bf drivers/net/ieee802154: Change configuration prefix
This commit changes Kconfig prefix for ieee802154 drivers to
IEEE802154_*. This is done for consistency with config prefixes
used in other subsystems.

Change-Id: Ibbb4d96d2b748f4f13135bde85304ec34c5a90a6
Signed-off-by: Wojciech Bober <wojciech.bober@nordicsemi.no>
2017-02-08 10:12:35 +02:00
Paul Sokolovsky 08e0ade38a doc: frdm_k64f: Document Eth PHY known issue
Working Ethernet, and actually even successfully booting with Ethernet
enabled (and Ethernet is enabled by default on enabling networking)
so far requires a network cable attached.

Change-Id: I9c17e417f867942ddf085db9e8342e945aa07370
Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
2017-02-06 22:53:30 +03:00
David B. Kinder e23099bcc4 doc: add cross-references to hello_world sample
Change-Id: I23c4d361251251cce8887dd67be2e548f7365491
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2017-02-03 22:57:05 +00:00
Maureen Helm 2e7a75c69b frdm_k64f: Add RST board documentation
Change-Id: I1027fce12b4f7153b02beadd5257e7d8956e1d7a
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-01-30 11:02:36 -06:00
Johann Fischer fcf27119a7 boards: frdm_k64f: add pinmux settings for MCR20A
Change-Id: Ifc4689983340e43bbd94c6b0cee8ef300c65fb30
Signed-off-by: Johann Fischer <j.fischer@phytec.de>
2017-01-27 12:35:51 +02:00
Maureen Helm bb45fd526e frdm_k64f: hexiwear_k64: Remove defaults for the uart_k20 driver
Jira: ZEP-719
Change-Id: If1d3e1d450f582d6d3d500385e7fc15afe00b79f
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-01-23 15:15:53 -06:00
Maureen Helm 8c3d4f770a k64: Change the default serial driver to the mcux one
Stop using the specific uart_k20 driver by default and start using the
more generic mcux uart driver instead.

Jira: ZEP-719
Change-Id: I7b107ea7118887591362159283ebb5413b45595a
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-01-23 15:15:53 -06:00
Maureen Helm 2e205e69d1 frdm_k64f: hexiwear_k64: Add defaults for the mcux serial driver
Jira: ZEP-719
Change-Id: I4e325df0d91b93ec832a50a24a8f3c34778281e8
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-01-23 15:15:53 -06:00
David B. Kinder ac74d8b652 license: Replace Apache boilerplate with SPDX tag
Replace the existing Apache 2.0 boilerplate header with an SPDX tag
throughout the zephyr code tree. This patch was generated via a
script run over the master branch.

Also updated doc/porting/application.rst that had a dependency on
line numbers in a literal include.

Manually updated subsys/logging/sys_log.c that had a malformed
header in the original file.  Also cleanup several cases that already
had a SPDX tag and we either got a duplicate or missed updating.

Jira: ZEP-1457

Change-Id: I6131a1d4ee0e58f5b938300c2d2fc77d2e69572c
Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2017-01-19 03:50:58 +00:00
Maureen Helm a758429b1e frdm_k64f: hexiwear_k64: Remove defaults for the k64 gpio driver
Jira: ZEP-1394
Change-Id: Ie0dd812ebca6306413300c6160f00ee764ebd4c2
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-01-12 09:46:27 -06:00
Maureen Helm bd40ca8741 frdm_k64f: hexiwear_k64: Add defaults for the mcux gpio driver
Jira: ZEP-1394
Change-Id: I1371e5a1a65dd85a8dd93b2c5d113d7520d5656f
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-01-12 09:46:27 -06:00
Maureen Helm c070aa74dd frdm_k64f: hexiwear_k64: Fix accel interrupt pinmux settings
The k64 gpio driver quietly initializes the pinmux to force the pin to
be a gpio, regardless of the setting defined by the board's pinmux
table, or even if the pin was not in the pinmux table.

This behavior caused the accelerometer interrupt pin to be incorrectly
defined in the frdm_k64f and hexiwear_k64 pinmux tables.

Change-Id: If46df0e051452fef291d5ad5cdff56463d5f465e
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-01-12 09:46:27 -06:00
Maureen Helm 4184c7f82e k64: Move uart console pins to board pinmux tables
Moves the uart console pins from the k64 soc init to the frdm_k64f and
hexiwear_k64 board pinmux tables. Not having these pins in the board
pinmux tables led one to believe that no pins in PORTB were being used
on the hexiwear_k64 board, and thus the port was incorrectly disabled by
default.

Also fixes PORTB to be enabled by default if the uart console is used.

Change-Id: Ide6b7b34dfba8a75a02a8f2bf37cce843afb92f1
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-01-12 09:46:27 -06:00
Maureen Helm 4183dae89b pinmux: Rename ksdk to mcux
Renames the ksdk pinmux driver to mcux.

Change-Id: I7a519318b5b580c47b6f6652a2ae763067d85033
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-01-12 09:46:27 -06:00
Maureen Helm 40f5de5a56 ethernet: Rename ksdk to mcux
Renames the ksdk ethernet shim driver to mcux.

Change-Id: Ief03eabe4ce39be0d0896543c1cb660ff380b439
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-01-12 09:46:26 -06:00
Maureen Helm acca033468 pinmux: Merge ksdk pinmux dev into regular ksdk pinmux driver
Merges the ksdk pinmux dev driver into the regular ksdk pinmux driver,
which now exposes the public pinmux API. Removes the private ksdk pinmux
API and converts the frdm_k64f and hexiwear_k64 boards to use the public
pinmux API.

Jira: ZEP-958, ZEP-1432
Change-Id: Ie5f60b604133093050b9c596050cad776d7b7cb3
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-01-12 09:46:25 -06:00
Maureen Helm fabc001ff3 frdm_k64f: Disable unused pinmux ports by default
Enable PORTD on the frdm_k64f only if SPI_0 is enabled. Otherwise, there
are no pins in the pinmux table for this port and it should be left
disabled.

Change-Id: I7f8a05552f6a320debfd11a780be1092da831101
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2017-01-12 09:46:25 -06:00
Anas Nashif 6d9ed994aa build: use target 'debugserver' for Qemu debugging
Use the existing debugserver target also for Qemu debugging. Qemu
should be maintained as one of many emulation/simulations platforms and
emulation should be abstracted in the Makefiles and not tied to Qemu.

qemugdb will still work, it is however being deprecated.

Change-Id: I0cd10fb66debb939b8f7f1304bf2ef4605da6a1d
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2017-01-10 20:20:46 +00:00
Maureen Helm feef536ada frdm_k64f: Fix basic button sample
The basic button sample expects SW0_GPIO_NAME and SW0_GPIO_PIN macros to
be defined by board.h. The frdm_64f doesn't have a physical switch with
this name, so create an alias to SW3 to make the sample work.

Change-Id: I61eb096582d9898dbcb9799e69078ad0c4b700cf
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2016-12-20 09:14:49 -06:00
Maureen Helm d73ee7e37d frdm_k64f: hexiwear_k64: Fix basic blinky sample
The basic blinky sample expects LED0_GPIO_PORT and LED0_GPIO_PIN macros
to be defined by board.h. The frdm_k64f and hexiwear_k64 boards don't
have a physical LED with this name, so create an alias to the green LED
to make the sample work.

Change-Id: I3426c571bb2e3165dbd9f4372d863b474c35fd5c
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2016-12-20 09:14:49 -06:00
Tomasz Bursztyka 6480594f0a drivers: eth_ksdk: Theres is no longer 'ETHERNET' Kconfig option
Only NET_L2_ETHERNET now.

Change-Id: Ic9bb3c57e0f91c7eeb53cbbfddab085c723a4a5a
Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
2016-12-16 19:14:55 +01:00
Maureen Helm 296c949920 frdm_k64f: Add pin init using ksdk pinmux driver
Some pins were not brought forward from the existing pin init in
drivers/pinmux/k64/pinmux_board_frdm_64f.c because they do not appear to
be used anywhere and it increases power consumption to enable them. For
example, 6 pins were enabled as analog inputs, but there is not yet an
ADC driver for the k64. The pins that were not brought forward are:
	* PTA 0-2
	* PTB 2,3,9-11,23
	* PTC 2-4,10,11

Jira: ZEP-1393
Change-Id: I7410f6d993bd0a4df8f80df72e84def73bcf74cc
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2016-12-10 21:14:12 +00:00
Maureen Helm 8e52d56110 frdm_k64f: Add fxos8700 defaults
Add defaults for the fxos8700 sensor, including which i2c instance, the
slave address, and interrupt pin.

Change-Id: I4b0255308fd5c9b7c43f0f22e8ce2fe86c5e7011
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2016-12-04 12:37:48 +00:00
Maureen Helm 6e6532c703 frdm_k64f: Change default Bluetooth UART dev name
Change the default Bluetooth UART device name to the UART connected to
the arduino header. This allows using the frdm_k64f with a frdm_kw40z
shield board.

Change-Id: Id22950f0a48a7c95bcddc6f1ec044f7a37cb9b72
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2016-11-04 23:00:03 +00:00
Maureen Helm 516d1286a6 k64: Move driver instance defconfigs to boards
The k64 SoC has multiple instances of many peripherals, but which
instances can actually be used depends upon the board design and pinmux
configuration.

Move all instance-specific default driver configurations from the SoC to
the boards (frdm_k64f and hexiwear_k64). Default driver selection
remains in the SoC (e.g., enable the KSDK I2C driver when I2C is
enabled).

This paves the way to support different driver defaults for the
frdm_k64f and hexiwear_k64 boards, but it does not yet change any of the
default values; it only changes where the default values get set.

Change-Id: Id9ed898762eb400ecefeac91ae4dce66da05622d
Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2016-11-03 22:10:36 -05:00
Kumar Gala 8d35760fec board: organize boards based on architecture
Introduce an architecture sorting of boards.  This is to allow for
easier maintenance going forward as the number of boards grows.  It
will be easier for any scripts to know the board/arch mapping without
having to maintain an explicit list of what boards are associated with
which arch.  We can also do things like have architecture maintainers
cover reviews and branches for arch/${ARCH} and boards/${ARCH} going
forward.

Change-Id: I02e0a30292b31fad58fb5dfab2682ad1c5a7d5a7
Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2016-10-24 19:59:42 +00:00