1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
Commit Graph

21674 Commits

Author SHA1 Message Date
Juan Carrano
748bc6deee makefiles/riotboot: use canned recipe for flashing.
A canned recipe had previously been defined to perform the flashing
procedure. The canned recipe is preferred to calling $(FLASHER) $(FFLAGS)
as there might be additional steps involved in flashing (this is handled by
preflash currently but with the canned recipe we will be able to fix it.)
2019-03-05 14:39:57 +01:00
Benjamin Valentin
6e7414e220 makefiles/tools: Automatically detect gdb-multiarch
Modern versions of GDB support multiple targets with the same gdb binary.
At least Ubuntu and Debian have dropped the gdb-arm-none-eabi package in favour
of gdb-multiarch.
Here, no $(PREFIX)-gdb binary is availiable, instead gdb-multiarch should be used.

This patch tries to automatically detect the presense of gdb-multiarch and uses it
instead of arm-none-eabi-gdb.
2019-03-05 14:31:22 +01:00
Francisco Acosta
52d2851747
Merge pull request #11089 from cladmi/pr/riotboot/use_flashfile
tests/riotboot: use FLASHFILE for the generated file
2019-03-05 14:29:02 +01:00
MrKevinWeiss
0738084657 Makefile: add APPLICATION to macro defines
This allows the application code to know what application it is running
2019-03-05 14:00:41 +01:00
Gaëtan Harter
7a88bb4c1f
riotboot: prepare for when FLASHFILE is used
This currently does nothing but setting FLASHFILE when flashing.
This will allow passing the variable when flasher will use the FLASHFILE
variable.
2019-03-05 12:04:15 +01:00
840a096ce6
boards/nrf52840-mdk: fix openocd programmer configuration
For nrf52 based boards, the default adapter is JLink and nrf52840-mdk
uses dap.
2019-03-05 11:48:16 +01:00
Gaëtan Harter
13e852c58c
tests/riotboot: use FLASHFILE for the generated file
FLASHFILE is now a generated file when doing `make all`.
This prepares also for when flashers will use `FLASHFILE` as a file to
be flashed.

It currently still needs the hack below for openocd and edbg.

This also fixes the issue when building 'riotboot' in docker that was
being built with the host toolchain.
2019-03-05 11:22:11 +01:00
Gaëtan Harter
240e4a3fe2
makefiles/riotboot.mk: slots only need to depend on BASELIBS
Using 'link' was working too but will introduce a circular dependency
when FLASHFILE is one of the slot files.

This trims down to the minimal required dependency to work. It is now
the same as `ELFFILE` dependencies.
2019-03-05 11:22:11 +01:00
Gaëtan Harter
ecfdece104
Makefile.include: include 'riotboot.mk' before using FLASHFILE
Include the 'riotboot.mk' file before using FLASHFILE/ELFFILE/HEXFILE
variables. This will allow setting variables to values from riotboot.mk
like `FLASHFILE = $(RIOTBOOT_COMBINED_BIN)` before it is evaluated in
Makefile.include.

It should be included after defining 'BINFILE' for 'riotboot.bin'
handling.
2019-03-05 11:22:11 +01:00
Gaëtan Harter
60f71a1c15
tests/riotboot: use 'RIOTBOOT_COMBINED_BIN' variable
Use the new variable instead of the composed name.
2019-03-05 11:22:11 +01:00
5355f6a7be
Merge pull request #11062 from jcarrano/picocom-no-echo
serial.inc.mk: disable local echo in picocom.
2019-03-05 09:58:59 +01:00
e863adaca2
Merge pull request #11100 from haukepetersen/opt_nrf802154_addrgen
cpu/nrf52/nrf802154: unify address generation
2019-03-04 23:27:37 +01:00
1bed56847a
Merge pull request #11097 from cladmi/pr/murdock/flashfile
makefiles/murdock.inc.mk: do not overwrite FLASHFILE if set
2019-03-04 22:28:59 +01:00
HendrikVE
b5dacb6534 examples/nimble_gatt: extend application with ble characteristics
Extend this application with 2 custom BLE characteristics. One is
read-only and returns a string including a random number and the
second one is writable. In addition, two characteristics for device
information were added (model and manufacturer). Access to the
characteristics produces output on the terminal.
2019-03-04 17:28:19 +01:00
Hauke Petersen
824fcf3c9d cpu/nrf52/nrf802154: unify address generation 2019-03-04 17:12:06 +01:00
Hauke Petersen
7cb1049eef
Merge pull request #10268 from SemjonKerner/add_nrf154
cpu/nrf52/radio: initial support for nrf52's ieee802.15.4 radio
2019-03-04 16:18:43 +01:00
f26425fdaf uncrustify: split lines at 80 chars 2019-03-04 16:14:57 +01:00
Gaëtan Harter
7467d1be75
makefiles/murdock.inc.mk: do not overwrite FLASHFILE if set
If FLASHFILE is set keep the original value.

