INET: How to check queue status

243 views
Skip to first unread message

SEDE

unread,
May 14, 2020, 1:30:29 AM5/14/20
to OMNeT++ Users

Hello Everyone,

I am a beginner in OMNET++, trying to work using INET frame work.

I want to keep track the current queue status in my MAC protocol i.e. the number of packets in the data queue.

I have seen the the .cc files in inet>>queueing>>buffer and inet>>queueing>>queue, could not figure it out.

Can anyone kindly suggest me,

1. which function/parameter is actually calculating the no. of packets in the queue?

2. how to add queue status in MAC layer ( for example in bmac.cc file)?


Many thanks.


Alfonso Ariza Quintana

unread,
May 14, 2020, 3:30:45 AM5/14/20
to omn...@googlegroups.com
And the queue, what type is the container, and STL container?

De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de SEDE <afroz...@gmail.com>
Enviado: jueves, 14 de mayo de 2020 7:30
Para: OMNeT++ Users <omn...@googlegroups.com>
Asunto: [Omnetpp-l] INET: How to check queue status
 
--
You received this message because you are subscribed to the Google Groups "OMNeT++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/omnetpp/141902ce-2783-4052-9265-5cfc215757dc%40googlegroups.com.

Levente Mészáros

unread,
May 14, 2020, 4:23:24 AM5/14/20
to OMNeT++ Discussion List
If you look at IPacketQueue.h in the contract folder then you will see that the class is derived from IPacketCollection. The latter happens to have a method called getNumPackets(). The class IPacketBuffer is meant to be used for shared buffers among multiple queues. The IPacketBuffer interface currently doesn't provide such a method but the actual implementation, called PacketBuffer, does.

Regards,
levy



Afroz Afroz

unread,
May 14, 2020, 5:46:37 AM5/14/20
to omn...@googlegroups.com
Hello Alfonso,

Sorry, I did not understand your question. I am beginner in omnet++. I am thinking of a queue like FIFO queue, where packets are stored and I need to keep track how many packets in the queue in my MAC protocol. Can you please explain a bit so I can understand?

Thank you

Afroz Afroz

unread,
May 14, 2020, 5:52:37 AM5/14/20
to omn...@googlegroups.com
Hello Ievy,

Thank you so much for your response. So, getNumPacket() actually can provide the number of packets in the queue. Is not it?

I have another question. Can you suggest how I can trace residual energy of the battery?

Many thanks





Ujjval Rathod

unread,
May 14, 2020, 5:56:16 AM5/14/20
to omn...@googlegroups.com
Hi,
Actually, I had similar question in my omnet simulation where I wanted to have a length/set a length of the queue. but it did not have any such function you can obviously check the lenth of the queue by getqueuelength(). I have no idea of how it is in INET.

Alfonso Ariza Quintana

unread,
May 14, 2020, 6:40:50 AM5/14/20
to omn...@googlegroups.com
It is not a question with omnet is a question of c++. You need to store the packets in a container, the container can be a STL container or an omnet++ containier. If the container is a stl, you can use the method size(), if the container  is an omnetpp container, you can use the method getNumPacket()

De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de Afroz Afroz <afroz...@gmail.com>
Enviado: jueves, 14 de mayo de 2020 11:46
Para: omn...@googlegroups.com <omn...@googlegroups.com>
Asunto: Re: [Omnetpp-l] INET: How to check queue status
 

SEDE

unread,
May 14, 2020, 7:12:04 AM5/14/20
to OMNeT++ Users
Hello Alfonso,

Thanks for the explanation, Sir. I am also new in C++.

If i use omnetpp container, can you please tell if the command "txQueue->getNumPacket" will work to get the number of packets in the queue?

Also, would you suggest in INET, which method is to check the residual energy of the battery?

Many thanks.


On Thursday, May 14, 2020 at 8:40:50 PM UTC+10, Alfonso Ariza Quintana wrote:
It is not a question with omnet is a question of c++. You need to store the packets in a container, the container can be a STL container or an omnet++ containier. If the container is a stl, you can use the method size(), if the container  is an omnetpp container, you can use the method getNumPacket()


