Commit graph

969 commits

Author SHA1 Message Date
joxe 7d235841b3 always include the RPL route state to allow compilation of rpl code 2010-05-03 14:12:03 +00:00
nifi 6c86398778 Added check to not copy or create too large packets 2010-05-02 14:59:11 +00:00
nifi a04372adc4 Fixed conversion of packetbuf address type to address index and corrected return value 2010-05-02 12:21:34 +00:00
joxe f72bd5572c added initialization of RPL 2010-05-01 13:04:31 +00:00
joxe 0531d9bd82 moved RPL routing state struct into uip-ds6 2010-05-01 12:02:25 +00:00
nvt-se 9a4a9b9437 Removed return value in function that should not return a value. 2010-04-30 23:13:58 +00:00
nvt-se ecada2d1ac *** empty log message *** 2010-04-30 23:10:45 +00:00
nvt-se b8a3a4109e Adjusted the code so as to remove compilation warnings. 2010-04-30 22:18:12 +00:00
nvt-se b822dbb25e Addressed compilation warnings. 2010-04-30 15:04:47 +00:00
nvt-se 4106f4d798 Increased minimum DIO interval from 1024 ms to 4096 ms in order to more calm in duty-cycled networks. 2010-04-30 15:03:55 +00:00
joxe 168a65d989 added ContikiRPL - an implementation of IETF ROLL RPL 2010-04-30 13:43:53 +00:00
joxe 167b0d636e added icmp_send function and moved rpl input function signature 2010-04-30 13:22:21 +00:00
joxe dc1a5f70ff added uip-debug utilities 2010-04-30 13:20:57 +00:00
nvt-se 7e0e2fe284 Removed obsolete rime-route code for IPv6 2010-04-30 12:43:37 +00:00
joxe cc9914a4f3 fixed uip to use UDP_BUF instead of TCP_BUF when setting udp ports - minor cleanup 2010-04-30 08:46:27 +00:00
adamdunkels 3d10dedecf Added a safety measure against a problem where a node in rare situations would turn itself into a sink. Not entirely sure why this happens, but the safety measure should at least avoid the results of the problem. Added more debug messages. 2010-04-30 07:33:51 +00:00
adamdunkels 0859d4b95f Avoid turning off the radio in the middle of a packet reception 2010-04-30 07:32:39 +00:00
adamdunkels e606c674c2 Rewrote LPP so that it uses 802.15.4 headers. A number of bugfixes with respect to alignment. Avoid turning off the radio in the middle of packet reception. 2010-04-30 07:31:44 +00:00
adamdunkels 55b6129bd2 Debug printout fix 2010-04-30 07:29:31 +00:00
adamdunkels e523c36cdf Removed the (unused) header packet of the queuebuf. Added a function for accessing address attributes in the queuebuf 2010-04-30 07:29:08 +00:00
adamdunkels 3c735fcea4 Added a packetbuf flag that indicates if the link layer acks should be used or not 2010-04-30 07:25:51 +00:00
adamdunkels 798f1c63bd Make it possible to receive multicast UDP packets 2010-04-30 07:19:33 +00:00
fros4943 18e5718c97 avoid freeing queuebuf multiple times, and free buffer after cancelling connection 2010-04-27 13:08:55 +00:00
fros4943 12b6f35ce7 PRINTF()ed debugging output 2010-04-27 12:56:35 +00:00
nifi 85d6f6c514 removed unused variable 2010-04-26 22:41:50 +00:00
nifi 875ad7ffda Fixed to not change the header if the header allocation fails 2010-04-26 22:05:40 +00:00
nifi b26f45a35b code cleanup 2010-04-26 17:55:11 +00:00
nifi d761b6e89a Added MAC header to handle padding 2010-04-26 17:46:21 +00:00
nifi 14b1bb9f57 Fixed to only use leds when DEBUG is set 2010-04-20 11:41:16 +00:00
nvt-se 2e5d97366a ensure matching format and type in debug printf 2010-04-09 16:21:07 +00:00
adamdunkels 3670fac618 Bugfix: timing fixed 2010-04-08 18:23:24 +00:00
adamdunkels f2bf8965d5 MAC sequence number attribute 2010-04-08 09:46:30 +00:00
adamdunkels 91ff8574ad Improved handling of duplicate packets 2010-04-08 09:32:56 +00:00
nvt-se ac4ba199bc Turn off DEBUG mode by default. 2010-04-06 21:37:54 +00:00
nvt-se 75dd41601b Added a macro for checking if an address is link local. 2010-04-06 16:47:18 +00:00
adamdunkels 497111bcc9 Added an optional rate limit for broadcast transmissions 2010-04-06 11:57:43 +00:00
adamdunkels e06a30fdb0 Added MAC-layer duplicate message suppression, which is very helpful when running with duty cycling turned off 2010-04-05 19:28:07 +00:00
adamdunkels c68ee6e577 Bugfix: memory from the wrong memb was freed. 2010-04-04 21:02:09 +00:00
adamdunkels a4c328785a Small timing tweaks 2010-04-04 21:01:24 +00:00
adamdunkels 62039a530d Removed non-existant cooja-debug.h include 2010-04-04 12:31:47 +00:00
adamdunkels 7d6ff0289e Fiddled more with the timing: the phase seems stable now at least. Still bugs left though... 2010-04-04 12:28:29 +00:00
adamdunkels be117afe04 After a lot of tweaking and twiddling with the timing of the ContikiMAC code and the mechanisms in the CC2420 driver, things seem to work somewhat stable now - knock on wood! 2010-04-04 07:49:30 +00:00
adamdunkels 83eaa70f03 Added pending flag 2010-04-03 13:34:20 +00:00
adamdunkels 121ca946e1 Improved phase lock behaviour when neighbor is not duty cycling: senders notify receivers via the 802.15.4 pending bit that they are not duty cycling. Neighbors then will start sending packets immediately and not wait for neighbors' phase. Tweaking of ContikiMAC timers to make it more reliable. 2010-04-03 13:28:30 +00:00
joxe 6ae86d001d made number of phase neighbors configurable 2010-04-01 17:17:36 +00:00
fros4943 59357e8b75 PRINTF():ed debugging output 2010-04-01 11:08:36 +00:00
adamdunkels cc11c9d3f2 Added missing #define 2010-04-01 10:56:00 +00:00
adamdunkels a8d8b6d31d Improved parent management: parent neighbor is retained until a better neighbor is found (with 1 ETX less than parent). Don't drop parent neighbors when loop is detected (loops are transient anyway). 2010-04-01 10:45:21 +00:00
adamdunkels d7457bc340 Improved parent management: parent neighbor is retained until a better neighbor is found (with 1 ETX less than parent). Don't drop parent neighbors when loop is detected (loops are transient anyway). 2010-04-01 10:03:19 +00:00
adamdunkels add426de4b Bugfixed stream mode: node listens 100% for 0.5 seconds in stream mode. Naming change: is_listening changed is_snooping. 2010-04-01 10:02:04 +00:00
adamdunkels 5b121b4829 Set stream bit only on non-FIN TCP segments 2010-04-01 10:01:01 +00:00
adamdunkels b43f7830b3 Fine-tuned the timing and phase lock optimization 2010-03-31 20:27:15 +00:00
adamdunkels 4e33112d3e Guard against malformed broadcast announcements 2010-03-31 12:17:24 +00:00
adamdunkels 877eb2fbe9 Fiddled with the timing 2010-03-31 11:54:38 +00:00
fros4943 3bd07ea55a bugfix: refresh correct source route
+
refreshing gateway route whenever data is received via a gateway
2010-03-31 09:38:42 +00:00
adamdunkels bcfa80102d Had previously not included the waiting time that the CC2420 introduces when sending a packet. Also increased the smallest packet size, just to be on the safe side. 2010-03-30 23:01:32 +00:00
adamdunkels 226abb8ec3 Removed non-existant include file 2010-03-29 22:10:03 +00:00
adamdunkels 4e3268e2e2 Added function that removes the header 2010-03-29 21:53:04 +00:00
adamdunkels 4c3b69dc07 Configuration parameter for number of MAC-layer retransmissions 2010-03-29 21:52:25 +00:00
adamdunkels 9c58768b59 Extend packet size after creating 802.15.4 header; prepare radio chip with packet before waiting for neighbor phase to make phase wait time deterministic 2010-03-29 21:51:36 +00:00
adamdunkels b4b7e942b6 Back off a guard time for every non-ack packet 2010-03-29 21:50:01 +00:00
oliverschmidt 315e446584 Adjusted formal parameter to single existing actual parameter. 2010-03-29 20:26:14 +00:00
fros4943 0fcbfae836 updated function: has_value argument was missing 2010-03-29 12:13:35 +00:00
fros4943 671629dea0 moved packet_sent function, it was in a HC06-specific unit 2010-03-29 11:48:09 +00:00
joxe bd6cd03c1d moved prefix to avoid compiler warning 2010-03-26 15:12:57 +00:00
nifi 9508d2c4d7 * Added configurable default number of transmissions for CSMA to use when not specified using packetbuf attributes (CSMA_CONF_MAX_MAC_TRANSMISSIONS).
* Renamed packetbuf attribute PACKETBUF_ATTR_MAX_MAC_REXMIT to PACKETBUF_ATTR_MAX_MAC_TRANSMISSIONS where value 0 (attribute not set) means that default number of transmissions should be used.
2010-03-26 12:29:29 +00:00
joxe bec1ccc57d added support for all UDP port compressions in hc06 2010-03-26 10:28:51 +00:00
nifi 0ec8d499e4 Bug fix: only call subscriber if set 2010-03-25 19:30:44 +00:00
adamdunkels a4f9e62295 Added a parameter to collect_open() that specifies whether or not the node should be a router for packets, or only an originator of packets. Updated the collect module to the new annoucement API. 2010-03-25 08:51:07 +00:00
adamdunkels 2559e27414 API change to the announcement module: an annoucement can now be registered without a value. Such announcements are never transmitted to neighbors, until the announcement's value is set. 2010-03-25 08:49:56 +00:00
adamdunkels 4d68bdf74b Bugfix and addition by Dogan Yazar: psock_readbuf() shouldn't wait for a full buffer (which might never happen); a new function for sending strings that batches data and sends full buffers instead of individual strings. 2010-03-24 21:03:32 +00:00
nifi c623616afd Neighbor state notification also when adding new neighbors 2010-03-24 16:29:45 +00:00
nifi 052c8db9f9 Added option for neighbor state changed notifications 2010-03-24 16:16:33 +00:00
joxe 4a6c6b0534 added route_rm_by_nexthop and small code cleanup 2010-03-23 14:21:04 +00:00
fros4943 95e870cc46 bugfix: structs should be declared static 2010-03-22 11:32:29 +00:00
nvt-se 0eae63b29a Set a higher start ETX. Avoiding adding a neighbor after a failed packet transmission. 2010-03-19 16:55:29 +00:00
adamdunkels 9d06d84255 Renamed the neighbor module to collect-neighbor, as it is only used by the collect module and is not a generic neighbor module 2010-03-19 13:25:15 +00:00
adamdunkels 49009e9cbd Extend the length of announcement packets if they are too short 2010-03-19 13:24:58 +00:00
adamdunkels 2e8bfa5d9a Include new broadcast-announcement and renamed collect-neighbor in compilation 2010-03-19 13:21:24 +00:00
adamdunkels f2c9b3e813 Remove old neighbor.h inclusion 2010-03-19 13:20:40 +00:00
adamdunkels 3a5be4a7e4 Added broadcast announcement module and collect-neighbor module 2010-03-19 13:17:55 +00:00
adamdunkels 14453e9fb7 Slight API change to support bump functionality 2010-03-19 13:17:31 +00:00
adamdunkels 7b0606cd58 Renamed the neighbor module to collect-neighbor, as it is only used by the collect module and is not a generic neighbor module 2010-03-19 13:17:00 +00:00
adamdunkels 137e02baac Added a bump method that tells the announcement module that a value has changed sufficiently much for it to be pushed out quicker 2010-03-19 13:16:11 +00:00
adamdunkels 17db783fb0 Broadcast announcement back-end that sends announcement data as broadcasts, with increasing transmission intervals 2010-03-19 13:15:19 +00:00
nifi 7f7922a10d typos 2010-03-19 12:54:38 +00:00
joxe cf9acf4748 made it possible to have zero contexts to avoid stateful compression in hc06 2010-03-19 08:15:20 +00:00
joxe 17a721a7e4 fixed buggy define for Traffic class and Flowlabel compression 2010-03-17 20:57:25 +00:00
adamdunkels 115b3a7c5c Minor timing bugfix: the time between channel checks should not include the time required for the channel check itself 2010-03-17 18:24:06 +00:00
adamdunkels efeb9944fa Increase the required non-activity periods before turning off the radio; remove the strict phase requirement (which messes up things with low-power streaming) 2010-03-17 16:35:52 +00:00
nvt-se 1a9e00ab78 Purge neighbors that go over a configurable ETX limit. Increase the no-ACK penalty. 2010-03-17 15:08:46 +00:00
nvt-se 4e0ceedc47 Enabled external neighbor removal 2010-03-17 15:00:52 +00:00
fros4943 55f780ec19 removed debugging output 2010-03-17 14:36:46 +00:00
joxe 4f27fcf766 added ipaddr variable if not UIP_ROUTER is defined 2010-03-17 12:30:25 +00:00
joxe e8916fe01f added hooks for adding an external header compressor 2010-03-17 12:08:59 +00:00
joxe d113577a8e made UIP_ND6_SEND_RA configurable from platforms and projects 2010-03-16 18:27:22 +00:00
adamdunkels 36b995cc9a Reenabled announcement support 2010-03-16 18:12:34 +00:00
adamdunkels 9be1a65211 Don't set the RELIABLE flag on incoming packets with the ack requested flag set, since it is set on most packets even if they aren't reliable 2010-03-16 18:11:58 +00:00
adamdunkels b1feac5a00 Bugfixes in low-power streaming mode, and re-added support for announcements. These now use the low-power streaming mode so that active listening for announcments have a radio duty cycle of 16% rather than 100% 2010-03-16 18:11:13 +00:00
nifi 6b7ec2d002 removed uip_router 2010-03-16 15:45:20 +00:00
nifi 75091661e6 fixed typo 2010-03-16 15:41:00 +00:00
joxe b4adc6bcb5 added fallback interface and removed uip_router 2010-03-16 15:35:03 +00:00
joxe 2b44f809fb added support for extending route entries 2010-03-16 14:11:46 +00:00
joxe 453cf7f2e6 refactoring of hc06 code 2010-03-16 10:21:04 +00:00
nvt-se 7f687b99e6 Debug off by default 2010-03-15 19:22:29 +00:00
joxe fd3d6c44d0 integration of new uip6 code from Mathilde and Julien - adds routing and improved interface handling 2010-03-15 16:41:24 +00:00
adamdunkels a9bad71fbd Increased the number of bits that repressent the MAX_RETRANSMITS attribute to allow for more than 7 hop-by-hop retransmissions 2010-03-14 23:01:12 +00:00
adamdunkels 7bab9316da Two major changes:
* Low-power streaming. Experimental support for a low-power mode which
  allows rapid exchange of packets with a 16% duty cycle. Does not
  seem to function correctly yet though.

