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

5647 Commits

Author SHA1 Message Date
Juan I Carrano
12729d62a5
Merge pull request #10053 from OTAkeys/feat/base64_const
sys/base64: api change (const + void*)
2018-10-23 17:53:58 +02:00
Juan I Carrano
8148790e92
Merge pull request #10218 from bergzand/pr/crypt/helper_equal_const
crypto/helper: Change equals arguments to const
2018-10-23 17:51:56 +02:00
danpetry
bed1e22e7d sys/auto_init: Changes to support SAUL
SAUL read functionality implemented only, as described in
tsl4531x_saul.c.
This driver will work with SAUL in both low and high power modes,
with the startup mode configurable in tsl4531x_params.h.
2018-10-23 17:26:28 +02:00
ed23bdf25a
crypto/helper: Change equals arguments to const 2018-10-21 20:27:33 +02:00
aedc5260d8
Merge pull request #9848 from ZetaR60/RIOT_eepreg2
sys/eepreg: EEPROM registration support (version 2)
2018-10-21 11:20:53 +02:00
Matthew Blue
ba4de322f4 sys/eepreg: Makefile support 2018-10-20 09:30:41 -04:00
Matthew Blue
d5e9994d1d sys/eepreg: initial EEPROM registration support 2018-10-20 09:30:40 -04:00
f48deb48d4 net/nanocoap: rename variable name 'class'
'class' is keyword in c++ and leads to conflicts
2018-10-19 10:27:06 +02:00
Martine Lenders
bdf820af46
Merge pull request #10194 from bergzand/pr/cord/enable_stacktest
CORD: enable THREAD_CREATE_STACKTEST for threads
2018-10-18 14:38:29 +02:00
José Alamos
372a729e21
Merge pull request #10070 from OTAkeys/pr/bump_littlefs_version
pkg/littlefs: bump version to v1.6.2
2018-10-18 14:35:55 +02:00
afb7d6e1fc
cord/epsim: enable THREAD_CREATE_STACKTEST for thread 2018-10-18 14:17:07 +02:00
be1dc15655
cord/ep: enable THREAD_CREATE_STACKTEST for thread 2018-10-18 14:09:32 +02:00
PeterKietzmann
d3e34b4334 sys/ecc: add repetition code 2018-10-18 13:37:21 +02:00
Martine Lenders
179f17ca42
Merge pull request #9989 from PeterKietzmann/pr_add_golay
sys/ecc: add golay(24,12) half rate code
2018-10-18 09:31:17 +02:00
PeterKietzmann
9768995a0b sys/ecc: add golay(24,12) ECC 2018-10-18 09:05:28 +02:00
Hauke Petersen
cfe4370a95 sys/shell/rdcli: rename to sc_cord_ep.c 2018-10-17 15:21:49 +02:00
Hauke Petersen
18cc7ee3ed net/rdcli: rename to cord_ep 2018-10-17 15:21:49 +02:00
Hauke Petersen
226b9fa383 net/rdcli_simple: rename to cord_epsim 2018-10-17 15:21:49 +02:00
Hauke Petersen
152623577e net/rdcli_config: rename to cord_config 2018-10-17 09:29:19 +02:00
Hauke Petersen
787524400c net/rdcli_common: rename to cord_common 2018-10-17 09:29:19 +02:00
Hauke Petersen
f0b0e25254 net/rdcli: new module structure and high-level doc 2018-10-17 09:29:19 +02:00
Kevin "Bear Puncher" Weiss
7187bbf8cf
Merge pull request #9426 from gschorcht/esp32
ESP32 port
2018-10-16 15:24:25 +02:00
Sebastian Meiling
ca90f9db2c
Merge pull request #10087 from kb2ma/nanocoap/fix_response_type
net/nanocoap: fix response type
2018-10-16 13:41:20 +02:00
Kevin "Bear Puncher" Weiss
f376b46691
Merge pull request #10150 from fedepell/arduino_2
sys/arduino: add arduino time functions micros() and delayMicroseconds()
2018-10-16 08:46:10 +02:00
Gunar Schorcht
7fde6fc258
Merge pull request #6712 from aabadie/driver_vcnl4010
drivers/vcnl4010: initial implementation
2018-10-15 16:12:45 +02:00
bb3e859680
Merge pull request #10036 from kb2ma/nanocoap/module-doc
net/nanocoap: add module documentation
2018-10-15 13:20:26 +02:00
Ken Bannister
ad38dd9a6f net/nanocoap: fix non-confirmable response type 2018-10-15 06:42:37 -04:00
22b2306536 sys/auto_init: add saul adaptation for vcnl40x0 2018-10-15 11:44:10 +02:00
d4bfb0f0a3 sys/phydat: add counts unit 2018-10-15 11:44:04 +02:00
8ee2bc5ffb coap: deprecate COAP_CT_ content type defines
COAP_CT_ style defines for the content types are deprecated in favour of
COAP_FORMAT_ style defines. COAP_FORMAT_ is expanded to include any
missing content type that was available with COAP_CT_.
2018-10-15 09:44:17 +02:00
726ebf3dad coap: use COAP_FORMAT style content-format defines
Replaces all occurences of COAP_CT_.* with COAP_FORMAT_.*
2018-10-15 09:44:17 +02:00
Ken Bannister
14c9b3062b
Merge pull request #8932 from bergzand/pr/nanocoap/block2
nanocoap: add server-side block2 support
2018-10-14 13:03:08 +00:00
551b3513db nanocoap: Add server-side block2 support 2018-10-14 14:30:29 +02:00
Martine Lenders
1095ac2487
Merge pull request #7428 from haukepetersen/add_rdcli
net: add full CoRE Resource Directory endpoint implementation
2018-10-12 17:56:05 +02:00
Federico Pellegrin
75c4dab3c7 sys/arduino: correct micros() return type 2018-10-12 17:40:37 +02:00
Kevin "Bear Puncher" Weiss
ceba02f368
Merge pull request #10149 from fedepell/arduino_1
sys/arduino: add docs for analog map (strictly needed to build)
2018-10-12 15:09:38 +02:00
Hauke Petersen
899d7fee8a shell: add shell command for rdcli 2018-10-12 14:41:40 +02:00
Hauke Petersen
49f21b8935 sys/auto_init: added rdcli_standalon initialization 2018-10-12 14:41:40 +02:00
Hauke Petersen
9acce40aad net: added full RD endpoint implementation 2018-10-12 14:41:40 +02:00
Hauke Petersen
314dfcb805 net/rdcli_common: added RES_LOC_LEN 2018-10-12 14:41:40 +02:00
Federico Pellegrin
a89e43ae31 sys/arduino: add possibility to customize Arduino serial port at compile time 2018-10-11 21:33:50 +02:00
Federico Pellegrin
4960607a1e sys/arduino: add arduino time functions micros() and delayMicroseconds() 2018-10-11 14:42:46 +02:00
Federico Pellegrin
4a7222072f sys/arduino: add docs for analog map (strictly needed to build) 2018-10-11 14:17:50 +02:00
Ken Bannister
2382855f38 net/nanocoap: add module documentation 2018-10-10 13:31:40 -04:00
Hauke Petersen
6ba1991a8e net/rdcli_simple: do not send CF opt in POST msg 2018-10-10 11:07:17 +02:00
Martine Lenders
f60f5f86bb
Merge pull request #10128 from gebart/pr/ubjson-include
sys/ubjson: Unconditionally include <sys/types.h>
2018-10-08 14:01:01 +02:00
Schorcht
3ac99877ac cpu: add esp32 2018-10-08 12:20:49 +02:00
Martine Lenders
bbae45cc87
Merge pull request #9840 from jia200x/pr/doc_serializer
doc: add `serialization` group to Doxygen
2018-10-08 11:34:03 +02:00
Joakim Nohlgård
eb4de92c2f sys/ubjson: Unconditionally include <sys/types.h>
msp430_types.h is included implicitly if needed by sys/types.h
native also needs sys/types.h, no idea why it was excluded originally..
2018-10-08 10:42:01 +02:00
f38b71b720
Merge pull request #10099 from gschorcht/sys_aut_init_saul
sys/auto_init/saul: fix of #10098
2018-10-05 20:43:49 +02:00
Schorcht
72ac8fdd39 sys/auto_init/saul: include assert.h 2018-10-05 20:01:25 +02:00
Schorcht
3e5c1d5f92 sys/auto_init/saul: VEML6070_NUMOF fix 2018-10-05 20:00:22 +02:00
Schorcht
cef81a102c sys/auto_init/saul: alphabetical order 2018-10-05 19:57:37 +02:00
Schorcht
dc8c363c45 sys/auto_init: auto_init_sht1x.c moved to saul 2018-10-05 19:56:50 +02:00
Jose Alamos
dac54db275 sys/ubjson: change ingroup directive 2018-10-05 15:34:49 +02:00
Jose Alamos
851150847c sys/base64: change ingroup directive 2018-10-05 15:34:49 +02:00
Jose Alamos
dbd31837f7 sys/serialization: add sys_serialization doxygen group 2018-10-05 15:34:49 +02:00
Peter Kietzmann
ed24d3622a
Merge pull request #9621 from bergzand/pr/netif/use_fmt
gnrc_netif: Use fmt for bytes to hex string
2018-10-04 14:34:37 +02:00
0d71c1ccf7
gnrc_netif: Use fmt for bytes to hex string 2018-10-04 13:34:18 +02:00
90ad1a0782
gnrc_netif_ieee802154: remove state access in recv
This replaces the netif->state accesses in netif::recv with a netdev call
and the new netif RAWMODE flag
2018-10-03 21:00:35 +02:00
3c032e5688
gnrc_netif: add rawmode flag
Adds a gnrc_netif specific rawmode flag to indicate that the netdev
device is configured in raw mode. This flag is kept in sync with a
possible flag in the netdev device and should only be modified via the
setter call.
2018-10-03 20:59:03 +02:00
Vincent Dupont
7e47e36e55 pkg/littlefs: fix file buffer size 2018-10-03 11:54:17 +02:00
Vincent Dupont
73e971fc56 uuid: add uuid_from_string() 2018-10-03 10:44:14 +02:00
Vincent Dupont
695a94449a fmt: add scn_u32_hex() 2018-10-03 10:44:14 +02:00
Vincent Dupont
8c5ffa0a8d fmt: add fmt_char 2018-10-03 10:44:14 +02:00
Vincent Dupont
db4ce5eff2 uuid: add uuid_to_string() 2018-10-03 10:44:14 +02:00
Vincent Dupont
71455b692f fmt: add fmt_to_lower() 2018-10-03 10:44:14 +02:00
Vincent Dupont
a542e954cf fmt: add fmt_u16_hex() 2018-10-03 10:44:03 +02:00
chrysn
f07308b07d gnrc: Extend gnrc_ipv6_get_header checks, use in sock recv
gnrc_sock_recv used to duplicate functionality of gnrc_ipv6_get_header,
but additionally checked whether the IPv6 snip is large enough.