Enviado: jueves, 14 de mayo de 2020 11:46
Para: omn...@googlegroups.com <omn...@googlegroups.com>
Asunto: Re: [Omnetpp-l] INET: How to check queue status
Hello Alfonso,

Sorry, I did not understand your question. I am beginner in omnet++. I am thinking of a queue like FIFO queue, where packets are stored and I need to keep track how many packets in the queue in my MAC protocol. Can you please explain a bit so I can understand?

Thank you

On Thu, May 14, 2020 at 5:30 PM Alfonso Ariza Quintana <aari...@hotmail.com> wrote:
And the queue, what type is the container, and STL container?


Enviado: jueves, 14 de mayo de 2020 7:30
Para: OMNeT++ Users <omn...@googlegroups.com>
Asunto: [Omnetpp-l] INET: How to check queue status

Hello Everyone,

I am a beginner in OMNET++, trying to work using INET frame work.

I want to keep track the current queue status in my MAC protocol i.e. the number of packets in the data queue.

I have seen the the .cc files in inet>>queueing>>buffer and inet>>queueing>>queue, could not figure it out.

Can anyone kindly suggest me,

1. which function/parameter is actually calculating the no. of packets in the queue?

2. how to add queue status in MAC layer ( for example in bmac.cc file)?


Many thanks.


--
You received this message because you are subscribed to the Google Groups "OMNeT++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to omn...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "OMNeT++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to omn...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "OMNeT++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to omn...@googlegroups.com.

Alfonso Ariza Quintana

unread,
May 14, 2020, 2:10:11 PM5/14/20
to omn...@googlegroups.com
You can search the energy storage

        cModule *en = host->getSubmodule("energyStorage");
        if (en != nullptr)
            energyStorage = check_and_cast<power::IEpEnergyStorage *>(host->getSubmodule("energyStorage"));

   J resEnergy;
   if (energyStorage)
          resEnergy = energyStorage->getResidualEnergyCapacity(); // return the energy in Jules

De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de SEDE <afroz...@gmail.com>
Enviado: jueves, 14 de mayo de 2020 13:12
Para: OMNeT++ Users <omn...@googlegroups.com>
To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/omnetpp/986312b6-fffd-4d64-98bc-2b1a8415e155%40googlegroups.com.

SEDE

unread,
May 14, 2020, 10:07:13 PM5/14/20
to OMNeT++ Users
Thanks a lot Sir! I will check.

Regards,



On Friday, May 15, 2020 at 4:10:11 AM UTC+10, Alfonso Ariza Quintana wrote:
You can search the energy storage

        cModule *en = host->getSubmodule("energyStorage");
        if (en != nullptr)
            energyStorage = check_and_cast<power::IEpEnergyStorage *>(host->getSubmodule("energyStorage"));

   J resEnergy;
   if (energyStorage)
          resEnergy = energyStorage->getResidualEnergyCapacity(); // return the energy in Jules

SEDE

unread,
May 16, 2020, 1:20:45 AM5/16/20
to OMNeT++ Users
Hello Alfonso,

Sir, in inet>>power, I have not found the exact code you suggested for tracking residual energy of the battery. May be i am missing something.

Can you please suggest me the file name?

Many thanks

On Friday, May 15, 2020 at 4:10:11 AM UTC+10, Alfonso Ariza Quintana wrote:
You can search the energy storage

        cModule *en = host->getSubmodule("energyStorage");
        if (en != nullptr)
            energyStorage = check_and_cast<power::IEpEnergyStorage *>(host->getSubmodule("energyStorage"));

   J resEnergy;
   if (energyStorage)
          resEnergy = energyStorage->getResidualEnergyCapacity(); // return the energy in Jules

Alfonso Ariza Quintana

unread,
May 17, 2020, 5:01:57 AM5/17/20
to omn...@googlegroups.com
First at all the version of inet, inet 3.x and 4.x are quite different, and the exact code, I don't uderstand what do you want to express, I only indicate a solution to extract the residual energy in inet 4.x

De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de SEDE <afroz...@gmail.com>
Enviado: sábado, 16 de mayo de 2020 7:20
To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/omnetpp/d323fde3-19f1-408e-aafa-b9b82edec43c%40googlegroups.com.

SEDE

unread,
May 18, 2020, 8:56:05 AM5/18/20
to OMNeT++ Users

