riebl / artery

OMNeT++ V2X simulation framework for ETSI ITS-G5
GNU General Public License v2.0
203 stars 131 forks source link

std::runtime_error (Can't determine size for unaligned PER encoding of type CAM because of Latitude sub-type) #200

Closed OverwatchGirl closed 3 years ago

OverwatchGirl commented 3 years ago

Hello @riebl ,

When running a basic scenario, with one road, 2 flows and 2 RSUs, i get a very slow simulation, then this error pops :

std::runtime_error: Can't determine size for unaligned PER encoding of type CAM because of Latitude sub-type -- in module (artery::StationaryMiddleware) World.rsuC1.middleware (id=164), at t=0.74517977871s, event #125

I also modified dcc::FlowControl, by modifying the enqueue() function, can this be the cause ?

Thank you in advance.

riebl commented 3 years ago

No, encoding of CAMs is not related to DCC at all. Most likely the set latitude value is invalid and thus cannot be encoded. Please ensure that the latitude is within the allowed bounds, i.e. greater or equal than -900000000 and less or equal than 900000001.

hagau commented 3 years ago

You most likely need to set the projParameter in the scenario's road network; see the documentation for SUMO Road Networks and the example configuration in extern/veins/examples/veins/erlangen.net.xml for details on how to do that for your scenario.

OverwatchGirl commented 3 years ago

Hello @hagau ,

I looked at the the extern/veins/examples/veins/erlangen.net.xml , but i do not find any projParameter , can you please guide me where to find it (i ma still a beginner with artery) ?

hagau commented 3 years ago

It's in line 58 in the location tag:

<location netOffset="0.00,0.00" convBoundary="644465.09,5491786.25,647071.55,5494795.98" origBoundary="10.998195,49.560791,11.034775,49.587847" projParameter="+proj=utm +zone=32 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"/>

The parameters given there are for proj. Most of the time you can just copy & paste projParameter="+proj=utm +zone=32 +ellps=WGS84 +datum=WGS84 +units=m +no_defs" into the location tag in your scenario's road network (the net.xml file generated by netedit)

riebl commented 3 years ago

I am closing this ticket because I assume the problem has been solved.