I don't know how to put this, but it looks like you've done
everything exactly right....and what's more, reported it clearly.

I don't think the compile error is a problem as Listen and ListenRaw
don't try to interpret message sub-structures. I also don't know
why you see the wrong stop-bits, it seems to work for me. I would
expect to at least see some junk on the line even when this is not
set correctly though.

Assuming you used the same setup, COM port, cable, MIB, etc
to program the mica2 successfully, I'd say it should just work.
I haven't used TOS2 so I can't swear to the above however.

Some things to try...

Make SURE that danged SW1 is OFF. Could be the switch is faulty.

Use "/dev/ttyS5" instead of "COM6". I don't have a grip on which versions
of tos and tools care one way or the other, but things have changed...

There could be something wrong with the javax.comm install that you
have. Maybe try re-installing, or other java programs that use serial.

Use hyperterm or other terminal emulator to see if you get anything
from the serial port. It should at least gasp and print some kind of
garbage while trying to interpret the binary data into ASCII.

Try another mica2 if you're got one. Also try a different program.
The old TOS had apps/MicaHWVerify that sent and received a simple
message.

If you have a breakout box or scope or something, look at the
serial line and see if you are really getting data.

Try a different PC host...not likely, but we're grasping at straws here.

MS

ps...How's Mills? I'm about the only person I know who didn't
attend or teach at the CCM there...


Emma Miller wrote:

I'm new to TinyOS and I'm having problems getting SerialForwarder, Oscilloscope, Listen, and ListenRaw to work with TinyOS-2. SerialForwarder does not show any packets being read and Listen and ListenRaw do not output anything.

I'm using Windows XP and Cygwin, Mica2, MIB510.

I can compile and install the Oscilloscope app onto the motes. The green and yellow leds blink indicating sending and receiving, and the red led doesn't blink.

The programming board switch (SW1) is off.

In the Makefile in apps/Oscilloscope directory I added: SENSORBOARD=micasb

When I run Listen I set [EMAIL PROTECTED]

Output from java net.tinyos.tools.Listen:
[EMAIL PROTECTED]:57600: resynchronising

Output from java net.tinyos.tools.ListenRaw -mica2 COM6:
Opening port COM6
 baud rate: 57600
 data bits: 8
 stop bits: 0
 parity:    false


The only things that look weird are:

When I did a 'make clean' and 'make' from the /opt/tinyos-2.x/support/sdk/java directory I got the error:

make[4]: Entering directory `/opt/tinyos-2.x/support/sdk/java/net/tinyos/message/avrmote'
... /opt/tinyos-2.x/support/sdk/java/net/tinyos/message/avrmote
mig java -target=mica2 -java-classname=net.tinyos.message.avrmote.SerialAMPacket /opt/tinyos-2.x/tos/lib/serial/Serial.h serial_packet -o S
erialAMPacket.java
warning: Cannot determine AM type for serial_packet
         (Looking for definition of AM_SERIAL_PACKET)

...And the rest of compilation continued as normal. If this is a problem how do I fix it?

I am also wondering why my ListenRaw output is 0 for the number of stop bits? And does it matter? In ListenRaw.java 1 is hard-coded as the number of stop bits, and the TinyOS-1 tutorial also lists 1.


I'd appreciate any help.

Thanks,
-Emma
_______________________________________________
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