All checks are now included in gnrc_ipv6_get_header, but as most of them
stem from programming / user errors, they were moved into asserts; this
constitutes an API change.
2018-09-28 19:40:59 +02:00
b4664a5bd3
Merge pull request #10067 from gebart/pr/color-Wdouble-promotion
color: Fix -Wdouble-promotion warnings
2018-09-28 10:16:13 +02:00
22b3523c1e
Merge pull request #9988 from PeterKietzmann/pr_ecc_generalize
sys/ecc: move hamming256 module to generic ecc
2018-09-28 10:08:58 +02:00
ee11af6c26
Merge pull request #9926 from haukepetersen/add_coap_genericheader
net/nanocoap: factor out generic CoAP defines
2018-09-28 09:38:53 +02:00
Joakim Nohlgård
de7863598f color: Fix -Wdouble-promotion warnings 2018-09-28 09:33:40 +02:00
PeterKietzmann
b7615e9e1b sys/ecc: remove separate hamming256 folder 2018-09-28 08:53:25 +02:00
Sebastian Meiling
22e03180fc
Merge pull request #9865 from jia200x/pr/doc_memory
doc: add `memory management` group
2018-09-27 15:45:39 +02:00
Jose Alamos
6089f4a10c doc/mem_management: add implementations and utils 2018-09-27 10:54:39 +02:00
Pieter Willemsen
394c3ecd6d base64: use void* to pass byte buffers 2018-09-26 18:24:21 +02:00
Pieter Willemsen
2cc1ac4fa8 base64: make input argument const 2018-09-26 17:51:08 +02:00
Hauke Petersen
f3f673eb45 net/nanocoap: factor out generic CoAP defines 2018-09-26 14:31:57 +02:00
Hauke Petersen
4a59113963 net/nanocoap: use correct type param for _bulid_hdr() 2018-09-26 13:00:39 +02:00
Sören Tempel
e523e8f5ec sys/cbor: remove module
Fixes #7707
Fixes #7800
2018-09-25 21:07:29 +02:00
Martine Lenders
05aa8ab66b gnrc_netif: assert that l2addr_len is 0 without address
If the device provides an address length, but no address it is
obviously faulty.
2018-09-25 18:45:32 +02:00
smlng
59e299635b cppcheck: add/correct reason for cppcheck-suppress
Adding and correcting description/rational on why certain cppcheck
warnings or errors are intentionally suppressed.
2018-09-25 12:03:58 +02:00
Joakim Nohlgård
3466a862df
Merge pull request #9985 from kaspar030/add_missing_string.h_includes
sys: add missing <string.h> includes
2018-09-21 06:51:01 +02:00
3db24b4603 sys: saul: add missing stddef.h include (for NULL) 2018-09-20 23:54:46 +02:00
05b6af466c sys: add missig <string.h> includes 2018-09-20 23:47:40 +02:00
josar
f770d17e12 xtimer_core: uncrustify 2018-09-18 16:13:18 +02:00
b518f3c73e
Merge pull request #9869 from bergzand/pr/tsrb/drop
tsrb: add drop function
2018-09-18 10:57:55 +02:00
Pekka Nikander
da81720d80 sys/color/color.c: Fix a typo 2018-09-15 08:52:00 +03:00
50d6cfd22c
Merge pull request #9918 from kb2ma/gcoap/fix-resource-order-doc
net/gcoap: fix doc for order of server resources
2018-09-13 15:45:17 +02:00
Ken Bannister
104de7b621
Merge pull request #9872 from haukepetersen/fix_nanocoap_optputstring
net/nanocoap: allow empty uri/location path option
2018-09-11 11:14:48 +00:00
Hauke Petersen
a027a1e608 sys/benchmark: incl irq.h and fixed output 2018-09-11 11:29:19 +02:00
Ken Bannister
949eb21116 net/gcoap: fix doc for order of server resources 2018-09-11 04:31:54 -04:00
Hauke Petersen
becfce247d net/nanocoap: allow empty uri/location path option
For CoAP, there is actually a difference between
`/some/path` and `/some/path/`. This needs to be reflected
when parsing the URI and location path options from a given
string.
2018-09-11 10:06:57 +02:00
Martine Lenders
235661668d gnrc_ipv6_nib: always configure 802.15.4 long address
Our `gnrc_minimal` example configures the link-local address from the
IEEE 802.15.4 short address since it does not include 6Lo-ND.
This causes the application to be incompatible with our other GNRC
application that do include 6Lo-ND, since it [assumes][1] the link-local
address to be based on the EUI-64 for address resolution.

