The Platooning Extension for Veins.

Plexe API

Plexe APIs extends the TraCI methods that standard Veins provides to enable some specific platooning functionalities. The methods are defined and implemented in src/plexe/mobility/CommandInterface.*. API methods can be invoked using the plexeTraciVehicle interface pointer in the modules. You find the plexeTraciVehicle interface pointer already declared in most of the modules in src/plexe. To load the pointer on your own, declare the following variables

1 2
traci::CommandInterface* plexeTraci; std::unique_ptr<traci::CommandInterface::Vehicle> plexeTraciVehicle;

and set their values in the following way within the initialize method of your module

1 2 3
auto plexe = FindModule<PlexeManager*>::findGlobalModule(); plexeTraci = plexe->getCommandInterface(); plexeTraciVehicle.reset(new traci::CommandInterface::Vehicle(plexeTraci, mobility->getExternalId()));

Through plexeTraciVehicle Plexe offers the following APIs: