Hua Yue schrieb:

Hi. I built TOSSIM in my TestTinyViz directory and tried running TinyViz but got the following output: [output snipped]

Any idea what the problem might be?

I bumped into the same problem a couple of weeks back.

I'm using TinyOS 1.1.15 (tinyos-1.1.15Dec2005cvs-1.cygwin.noarch.rpm). Running "tinyviz -run build/pc/main.exe 30" (as outlined in Lesson 5 of the TinyOS tutorial) produced Java ClassNotFoundExceptions for net.tinyos.message.avrmote.TOSMsg. The GUI started up, but the simulation could not be run.

In the tools/java/net/tinyos/sim/tinyviz script, java is called with the "-jar" switch, indicating the archive tools/java/net/tinyos/sim/simdriver.jar. When run with "-jar", java only uses the given jar-archive as source for class files (ignoring the CLASSPATH variable). As simdriver.jar does not contain net.tinyos.message.avrmote.TOSMsg, the ClassNotFoundException is produced and the simulation fails.

A quick & dirty fix is to compile the missing classes and include them in simdriver.jar manually:
- In directory tools/java/net/tinyos/message/avrmote issue "make"
- Edit tools/java/net/tinyos/sim/Makefile and include the line
  net/tinyos/message/avrmote/*.class      \
below the line
  net/tinyos/message/*.class              \
- In directory tools/java/net/tinyos/sim issue "make jarfile"

Now TinyViz should work as expected.

I hope that helps. Good luck.

Stefan

_______________________________________________
Tinyos-help mailing list
[email protected]
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to