Difference between revisions of "Advanced Topic 7"
(→The Last Position File) |
(→The Last Position File) |
||
Line 18: | Line 18: | ||
#The drive complete indicator is defined in scenario. | #The drive complete indicator is defined in scenario. | ||
#The restart file will be named the same as the daq filename that is passed into the MiniSim but with a “.lastpos.txt” so “my.daq” would produce a restart file of “my.daq.lastpos.txt”. An example of the contents of a .lastpos.txt file is as follows: | #The restart file will be named the same as the daq filename that is passed into the MiniSim but with a “.lastpos.txt” so “my.daq” would produce a restart file of “my.daq.lastpos.txt”. An example of the contents of a .lastpos.txt file is as follows: | ||
+ | |||
+ | [[File:3040.png|550px|thumb|center]] |
Revision as of 16:24, 18 October 2016
The Last Position File
When launched from the command line, the MiniSim creates a file ending with the string “.lastpos.txt” when it exits as follows:
- The file is only created when the MiniSim is launched from the command line
- The restart will only work if the scenario is set up to stop the scenario when the vehicle either leaves the roadway or has a collision. Example Expression trigger content:
Expression Name: End Drive
Expression: ReadVar('MyTime') > 54000 this ends the scenario after 54,000 frames, or 15 minutes
Actions:
Action 1, Type=Set Variable, Variable=VisualDisplaytext, Value=End of Drive, Please Come To a Stop, Delay=5s
Action 2, Type=Terminate Simulation, Delay=0s
Action 3, Type=Set Variable, Variable=FinishedDrive, Value=1, Delay=0s Action 4, Type=Log Data, Variable=Stream 2, Value=1
- The drive complete indicator is defined in scenario.
- The restart file will be named the same as the daq filename that is passed into the MiniSim but with a “.lastpos.txt” so “my.daq” would produce a restart file of “my.daq.lastpos.txt”. An example of the contents of a .lastpos.txt file is as follows: