Skip to content
This repository was archived by the owner on Feb 20, 2024. It is now read-only.

Commit 23c0936

Browse files
wischhofgiovanninardini
authored andcommitted
simulation cars: ini file corrected, workaround for using HostAutoConfigurator of inet 4.2.2.
Includes workaround for two issues when using the HostAutoConfigurator: * HostAutoConfigurator in inet 4.2.2 adds interface data in stage INITSTAGE_NETWORK_INTERFACE_CONFIGURATION, but cellular LteNic interface is created in same stage by the inet framework. In the long term, it might make sense to use INITSTAGE_NETWORK_CONFIGURATION for adding interface data in HostAutoConfigurator. Until this is done, the LteNic must get to stage INITSTAGE_NETWORK_INTERFACE_CONFIGURATION before the HostAutoConfigurator, therefore the structure of Node Ue was updated to list the LteNic before the ip layer. * Furthermore, the HostAutoConfigurator calls setBroadcast(true) in setupNetworkLayer at INITSTAGE_NETWORK_CONFIGURATION == 4. For LteNic, which does not support broadcast, this needs to be corrected - othewise the node will try to send ARP requests. As a workaround, the IP2lte now calls setBroadcast(false) in INITSTAGE_STATIC_ROUTING. Fingerprints had to be updated due to the modified order of initialization in Ue.
1 parent 316c2d4 commit 23c0936

File tree

8 files changed

+55
-49
lines changed

8 files changed

+55
-49
lines changed

simulations/cars/demo.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<config>
2-
<!-- Assign to the wlan interface of all eNodeBs and UEs one address of type 10.x.x.x, since dynamic-created UEs will be assigned one such address -->
3-
<interface hosts="eNodeB*" names="wlan" address="10.x.x.x" netmask="255.0.0.0"/>
4-
<interface hosts="ue*" names="wlan" address="10.x.x.x" netmask="255.0.0.0"/>
2+
<!-- Assign to the cellular interface of all eNodeBs and UEs one address of type 10.x.x.x, since dynamic-created UEs will be assigned one such address -->
3+
<interface hosts="eNodeB*" names="cellular" address="10.x.x.x" netmask="255.0.0.0"/>
4+
<interface hosts="ue*" names="cellular" address="10.x.x.x" netmask="255.0.0.0"/>
55

66
<!-- Assign 192.168.x.x addresses to all other interfaces -->
77
<interface hosts="*" address="192.168.x.x" netmask="255.255.255.0"/>

simulations/cars/omnetpp.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@ sim-time-limit = 70s
201201
*.car[1..9].app[*].localPort = 1000
202202

203203
# enrolled multicast groups must be set in the HostAutoConfigurator (instead of demo.xml), seperated by a single space character
204-
*.car[*].configurator.mcastGroups = "224.0.0.10"
204+
*.car[*].ipv4.configurator.mcastGroups = "224.0.0.10"
205205

206206

207207