Thanks for the clarification, Sir.

Kind Regards,

On Sunday, May 17, 2020 at 7:01:57 PM UTC+10, Alfonso Ariza Quintana wrote:
First at all the version of inet, inet 3.x and 4.x are quite different, and the exact code, I don't uderstand what do you want to express, I only indicate a solution to extract the residual energy in inet 4.x

SEDE

unread,
May 20, 2020, 11:36:43 AM5/20/20
to OMNeT++ Users
Hello Alfonso,

Sir, would you kindly suggest me the following two information?

1. Is there any method/parameter in xmac (for example) to estimate energy consumption per packet?

2. How to set the data length in bits or data duration in second in xmac?

Looking forward to hearing from you, Sir.

Regards,

On Friday, May 15, 2020 at 4:10:11 AM UTC+10, Alfonso Ariza Quintana wrote:
You can search the energy storage

        cModule *en = host->getSubmodule("energyStorage");
        if (en != nullptr)
            energyStorage = check_and_cast<power::IEpEnergyStorage *>(host->getSubmodule("energyStorage"));

   J resEnergy;
   if (energyStorage)
          resEnergy = energyStorage->getResidualEnergyCapacity(); // return the energy in Jules

Alfonso Ariza Quintana

unread,
May 20, 2020, 6:06:53 PM5/20/20
to omn...@googlegroups.com

 

It is a bit complex to compute the energy per packet because the radio is consuming even if the radio doesn’t transmit or receive, if the radio is listening the medium the radio consumes. Two different experiments can have different consumption per packet, in function of the traffic. The consumption is a function of the percentage of time that the radio is active.

 

Yes and no, you can set the length of the application packets, the total length of the xmac packets will be the length of the application packets plus the overhead introduce by the headers of the other protocols, if the only protocol is the xmac the length is the length of the application packet plus the header of the xmac protocol. If you use UDP, length application + UDP header + ip header+ xmac header…

 

 

Enviado desde Correo para Windows 10

 


De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de SEDE <afroz...@gmail.com>
Enviado: Wednesday, May 20, 2020 5:36:42 PM
To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/omnetpp/a28fa709-3cc0-45a3-95cb-877101b6093c%40googlegroups.com.

Alfonso Ariza Quintana

unread,
May 21, 2020, 3:07:03 AM5/21/20
to omn...@googlegroups.com

It is a bit complex to compute the energy per packet, because the radio is consuming even if the radio doesn’t transmit or receive, if the radio is listening the medium, the radio consumes. The comsuption is not a function of the packets is a function of the time that the radio has been active.


You can control the application size, the link layer size will be the application packet size plus the overhead of the other protocols (UDP+IP+Lik layer)



 

Enviado desde Correo para Windows 10

 

De: SEDE
Enviado: miércoles, 20 de mayo de 2020 17:36
Para:
OMNeT++ Users
Asunto: Re: [Omnetpp-l] INET: How to check queue status

 

 

Sir, would you kindly suggest me the following two information?

 

1. Is there any method/parameter in xmac (for example) to estimate energy consumption per packet?

 

2. How to set the data length in bits or data duration in second in xmac?

 

Looking forward to hearing from you, Sir.

 

Regards,


On Friday, May 15, 2020 at 4:10:11 AM UTC+10, Alfonso Ariza Quintana wrote:

You can search the energy storage

 

        cModule *en = host->getSubmodule("energyStorage");

        if (en != nullptr)

            energyStorage = check_and_cast<power::IEpEnergyStorage *>(host->getSubmodule("energyStorage"));

 

   J resEnergy;

   if (energyStorage)

          resEnergy = energyStorage->getResidualEnergyCapacity(); // return the energy in Jules

De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de SEDE <afro...@gmail.com>
Enviado: jueves, 14 de mayo de 2020 13:12
Para: OMNeT++ Users <
omn...@googlegroups.com>
Asunto: Re: [Omnetpp-l] INET: How to check queue status

 

Hello Alfonso,

 

Thanks for the explanation, Sir. I am also new in C++.

 

If i use omnetpp container, can you please tell if the command "txQueue->getNumPacket" will work to get the number of packets in the queue?

 

Also, would you suggest in INET, which method is to check the residual energy of the battery?

 

