Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[sumo-user] TraCI length of E2 detectors

Hi,

 

I want to obtain some traffic measurements (e.g. mean speed, density) on a road stretch for one specific lane. I currently use lane area detectors (E2) for this purpose. Since the area I want to observe is quite long, I added several successive lanes to the definition of the detector, and also used the pos and endPos attributes to let the area begin/end in the middle of the road. However, when I subscribe for this detector and read out the values, I got obscure results. Most interestingly, the length of the detector (0x44) has negative values! After doing some math it appears to me, that the length returned by TraCI is equal to “endPos -  pos”. If I do not set those attributes, the length returned is equal to the last lane added to the definition of the detector.

 

This situation makes the E2 detector quiet useless for me when it comes to measuring traffic density on a long lane segment.

 

Any advises?

 

Kind regards,

Karl


Back to the top