Summation equals zero when computing signal duration in UnitDiskTrasmitter.cc

23 views
Skip to first unread message

Adán G. Medrano-Chávez

unread,
Mar 10, 2020, 2:14:33 AM3/10/20
to OMNeT++ Users
Hi!

I'm asking for some help with the following problem. I'm trying to send a custom hello packet that extends FieldsChunk. However, I get this exception when running my simulation model:

<!> ASSERT: Condition 'signal->getDuration() != 0' does not hold in function 'createSignal' at inet/physicallayer/common/packetlevel/Radio.cc:409 -- in module (inet::physicallayer::UnitDiskRadio)

To find the reason of this exception message I print the output of the computation of the signal duration in UnitDiskTrasmitter.cc and I get this information:

UnitDiskTransmitter, communicationRange = 250 m
UnitDiskTransmitter: phyheader size is inet::UnitDiskPhyHeader, length = 12 B
UnitDiskTransmitter: data length 123 B
UnitDiskTransmitter:
    header duration 4.8e-05
    data duration 0.000492
    preamble duration 0
    duration 0
RadioMedium: signal duration is 0

I think it's very strange the operation:

auto duration = preambleDuration + headerDuration + dataDuration;

equals zero with my custom package despite the headerDuration and dataDuration are different from zero. The same computation with INET packages, e.g., AODV's rreq, gives a correct duration value:

UnitDiskTransmitter, communicationRange = 250 m
UnitDiskTransmitter: phyheader size is inet::UnitDiskPhyHeader, length = 12 B
UnitDiskTransmitter: data length 75 B
UnitDiskTransmitter:
    header duration 4.8e-05
    data duration 0.0003
    preamble duration 0
    duration 0.000348
RadioMedium: signal duration is 0.000348

I'm using the same settings of the of the AODV example to tune the wlan interface
# channel physical parameters
**.wlan[*].typename = "AckingWirelessInterface"
**.wlan[*].bitrate = 2Mbps
**.wlan[*].mac.headerLength = 23B
**.wlan[*].radio.typename = "UnitDiskRadio"
**.wlan[*].radio.transmitter.headerLength = 96b
**.wlan[*].radio.transmitter.communicationRange = 250m
**.wlan[*].radio.transmitter.interferenceRange = 0m
**.wlan[*].radio.transmitter.detectionRange = 0m
**.wlan[*].radio.receiver.ignoreInterference = true

The version of OMNeT++ is 5.6.1 and the version of INET is inet-4.2.0-cb6c37b3dc

Best regards!

Alfonso Ariza Quintana

unread,
Mar 10, 2020, 7:13:11 AM3/10/20
to omn...@googlegroups.com
I am using Unidisk and 802.11 unidisk without a problem,

**.wlan[*].radio.transmitter.interferenceRange = 0m
**.wlan[*].radio.transmitter.detectionRange = 0m

Should be at least the same as the transmission range.

De: omn...@googlegroups.com <omn...@googlegroups.com> en nombre de Adán G. Medrano-Chávez <ryu...@gmail.com>
Enviado: martes, 10 de marzo de 2020 7:14
Para: OMNeT++ Users <omn...@googlegroups.com>
Asunto: [Omnetpp-l] Summation equals zero when computing signal duration in UnitDiskTrasmitter.cc
 
--
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/a54680b2-0e6c-4311-840d-02567568de38%40googlegroups.com.

Adán G. Medrano-Chávez

unread,
Mar 10, 2020, 8:56:32 PM3/10/20
to OMNeT++ Users
Hi!

I solved the problem: the simtime-resolution configuration value was set to 1s and, obviously, the transmission time of a packet lasts less than such time.

Best regards!
To unsubscribe from this group and stop receiving emails from it, send an email to omn...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages