Commit Graph

503 Commits

Author SHA1 Message Date
Atis Elsts b3afd65b1d fix a few comments in TSCH 2016-06-10 15:04:06 +03:00
Atis Elsts 0cb222e6e1 add 2-channel TSCH hopping sequence 2016-06-10 15:04:06 +03:00
Billy Kozak ac6a1c5255 Fixed wrong first cycle_start
The first time that powercycle() runs, cycle_start is incremented
by CHECK_TIME twice which causes the second cycle to be late.

This commit fixes this.
2016-06-07 08:13:18 -06:00
Simon Duquennoy 26bf33c762 Merge pull request #1550 from thomas-ha/tsch-cc2538-port
Port of TSCH for CC2538
2016-06-02 21:33:55 +02:00
Antonio Lignan 34af72c047 Merge pull request #1609 from simonduq/pr/net-debug
Added net-debug.[ch] to provide debug functions even in the non-IP case
2016-06-01 23:52:34 +02:00
Antonio Lignan f065971efc Merge pull request #1619 from simonduq/pr/tsch-rtimer16-fix
Fix bug in TSCH for platforms with 16-bit rtimer
2016-06-01 23:03:50 +02:00
thomas-ha 8a7b1f07d1 add cc2538dk 2016-06-01 17:58:57 +02:00
thomas-ha e537a2ea92 Add CC2538DK 2016-06-01 16:01:58 +02:00
Antonio Lignan 8d6a290382 Merge pull request #1682 from simonduq/pr/fix-tsch-log
Fix tsch-log bug
2016-05-25 18:02:36 +02:00
Simon Duquennoy 2299a763d0 Fix tsch-log bug 2016-05-25 17:38:10 +02:00
Simon Duquennoy 1cd06a291e Merge pull request #1639 from yatch/pr-tsch-log-link-null
Handle the case when log->link is NULL in tsch_log_process_pending
2016-04-28 18:12:34 +02:00
Nicolas Tsiftes 4d67a48d3d Merge pull request #1625 from kkrentz/llsec-fix
Fix for "LLSEC802154_CONF_ENABLED undefined"
2016-04-28 12:01:15 +02:00
Antonio Lignan 4251539237 Merge pull request #1579 from bkozak-scanimetrics/fix_csma_backoff
Use collisions for csma backoff and retry
2016-04-28 10:24:55 +02:00
Yasuyuki Tanaka 763c63f428 Handle the case when log->link is NULL in tsch_log_process_pending 2016-04-27 20:35:05 +02:00
Simon Duquennoy bb5e5d5c6b TSCH: use RTIMER_CLOCK_DIFF to compute estimated drift, fixing a bug that would occur on 16-bit rtimer platforms 2016-04-27 14:13:33 +02:00
Simon Duquennoy abf08a7167 Added net-debug.[ch] to provide debug functions even in the non-IP case 2016-04-26 16:08:10 +02:00
Simon Duquennoy 90b886aa71 Csma: comply with IEEE 802.15.4 2016-04-25 08:52:48 -06:00
Billy Kozak ca0f32f45b Use collisions for csma backoff and retry
The collision count is now used in the calculation fot the CSMA
backoff and transmission will fail after a certain number of
collisisons.
2016-04-25 08:00:56 -06:00
kkrentz 39921f1231 rdc.h: Read LLSEC802154_ENABLED instead of LLSEC802154_CONF_ENABLED 2016-04-25 03:10:42 -07:00
Simon Duquennoy e1ea4955c7 TSCH: remove 'not for us' log 2016-04-25 11:51:43 +02:00
kkrentz 4a88e9e537 llsec: Removed TSCH_SECURITY_CONF_LEVEL and TSCH_SECURITY_LEVEL 2016-04-13 09:16:08 -07:00
kkrentz 10d8b05bc6 llsec: Permit dynamic security levels 2016-04-13 07:54:46 -07:00
kkrentz 0379af3624 llsec: Do not define surrogates in packetbuf.h, as otherwise configuration errors go unnoticed 2016-04-13 07:54:46 -07:00
Antonio Lignan 8f064511d3 Merge pull request #1213 from joakimeriksson/dao_ack_handling
End-to-End DAO and DAO ACK handling for Contiki RPL.
2016-04-11 18:53:43 +02:00
thomas-ha 2a69999214 space instead of tab 2016-04-05 17:12:48 +02:00
thomas-ha 871c725144 spaces instead of tabs 2016-03-31 11:24:57 +02:00
Carlo Vallati 855703e936 Fixed a bug into tsch-schedule - tsch_schedule_add_link that causes deadlock if a new link cannot be created 2016-03-31 10:35:19 +02:00
Oliver Schmidt 111a976f1e Explicitly mark constant as 'unsigned' to avoid unnecessary promotion to 'long'.
Long constants trigger the performance warning "Constant is long" with cc65.
2016-03-28 14:39:16 +02:00
Joakim Eriksson 444015df67 refactored the rpl-nbr-policy to be called from nbr-table module 2016-03-26 09:45:37 +01:00
thomas-ha 2d9b53667f not leaving promiscuous mode anymore if TSCH_HW_FRAME_FILTERING disabled 2016-03-16 12:24:49 +01:00
Simon Duquennoy 3057cb3363 TSCH: reset now also flushes all queues and resets backoff exponents 2016-03-15 16:24:04 +01:00
Simon Duquennoy 4b4ea36e9b TSCH: substract RADIO_DELAY_BEFORE_DETECT from ACK timestamp (more accurate timeout for the following busy wait) 2016-03-15 16:23:57 +01:00
Simon Duquennoy 0fd097f821 TSCH: bound max packet size to the system's packetbuf size 2016-03-15 16:23:57 +01:00
Simon Duquennoy 0aa36eaa0a TSCH: explicitly turn radio off after ACK tx 2016-03-15 16:23:57 +01:00
thomas-ha 38348b8703 enable/disable HW frame filtering
enable/disable HW frame filtering as defined in TSCH_CONF_HW_FRAME_FILTERING
2016-03-08 15:50:37 +01:00
thomas-ha 6e5e1d05cd TSCH: define to enable/disable HW frame filtering 2016-03-08 15:48:16 +01:00
Simon Duquennoy 73fcfa42c2 TSCH: fix compiler warning that shows up when disabling TSCH_LOG_LEVEL 2016-03-07 17:42:17 +01:00
Simon Duquennoy cc58384b40 jn516x: remove temporary adjustements for compilation in a 802.15.4e-free Contiki 2015-12-07 11:51:50 +01:00
Atis Elsts d79ce957a1 Adaptive time synchronization for TSCH 2015-12-07 11:51:41 +01:00
Simon Duquennoy 7eabf8d391 TSCH: latest update from https://github.com/EIT-ICT-RICH/contiki 2015-12-04 15:21:58 +01:00
Simon Duquennoy 2ca7a1a79f TSCH security: port to new ccm-star and llsec APIs 2015-12-04 15:21:56 +01:00
Simon Duquennoy b0f936263e Added IEEE 802.15.4e TSCH (TimeSlotted Channel Hopping) MAC layer 2015-12-04 15:21:52 +01:00
Simon Duquennoy ecba49c282 Add support for IEEE 802.15.4e Information Elements (IEs). All IEs used by TSCH are currently included. 2015-12-04 15:21:50 +01:00
Simon Duquennoy 5cf9871d5b Added support for IEEE 802.15.4 frame version 2 2015-12-04 15:21:50 +01:00
Atis Elsts b5d17bb620 ContikiMAC: use RTIMER_GUARD_TIME #define to avoid accidentally scheduling a rtimer in the past on platforms with fast rtimer ticks 2015-12-03 17:37:26 +01:00
Simon Duquennoy 27fd590b51 Merge pull request #1228 from bkozak-scanimetrics/contikimac_replace_function_pointer_cast
Replaced function pointer cast in contikimac
2015-12-01 15:35:28 +01:00
Antonio Lignan d31ba8dfdc Replaced tabs leftover in previous commit 2015-11-24 10:21:23 +01:00
Antonio Lignan e2cf8f9868 Made ContikiMAC more configurable (on uknoblic behalf) 2015-11-23 14:03:51 +01:00
Simon Duquennoy fbd78a7e3b Merge pull request #1293 from simonduq/pr/fix-warnings
Fix a number of compiler warnings and enable -Werror in Travis
2015-11-10 08:49:11 +01:00
Simon Duquennoy b979beb075 Merge pull request #1167 from bkozak-scanimetrics/contikimac_fix_qsend_list_packetbuf_pending
Fix Mishandling of PENDING/Queued Packets at ContikiMAC and CSMA
2015-10-23 10:52:17 +02:00
Simon Duquennoy 5dd6261fef Nullrdc: added missing include for cooja nodes 2015-10-20 10:11:15 +02:00
Konrad Krentz 1a12ef3334 llsec: Unsecuring within parse 2015-10-14 08:22:44 -07:00
Konrad Krentz 2059b6559e llsec: Let llsec_drivers define their own framer 2015-10-14 08:21:40 -07:00
Nicolas Tsiftes a536801e24 Merge pull request #657 from atiselsts/networking_patches
Phase RDC memory allocation bugfix
2015-09-24 16:50:00 +02:00
Billy Kozak 467f28286c The CSMA driver no longer throttles queued packets
Fix for #1166