This enforces long addresses (aka EUI-64) for all IEEE 802.15.4 devices
when IPv6 is compiled in so `gnrc_minimal` is compatible again to the
rest.

Fixes #9910

[1]: https://tools.ietf.org/html/rfc6775#section-5.2
2018-09-10 17:08:04 +02:00
Hauke Petersen
f2b1c5c87d net/gcoap: use sock_udp_ep_equal() 2018-09-07 12:03:19 +02:00
cladmi
a052801c2f
sys/hashes/sha256: replace include by stddef.h
stddef.h is enough for size_t, unistd.h adds a lot of other declarations
2018-09-06 12:45:04 +02:00
1a3bb65e3c
sys/hashes/sha256: add missing unistd.h include
It needs `size_t` definition.
2018-09-06 11:13:12 +02:00
Martine Lenders
3d9aad2027
Merge pull request #9854 from bergzand/pr/rpl/pass_opt_len
gnrc_rpl: Pass options length to msg validator
2018-09-03 14:20:12 +02:00
Martine Lenders
e54428ce1e
Merge pull request #9853 from bergzand/pr/rpl/fix_dis_reserved_fields
gnrc_rpl: fix zeroing of RPL DIS fields
2018-09-03 14:19:59 +02:00
e8dfabd4c4
Merge pull request #8920 from haukepetersen/add_nanocaop_urilocationoption
net/nanocoap: add generic handling for string-based options
2018-08-31 12:04:32 +02:00
8d9cb25ed7
tsrb: add drop function
The get function does not support passing NULL as an input buffer. to be
able to drop bytes from the buffer, a dedicated drop function is
required
2018-08-31 10:35:02 +02:00
Jose Alamos
dc9d77057d doc: add sys_memory_management Doxygen group 2018-08-30 13:29:00 +02:00
Hauke Petersen
b837e656f9 stdio/vfs: generalized VFS mapping for STDIO 2018-08-30 11:14:59 +02:00
Peter Kietzmann
5b87b1d621
Merge pull request #9858 from jia200x/pr/doc_hashes
doc: refactor `hashes` group
2018-08-30 10:36:47 +02:00
Hauke Petersen
a3b8c90485 net/gcoap: adjust to nanocoap changes 2018-08-30 10:31:03 +02:00
Hauke Petersen
4c08e77d00 net/nanocoap: improve option handling
- add generic string put and get functions
- add location path and location query options
- add dedicated functions for getting and setting
  URI query, URI path, location query, and location path
  options