Many thanks.

 


On Thursday, May 14, 2020 at 8:40:50 PM UTC+10, Alfonso Ariza Quintana wrote:

It is not a question with omnet is a question of c++. You need to store the packets in a container, the container can be a STL container or an omnet++ containier. If the container is a stl, you can use the method size(), if the container  is an omnetpp container, you can use the method getNumPacket()

De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de Afroz Afroz <afro...@gmail.com>
Enviado: jueves, 14 de mayo de 2020 11:46
Para: omn...@googlegroups.com <omn...@googlegroups.com>
Asunto: Re: [Omnetpp-l] INET: How to check queue status

 

Hello Alfonso,

 

Sorry, I did not understand your question. I am beginner in omnet++. I am thinking of a queue like FIFO queue, where packets are stored and I need to keep track how many packets in the queue in my MAC protocol. Can you please explain a bit so I can understand?

 

Thank you

 

On Thu, May 14, 2020 at 5:30 PM Alfonso Ariza Quintana <aari...@hotmail.com> wrote:

And the queue, what type is the container, and STL container?

To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+u...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/omnetpp/a28fa709-3cc0-45a3-95cb-877101b6093c%40googlegroups.com.

 

SEDE

unread,
May 21, 2020, 4:28:57 AM5/21/20
to OMNeT++ Users
Hello Alfonso,

Many thanks for you reply Sir. Your replies are really helpful.

- Would you kindly suggest me the following?

- Where to change/set application data size in bits? Which parameter/method it is?
I have checked UdpBasicApp.cc where i can see a parameter 'payload', but could not figure out how i can set data length for example as 32 bits.

Also regarding MAC header, in ini file, i can see these lines

**.radio.transmitter.headerLength = 8b  as well as **.wlan[*].mac.headerLength = 24B [under xmac configuration]

I think mac header is the second one in B. But i did not understand what is the difference between these two headerlength.

- How I can set ACK duration and power to receive?
I can see transmitter power can be set from ini file, but there is no parameter for power to receive and ACK duration in bits or second.

I want find the expected energy consumption to transmit a packet.


Many thanks for your explanations.

Kind Regards,

To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+unsubscribe@googlegroups.com.


To view this discussion on the web visit

Afroz Afroz

unread,
May 22, 2020, 7:23:28 AM5/22/20
to omn...@googlegroups.com
Hello Alfonso,

Sir, would you please suggest me?

Regards,


To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+u...@googlegroups.com.


To view this discussion on the web visit

You received this message because you are subscribed to the Google Groups "OMNeT++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/omnetpp/ee8a101e-661f-40b3-a4cc-d6e4a1d1c717%40googlegroups.com.

Alfonso Ariza Quintana

unread,
May 22, 2020, 7:38:19 AM5/22/20
to omn...@googlegroups.com
You can set he lenght in bit or bytes if you want

**.app[0].messageLength = 100b

**.app[0].messageLength = 100B

But you use UDP/IP, you will include also the UDP header and ip header (8B and 20B = 28B of overhead).


De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de Afroz Afroz <afroz...@gmail.com>
Enviado: viernes, 22 de mayo de 2020 13:22

SEDE

unread,
May 25, 2020, 7:43:32 PM5/25/20
to omn...@googlegroups.com
Hello Alfonso,

Thank you Sir. Actually, I wanted to set the data size in MAC layer. Can you please tell me which fragmentation policy is being used for XMAC (with sensornetwork examples)? I found a parameter fragmentationthreshold, but did not get much information on it in the manual.

Kind Regards,


On Friday, May 22, 2020 at 9:38:19 PM UTC+10, Alfonso Ariza Quintana wrote:
You can set he lenght in bit or bytes if you want

**.app[0].messageLength = 100b

**.app[0].messageLength = 100B

But you use UDP/IP, you will include also the UDP header and ip header (8B and 20B = 28B of overhead).



Enviado: viernes, 22 de mayo de 2020 13:22
Para: omn...@googlegroups.com <omn...@googlegroups.com>
Asunto: Re: [Omnetpp-l] INET: How to check queue status
Hello Alfonso,

Sir, would you please suggest me?

Regards,


To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+unsubscribe@googlegroups.com.


