Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [sumo-user] Traci ContextSubscription of Vechicle

try using curly brackets vor varIDs:
{traci.constants.VAR_SPEED,traci.constants.VAR_POSITION}

2018-05-11 10:16 GMT+02:00 Surya Soman <suryasoman43@xxxxxxxxx>:
Hi ,

I'm a new user of SUMO. As a part of my research, I was trying a code to access the speed and position of the vehicles around my ego vehicle using Traci vehicle contextsubscription command. Given below is the command I used:-

traci.vehicle.subscribeContext('2567#6',...
       traci.constants.CMD_GET_VEHICLE_VARIABLE, 20,...
       [traci.constants.VAR_SPEED,traci.constants.VAR_POSITION]);


It is giving an error :-

Error using vehicle.subscribeContext
The value of 'varIDs' is invalid. It must satisfy the function: iscell.

Error in traci.vehicle.subscribeContext (line 34)
p.parse(vehID, domain, dist, varargin{:})

Error in vehicleconsub (line 58)
       traci.vehicle.subscribeContext('2567#6',...


Could anyone help me with this. Thanks in advance !


Regards,
Surya 




_______________________________________________
sumo-user mailing list
sumo-user@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/sumo-user



Back to the top