* Phase locking. When the phase of a neighbor has been detected, the
  sender assumes that the neighbor will keeps it phase and does not
  send more strobes than necessary to hit the receiver's channel
  check - even if the receiver does not acknowledge the reception of
  the strobes when it should have been awake. Instead, the sender
  stops strobing and tries again at a later time.
2010-03-14 22:59:23 +00:00
oliverschmidt def540e6c0 Avoid newlines in macro expansions as cc65 doesn't support them between the macro name and the open parenthesis of the arguments.
There were btw other even longer lines with expansions of the same macro already present.
2010-03-14 12:13:54 +00:00
joxe e8bd53cfd8 added typedef of icmp6_error 2010-03-13 09:25:24 +00:00
dak664 0236c6e725 Leave compiler warning for 16 bit timers 2010-03-12 17:51:07 +00:00
joxe 4c2daf9886 started integration of Mathildes and Juliens new uip6 code + made some ND timers configurable 2010-03-12 16:19:19 +00:00
dak664 7c5eed6bda Add includes needed by AVR-gcc, fix compiler warning 2010-03-12 15:23:57 +00:00
dak664 52c9f4bde3 Remove compiler warning 2010-03-12 15:21:14 +00:00
nifi 2cf0fb9cce Changed to use short address mode with short rime addresses 2010-03-12 14:49:21 +00:00
nvt-se 6be0bac1a1 minor include fix + added documentation 2010-03-12 13:40:13 +00:00
nvt-se 881fac7f50 fixed comment 2010-03-12 13:25:14 +00:00
nvt-se 6ce15b14c9 prepend net/ to include paths 2010-03-12 13:23:50 +00:00
nvt-se c316fc2fa9 Make it possible to provide feedback to the neighbor modules 2010-03-12 13:20:13 +00:00
nvt-se 814dd8bf59 Added generic modules for neighbor information. 2010-03-12 13:19:45 +00:00
joxe d75ec2da53 fixed so that uip6 sends icmp6 errors from correct source when acting as router - improves support for tracert, etc. 2010-03-11 18:07:37 +00:00
adamdunkels 90bb63a383 Set the (correct) packet attribute to let the MAC layer perform retransmissions 2010-03-09 20:40:50 +00:00
adamdunkels 4b60301727 Don't set the ack flag for broadcast packets 2010-03-09 20:40:11 +00:00
adamdunkels 17f6b3a324 Simplified the structure of the code 2010-03-09 20:38:55 +00:00
adamdunkels d0e6436a20 Don't call up the netstack if the transmission was deferred 2010-03-09 20:37:02 +00:00
c_oflynn dc3e6c1877 Fix TC/FL errors in hc-06. Need to verify further 2010-03-09 16:19:44 +00:00
joxe 48a9bff889 added support for dropping packets if hop limit is reached 2010-03-09 15:50:15 +00:00
c_oflynn 1d483a5da4 Fix UDP compression to work per hc-06. More commits to come to fix Traffic Class stuff... 2010-03-09 15:18:03 +00:00
adamdunkels edda6dd86c Minor bugfix: don't subtract collisions and deferrals from the number of transmissions 2010-03-09 13:23:58 +00:00
adamdunkels 5a6fc2ade0 Bugfix: set up rtmetric before starting to announce it. Set the number of MAC layer retransmissions correctly 2010-03-09 13:21:28 +00:00
adamdunkels 2c3d3e3d73 Bugfix: handle deferred transmissions correctly (don't count them) 2010-03-09 13:20:08 +00:00
adamdunkels 79722b4247 Rework of the timing conditions of ContikiMAC: the old timing did not work well on real hardware, the new one seems to work better 2010-03-09 13:19:05 +00:00
nvt-se 96eb20d235 forward arguments even if REXMIT is not set 2010-03-04 14:17:43 +00:00
dak664 c65e09ceb2 Remove compiler warnings 2010-03-02 15:41:23 +00:00
nifi 5e43a6998b Replaced old framer (framer_get/framer_set) with new NETSTACK style configuration. Added nullrdc-framer that is a nullrdc with framer support. 2010-03-01 13:30:21 +00:00
nifi 0c084b8c68 added random init of sequence number 2010-03-01 13:17:01 +00:00
adamdunkels 524625dfd2 Removed debug string names of packet attribtues 2010-02-28 20:20:19 +00:00
adamdunkels 410d860a93 Improved handling of neighbor phase estimation: instead of busy-waiting while waiting for neighbor's phase, the new code schedules a timer just before neighbor wakes up 2010-02-28 20:19:47 +00:00
adamdunkels e6fceb7200 Added MAC-layer return value to indicate that a packet transmission was deferred 2010-02-28 20:18:30 +00:00
adamdunkels ec928a2a19 Make max queueing time depend on retransmission timeout 2010-02-28 14:15:58 +00:00
adamdunkels e06acc4525 Prod the watchdog if waiting for along time 2010-02-28 14:15:16 +00:00
adamdunkels 74da90a06b Don't count collisions as transmissions 2010-02-28 10:07:17 +00:00
adamdunkels f95a6cce85 Added function for obtaining packet queue length 2010-02-28 09:20:32 +00:00
adamdunkels 8fe15f7b45 New packet attribute for specifiying MAC layer retransmissions; reorder and commented packet attributes 2010-02-28 09:19:43 +00:00
adamdunkels 970a9eb9c7 Increased neighbor lifetime to allow for longer neighbor announcement intervals 2010-02-28 09:19:04 +00:00
adamdunkels 7165a3866f Significant rework of the Contiki data collection protocol:
* the new version makes use of MAC-layer feedback so that bad paths
  can be identified quicker and then avoided.

* the new code uses transport layer ACKs that contain feedback from
  the collect protocol: when a packet cannot be forwarded due to lack
  of resources, the ACK contains a flag that indicates that the packet
  could not be forwarded. ACKs also contain the routing metric of the
  sender, which improves agility in face of rapid path changes.

* loop detection and management has been improved: with higher path
  metric agility, the system is more prone to short-lived routing
  loops. Instead of dropping looping packets, the new version adjusts
  the routing metric for the routes that exhibit loops so that the
  risk for future loops is reduced.

* make use of packet attributes to inform the MAC layer of how many
  times packets should be retransmitted.
2010-02-28 09:18:01 +00:00
adamdunkels b6b4941871 Made the number of MAC-layer retransmissions configurable on a per-packet basis, via a packet attribute 2010-02-28 08:35:16 +00:00
adamdunkels ed88f487c8 Improved detection of link-layer ACKs; increased the time ContikiMAC waits when it has detected a link-layer ACK; increased the number of silence periods required to detect a CCA false positive 2010-02-28 08:33:21 +00:00
adamdunkels fa1a96636e Bugfix: the compile-time check for UIP_LLADDR_LEN previously generated a run-time error, when it should have generated a compile-time error 2010-02-28 08:30:39 +00:00
adamdunkels ba0e50a7b7 Set the default number of MAC layer retransmissions for IPv6 packets to 2 2010-02-28 08:29:42 +00:00
joxe 0ab2bc9a31 upgraded sicslowpan to hc-06 - no 48 bit multicast compression support yet 2010-02-25 15:50:58 +00:00
nifi b50d47fb80 added missing function in sicslowmac_driver 2010-02-23 22:45:11 +00:00
nifi 1cfcc8a73a Removed the combined name of CSMA and NETSTACK_RDC. The name of NETSTACK_RDC can be accessed separately if needed. 2010-02-23 20:42:45 +00:00
nifi c20047f657 Changed the network stack to use different structures for the different layers (network_driver, mac_driver, rdc_driver, radio_driver). This helps to avoid incorrect configuration. 2010-02-23 20:09:11 +00:00
adamdunkels bb62749de7 Made debug printfs optional 2010-02-23 18:49:58 +00:00
adamdunkels 0ab2ba433f Bugfix: the wrong callback pointer was passed to higher layers. 2010-02-23 18:49:45 +00:00
adamdunkels ed52586e18 Rework of parts of the ContikiMAC code based on input from experimental results. When channel check is triggered because of a false positive, the new version checks the radio several times to make sure that there really is an incoming packet. Otherwise, the radio is switched off. Cleaned up and removed old unused code. Added a few temporary debugging mechanisms and functions. 2010-02-23 18:49:05 +00:00
adamdunkels ca0417a923 Added the MAC layer callback functionality so that the Rime network layer gets information from the MAC about the status of sent packets: were they successfully transmitted, or was there a collisions? How many retries were there? 2010-02-23 18:38:05 +00:00
adamdunkels f10eedab3e Added debug printout 2010-02-23 18:37:15 +00:00
adamdunkels 2d13fecea7 Improved backoff management: timer is now doubled on every transmission, until the using module calls the neighbor_discovery_start() function again. Don't cancel the transmission even if a lower value arrives (this fixes a problem with multi-hop ETX propagaion). 2010-02-23 18:36:50 +00:00
adamdunkels 0eade2886c Better loop handling: when a loop is detected, the neighbor to which the packet was originally sent gets an inflated ETX; made sure that collect without announcments work; increased timeouts, to work nicer in larger networks 2010-02-23 18:35:23 +00:00
adamdunkels a4d9d6651b Added the option to specify the old value to observers so that they can determine if the announcement should be sent out quicklier than otherwise 2010-02-23 18:32:44 +00:00
adamdunkels b746b7fc06 Reworked the Rime/Chameleon interface so that packets now always hit Rime before Chameleon. Chameleon is now only called by Rime. This makes packet sniffing easier, and allows for sniffing packets after their header has been processed by Chameleon, thereby making per-packet power profiling much easier to implement 2010-02-23 18:29:53 +00:00
adamdunkels d8cce42d28 Set the default radio driver to nullradio 2010-02-23 18:28:04 +00:00
adamdunkels 0b2b7bcdba Removed inadvertedly left-over include file 2010-02-18 23:52:34 +00:00
adamdunkels 5cf3b83733 Common initialization code for the netstack 2010-02-18 23:15:26 +00:00
adamdunkels f49ebfe1c4 Temporarily disabled rime route udp because it breaks with newest MAC interfaces 2010-02-18 21:53:08 +00:00
adamdunkels e34eb54960 A work-in-progress rework of the Contiki MAC and radio layers. The
main ideas are:

* Separates the Contiki low-layer network stack into four layers:
  network (e.g. sicslowpan / rime), Medium Access Control MAC
  (e.g. CSMA), Radio Duty Cycling RDC (e.g. ContikiMAC, X-MAC), and
  radio (e.g. cc2420).
* Introduces a new way to configure the network stack. Four #defines
  that specify what mechanism/protocol/driver to use at the four
  layers: NETSTACK_CONF_NETWORK, NETSTACK_CONF_MAC, NETSTACK_CONF_RDC,
  NETSTACK_CONF_RADIO.
* Adds a callback mechanism to inform the MAC and network layers about
  the fate of a transmitted packet: if the packet was not possible to
  transmit, the cause of the failure is reported, and if the packets
  was successfully transmitted, the number of tries before it was
  finally transmitted is reported.
* NULL-protocols at both the MAC and RDC layers: nullmac and nullrdc,
  which can be used when MAC and RDC functionality is not needed.
* Extends the radio API with three new functions that enable more
  efficient radio duty cycling protocols: channel check, pending
  packet, and receiving packet.
* New initialization mechanism, which takes advantage of the NETSTACK
  #defines.
2010-02-18 21:48:39 +00:00
adamdunkels f8c804e28b ntikiMAC: a new radio duty cycling mechanism that uses a combination
of link-layer and MAC-layer mechanisms to achieve a very low power
consumption: during idle listening the radio is switched off between
99.2% and 99.6% of the time. One unicast transmission typically adds
between 0.07% and 1.2% additional radio time, depending on packet
size.

ContikiMAC uses the standard IEEE 802.15.4 message format and adds no
additional headers.

ContikiMAC is simple: it uses periodic two-shot channel sampling
during idle listening to keep the radio on-time down. Transmissions
are done with repeated transmissions until a link-layer ACK is
received.
2010-02-18 21:26:15 +00:00
adamdunkels f5c48751b5 Reworked 802.15.4 header creation and parsing so that it works regardless of the size of the rimeaddr_t typedef 2010-02-18 21:00:28 +00:00
adamdunkels 2fbf21b2b3 Refactored the phase optimization functionality into a separate module 2010-02-18 20:58:59 +00:00
adamdunkels 515a391ee4 Removed left-over debug printfs 2010-02-15 23:31:05 +00:00
dak664 bb9afb4fb1 Remove compiler warning 2010-02-15 20:49:38 +00:00
adamdunkels 4bb0375251 Buffer name definition bugfix 2010-02-15 19:23:54 +00:00
adamdunkels 9bb149ca13 Bugfix by Raimondas Sasnauskas: TCP SYN duplicate receptions in the SYN_RCVD state was not correctly handled 2010-02-15 18:03:07 +00:00
adamdunkels d67d1f7340 Major bugfix, found by Raimondas Sasnauskas: the TCP periodic timer was not started when a new connection request arrived. If there were no other active TCP connections, this means that the SYNACK would never be retransmitted, potentially leading to a forever stale TCP connection. 2010-02-09 12:58:53 +00:00
adamdunkels 4a522c96dd Added debugging statements for packet drops 2010-02-08 21:59:49 +00:00
adamdunkels 2b6a651233 Added missing include, made debug statement more explicit 2010-02-08 21:59:21 +00:00
adamdunkels 2eba08e8f6 Made queuebuf statistics configurable, and off by default 2010-02-08 21:10:32 +00:00
adamdunkels b98f7d891f Bugfix: added missing queuebuf allocation 2010-02-06 20:50:24 +00:00
adamdunkels 671216c558 No need to clear the headers now that we explicitly save a queuebuf when sending fragments 2010-02-06 17:07:43 +00:00
adamdunkels b6647b5630 Turns out that with cxmac, clearing the header after sending a packet is not enough to make fragmentation work. Instead, we allocate a queuebuf and restore the packet after from the queuebuf after sending it. 2010-02-06 09:42:49 +00:00
adamdunkels 494e692d0b Bugfix: clear the header after sending a packet solves a problem with fragmentation; also prod the watchdog since fragment transmissions can take a long time with some low-power MAC protocol 2010-02-06 07:49:58 +00:00
adamdunkels a68b4c40c4 Added a function to clear only the header part of the packetbuf 2010-02-06 07:48:52 +00:00
oliverschmidt e88d209214 Adjusted process name to title case. 2010-02-05 19:13:05 +00:00
nifi a1199721a6 Changed to use separate Contiki event type for ICMP6 notifications 2010-02-05 12:43:36 +00:00
oliverschmidt 5e66abda50 Initialize lastport in all cases it is defined. 2010-02-04 21:33:51 +00:00
adamdunkels d8b0625e21 Bugfix: lastport must be defines both when UIP_ACTIVE_OPEN or UIP_UDP are defined (thanks Oliver!) 2010-02-04 21:14:45 +00:00
adamdunkels 7bcb106fa9 Disable the stream mode for TCP packets since it does not seem to work reliably with cxmac 2010-02-04 18:57:33 +00:00
adamdunkels 13f6673d04 Bugfix: drop incoming TCP and UDP packets where port numbers are zero 2010-02-04 11:17:42 +00:00
adamdunkels d7b7b05d0e Moved the neigbor_init() call to the collect module, since it is the only one that currently uses it 2010-02-03 20:38:33 +00:00
adamdunkels 75e1c0c8c7 Include contiki-conf.h to let the MAC channel check rate be configurable 2010-02-03 16:45:12 +00:00
adamdunkels 06d17c7e1c Remove unused rtimer code 2010-02-03 16:44:43 +00:00
adamdunkels 4bffd277f5 Don't set the stream bit on outgoing TCP packets for now - it doesn't seem to play well with IPv6 and X-MAC 2010-02-03 16:44:19 +00:00
adamdunkels 36db5eb70b Added debug printout 2010-02-03 01:18:24 +00:00
adamdunkels e419eb3cc5 Retransmit packet if it didn't receive a MAC layer ack 2010-02-03 01:17:54 +00:00
adamdunkels d68af249ec Added a MAC layer return value that informs the caller that a packet did not receive a MAC layer acknowledgement 2010-02-03 01:17:32 +00:00
adamdunkels 4bc4f033e8 Increase the trickle resend interval for router advertisements 2010-02-03 01:13:17 +00:00
adamdunkels 181213124b Added a configuration option for setting the MAC channel check rate (which must be a power of two). The configuration is independent of the MAC protocol. 2010-02-02 23:28:58 +00:00
adamdunkels f66cd6d44e Increased the forwarding queue to six packets to improve collection robustness 2010-02-02 21:44:05 +00:00