├── Code
├── I-75.results
│ └── 1.db
├── DriverModel_DLL_HV
│ ├── DriverModel.h
│ ├── DriverModel.vcxproj.user
│ ├── DriverModel_changes.txt
│ ├── DriverModel.cpp
│ └── DriverModel.vcxproj
└── DriverModel_DLL_CAV
│ ├── DriverModel.h
│ ├── DriverModel.vcxproj.user
│ ├── DriverModel_changes.txt
│ ├── DriverModel.vcxproj
│ └── DriverModel.cpp
├── USF Readme updated.docx
├── CONTRIBUTING.md
├── STOL II TO 22_algorithm description document_CAV Lane Changing Model_Final_v2_clean.pdf
├── README.md
└── LICENSE
/Code/I-75.results/1.db:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STOL-AMS/TO-22-Lane-Changing/HEAD/Code/I-75.results/1.db
--------------------------------------------------------------------------------
/USF Readme updated.docx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STOL-AMS/TO-22-Lane-Changing/HEAD/USF Readme updated.docx
--------------------------------------------------------------------------------
/Code/DriverModel_DLL_HV/DriverModel.h:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STOL-AMS/TO-22-Lane-Changing/HEAD/Code/DriverModel_DLL_HV/DriverModel.h
--------------------------------------------------------------------------------
/Code/DriverModel_DLL_CAV/DriverModel.h:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STOL-AMS/TO-22-Lane-Changing/HEAD/Code/DriverModel_DLL_CAV/DriverModel.h
--------------------------------------------------------------------------------
/Code/DriverModel_DLL_CAV/DriverModel.vcxproj.user:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/Code/DriverModel_DLL_HV/DriverModel.vcxproj.user:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/CONTRIBUTING.md:
--------------------------------------------------------------------------------
1 | # Contributing
2 |
3 | When contributing to this repository, please first discuss the change you wish to make via issue, email, or any other method with the owners of this repository before making a change.
--------------------------------------------------------------------------------
/STOL II TO 22_algorithm description document_CAV Lane Changing Model_Final_v2_clean.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/STOL-AMS/TO-22-Lane-Changing/HEAD/STOL II TO 22_algorithm description document_CAV Lane Changing Model_Final_v2_clean.pdf
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 |
2 | # Summary:
3 |
4 | This repository contains the source code of a mixed traffic simulation model. The mixed traffic simulation model integrates vehicle car-following and lane-changing movements in mixed traffic with connected and automated vehicles of different cooperation behaviors. It is centered at a connected and automated vehicle lane changing model while fully considering the dynamics of surrounding vehicles under different mixed traffic scenarios. The source code was developed to generate two DLL files, which were imported into PTV VISSIM to conduct mixed traffic simulations. One of the DLL files is used for connected and automated vehicle (CAV) control and speed output. Another DLL is used for human-driven vehicle (HV) speed output. The source code was programmed in Microsoft Visual Studio 2017 with C++.
5 |
6 | # Organizational Outline:
7 | * Project Title
8 | * Release Notes
9 | * Getting Started
10 | * Prerequisites
11 | * Installing
12 | * Testing
13 | * Authors
14 | * License
15 | * Acknowledgments
16 | * Code.gov Registration
17 |
18 | # Project Title
19 |
20 | *Developing Analysis, Modeling, and Simulation (AMS) Tools for Connected Automated Vehicle Applications: PATH Model Description and Implementation in the Microscopic Traffic Simulation Platform*
21 |
22 | As road users start to adopt different technologies, the traffic stream might consist of human vehicles (HV), connected vehicles (CV), autonomous vehicles (AV), and connected automated vehicles (CAV) at the same time. The interaction of various types of vehicle fleet may induce complex traffic flow patterns that have never been observed in the existing transportation system. Such complex traffic is difficult to model with existing microscopic simulation and evaluation approaches. To address the challenge, the Federal Highway Administration (FHWA) supported a research project entitled “Developing Analysis, Modeling, and Simulation (AMS) Tools for Connected Automated Vehicle Applications”.
23 |
24 | ## Release Notes
25 |
26 | #### Release 1.0.0 (April 5, 2020)
27 | - Initial release
28 |
29 | ## Getting Started
30 |
31 | *Download the source code file and open it in Microsoft Visual Studio 2017 or higher.*
32 |
33 | ### Prerequisites
34 |
35 | Requires:
36 | - PTV VISSIM 11
37 | - Microsoft Visual Studio 2017 or higher
38 |
39 | ### Installing
40 |
41 | Step 1: Install software tools.
42 |
43 | ```
44 | - Install Microsoft Visual Studio 2017
45 | - Install Visual Studio 2017
46 | ```
47 |
48 | Step 2: Generate CAV control and speed output DLL in Microsoft Visual Studio.
49 |
50 | ```
51 | - Open and run “DriverModel.vcxproj” in Microsoft Visual Studio, which is located at \source code\DriverModel_DLL_CAV
52 | - Note: The generated DLL (DriverModel.dll) is located at \source code \DriverModel_DLL_CAV\x64\Debug
53 | ```
54 |
55 | Step 3: Generate HV speed output DLL in Microsoft Visual Studio.
56 |
57 | ```
58 | - Open and run “DriverModel.vcxproj” in Microsoft Visual Studio, which is located at \source code\DriverModel_DLL_HV
59 | - Note: The generated DLL (DriverModel.dll) is located at \source code \DriverModel_DLL_HV\x64\Debug
60 | ```
61 |
62 | Step 4: Import generated DLLs into PTV VISSIM.
63 |
64 | ```
65 | - Open I-75.inpx using PTV VISSIM
66 | - Right click on the AV row and then click “Edit”
67 | - Click “External Driver Model” and locate the DLL generated in Step 2
68 | - Right click on the HV row and then click “Edit”
69 | - Click “External Driver Model” and locate the DLL generated in Step 3
70 | ```
71 |
72 | ## Testing
73 |
74 | ```
75 | Step 1: Run the simulation in PTV VISSIM.
76 | Step 2: After the simulation (5 minutes), CAV and HV speed information will be generated and saved in data_put_out_AV.txt and data_put_out_HV.txt.
77 | Step 3: In data_put_out_AV.txt every appearance of “630” represents the appearance of a new CAV. Numbers following 630 are the CAV speeds (m/s) measured at each 0.1 second.
78 | Step 4: In data_put_out_HV.txt every appearance of “640” represents the appearance of a new HV. Numbers following 640 are the HV speeds (m/s) measured at each 0.1 second.
79 | ```
80 |
81 | ## Authors
82 |
83 | Qianwen Li, Ph.D. student, Department of Civil and Environmental Engineering, University of South Florida.
84 | Xiaopeng Li, Ph.D., Department of Civil and Environmental Engineering, University of South Florida.
85 |
86 | ## License
87 |
88 | This project is licensed under the Apache 2.0 License.
89 |
90 | ## Acknowledgments
91 |
92 | This research is supported by Federal Highway Administration (FHWA) Office of Operations Research and Development HRDO program under the project entitled Developing Analysis, Modeling, and Simulation (AMS) Tools for Connected Automated Vehicle Applications (Project Number: DTFH61-16-D-00030-0022).
93 |
94 | ## Code.gov Registration Info
95 |
96 | Agency: DOT
97 | Short Description: Source code of the USF traffic simulation model
98 | Status: Alpha
99 | Tags: Traffic simulation, Vissim, Lane Changing
100 | Labor hours: 0
101 | Contact Name: ??
102 | Contact Phone: ??
--------------------------------------------------------------------------------
/Code/DriverModel_DLL_HV/DriverModel_changes.txt:
--------------------------------------------------------------------------------
1 | New features and bugfixes in the DriverModel.DLL API (2017-09-15)
2 | ====================================================
3 | (+ = new features, - = bugs that have been fixed,
4 | * = changes in the usage by VISSIM.
5 | Details about the fixes are in brackets.)
6 |
7 | (2017-09-15) [with VISSIM 10.00-02]
8 | ------------
9 | + DriverModel.h + .cpp + DriverModelExample.cpp:
10 | Optional transfer of values of user-defined vehicle attributes:
11 | New types DRIVER_DATA_USE_UDA, DRIVER_DATA_VEH_UDA and DRIVER_DATA_NVEH_UDA.
12 | Optional transfer of values for *all* nearby vehicles found according to the
13 | driving behavior parameters. New type DRIVER_DATA_WANTS_ALL_NVEHS.
14 | Option to allow multithreaded simulation runs.
15 | New type DRIVER_DATA_ALLOW_MULTITHREADING.
16 |
17 | (2017-03-21) [with VISSIM 9.00-07 + 10.00]
18 | ------------
19 | + DriverModel.h + .cpp + DriverModelExample.cpp:
20 | New types DRIVER_DATA_VEH_Z_COORDINATE and DRIVER_DATA_VEH_REAR_Z_COORDINATE.
21 |
22 | (2016-12-14) [with VISSIM 9.00-05 + 10.00]
23 | ------------
24 | + DriverModel.h + .cpp + DriverModelExample.cpp:
25 | New types DRIVER_DATA_VEH_INTAC_STATE, DRIVER_DATA_VEH_INTAC_TARGET_TYPE,
26 | DRIVER_DATA_VEH_INTAC_TARGET_ID, DRIVER_DATA_VEH_INTAC_HEADWAY,
27 | DRIVER_DATA_NVEH_TYPE, DRIVER_DATA_USE_INTERNAL_MODEL.
28 | + DriverModel.cpp does now cause Vissim to handle the vehicles completely on its
29 | own with the internal models. (Previously, the limitation of the change of
30 | acceleration used in the internal model was not applied even when the driver
31 | model DLL passed back the acceleration suggested by Vissim.)
32 |
33 | (2016-08-23) [with VISSIM 8.00-13 + 9.00-03]
34 | ------------
35 | + DriverModel.h:
36 | Missing definitions of DRIVER_DATA_VEH_REAR_X_COORDINATE and
37 | DRIVER_DATA_VEH_REAR_Y_COORDINATE added.
38 | (Not added to DriverModel.cpp because these are optional.)
39 |
40 | (2014-07-29) [with VISSIM 6.00-20 + 7.00]
41 | ------------
42 | + DriverModelExample.cpp:
43 | Alternative version of DriverModel.cpp which contains its own very simple
44 | car following model.
45 |
46 | (2013-08-08) [with VISSIM 6.00-02]
47 | ------------
48 | + DriverModel.cpp:
49 | Back to default version which simply returns Vissim's suggestion.
50 | * DriverModel.vcproj replaced by DriverModel.vcxproj
51 | Switched project file example to Visual Studio 10.
52 |
53 | (2012-08-28) [with VISSIM 5.40-06]
54 | ------------
55 | + DriverModel.cpp:
56 | Contains a very simple car following model as an example.
57 | + DriverModel.vxproj:
58 | Updated to Visual Studio 8.0 (2005)
59 |
60 | (2010-07-29) [with VISSIM 5.20-11]
61 | ------------
62 | + New Interface_Description.pdf replacing DriverModel.txt
63 | (saying VISSIM 5.30 but valid for 5.20-11, too).
64 | + DriverModel.h + .cpp:
65 | New type code:
66 | DRIVER_DATA_PARAMETERFILE.
67 | Some comments improved.
68 | * VISSIM:
69 | All type codes added since 2005-05-24 are treated as optional, so there are
70 | no error messages anymore about values which cannot be set or retrieved.
71 |
72 | (2010-06-16) [released with VISSIM 5.20-10]
73 | ------------
74 | + DriverModel.h + .cpp (still old format):
75 | New type codes:
76 | DRIVER_DATA_STATUS, DRIVER_DATA_STATUS_DETAILS.
77 | + DriverModel.cpp:
78 | DriverModelSetValue() handles DRIVER_DATA_VEH_ACTIVE_LANE_CHANGE and
79 | DRIVER_DATA_VEH_REL_TARGET_LANE without returning zero.
80 |
81 | (2010-02-17) [since VISSIM 5.20-07]
82 | ------------
83 | * VISSIM:
84 | DRIVER_DATA_STATUS and DRIVER_DATA_STATUS_DETAILS are treated as optional now.
85 |
86 | (2010-01-14) [since VISSIM 5.20-06]
87 | ------------
88 | * VISSIM:
89 | DRIVER_DATA_VEH_DESTINATION_LINK, DRIVER_DATA_VEH_REAR_X_COORDINATE and
90 | DRIVER_DATA_VEH_REAR_Y_COORDINATE are treated as optional now.
91 |
92 | (2009-12-11) [since VISSIM 5.20-05]
93 | ------------
94 | * VISSIM:
95 | DRIVER_DATA_PARAMETERFILE is treated as optional now.
96 | * VISSIM:
97 | DRIVER_DATA_LINK_SEGMENT_UP_RIGHT_X, DRIVER_DATA_LINK_SEGMENT_UP_RIGHT_Y,
98 | DRIVER_DATA_LINK_SEGMENT_UP_LEFT_X, DRIVER_DATA_LINK_SEGMENT_UP_LEFT_Y,
99 | DRIVER_DATA_LINK_SEGMENT_DOWN_RIGHT_X, DRIVER_DATA_LINK_SEGMENT_DOWN_RIGHT_Y,
100 | DRIVER_DATA_LINK_SEGMENT_DOWN_LEFT_X, DRIVER_DATA_LINK_SEGMENT_DOWN_LEFT_Y,
101 | DRIVER_DATA_SIGNAL_HEAD_POS_RIGHT_X, DRIVER_DATA_SIGNAL_HEAD_POS_RIGHT_Y,
102 | DRIVER_DATA_SIGNAL_HEAD_POS_LEFT_X, DRIVER_DATA_SIGNAL_HEAD_POS_LEFT_Y
103 | are not used anymore.
104 |
105 | (2008-12-23) [since VISSIM 5.10-06]
106 | ------------
107 | * VISSIM:
108 | DRIVER_DATA_USES_PEDESTRIAN_POLYGONS and DRIVER_DATA_VEH_LEAVES_NETWORK
109 | are not used anymore.
110 |
111 | (2007-09-19) [since VISSIM 5.00-00]
112 | ------------
113 | * VISSIM:
114 | The DriverModel.DLL interface is not used anymore for the Pedestrian Module.
115 | Support for DRIVER_DATA_USES_PEDESTRIAN_POLYGONS has been discontinued.
116 | * VISSIM:
117 | DRIVER_DATA_VEH_Z_COORDINATE, DRIVER_DATA_VEH_HEIGHT,
118 | DRIVER_DATA_VEH_REAR_Z_COORDINATE and DRIVER_DATA_PEDESTRIAN_POLYGON_*
119 | are not used anymore.
120 |
121 | (2007-04-12) [since 4.30-01]
122 | ------------
123 | * VISSIM:
124 | DRIVER_DATA_VEH_REAR_X_COORDINATE, DRIVER_DATA_VEH_REAR_Y_COORDINATE are
125 | used even if DriverModelGetValue (DRIVER_DATA_USES_PEDESTRIAN_POLYGONS, ...)
126 | set *long_value to 0, i.e. for lane-based driver models.
127 |
128 | (2007-02-06) [not externally released]
129 | ------------
130 | + DriverModel.h + .cpp:
131 | New type code:
132 | DRIVER_DATA_VEH_REAR_Z_COORDINATE
133 | (only used with DRIVER_DATA_USES_PEDESTRIAN_POLYGONS).
134 |
135 | (2006-11-30) [not externally released]
136 | ------------
137 | + DriverModel.h + .cpp:
138 | New type codes:
139 | DRIVER_DATA_STATUS, DRIVER_DATA_STATUS_DETAILS.
140 | + DriverModel.cpp:
141 | DriverModelGetValue() and DriverModelSetValue() must return 1 to almost
142 | all calls (even with the new type codes added after 2005-05-24)
143 | to prevent VISSIM from stopping the simulation run with the error message
144 | "Could not send/retrieve ... to/from driver model"!
145 |
146 | (2006-10-20) [not externally released]
147 | ------------
148 | + DriverModel.h + .cpp:
149 | New type code:
150 | DRIVER_DATA_VEH_HEIGHT
151 | (only used with DRIVER_DATA_USES_PEDESTRIAN_POLYGONS).
152 |
153 | (2006-09-21) [not externally released]
154 | ------------
155 | + DriverModel.h + .cpp:
156 | New type code:
157 | DRIVER_DATA_VEH_Z_COORDINATE
158 | (only used with DRIVER_DATA_USES_PEDESTRIAN_POLYGONS).
159 |
160 | (2006-09-20) [not externally released]
161 | ------------
162 | + DriverModel.h + .cpp:
163 | DRIVER_DATA_SETS_XY_COORDINATES replaced by DRIVER_DATA_USES_PEDESTRIAN_POLYGONS.
164 | New type codes:
165 | DRIVER_DATA_PEDESTRIAN_POLYGON_*
166 | (only used with DRIVER_DATA_USES_PEDESTRIAN_POLYGONS).
167 | * VISSIM:
168 | DRIVER_DATA_LINK_SEGMENT_UP_RIGHT_X, DRIVER_DATA_LINK_SEGMENT_UP_RIGHT_Y,
169 | DRIVER_DATA_LINK_SEGMENT_UP_LEFT_X, DRIVER_DATA_LINK_SEGMENT_UP_LEFT_Y,
170 | DRIVER_DATA_LINK_SEGMENT_DOWN_RIGHT_X, DRIVER_DATA_LINK_SEGMENT_DOWN_RIGHT_Y,
171 | DRIVER_DATA_LINK_SEGMENT_DOWN_LEFT_X, DRIVER_DATA_LINK_SEGMENT_DOWN_LEFT_Y,
172 | DRIVER_DATA_SIGNAL_HEAD_POS_RIGHT_X, DRIVER_DATA_SIGNAL_HEAD_POS_RIGHT_Y,
173 | DRIVER_DATA_SIGNAL_HEAD_POS_LEFT_X, DRIVER_DATA_SIGNAL_HEAD_POS_LEFT_Y
174 | are passed to the driver model DLL if DriverModelGetValue
175 | (DRIVER_DATA_USES_PEDESTRIAN_POLYGONS, ...) set *long_value to 0!
176 |
177 | (2006-09-01) [since VISSIM 4.30-00, not externally released]
178 | ------------
179 | + DriverModel.h + .cpp:
180 | New format (created from an internal database).
181 | + DriverModel.h + .cpp:
182 | New type code:
183 | DRIVER_DATA_PARAMETERFILE.
184 | * VISSIM: The name of the DLL and a parameterfile can be selected for each
185 | vehicle type.
186 |
187 | (2005-11-09) [not externally released]
188 | ------------
189 | + DriverModel.h + .cpp:
190 | New type codes:
191 | DRIVER_DATA_VEH_DESTINATION_LINK, DRIVER_DATA_SETS_XY_COORDINATES,
192 | DRIVER_DATA_VEH_LEAVES_NETWORK,
193 | DRIVER_DATA_VEH_REAR_X_COORDINATE, DRIVER_DATA_VEH_REAR_Y_COORDINATE,
194 | DRIVER_DATA_LINK_SEGMENT_UP_RIGHT_X, DRIVER_DATA_LINK_SEGMENT_UP_RIGHT_Y,
195 | DRIVER_DATA_LINK_SEGMENT_UP_LEFT_X, DRIVER_DATA_LINK_SEGMENT_UP_LEFT_Y,
196 | DRIVER_DATA_LINK_SEGMENT_DOWN_RIGHT_X, DRIVER_DATA_LINK_SEGMENT_DOWN_RIGHT_Y,
197 | DRIVER_DATA_LINK_SEGMENT_DOWN_LEFT_X, DRIVER_DATA_LINK_SEGMENT_DOWN_LEFT_Y,
198 | DRIVER_DATA_SIGNAL_HEAD_POS_RIGHT_X, DRIVER_DATA_SIGNAL_HEAD_POS_RIGHT_Y,
199 | DRIVER_DATA_SIGNAL_HEAD_POS_LEFT_X, DRIVER_DATA_SIGNAL_HEAD_POS_LEFT_Y.
200 | + DriverModel.h + .cpp:
201 | DRIVER_DATA_VEH_TURNING_INDICATOR is used by DriverModelGetValue(), too.
202 | DRIVER_DATA_VEH_X_COORDINATE and DRIVER_DATA_VEH_Y_COORDINATE are
203 | used by DriverModelGetValue(), too, if DriverModelGetValue
204 | (DRIVER_DATA_SETS_XY_COORDINATES, ...) set *long_value to 1.
205 |
206 | (2005-05-24)
207 | ------------
208 | + DriverModel.h:
209 | Comments for index values for DRIVER_DATA_NVEH_ values improved.
210 |
--------------------------------------------------------------------------------
/Code/DriverModel_DLL_CAV/DriverModel_changes.txt:
--------------------------------------------------------------------------------
1 | New features and bugfixes in the DriverModel.DLL API (2018-09-06)
2 | ====================================================
3 | (+ = new features, - = bugs that have been fixed,
4 | * = changes in the usage by VISSIM.
5 | Details about the fixes are in brackets.)
6 |
7 | (2018-09-06) [with VISSIM 11.00-01]
8 | ------------
9 | + DriverModel.h:
10 | New types DRIVER_DATA_PRIO_RULE_DISTANCE and DRIVER_DATA_PRIO_RULE_STATE
11 | which are not yet used by Vissim.
12 | New types DRIVER_DATA_ROUTE_SIGNAL_DISTANCE, DRIVER_DATA_ROUTE_SIGNAL_STATE
13 | and DRIVER_DATA_ROUTE_SIGNAL_SWITCH for information about the next signal
14 | head downstream on the route of the vehicle, including necessary lane changes
15 | required by the route/path of the vehicle.
16 |
17 | (2017-11-02) [with VISSIM 10.00-03*]
18 | ------------
19 | + DriverModel.h + .cpp + DriverModelExample.cpp:
20 | New types DRIVER_DATA_NVEH_X_COORDINATE, DRIVER_DATA_NVEH_Y_COORDINATE,
21 | DRIVER_DATA_NVEH_Z_COORDINATE, DRIVER_DATA_NVEH_REAR_X_COORDINATE,
22 | DRIVER_DATA_NVEH_REAR_Y_COORDINATE, DRIVER_DATA_NVEH_REAR_Z_COORDINATE,
23 | DRIVER_DATA_CURRENT_LANE_POLY_N, DRIVER_DATA_CURRENT_LANE_POLY_X,
24 | DRIVER_DATA_CURRENT_LANE_POLY_Y, DRIVER_DATA_CURRENT_LANE_POLY_Z.
25 |
26 | (2017-09-15) [with VISSIM 10.00-02]
27 | ------------
28 | + DriverModel.h + .cpp + DriverModelExample.cpp:
29 | Optional transfer of values of user-defined vehicle attributes:
30 | New types DRIVER_DATA_USE_UDA, DRIVER_DATA_VEH_UDA and DRIVER_DATA_NVEH_UDA.
31 | Optional transfer of values for *all* nearby vehicles found according to the
32 | driving behavior parameters. New type DRIVER_DATA_WANTS_ALL_NVEHS.
33 | Option to allow multithreaded simulation runs.
34 | New type DRIVER_DATA_ALLOW_MULTITHREADING.
35 |
36 | (2017-03-21) [with VISSIM 9.00-07 + 10.00]
37 | ------------
38 | + DriverModel.h + .cpp + DriverModelExample.cpp:
39 | New types DRIVER_DATA_VEH_Z_COORDINATE and DRIVER_DATA_VEH_REAR_Z_COORDINATE.
40 |
41 | (2016-12-14) [with VISSIM 9.00-05 + 10.00]
42 | ------------
43 | + DriverModel.h + .cpp + DriverModelExample.cpp:
44 | New types DRIVER_DATA_VEH_INTAC_STATE, DRIVER_DATA_VEH_INTAC_TARGET_TYPE,
45 | DRIVER_DATA_VEH_INTAC_TARGET_ID, DRIVER_DATA_VEH_INTAC_HEADWAY,
46 | DRIVER_DATA_NVEH_TYPE, DRIVER_DATA_USE_INTERNAL_MODEL.
47 | + DriverModel.cpp does now cause Vissim to handle the vehicles completely on its
48 | own with the internal models. (Previously, the limitation of the change of
49 | acceleration used in the internal model was not applied even when the driver
50 | model DLL passed back the acceleration suggested by Vissim.)
51 |
52 | (2016-08-23) [with VISSIM 8.00-13 + 9.00-03]
53 | ------------
54 | + DriverModel.h:
55 | Missing definitions of DRIVER_DATA_VEH_REAR_X_COORDINATE and
56 | DRIVER_DATA_VEH_REAR_Y_COORDINATE added.
57 | (Not added to DriverModel.cpp because these are optional.)
58 |
59 | (2014-07-29) [with VISSIM 6.00-20 + 7.00]
60 | ------------
61 | + DriverModelExample.cpp:
62 | Alternative version of DriverModel.cpp which contains its own very simple
63 | car following model.
64 |
65 | (2013-08-08) [with VISSIM 6.00-02]
66 | ------------
67 | + DriverModel.cpp:
68 | Back to default version which simply returns Vissim's suggestion.
69 | * DriverModel.vcproj replaced by DriverModel.vcxproj
70 | Switched project file example to Visual Studio 10.
71 |
72 | (2012-08-28) [with VISSIM 5.40-06]
73 | ------------
74 | + DriverModel.cpp:
75 | Contains a very simple car following model as an example.
76 | + DriverModel.vxproj:
77 | Updated to Visual Studio 8.0 (2005)
78 |
79 | (2010-07-29) [with VISSIM 5.20-11]
80 | ------------
81 | + New Interface_Description.pdf replacing DriverModel.txt
82 | (saying VISSIM 5.30 but valid for 5.20-11, too).
83 | + DriverModel.h + .cpp:
84 | New type code:
85 | DRIVER_DATA_PARAMETERFILE.
86 | Some comments improved.
87 | * VISSIM:
88 | All type codes added since 2005-05-24 are treated as optional, so there are
89 | no error messages anymore about values which cannot be set or retrieved.
90 |
91 | (2010-06-16) [released with VISSIM 5.20-10]
92 | ------------
93 | + DriverModel.h + .cpp (still old format):
94 | New type codes:
95 | DRIVER_DATA_STATUS, DRIVER_DATA_STATUS_DETAILS.
96 | + DriverModel.cpp:
97 | DriverModelSetValue() handles DRIVER_DATA_VEH_ACTIVE_LANE_CHANGE and
98 | DRIVER_DATA_VEH_REL_TARGET_LANE without returning zero.
99 |
100 | (2010-02-17) [since VISSIM 5.20-07]
101 | ------------
102 | * VISSIM:
103 | DRIVER_DATA_STATUS and DRIVER_DATA_STATUS_DETAILS are treated as optional now.
104 |
105 | (2010-01-14) [since VISSIM 5.20-06]
106 | ------------
107 | * VISSIM:
108 | DRIVER_DATA_VEH_DESTINATION_LINK, DRIVER_DATA_VEH_REAR_X_COORDINATE and
109 | DRIVER_DATA_VEH_REAR_Y_COORDINATE are treated as optional now.
110 |
111 | (2009-12-11) [since VISSIM 5.20-05]
112 | ------------
113 | * VISSIM:
114 | DRIVER_DATA_PARAMETERFILE is treated as optional now.
115 | * VISSIM:
116 | DRIVER_DATA_LINK_SEGMENT_UP_RIGHT_X, DRIVER_DATA_LINK_SEGMENT_UP_RIGHT_Y,
117 | DRIVER_DATA_LINK_SEGMENT_UP_LEFT_X, DRIVER_DATA_LINK_SEGMENT_UP_LEFT_Y,
118 | DRIVER_DATA_LINK_SEGMENT_DOWN_RIGHT_X, DRIVER_DATA_LINK_SEGMENT_DOWN_RIGHT_Y,
119 | DRIVER_DATA_LINK_SEGMENT_DOWN_LEFT_X, DRIVER_DATA_LINK_SEGMENT_DOWN_LEFT_Y,
120 | DRIVER_DATA_SIGNAL_HEAD_POS_RIGHT_X, DRIVER_DATA_SIGNAL_HEAD_POS_RIGHT_Y,
121 | DRIVER_DATA_SIGNAL_HEAD_POS_LEFT_X, DRIVER_DATA_SIGNAL_HEAD_POS_LEFT_Y
122 | are not used anymore.
123 |
124 | (2008-12-23) [since VISSIM 5.10-06]
125 | ------------
126 | * VISSIM:
127 | DRIVER_DATA_USES_PEDESTRIAN_POLYGONS and DRIVER_DATA_VEH_LEAVES_NETWORK
128 | are not used anymore.
129 |
130 | (2007-09-19) [since VISSIM 5.00-00]
131 | ------------
132 | * VISSIM:
133 | The DriverModel.DLL interface is not used anymore for the Pedestrian Module.
134 | Support for DRIVER_DATA_USES_PEDESTRIAN_POLYGONS has been discontinued.
135 | * VISSIM:
136 | DRIVER_DATA_VEH_Z_COORDINATE, DRIVER_DATA_VEH_HEIGHT,
137 | DRIVER_DATA_VEH_REAR_Z_COORDINATE and DRIVER_DATA_PEDESTRIAN_POLYGON_*
138 | are not used anymore.
139 |
140 | (2007-04-12) [since 4.30-01]
141 | ------------
142 | * VISSIM:
143 | DRIVER_DATA_VEH_REAR_X_COORDINATE, DRIVER_DATA_VEH_REAR_Y_COORDINATE are
144 | used even if DriverModelGetValue (DRIVER_DATA_USES_PEDESTRIAN_POLYGONS, ...)
145 | set *long_value to 0, i.e. for lane-based driver models.
146 |
147 | (2007-02-06) [not externally released]
148 | ------------
149 | + DriverModel.h + .cpp:
150 | New type code:
151 | DRIVER_DATA_VEH_REAR_Z_COORDINATE
152 | (only used with DRIVER_DATA_USES_PEDESTRIAN_POLYGONS).
153 |
154 | (2006-11-30) [not externally released]
155 | ------------
156 | + DriverModel.h + .cpp:
157 | New type codes:
158 | DRIVER_DATA_STATUS, DRIVER_DATA_STATUS_DETAILS.
159 | + DriverModel.cpp:
160 | DriverModelGetValue() and DriverModelSetValue() must return 1 to almost
161 | all calls (even with the new type codes added after 2005-05-24)
162 | to prevent VISSIM from stopping the simulation run with the error message
163 | "Could not send/retrieve ... to/from driver model"!
164 |
165 | (2006-10-20) [not externally released]
166 | ------------
167 | + DriverModel.h + .cpp:
168 | New type code:
169 | DRIVER_DATA_VEH_HEIGHT
170 | (only used with DRIVER_DATA_USES_PEDESTRIAN_POLYGONS).
171 |
172 | (2006-09-21) [not externally released]
173 | ------------
174 | + DriverModel.h + .cpp:
175 | New type code:
176 | DRIVER_DATA_VEH_Z_COORDINATE
177 | (only used with DRIVER_DATA_USES_PEDESTRIAN_POLYGONS).
178 |
179 | (2006-09-20) [not externally released]
180 | ------------
181 | + DriverModel.h + .cpp:
182 | DRIVER_DATA_SETS_XY_COORDINATES replaced by DRIVER_DATA_USES_PEDESTRIAN_POLYGONS.
183 | New type codes:
184 | DRIVER_DATA_PEDESTRIAN_POLYGON_*
185 | (only used with DRIVER_DATA_USES_PEDESTRIAN_POLYGONS).
186 | * VISSIM:
187 | DRIVER_DATA_LINK_SEGMENT_UP_RIGHT_X, DRIVER_DATA_LINK_SEGMENT_UP_RIGHT_Y,
188 | DRIVER_DATA_LINK_SEGMENT_UP_LEFT_X, DRIVER_DATA_LINK_SEGMENT_UP_LEFT_Y,
189 | DRIVER_DATA_LINK_SEGMENT_DOWN_RIGHT_X, DRIVER_DATA_LINK_SEGMENT_DOWN_RIGHT_Y,
190 | DRIVER_DATA_LINK_SEGMENT_DOWN_LEFT_X, DRIVER_DATA_LINK_SEGMENT_DOWN_LEFT_Y,
191 | DRIVER_DATA_SIGNAL_HEAD_POS_RIGHT_X, DRIVER_DATA_SIGNAL_HEAD_POS_RIGHT_Y,
192 | DRIVER_DATA_SIGNAL_HEAD_POS_LEFT_X, DRIVER_DATA_SIGNAL_HEAD_POS_LEFT_Y
193 | are passed to the driver model DLL if DriverModelGetValue
194 | (DRIVER_DATA_USES_PEDESTRIAN_POLYGONS, ...) set *long_value to 0!
195 |
196 | (2006-09-01) [since VISSIM 4.30-00, not externally released]
197 | ------------
198 | + DriverModel.h + .cpp:
199 | New format (created from an internal database).
200 | + DriverModel.h + .cpp:
201 | New type code:
202 | DRIVER_DATA_PARAMETERFILE.
203 | * VISSIM: The name of the DLL and a parameterfile can be selected for each
204 | vehicle type.
205 |
206 | (2005-11-09) [not externally released]
207 | ------------
208 | + DriverModel.h + .cpp:
209 | New type codes:
210 | DRIVER_DATA_VEH_DESTINATION_LINK, DRIVER_DATA_SETS_XY_COORDINATES,
211 | DRIVER_DATA_VEH_LEAVES_NETWORK,
212 | DRIVER_DATA_VEH_REAR_X_COORDINATE, DRIVER_DATA_VEH_REAR_Y_COORDINATE,
213 | DRIVER_DATA_LINK_SEGMENT_UP_RIGHT_X, DRIVER_DATA_LINK_SEGMENT_UP_RIGHT_Y,
214 | DRIVER_DATA_LINK_SEGMENT_UP_LEFT_X, DRIVER_DATA_LINK_SEGMENT_UP_LEFT_Y,
215 | DRIVER_DATA_LINK_SEGMENT_DOWN_RIGHT_X, DRIVER_DATA_LINK_SEGMENT_DOWN_RIGHT_Y,
216 | DRIVER_DATA_LINK_SEGMENT_DOWN_LEFT_X, DRIVER_DATA_LINK_SEGMENT_DOWN_LEFT_Y,
217 | DRIVER_DATA_SIGNAL_HEAD_POS_RIGHT_X, DRIVER_DATA_SIGNAL_HEAD_POS_RIGHT_Y,
218 | DRIVER_DATA_SIGNAL_HEAD_POS_LEFT_X, DRIVER_DATA_SIGNAL_HEAD_POS_LEFT_Y.
219 | + DriverModel.h + .cpp:
220 | DRIVER_DATA_VEH_TURNING_INDICATOR is used by DriverModelGetValue(), too.
221 | DRIVER_DATA_VEH_X_COORDINATE and DRIVER_DATA_VEH_Y_COORDINATE are
222 | used by DriverModelGetValue(), too, if DriverModelGetValue
223 | (DRIVER_DATA_SETS_XY_COORDINATES, ...) set *long_value to 1.
224 |
225 | (2005-05-24)
226 | ------------
227 | + DriverModel.h:
228 | Comments for index values for DRIVER_DATA_NVEH_ values improved.
229 |
--------------------------------------------------------------------------------
/Code/DriverModel_DLL_HV/DriverModel.cpp:
--------------------------------------------------------------------------------
1 | /*==========================================================================*/
2 | /* DriverModel.cpp DLL Module for VISSIM */
3 | /* */
4 | /* Interface module for external driver models. */
5 | /* Dummy version that does nothing (uses Vissim's internal model). */
6 | /* export HV trajectory information */
7 | /*==========================================================================*/
8 |
9 | #include "DriverModel.h"
10 | #include
11 | #include
12 | #include
13 | #include
14 | #include
15 | #include
16 | #include