2018-08-30 10:31:03 +02:00
Jose Alamos
cac5944023 doc/hashes: deprecate supports section 2018-08-29 16:08:53 +02:00
Jose Alamos
060fb619e9 hashes: change ingroup directive 2018-08-29 15:57:24 +02:00
Jose Alamos
6b34f0b61c hashes: define Doxygen groups in non crypto hashes 2018-08-29 15:49:49 +02:00
af3232fb34
gnrc_rpl: Pass options length to msg validator
Currently the length of the full ICMPv6 packet is passed to the
validator function causing validation failures on valid packets. This
fixes that by passing the length of remaining RPL options of the packet.
2018-08-29 00:47:20 +02:00
0c790c6638
gnrc_rpl: fix zeroing of RPL DIS fields
The code originally assumed that the location of DIS struct is directly
after the ICMPv6 struct. This is not necessarily true when both structs
are individually allocated by pktbuf. This commit fixes this issue by
directly accessing the location of the DIS struct.
2018-08-29 00:33:27 +02:00
Jose Alamos
4865731fdd hashes/sha3: add missing macro documentation 2018-08-28 19:28:40 +02:00
Jose Alamos
7e30e3256f hashes/sha256: add missing macro documentation 2018-08-28 19:28:33 +02:00
Jose Alamos
6458942716 hashes/sha3: change ingroup directive 2018-08-28 19:26:10 +02:00
Jose Alamos
ea7e5a3935 hashes/sha256: change ingroup directive 2018-08-28 19:26:01 +02:00
Jose Alamos
0a29095197 hashes/sha1: change ingroup directive 2018-08-28 19:25:49 +02:00
Jose Alamos
c4b8731633 hashes/md5: change ingroup directive 2018-08-28 19:25:32 +02:00
Jose Alamos
3ee3a020c3 hashes/cmac: change ingroup directive 2018-08-28 19:25:20 +02:00
Jose Alamos
5cf0b1ae62 hasehs/sha-3: add doxygen group for sha-3 2018-08-28 19:19:36 +02:00
Jose Alamos
7c59f02639 hasehs/sha256: add doxygen group for sha256 2018-08-28 19:14:51 +02:00
Jose Alamos
116118af22 doc/hashes: define new hash groups 2018-08-28 19:06:36 +02:00
Jose Alamos
e1b88abe99 doc: move Checksum group under sys_hashes 2018-08-28 18:53:44 +02:00
0cfdaab246
Merge pull request #9842 from jia200x/pr/doc_math
doc: add `math` group to Doxygen
2018-08-27 10:34:09 +02:00
Jose Alamos
70420197ed sys/seq: change ingroup directive 2018-08-24 18:14:03 +02:00
Jose Alamos
58295ab757 sys/matstat: change ingroup directive 2018-08-24 18:14:03 +02:00
Jose Alamos
d87199420c sys/div.h: change ingroup directive 2018-08-24 18:14:03 +02:00
Jose Alamos
497dcb950c doc: add sys_math group 2018-08-24 18:08:17 +02:00
Joakim Nohlgård
6d6a6efac7 gnrc_netif: Check return value of netdev init during thread start 2018-08-24 12:11:12 +02:00
Hauke Petersen
c2184f3454 boards/cpu/drivers/sys: use generic stdio_ if 2018-08-22 10:54:25 +02:00
Hauke Petersen
9bd2363643 sys/stdio: s/rtt_stdio/stdio_rtt/ 2018-08-22 10:54:25 +02:00
Hauke Petersen
d55616a7f5 sys/stdio: s/uart_stdio/stdio_uart/ 2018-08-22 10:54:25 +02:00
Hauke Petersen
717e84f7b2 sys/stdio: factor out STDIO abstraction 2018-08-22 10:54:25 +02:00
Jose Alamos
f2ff06c9d4 posix/pthread_rwlock: fix unsigned variable comparison 2018-08-21 13:58:39 +02:00
Toon Stegen
3a69e0fa98 sys/fmt: remove useless assignment 2018-08-20 16:19:30 +02:00
Toon Stegen
9f90f31291 sys/fmt: add function for converting hex byte 2018-08-20 16:19:30 +02:00
Martine Lenders
a9d0f20c7e
Merge pull request #8626 from miri64/gnrc_sixlowpan_iphc/enh/clean-up-nhc
gnrc_sixlowpan_iphc: cleanup NHC encoding
2018-08-17 10:13:34 +02:00
Martine Lenders
0a9793c49b gnrc_sixlowpan_iphc: cleanup NHC encoding 2018-08-16 16:55:28 +02:00
Joakim Nohlgård
3cc088689e 6lo: Speling correction in comment 2018-08-14 10:08:52 +02:00
Joakim Nohlgård
58281e9135 6lo: Set more data flag on all but last frag 2018-08-14 10:08:17 +02:00
Cenk Gündoğan
ba6d386c5e
Merge pull request #9756 from smlng/pr/ccnlite/versionbump
pkg: update ccn-lite and adapt shell commands
2018-08-13 11:03:11 +02:00
Joakim Nohlgård
a247d8bfa5 gnrc_netif_ieee802154: set Frame Pending bit sometimes
Set frame pending bit in IEEE 802.15.4 FCF when
GNRC_NETIF_HDR_FLAGS_MORE_DATA is set on the netif header on outbound
frames.
2018-08-13 09:27:18 +02:00
Joakim Nohlgård
29e4a1ba3c gnrc_netif: Introduce GNRC_NETIF_HDR_FLAGS_MORE_DATA 2018-08-13 09:25:32 +02:00
smlng
990a76c80c pkg: update ccn-lite and adapt shell commands
This updates the ccn-lite package version which brings in the
    latest upstream fixes for some compiler issues found on macOS
    with clang and newer GCC versions.

    A minor adaption of the RIOT shell commands is also included.
2018-08-10 10:21:24 +02:00
Sebastian Meiling
513e3eca2f
Merge pull request #9522 from miri64/gnrc_ipv6_nib/enh/slaac-fallback
gnrc_ipv6_nib: fallback to SLAAC if ARO is ignored by upstream
2018-08-10 08:21:31 +02:00
Martine Lenders
4f87883ab8 gnrc_ipv6_nib: fallback to SLAAC if ARO is ignored by upstream
Linux doesn't have ARO support at the moment so this is a workaround to
try to speak 6Lo-ND while still being able to do DAD with a border
router that doesn't.
2018-08-09 10:56:36 +02:00
Ken Bannister
3f3df74bcd
Merge pull request #7237 from Ell-i/feature-gcoap-extra-indirection
net/gcoap: Make references to coap_resource_t all const in gcoap
2018-08-07 23:52:59 -04:00
Gaëtan Harter
a7241384be
Merge pull request #9719 from miri64/gnrc_ipv6_nib/enh/emit-conf
gnrc_ipv6_nib: make automatic NDP packet emission (NS/RS) configurable
2018-08-07 17:55:00 +02:00
Martine Lenders
ad173831db
Merge pull request #9721 from smlng/pr/gnrc_udp/assert
gnrc_udp: assert ports not zero
2018-08-06 16:59:55 +02:00
smlng
d4e8c57621 gnrc_netif: generalise address search functions
Reduce code duplication by combining internal helper functions
    that either loop over interface addresses or multicast groups.