Updated the CSMA driver so it no longer applies a time delay for
sending queued packets which were sent without error.
2015-09-18 09:35:29 -06:00
Billy Kozak 32e668ae2a Fix for #1165
It is possible that packetbuf is modified by the call to
mac_call_sent_callback. If this occurs ContikiMAC will not be able to
recognize that a packet is pending.

This fixes this problem by storing pending status in a local variable before
calling mac_call_sent_callback.
2015-09-18 09:33:10 -06:00
Simon Duquennoy 63ddba93a9 Merge pull request #1169 from feshie/pr-warnings-fix
Fix multiple warnings (TCPIP, coap-observe, msp430, z1/tmp102, ContikiMAC)
2015-09-08 09:05:44 +02:00
Billy Kozak 7b27ad64ca Replaced function pointer cast in contikimac
Replaced a cast of the funciton pointer to powercycle with a
wrapper calling powercycle which has the correct signature.

The previous implementation was an instance of undefined behaviour
according to the C standard.
2015-09-01 10:16:43 -06:00
Atis Elsts b75f673801 RDC phase optimization: correct the behavior in case of memory allocation failure
phase_wait did not check whether queuebuf_new_from_packetbuf() returns NULL. This potentially causes send_packet to behave incorrectly; the proper packet would not be sent out (because queuebuf_to_packetbuf(NULL) is a no-op). Instead, whatever has been left in the packet buffer by its previous user will be sent out.
2015-08-14 16:37:00 +02:00
Simon Duquennoy dc4de9d001 Merge pull request #1161 from g-oikonomou/contrib/contikimac-sw-ack
Implement TX of S/W ACKs with ContikiMAC
2015-08-04 13:15:03 +02:00
Arthur Fabre 8739113308 Fix warnings in ContikiMAC
../..//core/net/mac/contikimac/contikimac.c:503:11: warning: variable
‘seqno’ set but not used [-Wunused-but-set-variable]
../..//core/net/mac/contikimac/contikimac.c:496:7: warning: variable
‘len’ set but not used [-Wunused-but-set-variable]

