Reputation: 181
In my scenario in Veins 3.0, I want to find the vType for a given car node. How do I extract this information from TraCI?
In the TraCICommandInterface.h
file, a function getVehicleTypeID()
is declared but is not defined in the code. Another function getVehicleTypeIDs()
is defined but it returns a list of the IDs only. How do I match my car with it's type?
Thanks in advance.
Upvotes: 0
Views: 449
Reputation: 6943
You are right: this method is not implemented - you will need to implement it yourself. The following code might help...
std::string TraCICommandInterface::getVehicleTypeId(std::string nodeId) {
return genericGetString(CMD_GET_VEHICLE_VARIABLE, nodeId, VAR_TYPE, RESPONSE_GET_VEHICLE_VARIABLE);
}
Upvotes: 1