2018-08-06 16:28:48 +02:00
smlng
7cb41ba829 gnrc_netif: cleanup debug output
Correct typos and wording in debug output.
2018-08-06 16:28:48 +02:00
smlng
8e3953cd6c gnrc_netif: cleanup address matching
Cleanup of internal helper functions for IPv6 address matching.
2018-08-06 16:28:48 +02:00
smlng
fd718dfc74 gnrc_udp: assert ports not zero
UDP port 0 is reserved for system usage, e.g., to tell the OS to
    set a random source port. Hence, neither source nor destination
    port should be 0 when transmitting. This PR adds proper asserts.
2018-08-06 16:09:22 +02:00
Martine Lenders
9720cd857d gnrc_ipv6_nib: include SLAAC debug addr_str into #ifdef 2018-08-06 14:51:34 +02:00
Martine Lenders
bdb1e80e0a gnrc_ipv6_nib: make RS emission configurable 2018-08-06 14:51:18 +02:00
smlng
f35d15d429 doc: add missing defgroup for auto_init_saul 2018-08-02 15:52:58 +02:00
Michael Andersen
e354824bcf drivers/mma7760: Add initial support 2018-08-02 15:52:58 +02:00
Martine Lenders
f946314837 gnrc_ipv6: refactor to remove superfluous temporary variable
Since no release in this function is required anyways, we can just use
`payload` to check the return value directly.
2018-08-02 15:20:59 +02:00
Martine Lenders
cb4f6a96a8 gnrc_ipv6: correctly reset from temporary variable
While `tmp` in the loop for write-protection for the check-sum
calculation is used to check the return value of
`gnrc_pktbuf_start_write()`, it was never overwriting `payload` causing
the original snip to be used in the following iteration `prev` when
duplicated, and destroying the sanity of `ipv6`.
2018-08-02 15:17:40 +02:00
Martine Lenders
72e9b1f623 gnrc_ipv6: remove superfluous release
The packet handed to `_fill_ipv6_hdr()` is already released in the
caller (in the current version this is only `_save_fill_ipv6_hdr()`).
2018-08-02 15:16:08 +02:00
Sebastian Meiling
26c689ffbb
Merge pull request #9548 from RIOT-OS/new_i2c_if3
I2C: introduce and adapt new I2C interface (2nd attempt)
2018-08-02 12:00:59 +02:00
Pekka Nikander
8f10d65ad5 net/gcoap: Make references to coap_resource_t const in gcoap
A CoAP resource is a primary object between the application
    and CoAP library.  The Library needs the paths, methods,
    and handlers from it, so that it can call the right handler.
    However, it never needs to change any of them.

    The application also needs the resources.  The application
    may want to declare the resources as const, since it may
    want to store them in flash.
2018-07-30 09:00:21 +03:00
Gaëtan Harter
f996e1ca78
Merge pull request #9627 from cladmi/pr/sc_can/uninitialized
shell/sc_can: fix uninitialized warning
2018-07-27 12:34:19 +02:00
Cenk Gündoğan
f03e52d157
Merge pull request #9484 from miri64/gnrc_sixlowpan_iphc/enh/i8511-recv
gnrc_sixlowpan_iphc: refactor reception for #8511
2018-07-26 07:58:52 +02:00
Martine Lenders
69d9ecc0d9 gnrc_sixlowpan_iphc: refactor reception for #8511
This refactors reception/decoding part of `gnrc_sixlowpan_iphc` to the
more layered approach modeled in #8511. Since the reception part is
already complicated enough I decided to divide send and receive up into
separate changes.
2018-07-25 18:15:09 +02:00
Martine Lenders
9a88cc8004 gnrc_sixlowpan: remove assertion on multiple_by_size function
During the review of #9485 [we found out][1] that an assertion in this
function was invalid. However, the documentation on this assertion
wasn't removed on that. This fixes that.

[1] https://github.com/RIOT-OS/RIOT/pull/9485#issuecomment-407794280
2018-07-25 18:00:30 +02:00
Cenk Gündoğan
7fef5e030a
Merge pull request #9485 from miri64/gnrc_sixlowpan_iphc/enh/i8511-send
gnrc_sixlowpan_iphc: refactor sending for #8511
2018-07-25 17:57:59 +02:00
Martine Lenders
80322cbd7d gnrc_sixlowpan_iphc: refactor sending for #8511
This refactors sending/encoding part of `gnrc_sixlowpan_iphc` to the
more layered approach modeled in #8511. Since the reception part is
already was pretty complicated to refactor, I decided to divide send
and receive up into separate changes.
2018-07-25 17:35:59 +02:00
e006165b50 sys/auto_init: update isl29020 with new API 2018-07-25 12:01:39 +02:00
Matthew Blue
bc9b3ecaae */ads101x: copyright notice update 2018-07-25 12:01:39 +02:00
93fc27b93b sys/auto_init: update mag3110 auto_init 2018-07-25 12:01:39 +02:00
af647bfb53 sys/auto_init: update tsl2561 auto_init 2018-07-25 12:01:39 +02:00
a85fbd2c75 sys/auto_init: update tcs37727 auto_init 2018-07-25 12:01:38 +02:00
53ffe88384 sys/auto_init: update l3g4200d with new API 2018-07-25 12:01:38 +02:00
dd055f3b32 sys/auto_init: update lsm303dlhc with new API 2018-07-25 12:01:38 +02:00
0135aec86f sys/auto_init: update lps331ap with new API 2018-07-25 12:01:38 +02:00
7a12293eb1 drivers/at30tse75x: adapt to new I2C api 2018-07-25 12:01:38 +02:00
Martine Lenders
d6b2a9ed01
Merge pull request #9483 from miri64/gnrc_sixlowpan_frag/enh/finish-frag
gnrc_sixlowpan_frag: Expose functions to finish datagram
2018-07-25 11:53:14 +02:00
Martine Lenders
64fed621d2 gnrc_sixlowpan_frag: Expose functions to finish datagram
This will be used in the IPHC refactoring to control the reassembly
buffer as a context.

