workaround for impossible multiple udp client on same node

This commit is contained in:
Tim Schubert 2020-06-21 18:40:31 +02:00
parent d898890fa6
commit 76c314130e
3 changed files with 22 additions and 14 deletions

View file

@ -118,6 +118,7 @@ bool MockChannel::Deliver (
Ptr<MockNetDevice> dst,
Time txTime)
{
NS_LOG_FUNCTION (this << p << src->GetAddress () << dst->GetAddress () << txTime);
Time delay = GetDelay (src, dst, txTime);
/* Check if there is LOS between the source and destination */
@ -149,7 +150,7 @@ MockChannel::TransmitStart (
Address destAddr,
Time txTime)
{
NS_LOG_FUNCTION (destAddr << this << p << srcId);
NS_LOG_FUNCTION (this << p << srcId << destAddr << txTime);
NS_LOG_LOGIC ("UID is " << p->GetUid () << ")");
Ptr<MockNetDevice> src = m_link[srcId];

View file

@ -370,7 +370,10 @@ MockNetDevice::SetReceiveErrorModel (Ptr<ErrorModel> em)
void
MockNetDevice::Receive (Ptr<Packet> packet, Ptr<MockNetDevice> senderDevice)
{
NS_LOG_FUNCTION (this << packet);
NS_LOG_FUNCTION (this << packet << senderDevice);
NS_LOG_DEBUG (GetAddress () << " receiving packet from " << senderDevice->GetAddress ());
uint16_t protocol = 0;
if (m_receiveErrorModel && m_receiveErrorModel->IsCorrupt (packet) )