In the application, when you creating the packet the which you want to
send
Ptr<Packet> packet = Create<Packet> (m_packetSize);
add the tag like below
p->AddPacketTag (tag);
Please go through the example "/ns-3-dev/src/network/examples/main-
packet-tag.cc" for how to add a tag to a packet.
and go through the example "/ns-3-dev/examples/tutorial/fifth.cc" for
how to make a custom application.
--
Ganesh