It changes the variable from an immediate to a deferred variable but if
murdocks keeps working there is no issue.
2019-03-04 15:52:35 +01:00
MichelRottleuthner
1642a03125
Merge pull request #11066 from aabadie/pr/boards/common_f4_clock
boards/common/stm32: rework common clock configuration for stm32f4
2019-03-04 14:10:47 +01:00
Gaëtan Harter
731dcfc319
testrunner: disable local echo
When local echo is enabled, pexpect will also match on send lines to the
node. So could think a node is echoing when it is only seeing the sent
message.
The sent messages are still written to `logfile` but now only once.

This may show issues with our current tests implementation that expected
this behavior.
2019-03-04 13:26:53 +01:00
Gaëtan Harter
622645d03c
Merge pull request #11086 from cladmi/pr/codacy/python_asserts
codacy: disable complaining about python assert
2019-03-04 13:26:05 +01:00
Semjon Kerner
3efeb8056e examples/default: add ieee802.15.4 radio support for all nrf52840 boards 2019-03-04 13:21:47 +01:00
Semjon Kerner
84ebd83a62 boards/nrf52840dk: support ieee802.15.4 radio 2019-03-04 13:21:47 +01:00
Semjon Kerner
20728c2528 sys/auto_init: add auto_init for nrf52 ieee802.15.4 driver 2019-03-04 13:21:47 +01:00
Semjon Kerner
91787dcb5c cpu/nrf52: add 802.15.4 radio driver 2019-03-04 13:21:47 +01:00
Semjon Kerner
c2a40be458 drivers/netdev_ieee802154: add mac header filter 2019-03-04 13:21:43 +01:00
Kevin "Bear Puncher" Weiss
e3e2b6df15
Merge pull request #11084 from cladmi/pr/make/introduce_flashfile
Makefile.include: introduce FLASHFILE
2019-03-01 14:44:31 +01:00
Gaëtan Harter
4a23028265
codacy: disable complaining about python assert
This silents the reported issue in codacy about python asserts:

    Use of assert detected. The enclosed code will be removed when
    compiling to optimised byte code.

The concern is valid about python asserts, but they are used in tests
and python is not run with optimised byte code.

Solution taken from codacy website
https://support.codacy.com/hc/en-us/articles/207994335-Code-Patterns
2019-03-01 13:43:37 +01:00
Sebastian Meiling
d29d336894
Merge pull request #11039 from maribu/avrdude
makefiles/tools: Improved avrdude integration
2019-02-28 22:15:30 +02:00
Marian Buschsieweke
4abc41a227
makefiles/tools: Automatically set avrdude target
The CPU variable in the boards Makefile.include file already contains the target
CPU, so there is no reason to provide it in each board again as avrdude flag.

This commit automatically sets the avrdude target from the CPU variable and
removes the unneeded flags.
2019-02-28 20:55:04 +01:00
Marian Buschsieweke
93cd8a1b04
makefiles/tools: fix avrdude with ICSP programmers
Currently the flag "-P ${PORT}" is added to avrdude regardless of the programmer
used. But this flag should only be set for programmers that operate over a
serial port - e.g. like the various Arduino bootloaders. This commit changes
the behaviour so that the "-P flag" is only set for only of the default
programmers of the various AVR boards supported by RIOT. This allows to use
ICSP programmers (e.g. like the usbtiny) like this:

    make BOARD=arduino-uno PROGRAMMER=usbtiny
2019-02-28 20:55:00 +01:00
Gaëtan Harter
1d268c4cdb
Makefile.include: introduce FLASHFILE
Introduce FLASHFILE variable to start migrating boards to use it.

This is the file that will be used for flashing.
Boards do not currently use it but will migrated in upcoming PRs.
2019-02-28 18:11:49 +01:00
cladmi
3a17ddc43c
makefiles/docker.inc.mk: add support for EXTERNAL_MODULE_DIRS
They are remapped to `$(DOCKER_BUILD_ROOT)/external` if they are not
inside RIOT (usually the case but not for `tests/external_modul_dirs`).

