LoRaWAN The LoRa Alliance first defined the LoRaWAN standard with the objective of creating a medium access scheme and a set of network management policies that leverage the properties of […]
Low-power wide-area network (LPWAN). These networks use low-power radio signals, such as those in the sub-1 GHz range, to send small amounts of data over a large area. LPWANs are […]
SUMO has different tools for creating and customizing road networks and traffic flows and traffic signals. In this article, we will use some of those tools available in SUMO to […]
Spring Mobility Spring mobility is nothing but making a node to move in a path similar to that of an expanded circular coil spring. From the top or bottom point […]
Mobility Models of ns-3. The default ns-3 installation will contain the following mobility models. MobilityModel Subclasses ConstantPosition ConstantVelocity ConstantAcceleration GaussMarkov Hierarchical RandomDirection2D RandomWalk2D RandomWaypoint SteadyStateRandomWaypoint Waypoint PositionAllocator Position allocators […]
Aquatic Animal Tracking: Tracking marine animals can be extremely tricky due to GPS signals not functioning well underwater[1]. Underwater acoustic communication is a technique of sending and receiving messages below […]
hi,
i think the reason behind this is because AODV send a broadcast route request message (RREQ) i.e. 1 RREQ sent, and you get RREP (route reply) from all its neighbouring nodes.
so if you want to count the number of successfully received msg, you should specify the packet size (payload) of interest.
i found this AWK script which might be useful:
BEGIN {
recvdSize = 0
startTime = 1e6
stopTime = 0
}
{
# Trace line format: normal
if ($2 != “-t”) {
event = $1
time = $2
node_id = $3
flow_id = 0
pkt_id = $7 ;#seq no
pkt_size = $9
flow_t = $8
level = $4
dreason = $6
}
# Trace line format: new ($ns_ use-newtrace)
if ($2 == “-t”) {
event = $1
time = $3
node_id = $5
flow_id = $39
pkt_id = $41
pkt_size = $37
flow_t = $35
level = $19
}
# Store packets send time & count #packets sent
if (level == “AGT” && flow_id == flow &&
sendTime[pkt_id]==0 && (event == “+” || event == “s”) && pkt_size >= pkt) {
if (time < startTime) {
startTime = time
}
sendTime[pkt_id] = time
this_flow = flow_t
sendNum ++
}
# Update total received packets’ size and store packets arrival time
if (level == “AGT” && flow_id == flow && event == “r” && pkt_size >= pkt) {
if (time > stopTime) {
stopTime = time
}
# Rip off the header
hdr_size = pkt_size % pkt
pkt_size -= hdr_size
# Store received packet’s size
recvdSize += pkt_size
# Store packet’s reception time
recvTime[pkt_id] = time
}
}
END {
for (i in recvTime) {
if (sendTime == 0) {
printf(“nErrorn”,i)
}
delay += recvTime – sendTime
recvdNum ++
}
printf(” %15s: %gn”, “sendPkts”, sendNum)
printf(” %15s: %gn”, “receivedPkts”, recvdNum)
}
hi ghadah,
based on my limited knowledge on ns-2, you can do this using a procedure.
pls refer to:
http://www-sop.inria.fr/mistral/personnel/Eitan.Altman/COURS-NS/n3.pdf
page 45