Reputation: 510
After configuring the simulation environment in Veins 5.0
, different nodes send and receive messages at the same time. However, the following log is output only for specific messages.
Packet has bit Errors. Lost
Packet was not received correctly, sending it as control message to upper layer
After browsing various information, I modified the omnetpp.ini
code as follows, but the same transmission loss log is output.
omnetpp.ini
*.**.nic.phy80211p.allowTxDuringRx = true
*.**.nic.mac1609_4.txPower = 20mW
*.**.nic.mac1609_4.bitrate = 27Mbps
*.**.nic.phy80211p.minPowerLevel = -110dBm
*.connectionManager.maxInterfDist = 2600m
...
In addition, each node sends messages based on specific intervals. Does this error occur if the transmission times overlap? Some of the code implemented in the node is as follows:
A.h
...
const simtime_t TIME_MSG_INTERVAL = 1.0;
A.cc
...
BaseFrame1609_4* wsm = new BaseFrame1609_4();
wsm -> encapsulate(msg);
populateWSM(wsm);
sendDelayedDown(wsm, uniform(0.01, 0.50));
B.h
...
const simtime_t TIME_SYNC_INTERVAL = 1.0;
B.cc
...
BaseFrame1609_4* wsm = new BaseFrame1609_4();
wsm -> encapsulate(syncMsg);
populateWSM(wsm);
sendDelayedDown(wsm, uniform(0.01, 0.50));
I have read that packet collisions or simultaneous transmission and reception are not possible. But is there any way to ignore this?
Or should I increase TxPower
? I don't know the cause.
Upvotes: 0
Views: 235
Reputation: 6943
What you are describing are collisions: if a node receives two wireless transmissions at the same time, it has difficulties understanding either transmission. (Imagine two people speaking to you at the same time: in this situation you would also have a harder time understanding what is being said).
Normally, 802.11 tries to avoid this situation (this is the whole point of CSMA/CA, backoffs, ...), but there are cases where the mechanisms fail:
A rather well-known case is a "hidden terminal" situation, where a sender is not aware of the presence of another sender (e.g., the other sender is hidden behind a building).
Another, less well known case, is that where both senders start transmitting at the exact same time: Both senders will see that nobody else is transmitting, will change from receive to transmit mode, and will start sending (completely unaware that another sender is doing exactly this at exactly the same time). In practice, this situation is rather uncommon (after all, the two senders would need to start sending at very precisely the same time). Unfortunately, it is rather easy to do this by mistake in simulations: just configure two nodes to transmit at t=42s and they will both be trying to transmit at exactly t=42s.
Upvotes: 2