When in an invalid state, the board could not flash anymore.
Like for example after flashing `tests/driver_adt7310` this makes it
flash again.
I used `reset_config srst_only` as the other kinetis boards are also
configured that way.
Do not set 'OPENOCD_EXTRA_INIT' but rely on
'openocd/openocd-adapters/dap.inc.mk' to select the adapter.
Using 'OPENOCD_EXTRA_INIT' for this was deprecated.
When 'DEBUG_ADAPTER_ID' was set it was already the case but not with
'SERIAL'.
The compatibility with using 'SERIAL' is maintained.
cpu/$(CPU)/Makefile.features and cpu/$(CPU)/Makefile.dep are
automatically included
Part of moving CPU/CPU_MODEL definition to Makefile.features to have it
available before Makefile.include.
Keep the compiled '.bin' file to remove the need to compile it when
flashing. This remove the need to have the toolchain when flashing so
allow compiling and flashing with `BUILD_IN_DOCKER=1` without a local
toolchain.
Even if it ends up storing a binary, the file is only 34 bytes.
With the canned recipe for flashing, flash dependencies should be
added to FLASHDEPS, instead of writing `flash: dependencies`. This
ensures that both flash and flash-only depend on the same prerequisites.
This allows a board configuration to select which kind of averaging
should be applied to the pin instead of always using 32 sample average.
Very high impedance sources may need to disable hardware averaging in
order to give correct values, the on-chip temperature sensor is one such
signal source.
MCPU is already defined to `CPU_ARCH` which is `cortex-m4`.
Removing this line does not change the value:
make --no-print-directory -C examples/hello-world/ BOARD=pba-d-01-kw2x \
info-debug-variable-CPU_ARCH info-debug-variable-MCPU
cortex-m4
cortex-m4
A dispatcher function is implemented for directing writes to the correct
function. The dispatcher is bypassed completely if the CPU only contain
one kind of UART module.
There are at least two different UART hardware modules deployed in
different Kinetis CPU families (or possibly three or more when counting
variations of the UART module). The UART module is an older 8 bit module
with advanced functionality, while the LPUART is a 32 bit module with
focus on low power consumption.
- The older families in the K series all have UART modules.
- The K22F family have both UART and LPUART modules in the same CPU.
- Older L series (e.g. KL25Z) have two variations of the UART module
- Newer L series (e.g. KL43Z) have LPUART modules, and sometimes
UART as well.
- Newer W series (KW41Z) have only LPUART