David, If the application implemented in TOSSIM relies strictly on the HIL, it should work on the IRIS (or any other supported mote platform) as well. When moving from TOSSIM to the mote, the following issues need to be considered:
1. Memory usage. While you're typically not limited by memory constraints in a simulation, keep in mind that the IRIS has only 8kB of RAM. Also, malloc is technically possible in TOSSIM, however it will not work on a mote. When you compile for the IRIS target, the make system will display the memory usage of your app. I suggest that you check out the latest TinyOS 2.1 sources from the CVS, because there has been a nice new feature added recently that allows for stack depth analysis, as well. 2. Long-running computations. Since TOSSIM is a discrete event simulator, it has no issues simulating tasks that implement long-running computation, or contain atomic blocks that may take a long time to execute. When migrating the code to TinyOS, make sure that such long running computations are avoided. Also, try avoiding long atomic blocks that disable interrupts for a long time. 3. Timing. Tasks are executed instantaneously in TOSSIM. That is, in a TOSSIM simulation, it takes zero time for a task to execute. On the actual hardware, this will obviously be non-zero. Because of this, you may expect timing issues when you migrate the code from TOSSIM to the mote. Janos On Tue, Apr 21, 2009 at 1:22 PM, David Li <[email protected]> wrote: > Hi, > > After reading through the TOSSIM tutorial I am wondering how much of TOSSIM > can be used directly on the real hardware platform (e.g. iris mote). It > seems that only radio or phyical layer is simulated. so the question is can > the code above radio (MAC etc.) be used directly on the real hardward after > simulation without much modifications? If not what are the addtional steps > to be taken beside recompiling for the target? > > Thanks. > > David > > _______________________________________________ > Tinyos-help mailing list > [email protected] > https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help > _______________________________________________ Tinyos-help mailing list [email protected] https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