To view this discussion on the web visit

--
You received this message because you are subscribed to the Google Groups "OMNeT++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to omn...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "OMNeT++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to omn...@googlegroups.com.

Alfonso Ariza Quintana

unread,
May 26, 2020, 5:06:01 AM5/26/20
to omn...@googlegroups.com
I don't know, but I think that xmax doesn't implement fragmentation, the fragmentation for xmac is in the ip layer.

De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de SEDE <afroz...@gmail.com>
Enviado: martes, 26 de mayo de 2020 1:43

Para: OMNeT++ Users <omn...@googlegroups.com>
Asunto: Re: [Omnetpp-l] INET: How to check queue status
 
Hello Alfonso,

Thank you Sir. Actually, I wanted to set the data size in MAC layer. Can you please tell me which fragmentation policy is being used for XMAC in INET? I found a parameter fragmentationthreshold, but did not get much information on it in the manual.
To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/omnetpp/8f09f468-9009-44bd-9048-e0c8a453f687%40googlegroups.com.

SEDE

unread,
May 26, 2020, 8:08:10 PM5/26/20
to omn...@googlegroups.com
Hello Alfonso,

Sir, can you tell me in which file i can see the code for the fragmentation for xmac in IP level? I can see GlobalArp is being used for sensornetwork, but in that .cc file, no fragmentation code is given.

So, without fragmentation data size in MAC layer = application data + the header in UDP + the header in IP, is that correct?

Many thanks for your answers.


On Tuesday, May 26, 2020 at 7:06:01 PM UTC+10, Alfonso Ariza Quintana wrote:
I don't know, but I think that xmax doesn't implement fragmentation, the fragmentation for xmac is in the ip layer.

Alfonso Ariza Quintana

unread,
May 27, 2020, 4:46:55 AM5/27/20
to omn...@googlegroups.com

The fragmentation in the ip module is in ipv4.cc


De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de SEDE <afroz...@gmail.com>
Enviado: miércoles, 27 de mayo de 2020 2:08

Para: OMNeT++ Users <omn...@googlegroups.com>
Asunto: Re: [Omnetpp-l] INET: How to check queue status
 
Hello Alfonso,

Sir, can you tell me in which file i can see the code for the fragmentation for xmac in IP level? I can see in GlobalArp is being used for sensornetwork, but in that .cc file, no fragmentation code is given.
To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/omnetpp/2a07f467-0d24-4eb2-9575-80774fc0b070%40googlegroups.com.

SEDE

unread,
Jun 2, 2020, 7:20:11 AM6/2/20
to OMNeT++ Users
Hello Sir,

How I can check the time interval after which the number of packets in the queue is updated?

Where packet arrival rate is defined?

At the beginning and at the end of a time slot I want to check the number of packets in the queue. Can you kindly suggest?

Kind Regards,


On Thursday, May 14, 2020 at 8:40:50 PM UTC+10, Alfonso Ariza Quintana wrote:
It is not a question with omnet is a question of c++. You need to store the packets in a container, the container can be a STL container or an omnet++ containier. If the container is a stl, you can use the method size(), if the container  is an omnetpp container, you can use the method getNumPacket()


Enviado: jueves, 14 de mayo de 2020 11:46
Para: omn...@googlegroups.com <omn...@googlegroups.com>
Asunto: Re: [Omnetpp-l] INET: How to check queue status
Hello Alfonso,

Sorry, I did not understand your question. I am beginner in omnet++. I am thinking of a queue like FIFO queue, where packets are stored and I need to keep track how many packets in the queue in my MAC protocol. Can you please explain a bit so I can understand?

Thank you

On Thu, May 14, 2020 at 5:30 PM Alfonso Ariza Quintana <aari...@hotmail.com> wrote:
And the queue, what type is the container, and STL container?


Enviado: jueves, 14 de mayo de 2020 7:30
Para: OMNeT++ Users <omn...@googlegroups.com>
Asunto: [Omnetpp-l] INET: How to check queue status

Hello Everyone,

I am a beginner in OMNET++, trying to work using INET frame work.

I want to keep track the current queue status in my MAC protocol i.e. the number of packets in the data queue.

I have seen the the .cc files in inet>>queueing>>buffer and inet>>queueing>>queue, could not figure it out.