Both of these variables are only used if RDC_CONF_HARDWARE_ACK is not
true.
Their definitions and use have been moved into #ifdef guards so they do
not appear if RDC_CONF_HARDWARE_ACK is set.
2015-07-16 13:49:31 +01:00
George Oikonomou 315f6fe535 Implement TX of S/W ACKs with ContikiMAC 2015-07-12 00:07:33 +01:00
George Oikonomou 503a992887 Make ContikiMAC more configurable
Allow the project / platform to provide values for CCA_SLEEP_TIME and LISTEN_TIME_AFTER_PACKET_DETECTED.

This is useful for sub-ghz operation.

This has been shamelessly stolen from the [Mountain Sensing project](https://github.com/feshie/contiki)

@heliosfa @kmartinez
2015-07-11 23:55:44 +01:00
Benoît Thébaudeau 66acf74612 cc2538: examples: Fix build warnings
Toolchain used:
arm-none-eabi-gcc (GNU Tools for ARM Embedded Processors) 4.9.3 20150303
(release) [ARM/embedded-4_9-branch revision 221220]

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau.dev@gmail.com>
2015-06-02 01:38:11 +02:00
Moritz 'Morty' Strübe 0dab6926b3 Move MAX, MIN and ABS to sys/cc.h 2015-05-18 08:53:17 +02:00
George Oikonomou 11a5e0a49a Merge pull request #1051 from simonduq/fix-warning
Fixed a number of compiler warnings
2015-05-13 00:52:40 +01:00
Simon Duquennoy 4a93f5148d Fixed a number of compiler warnings 2015-05-08 09:07:20 +02:00
Simon Duquennoy 333e076b24 Disable PACKETBUF_ATTR_PACKET_TYPE in the non-Rime case by default 2015-05-06 16:36:15 +02:00
Simon Duquennoy 290fc829ea Consistently use PACKETBUF_ATTR_MAC_SEQNO for MAC sequence number, both input and output. Disable PACKETBUF_ATTR_PACKET_ID in the non-Rime case. 2015-05-06 16:34:44 +02:00
Simon Duquennoy bb76bb8beb Remove unused flag SICSLOWPAN_CONF_ACK_ALL. Include packetbuf attribute PACKETBUF_ATTR_RELIABLE only when RIME is compiled. 2015-05-06 16:34:26 +02:00
George Oikonomou dd4f181cde Fix warnings caused by incorrect \defgroup, \addtogroup, \file 2015-02-15 20:11:09 +01:00
Simon Duquennoy bd4233a953 Cleanup packetbuf: use rime attributes and addresses only when rime is enabled. Saves 32 byte per queuebuf in the non-rime case. 2014-12-02 16:54:58 +01:00
Simon Duquennoy a9cc909794 Network layer configuration: replace UIP_CONF_* with NETSTACK_CONF_WITH_* 2014-12-01 21:02:57 +01:00
Nicolas Tsiftes 9b90c378e8 Merge pull request #812 from kkrentz/packetbuf-holds-broadcast
packetbuf_holds_broadcast()
2014-11-28 19:15:19 +01:00
kkrentz 6ecbf8af34 ContikiMAC: Retain original copyright 2014-11-25 04:56:09 -08:00
kkrentz 18ee5ce294 ContikiMAC: Added missing length function to contikimac-framer.c 2014-11-25 04:56:09 -08:00
Nicolas Tsiftes 866bb99944 Merge pull request #860 from simonduq/frame802154-align
frame802154_t: make sure dest_addr and src_addr are aligned
2014-11-18 08:59:30 +01:00
kkrentz fb00a217f5 packetbuf: Use packetbuf_holds_broadcast() all-over 2014-11-13 09:58:08 -08:00
Enrico Joerns 85b494c16b [doc] Give files a common structure by placing license first (partial)
Followed by doxyen file and group tags.
This patch is only a first attempt to make provide a clean structure,
many more files require rework, too.
2014-11-10 23:54:49 +01:00
Enrico Joerns e9b5899eed [core/net/mac] Doxygen: Added frame802154 to net group 2014-11-10 23:53:32 +01:00
Simon Duquennoy 6b7017452b frame802154: move inclusion of linkaddr.h from .h to .c file 2014-11-10 15:43:32 +01:00
Simon Duquennoy df6a435d42 struct frame802154_t: make sure dest_addr and src_addr are aligned 2014-11-10 15:40:24 +01:00
Nicolas Tsiftes 6fb7dd238e Merge pull request #648 from cetic/pr-csma-fixes
High throughput fixes for csma and sixlowpan
2014-10-21 12:17:03 +02:00
Laurent Deru 7cbd59df03 Add per neighbor packet throttle 2014-08-13 10:11:02 +02:00
Laurent Deru 91d84a3086 Improve csma debug traces 2014-08-13 10:11:02 +02:00
kkrentz 2cf7d98cad ContikiMAC: Create and parse ContikiMAC header in special framer; Expanded framer interface
to allow for creating and securing frames in advance; Create and secure frames in advance when sending bursts; Do neither recreate nor resecure frames that come from phase
2014-08-05 05:07:06 -07:00
kkrentz 515287ef17 llsec: Removed superseded NETSTACK_ENCRYPT, NETSTACK_DECRYPT, and
NETSTACK_ENCRYPTION_INIT macros
2014-08-05 05:07:05 -07:00
kkrentz 41c5dbf961 llsec: Disable duplicate detection when the LLSEC driver provides replay protection anyway. 2014-08-05 05:07:05 -07:00
kkrentz eaae9f1100 llsec: Calling NETSTACK_LLSEC.on_frame_created() 2014-08-05 05:04:15 -07:00
kkrentz 8659c97fb0 framer-802154: Support for explicit keys 2014-08-05 05:04:15 -07:00
kkrentz 124dde25f3 framer-802154: Conditional compilation of security-related code 2014-08-05 05:04:14 -07:00
kkrentz fb6d2270ab framer-802154: Simplification of frame802154_create 2014-08-05 05:04:14 -07:00
kkrentz 11495a011c framer-802154: Renamed variable for the sake of consistency 2014-08-05 05:04:14 -07:00
kkrentz 1d324e50d2 framer-802154: Sequence number fix 2014-08-05 05:04:14 -07:00
kkrentz 9dc9e4bd9f framer-802154: Support for setting and accessing the frame type
attribute
2014-08-05 05:04:14 -07:00
kkrentz 19c9ef0a95 framer-802154: Support for creating and parsing frames with security headers 2014-08-05 05:04:14 -07:00
kkrentz be22883724 framer-802154: Introduced mnemonic variable 2014-08-05 05:04:14 -07:00
kkrentz c9ad9c04bd framer-802154: Style fixes 2014-08-04 01:09:57 -07:00
kkrentz bb74fc320f llsec: Configuration option for defining a constant LoWPAN-wide security level 2014-08-04 01:09:57 -07:00
kkrentz c396a85364 llsec: Added a layer in between NETSTACK_MAC and NETSTACK_NETWORK for implementing link layer security 2014-08-04 01:09:57 -07:00
Adam Dunkels cff30a394b Merge pull request #635 from nfi/linkaddr-size
Use LINKADDR_SIZE instead of sizeof(linkaddr_t) to avoid struct padding problems.
2014-06-11 23:18:27 +02:00
Adam Dunkels eceaf0c59b Merge pull request #631 from nfi/framer-len
Added function to framer that returns the estimated header length
2014-06-11 23:17:47 +02:00
Rémy Léone 25c8b0835d Closing doxygen groups 2014-05-30 11:01:20 +02:00
Niclas Finne b1335b08a8 Changed to use LINKADDR_SIZE instead of sizeof() to select between
short address and long address as some platforms might use padding in
the struct. This fixes #555.
2014-04-11 17:24:16 +02:00
Niclas Finne 68730566a3 Added method to framer that returns the header length if the framer
would create a header with the current packet information.

This allows sicslowpan to calculate the max payload size without
consuming a sequence number or clearing/restoring the packet buffer.
2014-04-11 17:03:23 +02:00
Adam Dunkels 5b1a9f5bc2 Bugfix: when a packet is sent by the RDC layer, we should count the number of transmissions made because a single callback can pertain to multiple transmissions at the RDC layer. 2014-03-24 08:36:18 +01:00
Adam Dunkels 45265249fc Changed the name of the rimeaddr module to linkaddr 2014-01-29 20:12:24 +01:00
Adam Dunkels bddd96d5c8 Removed all module makefiles. Instead, all .c files in a module directory are compiled. 2014-01-26 23:20:46 +01:00
Adam Dunkels 8eace27f9b Moved net/rime.h to net/rime/rime.h 2014-01-26 23:20:45 +01:00
Adam Dunkels 0fe08205e1 Moved the rimeaddr.[ch] code from the core/net/rime module to the core/net module, as it is used not only by rime code 2014-01-26 23:20:36 +01:00
Adam Dunkels 0f255606b0 Turned sicslowmac into a module 2014-01-26 23:20:28 +01:00
Adam Dunkels b78ab6753c Added makefiles to make core/net/mac into a separate module 2014-01-26 23:20:26 +01:00
Adam Dunkels d777ae14e4 Moved cxmac into a separate module 2014-01-26 23:20:26 +01:00
Adam Dunkels 083fe0b594 Moved the contikimac code into a core/net/mac/contikimac module 2014-01-26 23:20:25 +01:00
Adam Dunkels 5f3fe7f7c7 Updated include paths for the moved files under net/ 2014-01-26 23:20:23 +01:00
Martin Heusse 662eb4db14 Fix compilation error when DEBUG enabled in core/net/mac/framer-nullmac.c 2014-01-24 20:23:26 +01:00
Adam Dunkels 0908924f91 Removed the lpp.c code 2013-11-28 15:24:40 +01:00
Adam Dunkels f86aaf7c14 Removed the xmac.c code 2013-11-28 15:24:22 +01:00
Nicolas Tsiftes db4cada4e7 Merge pull request #462 from adamdunkels/push/no-reserved-double-inclusion-defines
Remove all leading double underscore inclusion #defines
2013-11-26 14:26:37 -08:00
Benoît Thébaudeau 4deba89f81 rdc: duplicate packets: Keep only the last sequence number for each address
According to IEEE 802.15.4e (§6.4.3.9), in order to detect duplicate received
MAC-layer frames, only the most recently received frame's sequence number needs
to be stored for each unique device address. Doing so limits the possible false
duplicate packet detections to a single sequence number. This also allows to
keep the last sequence number of more device addresses for the same value of
MAX_SEQNOS.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-11-25 13:01:11 +01:00
Benoît Thébaudeau 477a4a7178 rdc: duplicate packets: Factor out detection code
The code detecting duplicate packets in the RDC layer had been copied into most
RDC implementations. Factor it out into a new mac-sequence module in order to
have a single instance of this code.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-11-25 13:01:11 +01:00
Benoît Thébaudeau 14db3382af csma: Initialize sequence number with random value
According to IEEE 802.15.4 (§5.1.6.1, §6.4.2), the MAC sequence numbers should
be initialized to random values. This was already the case in
framer-802154.c:create(), but not in csma.c:send_packet(), sometimes causing
false detections of duplicate MAC-layer packets in other devices when a device
was restarted too quickly. This patch decreases the probability of such an
event.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
2013-11-25 13:01:11 +01:00
Adam Dunkels bb2dcaa057 A massive all-tree automated update of all double inclusion guard #defines that changes from using two underscores as a prefix, which are reserved, to not using two underscores as a prefix 2013-11-24 20:20:11 +01:00
Adam Dunkels bec721d313 Allow payload len to be larger than 256 bytes 2013-11-16 14:22:48 +01:00
Simon Duquennoy 03dcca15cb Implement a truncated exponential backoff for csma 2013-11-14 15:02:36 +01:00
Enrico Joerns 4ba22102fd [core/net/mac] Removed invalid struct member u8 in PRINTADDR 2013-10-15 01:43:26 +02:00
Simon Duquennoy 248301a041 Fix naming issues and includes in uip-ds6-nbr.h 2013-08-19 17:48:30 +02:00
Simon Duquennoy 5a1d8d8006 Make phase module use neighbor-table. 2013-08-19 17:48:29 +02:00
Fredrik Osterlind 8041f66d8c link-layer acks support for cooja motes 2013-08-15 14:32:35 +02:00
Adam Dunkels 0aa448f190 6lowpan fragmentation bugfix: the 6lowpan code had an unfortunate
interaction with the behavior of the rdc layer. If the first packet of a
fragment transmission was lost, the remaining packets would get dropped
on reception. Moreover, the reception code contained a bug that
sometimes would cause fragments to be misidentified as fragments. Taken
together, these problems would result in a pathelogical network
breakdown if too many fragmented packets would occur simultaneously.
2013-08-11 14:27:20 +02:00
Jelmer Tiete cf894b8b95 changed inter packet interval to 0.4ms 2013-06-21 13:15:45 +02:00
Nicolas Tsiftes 7cc8f326f4 Merge pull request #257 from adamdunkels/hotfix-csma
CSMA bugfix
2013-06-20 01:49:48 -07:00
Adam Dunkels 09f30e875d Bugfix: when a CSMA callback is received, we should remove the packet
that was transmitted and not just the first packet that happens to be on
the output queue.
2013-05-25 12:13:07 +02:00
Adam Dunkels c9de0e49be Added a number of default options for ContikiMAC, and allow them to be overridden with contiki-conf.h configuration options 2013-05-25 12:10:27 +02:00
lebrush 82d498f3a1 Removed undef 2013-05-15 16:25:34 +02:00
lebrush 071cfaf1cb Corrects some leftover uncapitalized printfs which may cause some platforms
to crash.
2013-05-15 12:21:15 +02:00
Nicolas Tsiftes 7f2a842b71 Merge pull request #174 from adamdunkels/feature-net-improvements
Improvements to the core/net/ code
2013-03-18 17:12:12 -07:00
Nicolas Tsiftes 6a07172662 Merge pull request #176 from adamdunkels/feature-net-bugfixes
Network system bugfixes
2013-03-18 13:38:44 -07:00
Adam Dunkels 7742b05d8c Major bugfix: when nullrdc is asked to send a list of packets, send the list of packets and not just the first packet - this is essential for retransmissions of fragmented IP packets to work 2013-03-18 13:35:29 +01:00
Adam Dunkels 4efd570cf9 Minor bugfix: explicitly cast pointer argument in debug printf 2013-03-18 11:22:05 +01:00
Adam Dunkels f2fbb4b49d Defensive programming: make sure that we don't fail completely if we get a callback for a NULL pointer 2013-03-18 11:22:04 +01:00
Adam Dunkels 82b755c017 Bugfix: keep track of receiver being awake as a local variable rather than a global, as it may have changed between invokations 2013-03-18 11:22:02 +01:00
Adam Dunkels 0670a8e1e2 Minor code style fixes to the contikimac and nullrdc code 2013-03-18 11:22:01 +01:00
Adam Dunkels 5993595a8f A number of updates to nullrdc
* add a few rimestats to keep track of sent and received acks
* made a number of configuration options possible to override (ack timing)
* added the logic for sending 802.15.4 link layer ack packets, despite not being able to guarentee the 802.15.4 MAC timing
* increased the number of sequence numbers to keep track of for duplicate filtering
2013-03-18 11:19:20 +01:00
Adam Dunkels 4541d3e85b Let the framer functions use ints instead of uint8_t to make them more generic 2013-03-18 11:19:18 +01:00
Robert Quattlebaum c0a693672c core/net: Added support for "bridge mode".
"Bridge mode" allows devices to more easily send 802.15.4 packets as if
they were a different device. It also turns off any packet filtering
that may be implemented at layer 2. It works by allowing
`PACKETBUF_ADDR_SENDER` to be set earlier in the stack.

This is useful for implementing 6LoWPAN-ethernet bridges.

Enabled via setting `NETSTACK_CONF_BRIDGE_MODE` to 1. Disabled by
default.
2013-03-10 14:45:15 -07:00
Adam Dunkels cb7842bd16 Added support for encryption and decryption of the packetbuf if macros
NETSTACK_ENCRYPT and NETSTACK_DECRYPT are defined. Those are intended
to be called as functions NETSTACK_ENCRYPT() and NETSTACK_DECRYPT() to
encrypt and decrypt the packetbuf, respectively. If needed, an
initialization function by the name NETSTACK_ENCRYPTION_INIT() can
also be defined.
2012-11-25 12:05:00 +01:00
Adam Dunkels 6ee1f72486 Removed old unused TDMA-based MAC and RDC code 2012-11-20 20:48:34 +01:00
Adam Dunkels ec8c7e9be0 Cleanup of the node-id.h files. The node-id.h file contains
declarations of functions for setting and getting a node ID number, a
functionality that exists on many platforms. Since this functionality
was not considered part of the Contiki core, each platform defined its
own node-id.h file. This commit attempts to clean this up by
collecting the node-id.h into a core/sys/node-id.h file that replaces
the old node-id.h files from the platform directories.
2012-11-20 19:59:46 +01:00
George Oikonomou 713c2e5974 DOS EOL and indentation fixes (core/ apps/ cpu/)
- Removed some DOS EOLs
- Changed some tabs to spaces
- Removed some trailing whitespaces

Part of Pull Request #6
2012-10-30 13:43:51 +00:00