When the node receives a message named "data"
it calls onData()
which, among others, does the animations you are asking for
else if (std::string(wsm->getName()) == "data") {
onData(wsm);
- Where can I find more exact information about the color of nodes :
when the node circle is green, red, etc.?
void TraCIDemo11p::onData(WaveShortMessage* wsm) {
// Here is the green color for the nodes
findHost()->getDisplayString().updateWith("r=16,green");
// Here the blue lines are drawn
annotations->scheduleErase(1, annotations->drawLine(wsm->getSenderPos(), mobility->getPositionAt(simTime()), "blue"));
if (mobility->getRoadId()[0] != ':') traciVehicle->changeRoute(wsm->getWsmData(), 9999);
if (!sentMessage) sendMessage(wsm->getWsmData());
}
- What do these blue connecting lines in the debug mode mean? Where can
I find more information?
When a node receives a data message, a blue line is drawn by the receiving node, from itself to the node that sent the message.