Can anyone kindly suggest me,

1. which function/parameter is actually calculating the no. of packets in the queue?

2. how to add queue status in MAC layer ( for example in bmac.cc file)?


Many thanks.


--
You received this message because you are subscribed to the Google Groups "OMNeT++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to omn...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "OMNeT++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to omn...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "OMNeT++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to omn...@googlegroups.com.

Alfonso Ariza Quintana

unread,
Jun 2, 2020, 11:08:48 AM6/2/20
to OMNeT++ Users
The packet generator is the source, you set the packet arrival in the source.
If you want to record the number of packets in the queue, I don't know if the statistic is generated, but it is quite easy to include the statistic, in this case, if you want record the evolution in the time, you can use a vector statistic, in the manual you can find how to use it,

De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de SEDE <afroz...@gmail.com>
Enviado: martes, 2 de junio de 2020 13:20
Para: OMNeT++ Users <omn...@googlegroups.com>
To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/omnetpp/4b034c58-15c4-4986-ad15-1a1311280c07%40googlegroups.com.

SEDE

unread,
Jun 2, 2020, 8:19:49 PM6/2/20
to OMNeT++ Users
Sorry Sir, can you kindly tell me the file name for packet generation and setting packet arrival time?  I still could not figure out which file it is. Thank you


On Wednesday, June 3, 2020 at 1:08:48 AM UTC+10, Alfonso Ariza Quintana wrote:
The packet generator is the source, you set the packet arrival in the source.
If you want to record the number of packets in the queue, I don't know if the statistic is generated, but it is quite easy to include the statistic, in this case, if you want record the evolution in the time, you can use a vector statistic, in the manual you can find how to use it,

Alfonso Ariza Quintana

unread,
Jun 3, 2020, 3:49:00 AM6/3/20
to OMNeT++ Users
There are several sources, without more information I don't know, the most probably is a udp source applications/udpapp

For udp sources the interarrival packet parameter is  "sendInterval"

De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de SEDE <afroz...@gmail.com>
Enviado: miércoles, 3 de junio de 2020 2:19
To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/omnetpp/5d0156d8-fae8-4be5-a831-5661dc8a7851%40googlegroups.com.

SEDE

unread,
Jun 11, 2020, 6:27:31 AM6/11/20
to omn...@googlegroups.com

Hello Alfonso,

Sir, for udp source, did you mean sendInterval is the packet arrival rate to each node?

In ini file, sendInterval is set as 1s and in INET documentation, it  is defined as each sensor node will send an UDP packet with a 10-byte payload every second to the server.

I need to know packet arrival rate to each node ie. how many packets arrive per second to each node that they queue before transmitting them to the receiver. Thank you.

 app
*.sensor*.numApps = 1
*.sensor*.app[0].typename = "UdpBasicApp"
*.sensor*.app[0].destAddresses = "server"
*.sensor*.app[0].destPort = 1000
*.sensor*.app[0].sendInterval = 1s
*.sensor*.app[0].startTime = exponential(1s)
*.sensor*.app[0].messageLength = 10Byte

On Wednesday, June 3, 2020 at 5:49:00 PM UTC+10, Alfonso Ariza Quintana wrote:
There are several sources, without more information I don't know, the most probably is a udp source applications/udpapp

For udp sources the interarrival packet parameter is  "sendInterval"

Alfonso Ariza Quintana

unread,
Jun 11, 2020, 9:32:12 AM6/11/20
to OMNeT++ Users
The packet is a lot of bigger,
10+8+20 + mac header = 38+mac header.

The arrival rate to the source is 1 packet per second.
Numer of packets per second = 1/inter arrival time

De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de SEDE <afroz...@gmail.com>
Enviado: jueves, 11 de junio de 2020 12:27

Para: OMNeT++ Users <omn...@googlegroups.com>
Asunto: Re: [Omnetpp-l] INET: How to check queue status
 

Hello Alfonso,

Sir, for udp source, did you mean sendInterval is the packet interval rate to each node?
To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/omnetpp/1882b237-53e0-4879-9d2d-d67eb3da3f4do%40googlegroups.com.

SEDE

unread,
Jun 14, 2020, 12:59:12 AM6/14/20
to OMNeT++ Users