I also adapted the name of `gnrc_sixlowpan_frag_gc_rbuf()` to be in
line with the rest of the newer functions.
2018-07-25 11:26:02 +02:00
Cenk Gündoğan
0dc02d9a97
Merge pull request #9482 from miri64/gnrc_sixlowpan_frag/enh/pages
gnrc_sixlowpan_frag: add page context to reassembly buffer
2018-07-24 18:16:39 +02:00
Cenk Gündoğan
e189d96171
Merge pull request #9585 from miri64/sixlowpan/fix/print
sixlowpan: various fixes to sixlowpan_print() function
2018-07-24 14:00:13 +02:00
Gaëtan Harter
eec88e3e53
shell/sc_can: fix uninitialized warning
When compiled for `hifive1` board with `gcc-7.2.0` this warning was raised:

'ret' may be used uninitialized in this function [-Werror=maybe-uninitialized]
2018-07-24 13:58:21 +02:00
Peter Kietzmann
1b7e164662
Merge pull request #9606 from bergzand/pr/netif/conf_events_on_reset
gnrc_netif: reapply event flags on device reset
2018-07-24 08:43:52 +02:00
Joseph Noir
0736de37c9
Merge pull request #9363 from gschorcht/pthread-g++
core/pthread: make them compilable with g++
2018-07-23 17:06:19 +02:00
Gunar Schorcht
9db03537b9 core/pthread: make them compilable with g++ 2018-07-21 14:24:57 +02:00
Martine Lenders
dc8c983d26
Merge pull request #9341 from bergzand/pr/sockutil/cleanup
sock_util: Add unittest and fix detected issues.
2018-07-20 12:09:31 +02:00
0c43dc743d
sock_util: Limit recursion in str2ep 2018-07-20 11:48:29 +02:00
b024ff1cb8
sock_util: Add checks to port number parsing
Add additional checks to the port number parsing in str2ep to validate
the port number supplied in the string. This only verifies that the port
number is no longer than 5 chars and the resulting number fits in a
uint16_t.

It is still possible to supply up to 5 random chars.
2018-07-19 22:07:19 +02:00
bff8694051
sock_util: check path length in urlsplit
Add a length check to the path to ensure that it fits in the supplied
buffer in the urlsplit function
2018-07-19 22:07:19 +02:00
d93ecab880
sock_util: Add terminator to host-port string
Add missing null terminator to the returned host-port string in
sock_udp_ep_fmt
2018-07-19 22:07:18 +02:00
b8a494fb76
sock_util: Prevent overflow in sock_urlsplit
This adds a length check to verify if the host-port part of the URL fits
in the supplied buffer
2018-07-19 22:07:18 +02:00
3096823ab4
sock_util: Allow URLs without path as valid
URLs without a path were treated as invalid, while according to the URL
specification they are valid

Also fixes a missing null terminator in the returned path
2018-07-19 22:07:18 +02:00
3402e3509c
sock_util: Prevent overflow in _find_pathstart
Limit the number of scanned chars in _find_pathstart to the predefined
size
2018-07-19 22:07:18 +02:00
b0309145f0
sock_util: Limit URL scheme size 2018-07-19 22:07:17 +02:00
Martine Lenders
0d3af49278
Merge pull request #9603 from miri64/gnrc_mac/fix/print-formatting
gnrc: mac: fix types according to print formatting
2018-07-19 17:18:48 +02:00
Martine Lenders
3870def74c gnrc: mac: fix types according to print formatting
As reported by `llvm`.
2018-07-19 15:13:39 +02:00
30e683ccfe
gnrc_netif: reapply event flags on device reset
On a NETOPT_STATE set call with NETOPT_STATE_RESET the netdev device
resets the callback event flags. This requires that after the netdev
device resets, the network stack also reapplies these callback event
flags
2018-07-19 14:51:14 +02:00
4c183257df
sock_util: Fix null terminator in sock_udp_ep_fmt 2018-07-18 17:44:03 +02:00
6a81a4d587
sock_util: add missing includes 2018-07-18 17:43:59 +02:00
Joakim Nohlgård
2b31129ef0
sys/cbor: Fix -Wformat=2 warnings 2018-07-18 15:29:06 +02:00
Martine Lenders
c6d46057b0 sixlowpan: use generic format strings instead of inttypes.h macros
We had bad experiences with those in the past when used with newlib-nano
;-)
2018-07-17 12:22:16 +02:00
Martine Lenders
ecfff3e812 sixlowpan: fix decoding of DAM in sixlowpan_print()
Destination address compression is all in the least significant nibble
of that byte in the IPHC header [[1]].

[1]: https://tools.ietf.org/html/rfc6282#section-3.1.1
2018-07-17 12:22:15 +02:00
Martine Lenders
d8081453f2 gnrc_ipv6: clean-up and simplify send handling
This change is a gnrc_ipv6_nib/gnrc_netif(2)-based rework of #7210.

Packet duplication
==================

Its main optimization is that it restructures `gnrc_ipv6` handling of
sent packets so that duplication for write-protection happens at the
latest possible step:

* potential `gnrc_netif` headers added by upper layers are
  write-protected before their removal
* This unifies the duplication of the IPv6 header directly after
  that
* Extension headers in-between the IPv6 header and the payload header
  are duplicated just before the check sum is duplicated

Especially the last point allows for only handing a single packet snip
to all lower functions instead of an already searched IPv6 header
(which now is always the first until it is handed to the interface) +
payload header.

Further clean-ups
=================
* Next-hop link-layer address determination was moved to the
  `_send_unicast` function, greatly simplifying the unicast case in the
  `_send` function
