Commit graph

397 commits

Author SHA1 Message Date
Joakim Eriksson f069cef73a fixed so that Cooja can run in quick mode when having UI 2016-12-15 13:52:05 +01:00
Niclas Finne a02481bc99 Fixed more MessageListUI to respect visualized in Cooja 2016-12-14 10:10:25 +01:00
Joakim Eriksson 2a3edc9136 Fixed so that COOJA sends in isVisible instead of quick as visibility parameter to plugins to get compile info back into COOJA - and fixed CoreComm to use MessageList text if no UI 2016-12-11 20:52:03 +01:00
Fredrik Österlind 0313a429e2 Merge pull request #1575 from atiselsts/cooja_bit_errors
Cooja: add Msp802154BitErrorRadio interface
2016-06-06 11:39:45 +02:00
Joakim Eriksson 19120788c0 made a text-based version of the MessageList for headless execution 2016-04-27 19:32:14 +02:00
Atis Elsts c7c3ef3b9c Cooja: add Msp802154BitErrorRadio interface
The interface more accurately models bit errors due to signal fading as observed in IEEE 802.15.4-compatible radios, such as CC2420 and CC2520.
2016-03-31 13:41:16 +03:00
Simon Duquennoy 10bd49a71a Merge pull request #756 from sieben/dos2unix
dos2unix fix
2015-10-18 20:26:07 +02:00
Fredrik Österlind 88f8d25070 Merge pull request #1122 from cetic/pr-always-add-crc
Add CRC to packets send by CoojaMote
2015-09-23 09:10:44 +02:00
Rémy Léone 7a5071dd30 Adding a gitattributes and correcting line-endings
https://help.github.com/articles/dealing-with-line-endings/
2015-09-07 15:40:02 +02:00
Fredrik Österlind dde83500c9 Merge pull request #1056 from tim-ist/packet_sync
[Cooja/cc2420] Check the frame preamble and MPDU length before parsing an outgoing packet
2015-09-07 14:36:15 +02:00
Laurent Deru 68c284b955 Do not add a CRC to packet incoming from RfListener 2015-06-16 10:36:33 +02:00
Timofei Istomin eb4bdde9ca Finish the transmission at the end of a correct packet
This patch restores the original behaviour of Cooja when
the transmitted packet is correct (which is true in a vast majority
of cases).

In case of a wrong outgoing packet (wrong length, wrong preamble)
the transmission will end when the radio changes its state (which
should always happen after transmitting a packet).

Benchmarks with RPL (33 runs, 50 nodes, 3 hours of simulated time each)
yield the same results (PDR, delay, number of transmitted packets)
as with the unmodified Cooja.
2015-06-05 15:13:45 +02:00
Timofei Istomin 034a97eed2 Don't generate a zero-length packet in case of errors.
The packet converter used to generate packets of length zero
when it encountered errors during conversion. This caused
exceptions in packet analyzers.

Now the converter returns null in case of error. Appropriate
checks have been added to the code that uses the return value.
2015-05-28 22:11:50 +02:00
Timofei Istomin eae25d622d Check the frame preamble and MPDU length before parsing
Due to errors in mspsim and/or radio drivers, packets of incorrect
length are sometimes transmitted. The length might be larger than
the 127-byte maximum (considered negative in the current code)
or not matching the actual number of transmitted bytes.
This leads to wrong packet delimiting when converting from
the mspsim-level stream of bytes to Cooja-level packets
causing unhandled exceptions that terminate the simulation.

This patch checks the frame preamble (0000007A) and the length field.
If they are wrong, no decoding attempt is done.

The transmitted bytes are still delivered to the receivers untouched.
The connection is terminated when the radio state is changed (which alway
s happens when TX is done).
2015-05-08 18:52:34 +02:00
Andreas Löscher abe8e024ce fixed a bug where the scheduled time is not the executed one 2015-05-07 13:24:30 +02:00
Andreas Löscher 44c317ce1c Fix: the last execution time must be carried over when skipping 2015-05-07 13:24:30 +02:00
Andreas Löscher 2bd50bcbdc better implementation of the drifting 2015-05-07 13:24:30 +02:00
Andreas Löscher 21a22caf33 Added GUI and config file handling for Clock 2015-05-07 13:24:30 +02:00
Andreas Löscher efbd170733 standart deviation is 1.0 2015-05-07 13:24:30 +02:00
Andreas Löscher 97da226255 time deviation for MSP based nodes 2015-05-07 13:24:30 +02:00
Andreas Löscher ff4aee68bd Support in the mote clock interface for time deviation 2015-05-07 13:24:30 +02:00
Enrico Joerns bc6b7535d0 Buttons: use non-deprecated MSPSim button api 2014-11-04 01:48:12 +01:00
Enrico Joerns b5d119babd Buttons: Some minor cleanups
Removed imports not required anymore and made some class members final
2014-11-04 01:48:12 +01:00
Enrico Joerns b28c593776 Buttons: Added missing @Override annotations 2014-11-04 01:48:12 +01:00
Enrico Joerns 0a63922fa2 Buttons: Move implementation of button routines to Button class
The implementation of clickButton(), pressButton(), and releaseButton()
can be shared accross the several node-dependent implementations as
they use the node-dependent doPressButton() doReleaseButton() routines.
2014-11-04 01:48:12 +01:00
Enrico Joerns be88a4fc52 Button: Add doPressButton() and doReleaseButton() to Button class
As every Button has a node-specific implementation part, this should be
the minimal interface to the backend node emulator for pressing and
releasing a button.
2014-11-04 01:48:11 +01:00
Enrico Joerns 378ca2629d Button: None of the buttons will saves its state
Saving a buttons state in simulation file is not required as its state
is much too volatile.
2014-11-04 01:48:11 +01:00
Enrico Joerns 82d30ef2e3 SkyButton: Reduce dependency on SkyMote
Placed call to setButton() in implementation-specific functions
doPressButton() and doReleaseButton() as in ContikiButton.
2014-11-04 01:48:11 +01:00
Enrico Joerns d99708ba08 Button: Move common interface visualization to Button class
The implementation of a simple JPanel with a JButton was only code
duplication accross the several button implementations.
2014-11-04 01:48:11 +01:00
Enrico Joerns 9d27b181c1 [cooja/mspsim] Msp802154Radio: Fix maximum power indicator
Previously getOutputPowerIndicatorMax() returned the fixed value 31.
This is valid for e.g. the mspsim CC2420 radio implementation but not for the CC2520 implementation where the maximum returned value is 9.

