Omnet++ 使用Velse\u inet从aodvRouter向AdhoHost发送消息时出错

Omnet++ 使用Velse\u inet从aodvRouter向AdhoHost发送消息时出错,omnet++,veins,Omnet++,Veins,我使用inet和ventures\u inet来模拟vanet。我希望我的节点在数据包从一个节点发送到另一个节点或从一个节点发送到rsu时使用Aodv路由数据包。为此,我执行了以下操作: 我将节点声明为AODVRouter,并将其移动性设置为VeinsInetMobility: *.node[*].typename = "AodvRouter" *.node[*].mobility.typename = "VeinsInetMobility" 和rsu作为固定移动的连接柱 *.rsu.type

我使用inet和ventures\u inet来模拟vanet。我希望我的节点在数据包从一个节点发送到另一个节点或从一个节点发送到rsu时使用Aodv路由数据包。为此,我执行了以下操作: 我将节点声明为AODVRouter,并将其移动性设置为VeinsInetMobility:

*.node[*].typename = "AodvRouter"
*.node[*].mobility.typename = "VeinsInetMobility"
和rsu作为固定移动的连接柱

*.rsu.typename = "AdhocHost"
*.rsu.mobility.typename = "StationaryMobility":
当我使用以下代码将消息从节点[43]发送到节点[101]或其他节点时,它可以工作:

bool nodeApp::startApplication(){
如果(getParentModule()->getIndex()==43){
destAddress=L3AddressResolver().addressOf(getModuleByPath(“节点[101]”),27);
auto tipChunk=makeShared();
有效载荷(tipChunk);
tipChunk->setChunkLength(B(100));
tipChunk->setPacket_类型(“tip”);
自动数据包=创建数据包(“提示”);
数据包->插入包(tipChunk);
socket.sendTo(packet.release(),destAddress,9001);
}
返回true;
}
但是,当我将dest地址更改为rsu地址时,它不起作用,我得到以下错误:

A runtime error occurred:

handlePacket(): Unknown protocol: id = 55, name = nexthopforwarding -- in module (inet::MessageDispatcher) Network.node[34].tn (id=3241), at t=20.000076211898s, event #1103
为了解决这个错误,我添加了以下标签

auto-req=packet->addTagIfAbsent();
请求->设置协议(&协议::udp);
auto-packetProtocolTag=数据包->addTagIfAbsent();
packetProtocolTag->setProtocol(&Protocol::udp)
但我有以下错误

A runtime error occurred:

Implicit chunk serialization is disabled to prevent unpredictable performance degradation (you may consider changing the Chunk::enableImplicitChunkSerialization flag or passing the PF_ALLOW_SERIALIZATION flag to peek) -- in module (inet::Udp) Network.node[12].udp (id=1216), at t=2.000076936898s, event #378
有人能帮我在不广播数据包的情况下从节点向rsu发送消息吗