* Code for loopback case was added to a new function `_send_to_self`
* Removed some code duplication
2018-07-16 15:08:56 +02:00
Peter Kietzmann
9f34513eec
Merge pull request #9563 from bergzand/pr/netif/netdev_recv_reset
gnrc_netif_ieee802154: drop frame on buffer error
2018-07-13 16:21:33 +02:00
ea6a2ef494
gnrc_netif_ieee802154: drop frame on buffer error
This adds a netdev recv call to indicate that the received frame should be
dropped when there is no buffer space available to store the frame.
2018-07-12 16:15:00 +02:00
Martine Lenders
3b1e4f54d2
Merge pull request #9532 from brummer-simon/gnrc_tcp-fix_includes
gnrc_tcp: Add missing includes
2018-07-10 20:22:13 +02:00
Simon Brummer
3b89bef366 gnrc_tcp: Add missing includes 2018-07-10 16:00:36 +02:00
Martine Lenders
8d47210228 gnrc_netif: don't spam user if dev doesn't support NETOPT_RX/TX_END_IRQ 2018-07-09 17:23:31 +02:00
Peter Kietzmann
15b0fe4368
Merge pull request #9467 from gebart/pr/gnrc_netif-netdev-flags
gnrc_netif: Enable RX and TX complete events after netdev init
2018-07-09 08:59:32 +02:00
Hauke Petersen
fb184a3b2c sys/auto_init: add init for asymcute 2018-07-05 15:44:16 +02:00
Hauke Petersen
ad20c4f1cc net: add Asymcute (asynchronous MQTT-SN client) 2018-07-05 15:44:16 +02:00
Hauke Petersen
ed01bf0e1d net: add header with generic MQTT-SN defines 2018-07-05 15:13:02 +02:00
Hauke Petersen
bf8f8dfa67 net/sock_udp: add sock_udp_ep_equal() 2018-07-05 15:13:01 +02:00
Martine Lenders
5361c4cfff sock_dns: return error if DNS server is not set 2018-07-05 11:09:34 +02:00
Martine Lenders
1916c45dc0 gnrc_ipv6_nib_router: add support to send RDNSSO 2018-07-05 11:09:34 +02:00
Martine Lenders
6d1f012c9d gnrc_ipv6_nib: add support to handle RDNSSO 2018-07-05 11:09:34 +02:00
Martine Lenders
0ef62b9690 gnrc_ndp: add support for building RDNSS option 2018-07-05 11:01:22 +02:00
Martine Lenders
fbf216f864 gnrc_sock_dns: Move DNS server end point to implementation 2018-07-05 11:01:22 +02:00
Martine Lenders
8eab80c3ec ndp: define RDNSS option 2018-07-05 11:01:22 +02:00
Martine Lenders
61e8825fa7
Merge pull request #9497 from haukepetersen/fix_byteorder_bufsletobe
core/byteorder: fix naming for htobebufs/bebuftohs functions
2018-07-04 21:51:34 +02:00
Cenk Gündoğan
835f8f0daa
Merge pull request #9290 from PeterKietzmann/pr_sram_puf
Add SRAM based PRNG seeder
2018-07-04 18:08:53 +02:00
PeterKietzmann
20397c5b15 cortexm_common: add SRAM based PRNG seeder 2018-07-04 17:55:16 +02:00
Hauke Petersen
1bfb3c8534 net/emcute: adapted to changes byteorder functions 2018-07-04 17:41:04 +02:00
Martine Lenders
8721d0b0a2 gnrc_sixlowpan_frag: add page context to reassembly buffer
While refactoring IPHC I noticed that the page actually can already be
used for fragmentation: Given @cgundogan's work on [ICN LoWPAN] we can
already assume, that the page context may (among other thing) determine
the type of the reassembled packet. This PR provides the basis for
that.

[ICN LoWPAN]: https://tools.ietf.org/html/draft-gundogan-icnrg-ccnlowpan-01
2018-07-03 14:08:14 +02:00
Cenk Gündoğan
16e1f972ab
Merge pull request #9424 from miri64/gnrc_sixlowpan_frag/enh/async-gc
gnrc_sixlowpan_frag: add asynchronous rbuf GC
2018-07-03 11:45:52 +02:00
Martine Lenders
254f16e81f gnrc_sixlowpan_frag: add asynchronous rbuf GC
While the current approach for garbage collection in the 6Lo reassembly
buffer is good for best-effort handling of
*fragmented* packets and nicely RAM saving, it has the problem that
incomplete, huge datagrams can basically DoS a node, if no further
fragmented datagram is received for a while (since the packet buffer is
full and GC is not triggered).

This change adds a asynchronous GC (utilizing the existing
functionality) to the reassembly buffer, so that even if there is no new
fragmented packet received, fragments older than `RBUF_TIMEOUT` will be
removed from the reassembly buffer, freeing up the otherwise wasted
packet buffer space.
2018-07-03 10:25:25 +02:00
Cenk Gündoğan
e5c6d0ebf1
Merge pull request #9240 from maxvankessel/pr/isrpipe
drivers/isrpipe: changed isrpipe_t content order
2018-07-02 22:28:41 +02:00
Cenk Gündoğan
bf33941819
Merge pull request #9434 from miri64/gnrc_pktbuf_static/fix/alignment-race
gnrc_pktbuf_static: fix alignment issue / leaks
2018-07-02 16:32:13 +02:00
Cenk Gündoğan
32e823acb2
Merge pull request #9447 from miri64/gnrc_sixlowpan_frag/enh/add-cur-size
gnrc_sixlowpan_frag: add current_size to exposed struct
2018-07-02 14:05:40 +02:00
Joakim Nohlgård
bbf4f1e453 gnrc_netif: Enable RX and TX complete events after netdev init 2018-06-29 21:53:23 +02:00
Francisco Acosta
23d176f46b
Merge pull request #8857 from ZetaR60/RIOT_atmega_time_dot_h
cpu/atmega_common: Use updated time.h
2018-06-28 22:29:20 +02:00
Martine Lenders
cb74063573 gnrc_sock_udp: use sock's local end-point for listening
Without this fix the listener doesn't actually listen on the
(potentially) ephemeral port introduced in #9382, but on port 0 which is
wrong.
2018-06-28 17:25:26 +02:00
Martine Lenders
68fe6682ff gnrc_sixlowpan_frag: add current_size to exposed struct
Since IPHC also manipulates the total number of bytes of a received
datagram (by decompressing it), this also needs to be exposed. I guess
I was too focused on introducing a *generic* packet buffer for a future
virtual reassembly buffer (where it isn't needed, but so isn't `pkt` to
be honest), that I totally forgot about it in #9352.
2018-06-28 12:28:51 +02:00
Joakim Nohlgård
904c583038
Merge pull request #8697 from aabadie/pr/drivers/params/lis3dh
drivers/lis3dh: apply unified driver params scheme + cleanup
2018-06-28 10:52:48 +02:00
Martine Lenders
acfe57a52b gnrc_pktbuf_static: reduce checks to be in line with new alignment 2018-06-27 17:19:34 +02:00
Martine Lenders
8a75d8d189 gnrc_pktbuf_static: fix alignment issue / leaks
This fixes an alignment issue I encountered in the static version of
the packet buffer.