Thus to fix transmission range issues (for example for Wismote node) the maxium value provided by the radio implementaiton must be used.
2014-10-05 00:38:49 +02:00
Enrico Joerns 434c4db1a2 [cooja] Implementation of former MspMoteMemory dummy functions 2014-07-31 21:20:08 +02:00
Enrico Joerns 44767324a5 [cooja] memory: Removed AddressMemory class including all references 2014-07-31 21:20:01 +02:00
Enrico Joerns 482dab5d16 [cooja] memory: Removed MoteMemory class including all references 2014-07-31 21:08:18 +02:00
Enrico Joerns 9dd29d56c9 [cooja] getMemory() now returns MemoryInterface
Including code adaptions based on new memory methods to keep code compilable
2014-07-31 21:08:18 +02:00
Enrico Joerns d1c05300a9 [cooja] memory: AvrMoteMemory and MspMoteMemory dummy implementation of MemoryInterface 2014-07-31 16:30:05 +02:00
Enrico Joerns 579f0a9a93 [cooja] Added MemoryLayout class to represent basic information about
motes memory such as word size or endianess
2014-07-31 13:32:06 +02:00
Enrico Joerns c6f8a2d558 [cooja] Added @Override annotations for relevant files 2014-07-31 13:32:06 +02:00
Enrico Joerns 418c51a7d5 [cooja/mspsim] a single sky mote in cooja.config should be sufficient 2014-03-08 01:18:07 +01:00
Fredrik Osterlind 51e62e8cb3 Cooja backwards compatibility with simulation files that uses non-Contiki Java package names 2013-11-20 16:43:28 +01:00
Fredrik Osterlind b5c94910ac Renamed Java packages to match our contiki-os.org domain. Note that this commit does not affect external dependencies
like /tools/mspsim.

This is a very simple modification that affects a very large number of files in Contiki: Cooja,
/platform/cooja, Collect-view, Coffe-manager, and Cooja simulation files (.csc).

I've gone through Contiki to update all references I could find. Nevertheless, this commit will likely
break external dependencies, like saved Cooja simulation files.
2013-11-20 16:43:27 +01:00
Fredrik Osterlind 2a9283884c renamed getGUI() method to getCooja(), to better reflect its purpose 2013-11-20 16:43:20 +01:00
Fredrik Osterlind 625537158f renamed main Java class of Cooja from GUI to Cooja.
se.sics.cooja.GUI -> se.sics.cooja.Cooja

this commit does not contain any functional changes, but may require external scripts to be updated
such as Makefiles.
2013-11-20 16:43:18 +01:00
Moritz 'Morty' Strübe d05b03108a Decent error if mspsim cant be built 2013-11-14 18:14:03 +01:00
Adam Dunkels 71eea754d6 Added mspsim as a submodule instead of as a binary mspsim.jar file 2013-11-07 17:28:50 +01:00
Moritz 'Morty' Strübe 2b5f3bc6bd Add MSPSim Logging 2013-08-20 10:43:32 +02:00
Fredrik Osterlind 96968cb35e bugfix: only write to infomem if empty 2013-08-16 15:02:08 +02:00
Fredrik Osterlind 7c125ced9a a set of new cooja-mspsim mote types 2013-08-16 12:02:16 +02:00
Fredrik Osterlind 92655159c8 added a set of new mspsim-based mote types using CC1120, CC1101 and the Enc28j60 ethernet chip
minor changes: removed some obsolete stack monitoring code, improved mspsim-cooja window handler
integration
2013-08-15 11:46:29 +02:00
Fredrik Osterlind 9929cc2a10 added new mote type method that returns the by default used mote interfaces, as opposed to all compatible mote
interfaces

this allows a user to override default settings in the create-new-mote-type dialogs
2013-08-14 13:30:15 +02:00
Fredrik Osterlind 8e264badb7 added new mote type method that returns the by-default used mote interfaces, as opposed to all compatible mote
interfaces

this allows the user to override default settings in the create-new-mote-type dialogs
2013-08-14 13:25:53 +02:00