GPSRNetwork.ned 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. //
  2. // This program is property of its copyright holder. All rights reserved.
  3. //
  4. package inet.examples.manetrouting.gpsr;
  5. import inet.common.lifecycle.LifecycleController;
  6. import inet.common.scenario.ScenarioManager;
  7. import inet.networklayer.configurator.ipv4.IPv4NetworkConfigurator;
  8. import inet.networklayer.ipv4.RoutingTableRecorder;
  9. import inet.node.gpsr.GPSRRouter;
  10. import inet.physicallayer.ieee80211.packetlevel.Ieee80211ScalarRadioMedium;
  11. //
  12. // TODO
  13. //
  14. network GPSRNetworkRandom
  15. {
  16. parameters:
  17. int numHosts;
  18. submodules:
  19. radioMedium: Ieee80211ScalarRadioMedium {
  20. parameters:
  21. @display("p=50,50");
  22. }
  23. configurator: IPv4NetworkConfigurator {
  24. parameters:
  25. config = xml("<config><interface hosts='*' address='145.236.x.x' netmask='255.255.0.0'/></config>");
  26. @display("p=50,100");
  27. }
  28. routingTableRecorder: RoutingTableRecorder {
  29. parameters:
  30. @display("p=50,150");
  31. }
  32. lifecycleController: LifecycleController {
  33. parameters:
  34. @display("p=50,200");
  35. }
  36. scenarioManager: ScenarioManager {
  37. parameters:
  38. script = default(xml("<scenario/>"));
  39. @display("p=50,250");
  40. }
  41. host[numHosts]: GPSRRouter {
  42. parameters:
  43. @display("i=device/pocketpc_s;r=,,#707070");
  44. }
  45. connections allowunconnected:
  46. }
  47. network GPSRNetworkManual
  48. {
  49. submodules:
  50. radioMedium: Ieee80211ScalarRadioMedium {
  51. parameters:
  52. @display("p=50,50");
  53. }
  54. configurator: IPv4NetworkConfigurator {
  55. parameters:
  56. config = xml("<config><interface hosts='*' address='145.236.x.x' netmask='255.255.0.0'/></config>");
  57. @display("p=50,100");
  58. }
  59. routingTableRecorder: RoutingTableRecorder {
  60. parameters:
  61. @display("p=50,150");
  62. }
  63. host0: GPSRRouter {
  64. parameters:
  65. @display("i=device/pocketpc_s;r=,,#707070;p=37,300");
  66. }
  67. host1: GPSRRouter {
  68. parameters:
  69. @display("i=device/pocketpc_s;r=,,#707070;p=723,300");
  70. }
  71. host2: GPSRRouter {
  72. parameters:
  73. @display("i=device/pocketpc_s;r=,,#707070;p=185,300");
  74. }
  75. host3: GPSRRouter {
  76. parameters:
  77. @display("i=device/pocketpc_s;r=,,#707070;p=345,300");
  78. }
  79. host4: GPSRRouter {
  80. parameters:
  81. @display("i=device/pocketpc_s;r=,,#707070;p=345,157");
  82. }
  83. host5: GPSRRouter {
  84. parameters:
  85. @display("i=device/pocketpc_s;r=,,#707070;p=346,26");
  86. }
  87. host6: GPSRRouter {
  88. parameters:
  89. @display("i=device/pocketpc_s;r=,,#707070;p=446,26");
  90. }
  91. host7: GPSRRouter {
  92. parameters:
  93. @display("i=device/pocketpc_s;r=,,#707070;p=346,446");
  94. }
  95. host8: GPSRRouter {
  96. parameters:
  97. @display("i=device/pocketpc_s;r=,,#707070;p=345,572");
  98. }
  99. host9: GPSRRouter {
  100. parameters:
  101. @display("i=device/pocketpc_s;r=,,#707070;p=446,572");
  102. }
  103. host10: GPSRRouter {
  104. parameters:
  105. @display("i=device/pocketpc_s;r=,,#707070;p=642,100");
  106. }
  107. }