Hello Alfonso,

Sir, did you mean sendInterval = 1s means the packet arrival rate at the sender node is 1 packet per second?

I am very confused because as per INET web, sendInterval =1s means the following

"Each sensor node will send an UDP packet with a 10-byte payload (“temperature data”) every second to the server"


Can you kindly clarify me Sir? I need to know packet arrival rate at sender node, not at the server.

Thank you for all your answers Sir.




On Thursday, June 11, 2020 at 11:32:12 PM UTC+10, Alfonso Ariza Quintana wrote:
The packet is a lot of bigger,
10+8+20 + mac header = 38+mac header.

The arrival rate to the source is 1 packet per second.
Numer of packets per second = 1/inter arrival time

Alfonso Ariza Quintana

unread,
Jun 14, 2020, 5:48:18 AM6/14/20
to omn...@googlegroups.com

 

sendInterval is the time between two consecutives packets.

 

Number of packets per second = 1 / sendInterval.

Number of packets per second = 1/1s = 1 pk/s

 

Enviado desde Correo para Windows 10

 

De: SEDE
Enviado: domingo, 14 de junio de 2020 6:59
Para: OMNeT++ Users
Asunto: Re: [Omnetpp-l] INET: How to check queue status

 

 

Hello Alfonso,

 

Sir, did you mean sendInterval = 1s means the packet arrival rate at the sender node is 1 packet per second?

 

I am very confused because as per INET web, sendInterval =1s means the following

 

"Each sensor node will send an UDP packet with a 10-byte payload (“temperature data”) every second to the server"

 

 

Can you kindly clarify me Sir? I need to know packet arrival rate at sender node, not at the server.

 

Thank you for all your answers Sir.

 

 

 

 

On Thursday, June 11, 2020 at 11:32:12 PM UTC+10, Alfonso Ariza Quintana wrote:

The packet is a lot of bigger,

10+8+20 + mac header = 38+mac header.

 

The arrival rate to the source is 1 packet per second.

Numer of packets per second = 1/inter arrival time

De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de SEDE <afro...@gmail.com>
Enviado: jueves, 11 de junio de 2020 12:27
Para: OMNeT++ Users <omn...@googlegroups.com>
Asunto: Re: [Omnetpp-l] INET: How to check queue status

 

 

Hello Alfonso,

 

Sir, for udp source, did you mean sendInterval is the packet interval rate to each node?

 

In ini file, sendInterval is set as 1s and in INET documentation, it  is defined as each sensor node will send an UDP packet with a 10-byte payload every second to the server.

 

I need to know packet arrival rate to each node ie. how many packets arrive per second to each node that they queue before transmitting them to the receiver. Thank you.

 

 app
*.sensor*.numApps = 1
*.sensor*.app[0].typename = "UdpBasicApp"
*.sensor*.app[0].destAddresses = "server"
*.sensor*.app[0].destPort = 1000
*.sensor*.app[0].sendInterval = 1s

*.sensor*.app[0].startTime = exponential(1s)
*.sensor*.app[0].messageLength = 10Byte


On Wednesday, June 3, 2020 at 5:49:00 PM UTC+10, Alfonso Ariza Quintana wrote:

There are several sources, without more information I don't know, the most probably is a udp source applications/udpapp

 

For udp sources the interarrival packet parameter is  "sendInterval"

De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de SEDE <afro...@gmail.com>
Enviado: miércoles, 3 de junio de 2020 2:19
Para: OMNeT++ Users <omn...@googlegroups.com>
Asunto: Re: [Omnetpp-l] INET: How to check queue status

 

Sorry Sir, can you kindly tell me the file name for packet generation and setting packet arrival time?  I still could not figure out which file it is. Thank you

On Wednesday, June 3, 2020 at 1:08:48 AM UTC+10, Alfonso Ariza Quintana wrote:

The packet generator is the source, you set the packet arrival in the source.

If you want to record the number of packets in the queue, I don't know if the statistic is generated, but it is quite easy to include the statistic, in this case, if you want record the evolution in the time, you can use a vector statistic, in the manual you can find how to use it,

