机会网络仿真软件ONE:配置文件settings解读

来源:互联网 发布:淘宝鞋店店铺简介 编辑:程序博客网 时间:2024/04/30 00:44

本文对ONE仿真软件的Default settings.xml文件进行解读,以便接下来对实验仿真进行一些基础的配置,有不对的地方希望大家指出,共同学习。

下面给出Default settings.xml文件相关代码及注释:

# Default settings for the simulation#### Scenario settings  场景设置Scenario.name = default_scenarioScenario.simulateConnections = true# 设置场景更新间隔为0.1sScenario.updateInterval = 0.1# 43200s == 12h 设置仿真时间为43200sScenario.endTime = 43200## Interface-specific settings:# type : which interface class the interface belongs to# For different types, the sub-parameters are interface-specific# For SimpleBroadcastInterface, the parameters are:# transmitSpeed : transmit speed of the interface (bytes per second) # transmitRange : range of the interface (meters)# "Bluetooth" interface for all nodes 设置接口类型btInterface.type = SimpleBroadcastInterface# Transmit speed of 2 Mbps = 250kBps 设置接口传输速率为250KB/sbtInterface.transmitSpeed = 250k# 设置接口传输范围为10mbtInterface.transmitRange = 10# High speed, long range, interface for group 4# 对于第四组节点设置高速,大范围的通信接口highspeedInterface.type = SimpleBroadcastInterfacehighspeedInterface.transmitSpeed = 10MhighspeedInterface.transmitRange = 1000# Define 6 different node groups 设置场景中包含6组节点Scenario.nrofHostGroups = 6## Group-specific settings:# groupID : Group's identifier. Used as the prefix of host names# nrofHosts: number of hosts in the group# movementModel: movement model of the hosts (valid class name from movement package)# waitTime: minimum and maximum wait times (seconds) after reaching destination# speed: minimum and maximum speeds (m/s) when moving on a path# bufferSize: size of the message buffer (bytes)# router: router used to route messages (valid class name from routing package)# activeTimes: Time intervals when the nodes in the group are active (start1, end1, start2, end2, ...)# msgTtl : TTL (minutes) of the messages created by this host group, default=infinite## Group and movement model specific settings# pois: Points Of Interest indexes and probabilities (poiIndex1, poiProb1, poiIndex2, poiProb2, ... )#       for ShortestPathMapBasedMovement# okMaps : which map nodes are OK for the group (map file indexes), default=all #          for all MapBasedMovent models# routeFile: route's file path - for MapRouteMovement# routeType: route's type - for MapRouteMovement# Common settings for all groups# 对所有组的共同设置# 设置所有组的移动模型为基于地图的最短路径移动模型Group.movementModel = ShortestPathMapBasedMovement# 设置所有组采用的Epidemic路由模式Group.router = EpidemicRouter# 设置所有组的缓存大小Group.bufferSize = 5MGroup.waitTime = 0, 120# All nodes have the bluetooth interface# 设置所有组一共有几个接口 1为仅有一个接口,btInterface为蓝牙接口Group.nrofInterfaces = 1Group.interface1 = btInterface# Walking speeds# 设置所有组的移动速度为0.5~1.5m/sGroup.speed = 0.5, 1.5# Message TTL of 300 minutes (5 hours)# 设置所有组发送出的数据分组的生存周期为300分钟Group.msgTtl = 300# 设置每组有40个节点Group.nrofHosts = 40# group1 (pedestrians) specific settings# 对不同分组进行不同设置,设置第一组为行人p# 设置第一组的ID编号为pGroup1.groupID = p# group2 specific settings# 对不同分组进行不同设置,设置第二组# 设置第二组的ID编号为c,即carGroup2.groupID = c# cars can drive only on roads# 设置第二组只能在道路上行动Group2.okMaps = 1# 10-50 km/h# 设置第二组的移动速度为2.7~13.9m/sGroup2.speed = 2.7, 13.9# another group of pedestrians# 第三组定义为行人,ID为wGroup3.groupID = w# The Tram groups# 设置第四组为电车组ID为tGroup4.groupID = t# 设置第四组的缓存空间大小为50MGroup4.bufferSize = 50M# 设置第四组的移动模型为模拟了基于地图的,且预先确定的路径的移动方式Group4.movementModel = MapRouteMovement# 设置第四组的路由文件存放在目录data/tram3.wkt下Group4.routeFile = data/tram3.wkt# 设置第四组的路由类型为1Group4.routeType = 1# 设置第四组的等待时间为10~30sGroup4.waitTime = 10, 30# 设置第四组的运行速度为7~10m/sGroup4.speed = 7, 10# 设置第四组有两个节点Group4.nrofHosts = 2# 设置第四组有两个接口,一个为蓝牙接口,一个为高速接口Group4.nrofInterfaces = 2Group4.interface1 = btInterfaceGroup4.interface2 = highspeedInterface# 设置第五组的ID也为t,也为电车Group5.groupID = tGroup5.bufferSize = 50MGroup5.movementModel = MapRouteMovementGroup5.routeFile = data/tram4.wktGroup5.routeType = 2Group5.waitTime = 10, 30Group5.speed = 7, 10Group5.nrofHosts = 2# 设置第六组的ID也为t,也为电车Group6.groupID = tGroup6.bufferSize = 50MGroup6.movementModel = MapRouteMovementGroup6.routeFile = data/tram10.wktGroup6.routeType = 2Group6.waitTime = 10, 30Group6.speed = 7, 10Group6.nrofHosts = 2## Message creation parameters # How many event generators# 每个节点的时间数量为1Events.nrof = 1# Class of the first event generator# Events1的事件的类型为消息事件生成器Events1.class = MessageEventGenerator# (following settings are specific for the MessageEventGenerator class)# Creation interval in seconds (one new message every 25 to 35 seconds)# Events1时间发生的间隔,每25~35s发生一次Events1.interval = 25,35# Message sizes (500kB - 1MB)# 该事件生成数据分组的大小是500kb~1MB,在此范围内随机产生Events1.size = 500k,1M# range of message source/destination addresses# 事件1对应的节点代码,第一个节点的编号是从0开始的,一直到第126个节点,都遵守此事件Events1.hosts = 0,126# Message ID prefix# Events1产生的数据分组前缀为MEvents1.prefix = M## Movement model settings# seed for movement models' pseudo random number generator (default = 0)# 使用随机方式的移动模型是通过伪随机函数生成的,其种子值为1MovementModel.rngSeed = 1# World's size for Movement Models without implicit size (width, height; meters)# 设置移动模型的边界,宽4500m,高3400mMovementModel.worldSize = 4500, 3400# How long time to move hosts in the world before real simulation# 仿真热身时间设置,仿真开始时,容易产生失真,放弃前1000s数据MovementModel.warmup = 1000## Map based movement -movement model specific settings## MapBasedMovement移动模型2级参数设置,涉及4个地图文件MapBasedMovement.nrofMapFiles = 4# 地图文件都存放在data文件夹下MapBasedMovement.mapFile1 = data/roads.wktMapBasedMovement.mapFile2 = data/main_roads.wktMapBasedMovement.mapFile3 = data/pedestrian_paths.wktMapBasedMovement.mapFile4 = data/shops.wkt## Reports - all report names have to be valid report classes# how many reports to load# 生成报告的数量----这里设置我们想要得到的报告的数量Report.nrofReports = 1# length of the warm up period (simulated seconds)# 报告的热身时间为0sReport.warmup = 0# default directory of reports (can be overridden per Report with output setting)# 指定报告输出的位置Report.reportDir = reports/# Report classes to load# 指定报告的类型----这里可以添加我们想要的报告的类型Report.report1 = MessageStatsReport## Default settings for some routers settings
# 对路由的默认设置
ProphetRouter.secondsInTimeUnit = 30SprayAndWaitRouter.nrofCopies = 6SprayAndWaitRouter.binaryMode = true## Optimization settings -- these affect the speed of the simulation## see World class for details.Optimization.cellSizeMult = 5Optimization.randomizeUpdateOrder = true## GUI settings# GUI underlay image settingsGUI.UnderlayImage.fileName = data/helsinki_underlay.png# Image offset in pixels (x, y)GUI.UnderlayImage.offset = 64, 20# Scaling factor for the imageGUI.UnderlayImage.scale = 4.75# Image rotation (radians)GUI.UnderlayImage.rotate = -0.015# how many events to show in the log panel (default = 30)GUI.EventLogPanel.nrofEvents = 100# Regular Expression log filter (see Pattern-class from the Java API for RE-matching details)#GUI.EventLogPanel.REfilter = .*p[1-9]<->p[1-9]$


之后准备对一些报告进行详细解读。

 

 


 

0 0
原创粉丝点击