SUMO - Simulation of Urban MObility
TraCIConstants.h
Go to the documentation of this file.
1
/****************************************************************************/
2
// Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo
3
// Copyright (C) 2007-2018 German Aerospace Center (DLR) and others.
4
// This program and the accompanying materials
5
// are made available under the terms of the Eclipse Public License v2.0
6
// which accompanies this distribution, and is available at
7
// http://www.eclipse.org/legal/epl-v20.html
8
// SPDX-License-Identifier: EPL-2.0
9
/****************************************************************************/
25
// holds codes used for TraCI
26
/****************************************************************************/
27
#ifndef TRACICONSTANTS_H
28
#define TRACICONSTANTS_H
29
30
// ****************************************
31
// VERSION
32
// ****************************************
33
#define TRACI_VERSION 18
34
35
// ****************************************
36
// COMMANDS
37
// ****************************************
38
// command: get version
39
#define CMD_GETVERSION 0x00
40
41
// command: load
42
#define CMD_LOAD 0x01
43
44
// command: simulation step
45
#define CMD_SIMSTEP 0x02
46
47
// command: set connection priority (execution order)
48
#define CMD_SETORDER 0x03
49
50
// command: stop node
51
#define CMD_STOP 0x12
52
53
// command: reroute to parking area
54
#define CMD_REROUTE_TO_PARKING 0xc2
55
56
// command: Resume from parking
57
#define CMD_RESUME 0x19
58
59
// command: set lane
60
#define CMD_CHANGELANE 0x13
61
62
// command: slow down
63
#define CMD_SLOWDOWN 0x14
64
65
// command: set sublane (vehicle)
66
#define CMD_CHANGESUBLANE 0x15
67
68
// command: change target
69
#define CMD_CHANGETARGET 0x31
70
71
// command: close sumo
72
#define CMD_CLOSE 0x7F
73
74
// command: add subscription filter
75
#define CMD_ADD_SUBSCRIPTION_FILTER 0x7e
76
77
78
// command: subscribe induction loop (e1) context
79
#define CMD_SUBSCRIBE_INDUCTIONLOOP_CONTEXT 0x80
80
// response: subscribe induction loop (e1) context
81
#define RESPONSE_SUBSCRIBE_INDUCTIONLOOP_CONTEXT 0x90
82
// command: get induction loop (e1) variable
83
#define CMD_GET_INDUCTIONLOOP_VARIABLE 0xa0
84
// response: get induction loop (e1) variable
85
#define RESPONSE_GET_INDUCTIONLOOP_VARIABLE 0xb0
86
// command: subscribe induction loop (e1) variable
87
#define CMD_SUBSCRIBE_INDUCTIONLOOP_VARIABLE 0xd0
88
// response: subscribe induction loop (e1) variable
89
#define RESPONSE_SUBSCRIBE_INDUCTIONLOOP_VARIABLE 0xe0
90
91
// command: subscribe multi-entry/multi-exit detector (e3) context
92
#define CMD_SUBSCRIBE_MULTIENTRYEXIT_CONTEXT 0x81
93
// response: subscribe multi-entry/multi-exit detector (e3) context
94
#define RESPONSE_SUBSCRIBE_MULTIENTRYEXIT_CONTEXT 0x91
95
// command: get multi-entry/multi-exit detector (e3) variable
96
#define CMD_GET_MULTIENTRYEXIT_VARIABLE 0xa1
97
// response: get multi-entry/multi-exit detector (e3) variable
98
#define RESPONSE_GET_MULTIENTRYEXIT_VARIABLE 0xb1
99
// command: subscribe multi-entry/multi-exit detector (e3) variable
100
#define CMD_SUBSCRIBE_MULTIENTRYEXIT_VARIABLE 0xd1
101
// response: subscribe multi-entry/multi-exit detector (e3) variable
102
#define RESPONSE_SUBSCRIBE_MULTIENTRYEXIT_VARIABLE 0xe1
103
104
// command: subscribe traffic lights context
105
#define CMD_SUBSCRIBE_TL_CONTEXT 0x82
106
// response: subscribe traffic lights context
107
#define RESPONSE_SUBSCRIBE_TL_CONTEXT 0x92
108
// command: get traffic lights variable
109
#define CMD_GET_TL_VARIABLE 0xa2
110
// response: get traffic lights variable
111
#define RESPONSE_GET_TL_VARIABLE 0xb2
112
// command: set traffic lights variable
113
#define CMD_SET_TL_VARIABLE 0xc2
114
// command: subscribe traffic lights variable
115
#define CMD_SUBSCRIBE_TL_VARIABLE 0xd2
116
// response: subscribe traffic lights variable
117
#define RESPONSE_SUBSCRIBE_TL_VARIABLE 0xe2
118
119
// command: subscribe lane context
120
#define CMD_SUBSCRIBE_LANE_CONTEXT 0x83
121
// response: subscribe lane context
122
#define RESPONSE_SUBSCRIBE_LANE_CONTEXT 0x93
123
// command: get lane variable
124
#define CMD_GET_LANE_VARIABLE 0xa3
125
// response: get lane variable
126
#define RESPONSE_GET_LANE_VARIABLE 0xb3
127
// command: set lane variable
128
#define CMD_SET_LANE_VARIABLE 0xc3
129
// command: subscribe lane variable
130
#define CMD_SUBSCRIBE_LANE_VARIABLE 0xd3
131
// response: subscribe lane variable
132
#define RESPONSE_SUBSCRIBE_LANE_VARIABLE 0xe3
133
134
// command: subscribe vehicle context
135
#define CMD_SUBSCRIBE_VEHICLE_CONTEXT 0x84
136
// response: subscribe vehicle context
137
#define RESPONSE_SUBSCRIBE_VEHICLE_CONTEXT 0x94
138
// command: get vehicle variable
139
#define CMD_GET_VEHICLE_VARIABLE 0xa4
140
// response: get vehicle variable
141
#define RESPONSE_GET_VEHICLE_VARIABLE 0xb4
142
// command: set vehicle variable
143
#define CMD_SET_VEHICLE_VARIABLE 0xc4
144
// command: subscribe vehicle variable
145
#define CMD_SUBSCRIBE_VEHICLE_VARIABLE 0xd4
146
// response: subscribe vehicle variable
147
#define RESPONSE_SUBSCRIBE_VEHICLE_VARIABLE 0xe4
148
149
// command: subscribe vehicle type context
150
#define CMD_SUBSCRIBE_VEHICLETYPE_CONTEXT 0x85
151
// response: subscribe vehicle type context
152
#define RESPONSE_SUBSCRIBE_VEHICLETYPE_CONTEXT 0x95
153
// command: get vehicle type variable
154
#define CMD_GET_VEHICLETYPE_VARIABLE 0xa5
155
// response: get vehicle type variable
156
#define RESPONSE_GET_VEHICLETYPE_VARIABLE 0xb5
157
// command: set vehicle type variable
158
#define CMD_SET_VEHICLETYPE_VARIABLE 0xc5
159
// command: subscribe vehicle type variable
160
#define CMD_SUBSCRIBE_VEHICLETYPE_VARIABLE 0xd5
161
// response: subscribe vehicle type variable
162
#define RESPONSE_SUBSCRIBE_VEHICLETYPE_VARIABLE 0xe5
163
164
// command: subscribe route context
165
#define CMD_SUBSCRIBE_ROUTE_CONTEXT 0x86
166
// response: subscribe route context
167
#define RESPONSE_SUBSCRIBE_ROUTE_CONTEXT 0x96
168
// command: get route variable
169
#define CMD_GET_ROUTE_VARIABLE 0xa6
170
// response: get route variable
171
#define RESPONSE_GET_ROUTE_VARIABLE 0xb6
172
// command: set route variable
173
#define CMD_SET_ROUTE_VARIABLE 0xc6
174
// command: subscribe route variable
175
#define CMD_SUBSCRIBE_ROUTE_VARIABLE 0xd6
176
// response: subscribe route variable
177
#define RESPONSE_SUBSCRIBE_ROUTE_VARIABLE 0xe6
178
179
// command: subscribe poi context
180
#define CMD_SUBSCRIBE_POI_CONTEXT 0x87
181
// response: subscribe poi context
182
#define RESPONSE_SUBSCRIBE_POI_CONTEXT 0x97
183
// command: get poi variable
184
#define CMD_GET_POI_VARIABLE 0xa7
185
// response: get poi variable
186
#define RESPONSE_GET_POI_VARIABLE 0xb7
187
// command: set poi variable
188
#define CMD_SET_POI_VARIABLE 0xc7
189
// command: subscribe poi variable
190
#define CMD_SUBSCRIBE_POI_VARIABLE 0xd7
191
// response: subscribe poi variable
192
#define RESPONSE_SUBSCRIBE_POI_VARIABLE 0xe7
193
194
// command: subscribe polygon context
195
#define CMD_SUBSCRIBE_POLYGON_CONTEXT 0x88
196
// response: subscribe polygon context
197
#define RESPONSE_SUBSCRIBE_POLYGON_CONTEXT 0x98
198
// command: get polygon variable
199
#define CMD_GET_POLYGON_VARIABLE 0xa8
200
// response: get polygon variable
201
#define RESPONSE_GET_POLYGON_VARIABLE 0xb8
202
// command: set polygon variable
203
#define CMD_SET_POLYGON_VARIABLE 0xc8
204
// command: subscribe polygon variable
205
#define CMD_SUBSCRIBE_POLYGON_VARIABLE 0xd8
206
// response: subscribe polygon variable
207
#define RESPONSE_SUBSCRIBE_POLYGON_VARIABLE 0xe8
208
209
// command: subscribe junction context
210
#define CMD_SUBSCRIBE_JUNCTION_CONTEXT 0x89
211
// response: subscribe junction context
212
#define RESPONSE_SUBSCRIBE_JUNCTION_CONTEXT 0x99
213
// command: get junction variable
214
#define CMD_GET_JUNCTION_VARIABLE 0xa9
215
// response: get junction variable
216
#define RESPONSE_GET_JUNCTION_VARIABLE 0xb9
217
// command: set junction variable
218
#define CMD_SET_JUNCTION_VARIABLE 0xc9
219
// command: subscribe junction variable
220
#define CMD_SUBSCRIBE_JUNCTION_VARIABLE 0xd9
221
// response: subscribe junction variable
222
#define RESPONSE_SUBSCRIBE_JUNCTION_VARIABLE 0xe9
223
224
// command: subscribe edge context
225
#define CMD_SUBSCRIBE_EDGE_CONTEXT 0x8a
226
// response: subscribe edge context
227
#define RESPONSE_SUBSCRIBE_EDGE_CONTEXT 0x9a
228
// command: get edge variable
229
#define CMD_GET_EDGE_VARIABLE 0xaa
230
// response: get edge variable
231
#define RESPONSE_GET_EDGE_VARIABLE 0xba
232
// command: set edge variable
233
#define CMD_SET_EDGE_VARIABLE 0xca
234
// command: subscribe edge variable
235
#define CMD_SUBSCRIBE_EDGE_VARIABLE 0xda
236
// response: subscribe edge variable
237
#define RESPONSE_SUBSCRIBE_EDGE_VARIABLE 0xea
238
239
// command: subscribe simulation context
240
#define CMD_SUBSCRIBE_SIM_CONTEXT 0x8b
241
// response: subscribe simulation context
242
#define RESPONSE_SUBSCRIBE_SIM_CONTEXT 0x9b
243
// command: get simulation variable
244
#define CMD_GET_SIM_VARIABLE 0xab
245
// response: get simulation variable
246
#define RESPONSE_GET_SIM_VARIABLE 0xbb
247
// command: set simulation variable
248
#define CMD_SET_SIM_VARIABLE 0xcb
249
// command: subscribe simulation variable
250
#define CMD_SUBSCRIBE_SIM_VARIABLE 0xdb
251
// response: subscribe simulation variable
252
#define RESPONSE_SUBSCRIBE_SIM_VARIABLE 0xeb
253
254
// command: subscribe GUI context
255
#define CMD_SUBSCRIBE_GUI_CONTEXT 0x8c
256
// response: subscribe GUI context
257
#define RESPONSE_SUBSCRIBE_GUI_CONTEXT 0x9c
258
// command: get GUI variable
259
#define CMD_GET_GUI_VARIABLE 0xac
260
// response: get GUI variable
261
#define RESPONSE_GET_GUI_VARIABLE 0xbc
262
// command: set GUI variable
263
#define CMD_SET_GUI_VARIABLE 0xcc
264
// command: subscribe GUI variable
265
#define CMD_SUBSCRIBE_GUI_VARIABLE 0xdc
266
// response: subscribe GUI variable
267
#define RESPONSE_SUBSCRIBE_GUI_VARIABLE 0xec
268
269
// command: subscribe areal detector (e2) context
270
#define CMD_SUBSCRIBE_LANEAREA_CONTEXT 0x8d
271
// response: subscribe areal detector (e2) context
272
#define RESPONSE_SUBSCRIBE_LANEAREA_CONTEXT 0x9d
273
// command: get areal detector (e2) variable
274
#define CMD_GET_LANEAREA_VARIABLE 0xad
275
// response: get areal detector (e2) variable
276
#define RESPONSE_GET_LANEAREA_VARIABLE 0xbd
277
// command: subscribe areal detector (e2) variable
278
#define CMD_SUBSCRIBE_LANEAREA_VARIABLE 0xdd
279
// response: subscribe areal detector (e2) variable
280
#define RESPONSE_SUBSCRIBE_LANEAREA_VARIABLE 0xed
281
282
// command: subscribe person context
283
#define CMD_SUBSCRIBE_PERSON_CONTEXT 0x8e
284
// response: subscribe person context
285
#define RESPONSE_SUBSCRIBE_PERSON_CONTEXT 0x9e
286
// command: get person variable
287
#define CMD_GET_PERSON_VARIABLE 0xae
288
// response: get person variable
289
#define RESPONSE_GET_PERSON_VARIABLE 0xbe
290
// command: set person variable
291
#define CMD_SET_PERSON_VARIABLE 0xce
292
// command: subscribe person variable
293
#define CMD_SUBSCRIBE_PERSON_VARIABLE 0xde
294
// response: subscribe person variable
295
#define RESPONSE_SUBSCRIBE_PERSON_VARIABLE 0xee
296
297
298
// ****************************************
299
// POSITION REPRESENTATIONS
300
// ****************************************
301
// Position in geo-coordinates
302
#define POSITION_LON_LAT 0x00
303
// 2D cartesian coordinates
304
#define POSITION_2D 0x01
305
// Position in geo-coordinates with altitude
306
#define POSITION_LON_LAT_ALT 0x02
307
// 3D cartesian coordinates
308
#define POSITION_3D 0x03
309
// Position on road map
310
#define POSITION_ROADMAP 0x04
311
312
313
// ****************************************
314
// DATA TYPES
315
// ****************************************
316
// Polygon (2*n doubles)
317
#define TYPE_POLYGON 0x06
318
// unsigned byte
319
#define TYPE_UBYTE 0x07
320
// signed byte
321
#define TYPE_BYTE 0x08
322
// 32 bit signed integer
323
#define TYPE_INTEGER 0x09
324
// double
325
#define TYPE_DOUBLE 0x0B
326
// 8 bit ASCII string
327
#define TYPE_STRING 0x0C
328
// list of traffic light phases
329
#define TYPE_TLPHASELIST 0x0D
330
// list of strings
331
#define TYPE_STRINGLIST 0x0E
332
// compound object
333
#define TYPE_COMPOUND 0x0F
334
// color (four ubytes)
335
#define TYPE_COLOR 0x11
336
337
338
// ****************************************
339
// RESULT TYPES
340
// ****************************************
341
// result type: Ok
342
#define RTYPE_OK 0x00
343
// result type: not implemented
344
#define RTYPE_NOTIMPLEMENTED 0x01
345
// result type: error
346
#define RTYPE_ERR 0xFF
347
348
// return value for invalid queries (especially vehicle is not on the road), see Position::INVALID
349
#define INVALID_DOUBLE_VALUE -1073741824.
350
// return value for invalid queries (especially vehicle is not on the road), see Position::INVALID
351
#define INVALID_INT_VALUE -1073741824
352
// maximum value for client ordering (2 ^ 30)
353
#define MAX_ORDER 1073741824
354
355
// ****************************************
356
// TRAFFIC LIGHT PHASES
357
// ****************************************
358
// red phase
359
#define TLPHASE_RED 0x01
360
// yellow phase
361
#define TLPHASE_YELLOW 0x02
362
// green phase
363
#define TLPHASE_GREEN 0x03
364
// tl is blinking
365
#define TLPHASE_BLINKING 0x04
366
// tl is off and not blinking
367
#define TLPHASE_NOSIGNAL 0x05
368
369
370
// ****************************************
371
// DIFFERENT DISTANCE REQUESTS
372
// ****************************************
373
// air distance
374
#define REQUEST_AIRDIST 0x00
375
// driving distance
376
#define REQUEST_DRIVINGDIST 0x01
377
378
379
// ****************************************
380
// VEHICLE REMOVAL REASONS
381
// ****************************************
382
// vehicle started teleport
383
#define REMOVE_TELEPORT 0x00
384
// vehicle removed while parking
385
#define REMOVE_PARKING 0x01
386
// vehicle arrived
387
#define REMOVE_ARRIVED 0x02
388
// vehicle was vaporized
389
#define REMOVE_VAPORIZED 0x03
390
// vehicle finished route during teleport
391
#define REMOVE_TELEPORT_ARRIVED 0x04
392
393
// ****************************************
394
// PERSON/CONTAINER STAGES
395
// ****************************************
396
// person / container stopping
397
#define STAGE_WAITING_FOR_DEPART 0x00
398
// person / container stopping
399
#define STAGE_WAITING 0x01
400
// person walking / container transhiping
401
#define STAGE_WALKING 0x02
402
// person riding / container being transported
403
#define STAGE_DRIVING 0x03
404
405
// ****************************************
406
// Stop Flags
407
// ****************************************
408
#define STOP_DEFAULT 0x00
409
#define STOP_PARKING 0x01
410
#define STOP_TRIGGERED 0x02
411
#define STOP_CONTAINER_TRIGGERED 0x04
412
#define STOP_BUS_STOP 0x08
413
#define STOP_CONTAINER_STOP 0x10
414
#define STOP_CHARGING_STATION 0x20
415
#define STOP_PARKING_AREA 0x40
416
417
// ****************************************
418
// Departure Flags
419
// ****************************************
420
#define DEPARTFLAG_TRIGGERED -0x01
421
#define DEPARTFLAG_CONTAINER_TRIGGERED -0x02
422
#define DEPARTFLAG_NOW -0x03
423
424
#define DEPARTFLAG_SPEED_RANDOM -0x02
425
#define DEPARTFLAG_SPEED_MAX -0x03
426
427
#define DEPARTFLAG_LANE_RANDOM -0x02
428
#define DEPARTFLAG_LANE_FREE -0x03
429
#define DEPARTFLAG_LANE_ALLOWED_FREE -0x04
430
#define DEPARTFLAG_LANE_BEST_FREE -0x05
431
#define DEPARTFLAG_LANE_FIRST_ALLOWED -0x06
432
433
#define DEPARTFLAG_POS_RANDOM -0x02
434
#define DEPARTFLAG_POS_FREE -0x03
435
#define DEPARTFLAG_POS_BASE -0x04
436
#define DEPARTFLAG_POS_LAST -0x05
437
#define DEPARTFLAG_POS_RANDOM_FREE -0x06
438
439
#define ARRIVALFLAG_LANE_CURRENT -0x02
440
#define ARRIVALFLAG_SPEED_CURRENT -0x02
441
442
#define ARRIVALFLAG_POS_RANDOM -0x02
443
#define ARRIVALFLAG_POS_MAX -0x03
444
445
// ****************************************
446
// Routing modes
447
// ****************************************
448
// use custom weights if available, fall back to loaded weights and then to free-flow speed
449
#define ROUTING_MODE_DEFAULT 0x00
450
// use aggregated travel times from device.rerouting
451
#define ROUTING_MODE_AGGREGATED 0x01
452
// use loaded efforts
453
#define ROUTING_MODE_EFFORT 0x02
454
// use combined costs
455
#define ROUTING_MODE_COMBINED 0x03
456
457
// ****************************************
458
// FILTER TYPES (for context subscription filters)
459
// ****************************************
460
461
// Reset all filters
462
#define FILTER_TYPE_NONE 0x00
463
464
// Filter by list of lanes relative to ego vehicle
465
#define FILTER_TYPE_LANES 0x01
466
467
// Exclude vehicles on opposite (and other) lanes from context subscription result
468
#define FILTER_TYPE_NOOPPOSITE 0x02
469
470
// Specify maximal downstream distance for vehicles in context subscription result
471
#define FILTER_TYPE_DOWNSTREAM_DIST 0x03
472
473
// Specify maximal upstream distance for vehicles in context subscription result
474
#define FILTER_TYPE_UPSTREAM_DIST 0x04
475
476
// Only return leader and follower in context subscription result
477
#define FILTER_TYPE_CF_MANEUVER 0x05
478
479
// Only return leader and follower on ego and neighboring lane in context subscription result
480
#define FILTER_TYPE_LC_MANEUVER 0x06
481
482
// Only return foes on upcoming junction in context subscription result
483
#define FILTER_TYPE_TURN_MANEUVER 0x07
484
485
// Only return vehicles of the given vClass in context subscription result
486
#define FILTER_TYPE_VCLASS 0x08
487
488
// Only return vehicles of the given vType in context subscription result
489
#define FILTER_TYPE_VTYPE 0x09
490
491
492
493
494
495
// ****************************************
496
// VARIABLE TYPES (for CMD_GET_*_VARIABLE)
497
// ****************************************
498
// list of instances' ids (get: all)
499
#define ID_LIST 0x00
500
501
// count of instances (get: all)
502
#define ID_COUNT 0x01
503
504
// subscribe object variables (get: all)
505
#define AUTOMATIC_VARIABLES_SUBSCRIPTION 0x02
506
507
// subscribe context variables (get: all)
508
#define AUTOMATIC_CONTEXT_SUBSCRIPTION 0x03
509
510
// generic attributes (get/set: all)
511
#define GENERIC_ATTRIBUTE 0x03
512
513
// last step vehicle number (get: induction loops, multi-entry/multi-exit detector, lanes, edges)
514
#define LAST_STEP_VEHICLE_NUMBER 0x10
515
516
// last step vehicle number (get: induction loops, multi-entry/multi-exit detector, lanes, edges)
517
#define LAST_STEP_MEAN_SPEED 0x11
518
519
// last step vehicle list (get: induction loops, multi-entry/multi-exit detector, lanes, edges)
520
#define LAST_STEP_VEHICLE_ID_LIST 0x12
521
522
// last step occupancy (get: induction loops, lanes, edges)
523
#define LAST_STEP_OCCUPANCY 0x13
524
525
// last step vehicle halting number (get: multi-entry/multi-exit detector, lanes, edges)
526
#define LAST_STEP_VEHICLE_HALTING_NUMBER 0x14
527
528
// last step mean vehicle length (get: induction loops, lanes, edges)
529
#define LAST_STEP_LENGTH 0x15
530
531
// last step time since last detection (get: induction loops)
532
#define LAST_STEP_TIME_SINCE_DETECTION 0x16
533
534
// entry times
535
#define LAST_STEP_VEHICLE_DATA 0x17
536
537
// last step jam length in vehicles
538
#define JAM_LENGTH_VEHICLE 0x18
539
540
// last step jam length in meters
541
#define JAM_LENGTH_METERS 0x19
542
543
// last step person list (get: edges, vehicles)
544
#define LAST_STEP_PERSON_ID_LIST 0x1a
545
546
547
// traffic light states, encoded as rRgGyYoO tuple (get: traffic lights)
548
#define TL_RED_YELLOW_GREEN_STATE 0x20
549
550
// index of the phase (set: traffic lights)
551
#define TL_PHASE_INDEX 0x22
552
553
// traffic light program (set: traffic lights)
554
#define TL_PROGRAM 0x23
555
556
// phase duration (set: traffic lights)
557
#define TL_PHASE_DURATION 0x24
558
559
// controlled lanes (get: traffic lights)
560
#define TL_CONTROLLED_LANES 0x26
561
562
// controlled links (get: traffic lights)
563
#define TL_CONTROLLED_LINKS 0x27
564
565
// index of the current phase (get: traffic lights)
566
#define TL_CURRENT_PHASE 0x28
567
568
// name of the current program (get: traffic lights)
569
#define TL_CURRENT_PROGRAM 0x29
570
571
// controlled junctions (get: traffic lights)
572
#define TL_CONTROLLED_JUNCTIONS 0x2a
573
574
// complete definition (get: traffic lights)
575
#define TL_COMPLETE_DEFINITION_RYG 0x2b
576
577
// complete program (set: traffic lights)
578
#define TL_COMPLETE_PROGRAM_RYG 0x2c
579
580
// assumed time to next switch (get: traffic lights)
581
#define TL_NEXT_SWITCH 0x2d
582
583
// current state, using external signal names (get: traffic lights)
584
#define TL_EXTERNAL_STATE 0x2e
585
586
// outgoing link number (get: lanes)
587
#define LANE_LINK_NUMBER 0x30
588
589
// id of parent edge (get: lanes)
590
#define LANE_EDGE_ID 0x31
591
592
// outgoing link definitions (get: lanes)
593
#define LANE_LINKS 0x33
594
595
// list of allowed vehicle classes (get&set: lanes)
596
#define LANE_ALLOWED 0x34
597
598
// list of not allowed vehicle classes (get&set: lanes)
599
#define LANE_DISALLOWED 0x35
600
601
// list of foe lanes (get: lanes)
602
#define VAR_FOES 0x37
603
604
// slope (get: edge, lane, vehicle, person)
605
#define VAR_SLOPE 0x36
606
607
// speed (get: vehicle)
608
#define VAR_SPEED 0x40
609
610
// maximum allowed/possible speed (get: vehicle types, lanes, set: edges, lanes)
611
#define VAR_MAXSPEED 0x41
612
613
// position (2D) (get: vehicle, poi, inductionloop, areadetector; set: poi)
614
#define VAR_POSITION 0x42
615
616
// position (3D) (get: vehicle, poi, set: poi)
617
#define VAR_POSITION3D 0x39
618
619
// angle (get: vehicle)
620
#define VAR_ANGLE 0x43
621
622
// angle (get: vehicle types, lanes, arealdetector, set: lanes)
623
#define VAR_LENGTH 0x44
624
625
// color (get: vehicles, vehicle types, polygons, pois)
626
#define VAR_COLOR 0x45
627
628
// max. acceleration (get: vehicles, vehicle types)
629
#define VAR_ACCEL 0x46
630
631
// max. comfortable deceleration (get: vehicles, vehicle types)
632
#define VAR_DECEL 0x47
633
634
// max. (physically possible) deceleration (get: vehicles, vehicle types)
635
#define VAR_EMERGENCY_DECEL 0x7b
636
637
// apparent deceleration (get: vehicles, vehicle types)
638
#define VAR_APPARENT_DECEL 0x7c
639
640
// action step length (get: vehicles, vehicle types)
641
#define VAR_ACTIONSTEPLENGTH 0x7d
642
643
// last action time (get: vehicles)
644
#define VAR_LASTACTIONTIME 0x7f
645
646
// driver's desired headway (get: vehicle types)
647
#define VAR_TAU 0x48
648
649
// vehicle class (get: vehicle types)
650
#define VAR_VEHICLECLASS 0x49
651
652
// emission class (get: vehicle types)
653
#define VAR_EMISSIONCLASS 0x4a
654
655
// shape class (get: vehicle types)
656
#define VAR_SHAPECLASS 0x4b
657
658
// minimum gap (get: vehicle types)
659
#define VAR_MINGAP 0x4c
660
661
// width (get: vehicle types, lanes)
662
#define VAR_WIDTH 0x4d
663
664
// shape (get: polygons)
665
#define VAR_SHAPE 0x4e
666
667
// type id (get: vehicles, polygons, pois)
668
#define VAR_TYPE 0x4f
669
670
// road id (get: vehicles)
671
#define VAR_ROAD_ID 0x50
672
673
// lane id (get: vehicles, inductionloop, arealdetector)
674
#define VAR_LANE_ID 0x51
675
676
// lane index (get: vehicle, edge)
677
#define VAR_LANE_INDEX 0x52
678
679
// route id (get & set: vehicles)
680
#define VAR_ROUTE_ID 0x53
681
682
// edges (get: routes, vehicles)
683
#define VAR_EDGES 0x54
684
685
// update bestLanes (set: vehicle)
686
#define VAR_UPDATE_BESTLANES 0x6a
687
688
// filled? (get: polygons)
689
#define VAR_FILL 0x55
690
691
// position (1D along lane) (get: vehicle)
692
#define VAR_LANEPOSITION 0x56
693
694
// route (set: vehicles)
695
#define VAR_ROUTE 0x57
696
697
// travel time information (get&set: vehicle)
698
#define VAR_EDGE_TRAVELTIME 0x58
699
700
// effort information (get&set: vehicle)
701
#define VAR_EDGE_EFFORT 0x59
702
703
// last step travel time (get: edge, lane)
704
#define VAR_CURRENT_TRAVELTIME 0x5a
705
706
// signals state (get/set: vehicle)
707
#define VAR_SIGNALS 0x5b
708
709
// new lane/position along (set: vehicle)
710
#define VAR_MOVE_TO 0x5c
711
712
// driver imperfection (set: vehicle)
713
#define VAR_IMPERFECTION 0x5d
714
715
// speed factor (set: vehicle)
716
#define VAR_SPEED_FACTOR 0x5e
717
718
// speed deviation (set: vehicle)
719
#define VAR_SPEED_DEVIATION 0x5f
720
721
// routing mode (get/set: vehicle)
722
#define VAR_ROUTING_MODE 0x89
723
724
// speed without TraCI influence (get: vehicle)
725
#define VAR_SPEED_WITHOUT_TRACI 0xb1
726
727
// best lanes (get: vehicle)
728
#define VAR_BEST_LANES 0xb2
729
730
// how speed is set (set: vehicle)
731
#define VAR_SPEEDSETMODE 0xb3
732
733
// move vehicle to explicit (remote controlled) position (set: vehicle)
734
#define MOVE_TO_XY 0xb4
735
736
// is the vehicle stopped, and if so parked and/or triggered?
737
// value = stopped + 2 * parking + 4 * triggered
738
#define VAR_STOPSTATE 0xb5
739
740
// how lane changing is performed (get/set: vehicle)
741
#define VAR_LANECHANGE_MODE 0xb6
742
743
// maximum speed regarding max speed on the current lane and speed factor (get: vehicle)
744
#define VAR_ALLOWED_SPEED 0xb7
745
746
// position (1D lateral position relative to center of the current lane) (get: vehicle)
747
#define VAR_LANEPOSITION_LAT 0xb8
748
749
// get/set prefered lateral alignment within the lane (vehicle)
750
#define VAR_LATALIGNMENT 0xb9
751
752
// get/set maximum lateral speed (vehicle, vtypes)
753
#define VAR_MAXSPEED_LAT 0xba
754
755
// get/set minimum lateral gap (vehicle, vtypes)
756
#define VAR_MINGAP_LAT 0xbb
757
758
// get/set vehicle height (vehicle, vtypes)
759
#define VAR_HEIGHT 0xbc
760
761
// get/set vehicle line
762
#define VAR_LINE 0xbd
763
764
// get/set vehicle via
765
#define VAR_VIA 0xbe
766
767
// current CO2 emission of a node (get: vehicle, lane, edge)
768
#define VAR_CO2EMISSION 0x60
769
770
// current CO emission of a node (get: vehicle, lane, edge)
771
#define VAR_COEMISSION 0x61
772
773
// current HC emission of a node (get: vehicle, lane, edge)
774
#define VAR_HCEMISSION 0x62
775
776
// current PMx emission of a node (get: vehicle, lane, edge)
777
#define VAR_PMXEMISSION 0x63
778
779
// current NOx emission of a node (get: vehicle, lane, edge)
780
#define VAR_NOXEMISSION 0x64
781
782
// current fuel consumption of a node (get: vehicle, lane, edge)
783
#define VAR_FUELCONSUMPTION 0x65
784
785
// current noise emission of a node (get: vehicle, lane, edge)
786
#define VAR_NOISEEMISSION 0x66
787
788
// current person number (get: vehicle)
789
#define VAR_PERSON_NUMBER 0x67
790
791
// number of persons waiting at a defined bus stop (get: simulation)
792
#define VAR_BUS_STOP_WAITING 0x67
793
794
// current leader together with gap (get: vehicle)
795
#define VAR_LEADER 0x68
796
797
// edge index in current route (get: vehicle)
798
#define VAR_ROUTE_INDEX 0x69
799
800
// current waiting time (get: vehicle, lane)
801
#define VAR_WAITING_TIME 0x7a
802
803
// current waiting time (get: vehicle)
804
#define VAR_ACCUMULATED_WAITING_TIME 0x87
805
806
// upcoming traffic lights (get: vehicle)
807
#define VAR_NEXT_TLS 0x70
808
809
// upcoming stops (get: vehicle)
810
#define VAR_NEXT_STOPS 0x73
811
812
// current acceleration (get: vehicle)
813
#define VAR_ACCELERATION 0x72
814
815
// current time in seconds (get: simulation)
816
#define VAR_TIME 0x66
817
818
// current time step (get: simulation)
819
#define VAR_TIME_STEP 0x70
820
821
// current electricity consumption of a node (get: vehicle, lane, edge)
822
#define VAR_ELECTRICITYCONSUMPTION 0x71
823
824
// number of loaded vehicles (get: simulation)
825
#define VAR_LOADED_VEHICLES_NUMBER 0x71
826
827
// loaded vehicle ids (get: simulation)
828
#define VAR_LOADED_VEHICLES_IDS 0x72
829
830
// number of departed vehicle (get: simulation)
831
#define VAR_DEPARTED_VEHICLES_NUMBER 0x73
832
833
// departed vehicle ids (get: simulation)
834
#define VAR_DEPARTED_VEHICLES_IDS 0x74
835
836
// number of vehicles starting to teleport (get: simulation)
837
#define VAR_TELEPORT_STARTING_VEHICLES_NUMBER 0x75
838
839
// ids of vehicles starting to teleport (get: simulation)
840
#define VAR_TELEPORT_STARTING_VEHICLES_IDS 0x76
841
842
// number of vehicles ending to teleport (get: simulation)
843
#define VAR_TELEPORT_ENDING_VEHICLES_NUMBER 0x77
844
845
// ids of vehicles ending to teleport (get: simulation)
846
#define VAR_TELEPORT_ENDING_VEHICLES_IDS 0x78
847
848
// number of arrived vehicles (get: simulation)
849
#define VAR_ARRIVED_VEHICLES_NUMBER 0x79
850
851
// ids of arrived vehicles (get: simulation)
852
#define VAR_ARRIVED_VEHICLES_IDS 0x7a
853
854
// delta t (get: simulation)
855
#define VAR_DELTA_T 0x7b
856
857
// bounding box (get: simulation)
858
#define VAR_NET_BOUNDING_BOX 0x7c
859
860
// minimum number of expected vehicles (get: simulation)
861
#define VAR_MIN_EXPECTED_VEHICLES 0x7d
862
863
// number of vehicles starting to park (get: simulation)
864
#define VAR_STOP_STARTING_VEHICLES_NUMBER 0x68
865
866
// ids of vehicles starting to park (get: simulation)
867
#define VAR_STOP_STARTING_VEHICLES_IDS 0x69
868
869
// number of vehicles ending to park (get: simulation)
870
#define VAR_STOP_ENDING_VEHICLES_NUMBER 0x6a
871
872
// ids of vehicles ending to park (get: simulation)
873
#define VAR_STOP_ENDING_VEHICLES_IDS 0x6b
874
875
// number of vehicles starting to park (get: simulation)
876
#define VAR_PARKING_STARTING_VEHICLES_NUMBER 0x6c
877
878
// ids of vehicles starting to park (get: simulation)
879
#define VAR_PARKING_STARTING_VEHICLES_IDS 0x6d
880
881
// number of vehicles ending to park (get: simulation)
882
#define VAR_PARKING_ENDING_VEHICLES_NUMBER 0x6e
883
884
// ids of vehicles ending to park (get: simulation)
885
#define VAR_PARKING_ENDING_VEHICLES_IDS 0x6f
886
887
// number of vehicles involved in a collision (get: simulation)
888
#define VAR_COLLIDING_VEHICLES_NUMBER 0x80
889
890
// ids of vehicles involved in a collision (get: simulation)
891
#define VAR_COLLIDING_VEHICLES_IDS 0x81
892
893
// number of vehicles involved in a collision (get: simulation)
894
#define VAR_EMERGENCYSTOPPING_VEHICLES_NUMBER 0x89
895
896
// ids of vehicles involved in a collision (get: simulation)
897
#define VAR_EMERGENCYSTOPPING_VEHICLES_IDS 0x8a
898
899
// clears the simulation of all not inserted vehicles (set: simulation)
900
#define CMD_CLEAR_PENDING_VEHICLES 0x94
901
902
// triggers saving simulation state (set: simulation)
903
#define CMD_SAVE_SIMSTATE 0x95
904
905
// sets/retrieves abstract parameter
906
#define VAR_PARAMETER 0x7e
907
908
909
// add an instance (poi, polygon, vehicle, person, route)
910
#define ADD 0x80
911
912
// remove an instance (poi, polygon, vehicle, person)
913
#define REMOVE 0x81
914
915
// copy an instance (vehicle type, other TBD.)
916
#define COPY 0x88
917
918
// convert coordinates
919
#define POSITION_CONVERSION 0x82
920
921
// distance between points or vehicles
922
#define DISTANCE_REQUEST 0x83
923
924
// the current driving distance
925
#define VAR_DISTANCE 0x84
926
927
// add a fully specified instance (vehicle)
928
#define ADD_FULL 0x85
929
930
// find a car based route
931
#define FIND_ROUTE 0x86
932
933
// find an intermodal route
934
#define FIND_INTERMODAL_ROUTE 0x87
935
936
// force rerouting based on travel time (vehicles)
937
#define CMD_REROUTE_TRAVELTIME 0x90
938
939
// force rerouting based on effort (vehicles)
940
#define CMD_REROUTE_EFFORT 0x91
941
942
// validates current route (vehicles)
943
#define VAR_ROUTE_VALID 0x92
944
945
// retrieve information regarding the current person/container stage
946
#define VAR_STAGE 0xc0
947
948
// retrieve information regarding the next edge including crossings and walkingAreas (pedestrians only)
949
#define VAR_NEXT_EDGE 0xc1
950
951
// retrieve information regarding the number of remaining stages
952
#define VAR_STAGES_REMAINING 0xc2
953
954
// retrieve the current vehicle id for the driving stage (person, container)
955
#define VAR_VEHICLE 0xc3
956
957
// append a person stage (person)
958
#define APPEND_STAGE 0xc4
959
960
// append a person stage (person)
961
#define REMOVE_STAGE 0xc5
962
963
// zoom
964
#define VAR_VIEW_ZOOM 0xa0
965
966
// view position
967
#define VAR_VIEW_OFFSET 0xa1
968
969
// view schema
970
#define VAR_VIEW_SCHEMA 0xa2
971
972
// view by boundary
973
#define VAR_VIEW_BOUNDARY 0xa3
974
975
// screenshot
976
#define VAR_SCREENSHOT 0xa5
977
978
// track vehicle
979
#define VAR_TRACK_VEHICLE 0xa6
980
981
// presence of view
982
#define VAR_HAS_VIEW 0xa7
983
984
985
#endif
src
traci-server
TraCIConstants.h
Generated on Tue Sep 4 2018 00:12:16 for SUMO - Simulation of Urban MObility by
1.8.13