If they are inside 'riotproject' they are currently also remapped to
'external'.

The value of `EXTERNAL_MODULE_DIRS` is then enforced by configuring it on
the command line as the application should not try to set it anymore.

The remapping is done in `external/directory_name` so cannot handle
multiple external directories with the same name.
2019-02-28 15:13:35 +01:00
cladmi
8b54f87fc4
makefiles:docker.inc.mk: add a global documentation on directory mapping 2019-02-28 14:46:43 +01:00
cladmi
3c0ecebb2c
makefiles/docker.inc.mk: use more directories in RIOT
Use the directories from in RIOT if possible for RIOTCPU/RIOTBOARD/RIOTMAKE.
2019-02-28 14:46:43 +01:00
Gaëtan Harter
8687d53c82
makefiles/docker.inc.mk: use BUILD_DIR in RIOT if possible
Use BUILD_DIR from within the riot repository if it is inside.
2019-02-28 14:46:43 +01:00
Gaëtan Harter
a57f141cf6
makefiles/docker.inc.mk: use RIOTPROJECT in the RIOT if possible
Use RIOTPROJECT from within the riot repository if it is inside.

This means when it is the case to use:

 * Not mounting the directory to `riotproject`
 * Use `APPDIR` relative to inside RIOT

If it is not inside, do the same as before:

 * Mount the RIOTPROJECT to `riotproject`
 * Use `APPDIR` relative to RIOTPROJECT
2019-02-28 14:46:43 +01:00
cladmi
e59b77988d
makefiles/docker.inc.mk: add docker_volume_and_env
Add functions to get volume and env arguments for a given directory environment
variable.

It handles:

 * variables with multiple directories like EXTERNAL_MODULE_DIRS
 * relative path
 * if the 'directories' variable is empty, it will not be exported to docker
2019-02-28 14:46:43 +01:00
cladmi
8351b13cc3
makefiles/docker.inc.mk: add path_in_docker function
Return to which directory in the container this directory should be mapped.
2019-02-28 14:46:43 +01:00
cladmi
a462c4aeb9
makefiles/docker.inc.mk: change definition order
Update definition order for DOCKER_VOLUMES_AND_ENV.

* Localtime
* Mapping and env related to `RIOTBASE`
* Build directories
* Project
* CPU/BOARD/make
2019-02-28 14:46:43 +01:00
cladmi
e5871d9deb
makefiles/docker.inc.mk: use a variable for all volumes and environment 2019-02-28 14:46:27 +01:00
cladmi
378f9fd144
makefiles/docker.inc.mk: add DOCKER_APPDIR variable
Prepare for when it can have a different value.
2019-02-28 14:44:53 +01:00
cladmi
a0f25ed47b
makefiles/docker.inc.mk: add DOCKER_RIOTBASE variable
It represents the path of RIOTBASE inside the docker container.
2019-02-28 14:44:49 +01:00
f74b819efe makefiles/tools/dfu: add initial DFU programming support 2019-02-28 13:57:12 +01:00
Gaëtan Harter
8c15d97629
tools/compile_and_test_for_board: add tests for help message
Verify that the help message matches what is in the docstring.
2019-02-28 13:45:40 +01:00
Gaëtan Harter
998211d738
tools/compile_and_test_for_board: add tests directory
Tests in `tests` will be used by 'tox'.
2019-02-28 13:45:40 +01:00
Gaëtan Harter
94aeb5a223
tools/compile_and_test_for_board: FIX outdated help docstring
Update the help message in the docstring.
It should reflect the content of `--help`.

I replaced the manual line wrapping by disabling the warning on the
docstring.
2019-02-28 13:45:40 +01:00
a5ff1dc32a
boards/stm32f4discovery: use common clock configuration without LSE
This fixes the boards being stuck when initializing the RTC
2019-02-27 21:49:56 +01:00
7d31bb43f1
boards/stm32/f4: factorize common clock configuration (168/8)
A common configuration file is introduced for stm32f4 with core clock
at 168MHz with HSE at 8MHz, 2 configuration files are introduced to²:
distinguish between clock configuration with and without LSE.
2019-02-27 21:49:55 +01:00
Peter Kietzmann
2bfa0e4940
Merge pull request #10322 from Rotzbua/patch-1
tests/leds: initialize led0 by default
2019-02-27 17:44:52 +01:00