#!/usr/bin/python3
# This file was automatically generated from drawio2cbd with the command:
#   /home/red/git/DrawioConvert/__main__.py AGV.drawio -Safrgv -e AGV -F CBD -E delta=0.1 -t 100

from AGV import *
from CBD.simulator import Simulator

DELTA_T = 0.1
TIME = 100.0

cbd = AGV("AGV")

# Run the Simulation
sim = Simulator(cbd)
sim.setDeltaT(DELTA_T)
# sim.setProgressBar()
sim.setRealTime()
sim.run(TIME)

while sim.is_running(): pass

log = sim.getDurationLog()
with open('delays.log', 'w') as file:
	file.write("{}\n{}\n".format(TIME, DELTA_T))
	file.write("\n".join([str(x) for x in log]))
