uint8_t gLastHeard;
int16_t gCurrentSeqNo;
-
+ int16_t gOriginSeqNo;
+
uint16_t gUpdateInterval;
uint8_t gRecentIndex;
bMsg->cost = 0;
bMsg->originaddr = TOS_NODE_ID;
bMsg->hopcount = 0;
- bMsg->originseqno = gCurrentSeqNo;
bMsg->seqno = gCurrentSeqNo++;
}
else {
bMsg->cost = gbCurrentParentCost + gbCurrentLinkEst;
bMsg->originaddr = TOS_NODE_ID;
bMsg->hopcount = gbCurrentHopCount;
- bMsg->originseqno = gCurrentSeqNo;
bMsg->seqno = gCurrentSeqNo++;
}
gbCurrentHopCount = ROUTE_INVALID;
gbCurrentCost = 0xfffe;
+ gOriginSeqNo = 0;
gCurrentSeqNo = 0;
gUpdateInterval = BEACON_PERIOD;
msgBufBusy = FALSE;
lqi_header_t* header = (lqi_header_t*)call Packet.getPayload(msg, NULL);
header->originaddr = TOS_NODE_ID;
- header->originseqno = gCurrentSeqNo;
+ header->originseqno = gOriginSeqNo++;
header->seqno = gCurrentSeqNo;
if (isRoot) {