src/corenetwork/lteip/IP2lte.cc

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ void IP2lte::initialize(int stage)
7777
else if (stage == inet::INITSTAGE_STATIC_ROUTING) {
7878
if (nodeType_ == UE) {
7979
// TODO: shift to routing stage
80-
// if the UE has been created dynamically, we need to manually add a default route having "wlan" as output interface
80+
// if the UE has been created dynamically, we need to manually add a default route having "cellular" as output interface
8181
// otherwise we are not able to reach devices outside the cellular network
8282
if (NOW > 0) {
8383
/**
@@ -94,6 +94,12 @@ void IP2lte::initialize(int stage)
9494
defaultRoute->setInterface(interfaceEntry);
9595

9696
irt->addRoute(defaultRoute);
97+
98+
// workaround for nodes using the HostAutoConfigurator:
99+
// Since the HostAutoConfigurator calls setBroadcast(true) for all
100+
// interfaces in setupNetworking called in INITSTAGE_NETWORK_CONFIGURATION
101+
// we must reset it to false since LteNic does not support broadcasts
102+
interfaceEntry->setBroadcast(false);
97103
}
98104
}
99105
} else if (stage == inet::INITSTAGE_TRANSPORT_LAYER) {
@@ -414,7 +420,7 @@ void IP2lte::registerInterface()
414420
if (!ift)
415421
return;
416422
interfaceEntry = getContainingNicModule(this);
417-
interfaceEntry->setInterfaceName(par("interfaceName").stdstringValue().c_str()); // FIXME: user different name for lte interfaces
423+
interfaceEntry->setInterfaceName(par("interfaceName").stdstringValue().c_str());
418424
// TODO configure MTE size from NED
419425
interfaceEntry->setMtu(1500);
420426
//disable broadcast (not supported in LteNic), enable multicast

src/corenetwork/nodes/Ue.ned

Lines changed: 19 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -85,9 +85,22 @@ module Ue
8585
mobility: <mobilityType> like IMobility {
8686
@display("p=127.368004,172.26001;is=s");
8787
}
88-
app[numApps]: <> like IApp {
89-
@display("p=375,76,row,140");
88+
// link layer
89+
lteNic: <nicType> like ILteNic {
90+
nodeType = nodeType;
91+
//d2dCapable = d2dCapable;
92+
@display("p=525,525");
93+
}
94+
// network layer
95+
ipv4: <default("Ipv4NetworkLayer")> like INetworkLayer if hasIpv4 {
96+
parameters:
97+
@display("p=375,376;q=queue");
98+
}
99+
ipv6: <default("Ipv6NetworkLayer")> like INetworkLayer if hasIpv6 {
100+
parameters:
101+
@display("p=525,376;q=queue");
90102
}
103+
// transport layer
91104
udp: <default(firstAvailableOrEmpty("Udp"))> like IUdp if hasUdp {
92105
parameters:
93106
@display("p=375,226");
@@ -100,20 +113,11 @@ module Ue
100113
parameters:
101114
@display("p=675,226");
102115
}
103-
// network layer
104-
ipv4: <default("Ipv4NetworkLayer")> like INetworkLayer if hasIpv4 {
105-
parameters:
106-
@display("p=375,376;q=queue");
107-
}
108-
ipv6: <default("Ipv6NetworkLayer")> like INetworkLayer if hasIpv6 {
109-
parameters:
110-
@display("p=525,376;q=queue");
111-
}
112-
lteNic: <nicType> like ILteNic {
113-
nodeType = nodeType;
114-
//d2dCapable = d2dCapable;
115-
@display("p=525,525");
116+
// application layer
117+
app[numApps]: <> like IApp {
118+
@display("p=375,76,row,140");
116119
}
120+
117121
// message dispatcher for SAP between application and transport layer
118122
at: MessageDispatcher {
119123
parameters:

src/corenetwork/nodes/cars/Car.ned

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,9 @@ module Car extends Ue
3434
mobilityType = default("VeinsInetMobility");
3535

3636
//# Network Layer specs
37-
*.routingTableModule = default(absPath(".ipv4.routingTable"));
37+
*.routingTableModule = default("^.^.ipv4.routingTable");
3838

39+
//# Parameter values for HostAutoConfigurator: configure cellular interface
3940
ipv4.configurator.typename = "HostAutoConfigurator";
40-
ipv4.configurator.interfaces = "cellular";
41-
42-
submodules:
43-
configurator: HostAutoConfigurator {
44-
@display("p=126.4,413.96");
45-
}
41+
ipv4.configurator.interfaces = default("cellular");
4642
}

tests/fingerprint/d2d_wResults.csv

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# workingdir, args, simtimelimit, fingerprint
2-
/simulations/d2d/, -f omnetpp.ini -c SinglePair-UDP-D2D -r 0, 5s, bd6b-f339/tls, PASS,
3-
/simulations/d2d/, -f omnetpp.ini -c SinglePair-UDP-Infra -r 0, 5s, df96-49db/tls, PASS,
4-
/simulations/d2d/, -f omnetpp.ini -c MultiplePairs-UDP-D2D -r 0, 5s, 6772-675a/tls, PASS,
5-
/simulations/d2d/, -f omnetpp.ini -c MultiplePairs-UDP-Infra -r 0, 5s, 772e-bf0a/tls, PASS,
6-
/simulations/d2d/, -f omnetpp.ini -c MultiplePairs-UDP-D2D-wReuse -r 0, 5s, c77c-bab3/tls, PASS,
2+
/simulations/d2d/, -f omnetpp.ini -c SinglePair-UDP-D2D -r 0, 5s, 4c3a-4e48/tls, PASS,
3+
/simulations/d2d/, -f omnetpp.ini -c SinglePair-UDP-Infra -r 0, 5s, f010-7f39/tls, PASS,
4+
/simulations/d2d/, -f omnetpp.ini -c MultiplePairs-UDP-D2D -r 0, 5s, a1f8-f55c/tls, PASS,
5+
/simulations/d2d/, -f omnetpp.ini -c MultiplePairs-UDP-Infra -r 0, 5s, b4b7-5803/tls, PASS,
6+
/simulations/d2d/, -f omnetpp.ini -c MultiplePairs-UDP-D2D-wReuse -r 0, 5s, ba5e-1aa8/tls, PASS,
77

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
# workingdir, args, simtimelimit, fingerprint
2-
/simulations/demo/, -f omnetpp.ini -c VideoStreaming -r 0, 5s, afa2-bd58/s, PASS,
3-
/simulations/demo/, -f omnetpp.ini -c VoIP -r 0, 5s, 4ec8-8e42/s, PASS,
4-
/simulations/demo/, -f omnetpp.ini -c VoIP_PF -r 0, 5s, 914a-4966/s, PASS,
2+
/simulations/demo/, -f omnetpp.ini -c VideoStreaming -r 0, 5s, 37a9-7801/s, PASS,
3+
/simulations/demo/, -f omnetpp.ini -c VoIP -r 0, 5s, 4c62-9e88/s, PASS,
4+
/simulations/demo/, -f omnetpp.ini -c VoIP_PF -r 0, 5s, fdd3-1eb6/s, PASS,
55
#/simulations/demo/, -f omnetpp.ini -c Large-VoIP_PF -r 0, 5s, ada5-c3af/s, PASS,
66
#/simulations/demo/, -f omnetpp.ini -c Large-VoIP_MaxCI -r 0, 5s, 981a-be0c/s, PASS,
7-
/simulations/demo/, -f omnetpp.ini -c VoIP_DL-UL -r 0, 5s, 7d69-f817/s, PASS,
8-
/simulations/demo/, -f omnetpp.ini -c VoIP-DL -r 0, 5s, 1d27-653a/s, PASS,
9-
/simulations/demo/, -f omnetpp.ini -c VoIP-UL -r 0, 5s, cc1c-684c/s, PASS,
7+
/simulations/demo/, -f omnetpp.ini -c VoIP_DL-UL -r 0, 5s, 3f76-5f90/s, PASS,
8+
/simulations/demo/, -f omnetpp.ini -c VoIP-DL -r 0, 5s, bc13-7d53/s, PASS,
9+
/simulations/demo/, -f omnetpp.ini -c VoIP-UL -r 0, 5s, 06c9-afd0/s, PASS,
1010

11-
/simulations/demo/, -f omnetpp.ini -c VoIP-DL_MACresCheck -r 0, 5s, 1d27-653a/s, PASS,
12-
/simulations/demo/, -f omnetpp.ini -c VoIP-UL_MACresCheck -r 0, 5s, cc1c-684c/s, PASS,
13-
/simulations/demo/, -f omnetpp.ini -c VoIP-DL_PHYresCheck -r 0, 5s, 1d27-653a/s, PASS,
14-
/simulations/demo/, -f omnetpp.ini -c VoIP-UL_PHYresCheck -r 0, 5s, cc1c-684c/s, PASS,
11+
/simulations/demo/, -f omnetpp.ini -c VoIP-DL_MACresCheck -r 0, 5s, bc13-7d53/s, PASS,
12+
/simulations/demo/, -f omnetpp.ini -c VoIP-UL_MACresCheck -r 0, 5s, 06c9-afd0/s, PASS,
13+
/simulations/demo/, -f omnetpp.ini -c VoIP-DL_PHYresCheck -r 0, 5s, bc13-7d53/s, PASS,
14+
/simulations/demo/, -f omnetpp.ini -c VoIP-UL_PHYresCheck -r 0, 5s, 06c9-afd0/s, PASS,

tests/fingerprint/global.csv

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,14 @@
1616
/simulations/demo/, -f omnetpp.ini -c VoIP-UL -r 0, 5s, 1fdd-6780/tplx, PASS,
1717

1818
# DEMO W/ results
19-
/simulations/demo/, -f omnetpp.ini -c VideoStreaming -r 0, 5s, cd55-3175/tls, PASS,
20-
/simulations/demo/, -f omnetpp.ini -c VoIP -r 0, 5s, ccb1-1cc9/tls, PASS,
21-
/simulations/demo/, -f omnetpp.ini -c VoIP_PF -r 0, 5s, 4a4a-afcb/tls, PASS,
19+
/simulations/demo/, -f omnetpp.ini -c VideoStreaming -r 0, 5s, 555e-f42c/tls, PASS,
20+
/simulations/demo/, -f omnetpp.ini -c VoIP -r 0, 5s, ce1b-0c03/tls, PASS,
21+
/simulations/demo/, -f omnetpp.ini -c VoIP_PF -r 0, 5s, 26d3-f81b/tls, PASS,
2222
#/simulations/demo/, -f omnetpp.ini -c Large-VoIP_PF -r 0, 5s, ada5-c3af/tls, PASS,
2323
#/simulations/demo/, -f omnetpp.ini -c Large-VoIP_MaxCI -r 0, 5s, 981a-be0c/tls, PASS,
24-
/simulations/demo/, -f omnetpp.ini -c VoIP_DL-UL -r 0, 5s, b15d-c8ad/tls, PASS,
25-
/simulations/demo/, -f omnetpp.ini -c VoIP-DL -r 0, 5s, c0c2-f01e/tls, PASS,
26-
/simulations/demo/, -f omnetpp.ini -c VoIP-UL -r 0, 5s, e67a-518d/tls, PASS,
24+
/simulations/demo/, -f omnetpp.ini -c VoIP_DL-UL -r 0, 5s, f342-6f2a/tls, PASS,
25+
/simulations/demo/, -f omnetpp.ini -c VoIP-DL -r 0, 5s, 61f6-e877/tls, PASS,
26+
/simulations/demo/, -f omnetpp.ini -c VoIP-UL -r 0, 5s, 2caf-9611/tls, PASS,
2727

2828

2929
# D2D Multicast

0 commit comments

Comments
 (0)