The bug is caused by a race-condition where a certain order of
operations leads to a chunk being released according to the
byte-alignment of the platform, but overlapping potential space for
a future `_unused_t` struct e.g. (x mark allocated regions):

                    Future leak of size sizeof(_unused_t)       Time
                    v                                            |
    +------------+-----+--------------------+                    |
    |xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx|                    +
    +------------+-----+--------------------+                    |
                                                                 |
    +------------+--+--+--------------------+                    |
    |               |xxxxxxxxxxxxxxxxxxxxxxx|                    +
    +------------+--+--+--------------------+                    |
                                                                 |
    +-----+------+--+--+--------------------+                    |
    |xxxxx|         |xxxxxxxxxxxxxxxxxxxxxxx|                    +
    +-----+------+--+--+--------------------+                    |
                                                                 |
    +-----+------+-----+---------+----------+                    |
    |xxxxx|                      |xxxxxxxxxx|                    +
    +-----+------+-----+---------+----------+                    |
                                                                 |
    +-----+------+-----+--------------------+                    |
    |xxxxx|      |xxxxxxxxxxxxxxxxxxxxxxxxxx|                    +
    +-----+------+-----+--------------------+                    |
                                                                 |
    +------------+-----+--------------------+                    |
    |xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx|                    +
    +------------+-----+--------------------+                    |
                                                                 |
    +------------+-----+--------------------+                    |
    |xxxxxxxxxxxxxxxxxx|                    |                    +
    +------------+-----+--------------------+                    |
                                                                 |
    +------------+-----+--------------------+                    |
    |            |xxxxx|                    |                    +
    +------------+-----+--------------------+                    |
                                                                 v

Sadly, I wasn't able to create a reproducable unittest that show-cases
this corner-case, since I don't understand the order of operations that
cause this one 100%, but the bug is reproducable (but also not
reliably) by sending large (i.e. fragmented) packets to a 6Lo-enabled
host from more than 1 host simultaneously (use `gnrc_pktbuf_cmd` to
check).

By making the size of `_unused_t` the only condition for alignment,
this bug is fixed.
2018-06-27 17:18:24 +02:00
6e6716a1a6
Merge pull request #9317 from maribu/sht1x
drivers/sht11: Major refactoring
2018-06-27 10:10:39 +02:00
Marian Buschsieweke
b91359b05b
drivers/sht1x: Added SAUL integration 2018-06-27 08:58:05 +02:00
Marian Buschsieweke
de9b67bdc2
drivers/sht1x: Major refactoring
- Use RIOT's GPIO interface to access the sensor to increase portability
- Changed API to allow more than one sensor per board
- Added `sht1x_params.h` that specifies how the sensors is connected - each
  board can overwrite default settings by #defining SHT1X_PARAM_CLK and
  SHT1X_PARAM_DATA
- Changed arithmetic to use integer calculations only instead of floating point
  arithmetic
- Added support for checking the CRC sum
- Allow optional skipping of the CRC check to speed up measuring
- Added support for advanced features like reducing the resolution and skipping
  calibration to speed up measuring
- Allow specifying the supply voltage of sensor which heavily influences the
  temperature result (and use that information to calculate the correct
  temperature)
- Reset sensor on initialization to bring it in a well known state
- Support for the obscure heater feature. (Can be useful to check the
  temperature sensor?)
- Updated old SHT11 shell commands to the new driver interface, thus allowing
  more than one SHT10/11/15 sensor to be used
- Added new shell command to allow full configuration of all attached SHT1x
  sensors
- Removed old command for setting the SHT11 temperature offset, as this feature
  is implemented in the new configuration command
2018-06-27 08:58:00 +02:00
Marian Buschsieweke
d208c224b0
drivers: Renamed module sht11 to sht1x
The sensor family SHT10, SHT11 and SHT15 only differ in their accuracy (as in
calibration, not as in resolution). Thus, the same driver can be used for all.
The new driver name better reflects this fact.
2018-06-27 08:57:58 +02:00
Hyungsin
0c5c3d9b77 driver/pir: add pir-based occupancy sensing 2018-06-26 13:46:37 -07:00
Cenk Gündoğan
315c201747
Merge pull request #9372 from miri64/gnrc_sixlowpan_frag/enh/i8511
gnrc_sixlowpan_frag: adapt for #8511
2018-06-26 19:47:25 +02:00
Martine Lenders
a2eb3c7f15 gnrc_sixlowpan_frag: adapt for #8511
This refactors the `gnrc_sixlowpan_frag` module for the API proposed
in #8511.

The `ctx` for `gnrc_sixlowpan_frag_send()` is required to be a
`gnrc_sixlowpan_msg_frag_t` object, so IPHC can later on use it to
provide the *original* datagram size (otherwise, we would need to adapt
the API just for that, which seems to me as convoluted as this
proposal).

I also provide an expose function with a future possibility to provide
more than just one `gnrc_sixlowpan_msg_frag_t` object later on (plus
having cleaner module separation in general).
2018-06-26 19:38:33 +02:00
PeterKietzmann
ec5fb4fbda sys/random: fix distribution of random_uint32_range() 2018-06-26 14:08:43 +02:00
42c4460daf
Merge pull request #9325 from aabadie/pr/saul/tvoc_ppb
drivers/saul :sys/phydat: add definitions for TVOC sensor type and PPB unit
2018-06-25 12:20:11 +02:00
Cenk Gündoğan
bc57e901a8
Merge pull request #9374 from PeterKietzmann/pr_sys_sha1prng
sys/random: add SHA1PRNG
2018-06-22 16:22:09 +02:00
PeterKietzmann
3c4360eddb sys/random: add SHA1PRNG 2018-06-22 16:11:53 +02:00
Martine Lenders
ffde933259
Merge pull request #9399 from miri64/sock_dns/doc/fix-spelling
sock_dns: fix typo in doc
2018-06-22 13:32:20 +02:00
Martine Lenders
a027684a1e sock_dns: fix typo in doc
`s/fuction/function/` ;-)
2018-06-22 13:23:26 +02:00
Cenk Gündoğan
3712cdffc2
Merge pull request #9391 from miri64/shell/feat/pktbuf-cmd
shell_commands: add command for packet buffer stats
2018-06-22 10:04:37 +02:00