The first problem is simply that you have overwritten the classpath
that contains the tools/java files so it can't find MessageListener.
This is a red herring, so stick with the second java invocation.

The real problem is in your second example where, apparently, serial-
Forwarder isn't connecting to your TOSBase mote. I would backup and use
some of the simpler apps, like MicaHWVerify and CntToLedsAndRfm to
verify that you have all the components working correctly.

Also, I think you can bypass serialForwarder and connect
Sample directly to the serial port that goes to TOSBase if you
set your MOTECOM envvar to [EMAIL PROTECTED]:mica2

MS

Amit Satpathy wrote:
Hi.
I am currently trying to run the High Frequency Sampling program in the tinyos-1.x/apps folder on 2 Mica2 motes. I have followed all the instructions written in the readme file. However, when i run Sample.class using the "java -cp . Sample 200 20000" , i get the following error:

---------- Capture Output ----------
"C:\Program Files\Crossbow\Crimson\IDE.bat" "C:\tinyos\cygwin\opt\tinyos-1.x\apps\HighFrequencySampling" "c:\tinyos\cygwin\bin" "java -cp . Sample 200 20000"
#############################
Command:   java -cp . Sample 200 20000
Cygwin:    c:\tinyos\cygwin\bin
Directory: C:\tinyos\cygwin\opt\tinyos-1.x\apps\HighFrequencySampling
Directory: /opt/tinyos-1.x/apps/HighFrequencySampling
#############################

java.lang.NoClassDefFoundError: net/tinyos/message/MessageListener
    at java.lang.ClassLoader.defineClass0(Native Method)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:502)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
    at java.net.URLClassLoader.defineClass(URLClassLoader.java:250)
    at java.net.URLClassLoader.access$100(URLClassLoader.java:54)
    at java.net.URLClassLoader$1.run(URLClassLoader.java:193)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:186)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:299)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:265)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:255)
    at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:315)
Terminated with exit code 0

When i use "java Sample 200 20000" command, the entire class just hangs and on the Serial Forwarder, it just indicates the write has failed and nothing else happens. The HFS mote does not light the yellow LED and no sampling occurs. Could anyone tell me if there's a solution for this?

Thank you and regards.

Amit Satpathy.
Institute of Infocomm Research.


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

Reply via email to