【问题标题】:How to run different scenarios in Omnet++ (Veins)?如何在 Omnet++ (Veins) 中运行不同的场景?
【发布时间】:2021-08-21 13:02:08
【问题描述】:

我在 SUMO 中创建了一个交通场景并使用 Omnet++ 运行它。我有 Inet、Veins 和 VANET 可以使用它。我将车辆作为节点并使用 Veins 运行场景,并使用 VANET 建立节点之间的通信。但是我在 SUMO 中有 3 个不同的场景,我必须在 Veins 中运行它们,那么我该如何运行多个场景呢?是否可以使用单个 Veins_Inet?

【问题讨论】:

    标签: omnet++ veins inet sumo traffic-simulation


    【解决方案1】:

    您在 omnetpp.ini 中创建三个不同的配置,每个配置加载不同的 SUMO 配置:

    [Config FirstConfig]
    *.manager.launchConfig = xmldoc("firstSquare.launchd.xml")
    
    [Config SecondConfig]
    *.manager.launchConfig = xmldoc("secondSquare.launchd.xml")
    
    [Config ThirdConfig]
    *.manager.launchConfig = xmldoc("thirdSquare.launchd.xml")
    

    然后你开始他们

    ./run -u Cmdenv -c FirstConfig -r 0
    ./run -u Cmdenv -c SecondConfig -r 0
    ./run -u Cmdenv -c ThirdConfig -r 0
    

    【讨论】:

    • [Config FirstConfig]重复,应该是[Config SecondConfig]和[Config ThirdConfig]。
    • 谢谢@MohammadPasha - 我更新了答案
    猜你喜欢
    • 2016-05-21
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-09-20
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多