De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de SEDE <afro...@gmail.com>
Enviado: martes, 2 de junio de 2020 13:20
Para: OMNeT++ Users <omn...@googlegroups.com>
Asunto: Re: [Omnetpp-l] INET: How to check queue status

 

Hello Sir,

 

How I can check the time interval after which the number of packets in the queue is updated?

 

Where packet arrival rate is defined?

 

At the beginning and at the end of a time slot I want to check the number of packets in the queue. Can you kindly suggest?

 

Kind Regards,

 


On Thursday, May 14, 2020 at 8:40:50 PM UTC+10, Alfonso Ariza Quintana wrote:

It is not a question with omnet is a question of c++. You need to store the packets in a container, the container can be a STL container or an omnet++ containier. If the container is a stl, you can use the method size(), if the container  is an omnetpp container, you can use the method getNumPacket()

De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de Afroz Afroz <afro...@gmail.com>
Enviado: jueves, 14 de mayo de 2020 11:46
Para: omn...@googlegroups.com <omn...@googlegroups.com>
Asunto: Re: [Omnetpp-l] INET: How to check queue status

 

Hello Alfonso,

 

Sorry, I did not understand your question. I am beginner in omnet++. I am thinking of a queue like FIFO queue, where packets are stored and I need to keep track how many packets in the queue in my MAC protocol. Can you please explain a bit so I can understand?

 

Thank you

 

On Thu, May 14, 2020 at 5:30 PM Alfonso Ariza Quintana <aari...@hotmail.com> wrote:

And the queue, what type is the container, and STL container?

To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/omnetpp/bf2484ee-3491-4267-9d68-a9d99cfe9660o%40googlegroups.com.

 

SEDE

unread,
Jun 14, 2020, 7:03:44 AM6/14/20
to OMNeT++ Users
Hello Alfonso,

Sir, so packet arrival rate at the sender node is 1 packet/s?

Thank you

SEDE

unread,
Jun 14, 2020, 11:47:28 PM6/14/20
to OMNeT++ Users
Hello Alfonso,

Sir, sorry for asking you again.

I changed to value of sendInterval parameter value (for example 0.5s i.e. 2 packets per second) to see the effect. In that case the number of packets at the server increases.

In my knowledge, send interval should be shorter than the traffic collection interval of the sender node to overcome overflow.

So, did you mean with sendInderval =1s, the data arrival rate/ data collection interval at the source sensor node is 1 packet per second?

Thank you Sir.

Alfonso Ariza Quintana

unread,
Jun 15, 2020, 6:43:40 AM6/15/20
to OMNeT++ Users

No necessarily, you need to consider also the network bit rate, loses ... . the arrival rate to the destination can be lower than the sending, if the offered traffic to the network is bigger than the network capacity, the packets will be stored in the queues and some packets will be loss.



De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de SEDE <afroz...@gmail.com>
Enviado: lunes, 15 de junio de 2020 5:47
To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/omnetpp/336c8595-6af0-4fe7-be84-6b8fbf7bd0c6o%40googlegroups.com.

SEDE

unread,
Jun 15, 2020, 6:57:25 AM6/15/20
to OMNeT++ Users
Hello Alfonso,

So the arrival rate at the sender node is 1 packet/sec with sendInterval 1s?

In INET, is there any other parameter from where i can know data collection interval of a sensor node? Or, data collection interval is also 1 packet/s?

Thank you

On Monday, June 15, 2020 at 8:43:40 PM UTC+10, Alfonso Ariza Quintana wrote:

No necessarily, you need to consider also the network bit rate, loses ... . the arrival rate to the destination can be lower than the sending, if the offered traffic to the network is bigger than the network capacity, the packets will be stored in the queues and some packets will be loss.



Alfonso Ariza Quintana

unread,
Jun 15, 2020, 7:17:58 AM6/15/20
to omn...@googlegroups.com
If you have several nodes that send data to the sink, the arrival will be bigger.
If is only a node, the arrival, probably will be smaller, some packets could be lossed.

and the arrival will have a jitter

De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de SEDE <afroz...@gmail.com>
Enviado: lunes, 15 de junio de 2020 12:57
To unsubscribe from this group and stop receiving emails from it, send an email to omnetpp+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/omnetpp/f5afaa65-cbc3-4ac6-ab8a-9ba87e86b22co%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages