Cppcheck was (correctly) warning here that concat to strings might
result in buffer overflow because the terminating `\0` was not considered.
This is fixed here, making the cppcheck suppression also obsolete.
Extend the cppcheck suppression example to show that each suppression
should have a reason describing the intentional suppression of a
cppcheck warning or error.
Currently version information of commands and tools is only parsed
from STDOUT, however some tools like openocd print version info
to STDERR only. This commits adds parsing of STDERR for version
infos if STDOUT does not contain such info.
When executing `make test` on devices using JLink, testrunner
launches `make term` which calls `jlink.sh term_rtt`. When finished
the father process is killed but `setsid` has launched JLinkExe
as another subprocess, which is not killed by `os.killpg` from
testrunner since it doesn't belong to the same group.
While running `make term` JLinkExe is expecting commands and thus
can be disturbed by other JLink commands, e.g. `make reset`.
This enable `make test` (which runs those two commands at the same
time) on target using JLinkExe as a programmer/debugger.
Add the rom base address to the flash address when flashing binaries.
This allows flashing binaries with the default openocd configuration.
It is an API change to IMAGE_OFFSET with binary files as it should now
only be an offset to the base address.
Force openocd type to '.bin' in case we want to flash hex/elf objects or
files not automatically recognized as bin.
This allows getting the ROM base address.
It may not be available in the build system directly so better extract it from
openocd. Also openocd is board specific and this address is cpu specific
so would have definition order issue in the build system.
When flashing with an IMAGE_OFFSET, it should also be passed to
verify_image. It is handling the base address in the image too.
This works with both elf files and binaries with the base address added.
This PR add deprication warning to notify anyone using the if_lib files that it is being removed from RIOT repo and making it's own repo (RIOT-OS/lib_if).
This is intended to help wil modularization since it is not only being used within RIOT but in other areas as well.
README files are updated to indicate the change and if the if_lib is used it will throw a warning indicating the deprecation.
Write stdin to <outfile> if it is different from the previous content.
If data provided in stdin is the same as the data that was in <outfile>, it is
not modified so `last modification date` is not changed.
Introduce dist/pythonlibs directory to store RIOT python packages.
This directory is exported via PYTHONPATH by the build system to
make it commonly available.
Create if_lib package containing all the modules and adapt the *.py files
to import each other using the intra-package references.
The idea behind a package is to invoke test.py either by permanently
modifying PYTHONPATH in user profile via adding path to $RIOTBASE/dist/tests
or make temporary PYTHONPATH changes during the invocation:
PYTHONPATH=$PYTHONPATH:$RIOTBASE/dist/tests python3 test.py
Leave periph_i2c_if.py in the same folder as test.py as this file is
just a Python wrapper around periph specific main.c.
Update BPT memory map. Use definitions generated with the latest code
generator. Both routine names and mapping have changed.
Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
Since the `iotlab-term` target uses `tmux` error messages are not really
printed, so it took me a while to find out why at some sites this target
wasn't working for me anymore.
If the IoT-LAB password was changed, just checking if `.iotlabrc`
exists isn't enough, so I use `iotlab-experiment` to check if I'm logged
in properly to prompt the password input in case I'm not.
update to the current lastest version of EDBG to allow user to reflash a bricked board due to sleep mode or wrong clock assignment. this avoid the use of Atmel Studio to erase flash.
The new tool (mkconstfs2) features:
* more robust filename handling: no need for mangling,
and works on Windows.
* Better output generation: nothing is written in case
of failures.
* Allows more control over the files that are included:
- does not traverse directories, filenames must be explicitly
given.
- The "root" can be explicitly given (thus the tool can get
the same result independently of the CWD).
Thanks to MichelRottleuthner for making it work with Windows paths.