Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [sumo-user] TraCI-controlled person movement + notification on boarding / alighting a vehicle

Yes.  If you do not know the rides beforehand, the plan will always have to include a dummy stop after the current ride so that the person stays in the simulation.
You can then query in each simulation step for the current status of the person and once the ride is finished you can replace the dummy stop with the next ride
It will on occasion be necessary to transfer between stations and for this you can either add walk or teleport the person by defining two consecutive stops at different locations.

relevant calls are
person.getStage, replaceStage, appendStage, removeStage (also appendRidingStage, appendWaitingStage and appendWalkingStage).

Am Do., 8. Jan. 2026 um 01:38 Uhr schrieb Aslan Yurekli Richard via sumo-user <sumo-user@xxxxxxxxxxx>:
Hello,
I am currently working with persons in SUMO and I was wondering whether the following workflow is supported and recommended.
I would like to control a person entirely via TraCI, without letting SUMO automatically execute a predefined XML plan.
More specifically, my intention is that the person:
  • The person should not move at all unless a TraCI command is sent
  • Each movement stage (ride) should start only after I explicitly send a TraCI command
  • When the person boards a vehicle or leaves a vehicle, I want to detect this immediately in TraCI (to trigger a notification / callback in my code)
Example scenario I want to control dynamically:
<person id="p_16" depart="0">
    <ride from="202761590" to="484592976" lines="ANY"/>
    <ride to="250047662#1" lines="ANY"/>
    <stop edge="250047662#1" until="3600"/>
</person>

Would this kind of stage-by-stage control and boarding/alighting detection be possible with TraCI, and if so, what would be the recommended approach?

Thank you very much for your time and guidance.
Best regards,
Aslan
_______________________________________________
sumo-user mailing list
sumo-user@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/sumo-user

Back to the top