Aggregating results of vectors based on Omnet++ signals - omnet++

I want to compute an overall delivery ratio in function of time using vectors based on Omnet++ signals ? How can i achieve it when there is a multiple source and only one sink.
For example, say that i have 10 mobiles nodes that send data to a fixed AP, the delivery ratio is equal to (received/sent packets), but the AP knows only the amount of received packets.
I declared the following signals and statistics:
For AP:
#signal[receivedBndl](type = "int");
#statistic[receivedBundle](title="ReceivedBundle";source=receivedBndl;record=count,mean,last,vector);
For Nodes:
#signal[sentBndl](type = "int");
#statistic[sentBundle](title="SentBundle";source=sentBndl;record=count,mean,last,vector);
Is it possible to create another #statistics that compute the Delivery Ratio in function of time with this 2 signals ?
Thanks,

This is more like a network wide statistic, than something related to a single node so you have to install your statistic listeners on the top-level network module itself instead of the actual nodes. OMNeT++ signals propagate up on the containment chain so any signal that was sent to a specific node will be delivered also to the containing network module. This makes it possible to install the statistics on the network and get the given signal there (too).
To achieve this I would rewrite the code to actually emit the sent/received cPacket objects (and not the count of them as an integer). You still can count the number of packets using the count() function in the statistics.
For AP:
#signal[receivedBndl](type = cPacket);
For nodes:
#signal[sentBndl](type = cPacket);
As each actual sent/received packet is now emitted to their sending/receiving module (and anything above them), you can install a statistic in the top-level module and combine them into a single statistic:
#statistic[deliveryratio](source=count(receivedBndl)/count(sentBndl); record=last);
This last line will install two signal listeners on the top level module and the statistics will calculate the value each and every time any module generates or receives a packet anywhere in the network.

Related

Vivado routing metrics

I'm trying to gather metrics to measure routing utilization on a set of different designs. Any pointers would help a lot!
In the Router Utilization Summary, what does "Global Vertical/Horizontal Routing Utilization" measure?
Global Vertical Routing Utilization = 15.3424 %
Global Horizontal Routing Utilization = 16.3981 %
Routable Net Status*
*Does not include unroutable nets such as driverless and loadless.
Run report_route_status for detailed report.
Number of Failed Nets = 0
Number of Unrouted Nets = 0
Number of Partially Routed Nets = 0
Number of Node Overlaps = 0
Is there any way to access the per CLB metrics mentioned here (especially the "Horizontal/Vertical routing congestion per CLB") through tcl? I've searched far and wide to no avail.
Routing report
Since CLBs in an FPGA are connected through configurable switches to redirect traffic, as shown in this source:
Also quoting it:
A vertical (horizontal) channel is defined as a set of tracks between two consecutive columns (rows) of CLBs; wire segments connecting CLB pins are aligned into tracks running in the channel.
So it seems that the Vivado report means how much the switches are used in vertical and horizontal configuration. I don't know how much this information could be useful to the end user, maybe a big disproportion of these percentages might indicate that some particular hard IPs are overutilized and all the connections follow one direction, but other than that I would expect the percentages to be quite similar, and together an indication of how "crowded" your design is.
Metrics
For the second question, I believe you can't access the metrics because the link you have shown is just a heat map over the device, that is drawn by Vivado.
You can however access to the underlying data used to generate the map, for instance by running the time report
report_timing_summary -delay_type min_max -report_unconstrained -check_timing_verbose -max_paths 10 -input_pins -routable_nets -name timing_1
You can access to the Min Slack per placed BEL.

How to change the behavior of nodes (cars), rsu in Omnet++ Veins project

I have setup my environment using omnet++, sumo and veins in ubuntu. I want to reduce packet loss in an emergency situation among vehicles and improve packet delivery time and cost. My project is about choosing the suitable processing position among cluster head (nodes), road side unit (rsu) and cloud. I want to achieve certain tasks that is need to implement my veins project. I have configured 50 nodes and 4 rsu and provide data rate about 6mbps and assign the packet size upto 2MB.
Therefore, how can I change the behavior of vehicles (nodes), road side unit (rsu) and cloud in order to implement the following parameters?
processing rate of clusters (nodes) = 3 Mbps.
processing rate of RSUs = 7 Mbps.
processing rate of cloud = 10 Mbps.
the range of clusters (nodes) = 60 m.
the range of RSU = 120 m.
the range of cloud = 500 m.
If you could help with building these parameters I will appreciate it.
Thank you
If you are talking about transsmision rate, then you can set the bit rate in the ini file (check veins example) but if you meant processing delay then it is usually simulated by scheduling self messages (check tictoc example). In terms of transsmsion range, veins uses Free Space Propagation model and the related parameters are set in the ini file so you can change them to decide the required range. Finally, I recommand to read more about veins and how it deal with the parameters you asked about. There are alot of answered questions on StackOverFlow about your questions.

Calculate end-to-end delay of a network by using endToEndDelay:vector and endToEndDelay:histogram

How to calculate end-to-end delay of a network by using endToEndDelay:vector and endToEndDelay:histogram in omnet++?
Is there better another way?
Measure the endToEndDelay in each node, and (weighted) average the results for each node to get a single value. Or you can add the endToEndDelay:vector statistics to the network module itself. Signals emitted by the modules are bubbling up in the topology tree, so you can opt also to catch all the signals at network level.

XBee coordinator data package reception

Hi I'm creating a xbee network with 1 coordinator and 20 end nodes transmitting data 8 times per second. (Currently i just made one of them talk to the coordinator).
I would like to know how many data packages the coordinator will be able to receive as I'll be transmitting in a high data rate. (20 end index x 8 times per second its 160 data packages per second).
Is that feasible ? Will I face any problems ? What should I be worried with ? For that data rate is there any other protocol I could use?
Thanks
I would say that it isn't feasible. The radio data rate of 802.15.4 networks is 250kbps. Once you're sending that many data packets per second, you'll be getting collisions and retransmissions. It might work if the packets are very small, but you'll still have a lot of overhead for packet headers. If this is a mesh network, you'll be using bandwidth for packet retransmission when a node can't communicate directly with the coordinator.
Is there a reason you need that data frequency? Can the end devices aggregate their data and send a single packet once/second with 8 data samples? Zigbee and 802.15.4 were designed for low data rates and low power.
If you're going to try this out, you'll want to configure the coordinator for at least 230kbps to keep up with the data flow. Do a proof of concept with a single end device (and configure it as a router, since you don't need "sleeping" capability of end devices), and then consider testing with 5 devices sending 4 times as much data (32 packets/second) to see if the coordinator can even keep up with that data flow.

how to analyze different parameters between the two nodes in veins example of omnet++

in veins, the results obtained are collective of all nodes at all possible timings. is there any possible way to investigate and analyse the communication between the two nodes in the example of veins, while they are broadcasting the messages in case of an accident? like how to find packet loss between the two nodes, in the veins example of omnet++?
OMNeT++ supports two main types of data to be collected: scalars and vectors. By default, a vector is a collection of (module, statistic, event, time, value) tuples. A scalar records only (module, statistic, value) tuples, that is, it records statistics that are not associated with a particular time. In the OMNeT++ IDE, you can filter any one of these tuples before plotting, to include only certain modules, certain statistics, or (for vectors) those recorded at a particular time.

Resources