[Environment]
Moteiv telosb (upgraded)
2 motes with SurgeTelos program (node id = 1 and 2)
[Programs]
tinyos1.x/contrib/ucb/apps/SurgeTelos
tinyos1.x/tools/java/net/tinyos/surge (compiled with SURGE_PLATFORM=telosb)
[Run]
java net.tinyos.sf.SerialForwarder -comm serial at COM6 :tmote
java net.tinyos.surge.MainClass 0x7d
[Problem]
While I am trying to broadcast packets from PC to motes, the gateway mote
(node id=0) does receive the message.
However, it does not forward the message to the next hop. that is the mote 1 and 2 cannot receive the message from pc,so i cannot change the Timer's frequnecy.
void changeSampleRateButton_actionPerformed(java.awt.event.ActionEvent event) {
/* MDW Disabling for now */
try {
// Send change sample rate command
sampleRate = tentativeSampleRate;
BcastMsg bcm = new BcastMsg();
SurgeCmdMsg scm = new SurgeCmdMsg(bcm,
bcm.offset_data(0));
scm.set_type((short)2);
scm.set_args_newrate(sampleRate);
//mhm.set_parentaddr(0);
//mhm.set_originaddr(0);
//sm.set_hopcount((short)0);
bcast_seqno = (bcast_seqno + 1) % 256;
bcm.set_seqno((short)bcast_seqno);
MainClass.getMoteIF().send(net.tinyos.message.MoteIF.TOS_BCAST_ADDR,scm);
if (DEBUG_MODE) System.err.println("SENDING: "+scm);
} catch (java.lang.Exception
e) {
}
}
ps. i have add these lines to the makefile
PFLAGS= -I%T/../contrib/ucb/tos/lib/MultiHopLQI
-DSEND_QUEUE_SIZE=8 -DMHOP_LEDS
PFLAGS += -I%T/../tos/lib/Broadcast
PFLAGS += -I%T/../tos/lib/Queue
_______________________________________________ Tinyos-help mailing list Tinyos-help@Millennium.Berkeley.EDU https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help