Abstract
This thesis will focus on developing a Digital Twin prototype for an autonomous vehicle. The goal for the project was to discover how OpenModelica and Carla can be connected and configured to serve as a Digital Twin. It was acquired two methodologies of connecting OpenModelica models to a Digital Twin. The first method got used to simulate a mechanical model with historical data to re-simulate the scenarios. Further, the second method got used to simulate a mathematical model to add a feature from the physical environment to the Digital Twin. To begin the Digital Twin configuration, Carla got used to generating the states representing the forward speed and acceleration for a vehicle so the OpenModelica models could get tested. It was looked at possibilities to extend the configuration to use Carla as the visual simulation tool to combine OpenModelica and Carla as the Digital Twin. This thesis designed one configuration, which introduced the concept of having the Digital Twin one step in front of the Physical Twin. The LGSVL-simulator was introduced as the Physical Twin to generate similar parameters as a vehicle situated in a physical environment to test this configuration. The project did not explore methods to integrating the same 3D environment in Carla and the LGSVL-simulate. Which led to that the experiments while the LGSVL-simulator served as a Physical Twin got limited. The configuration between Carla and OpenModelica could not explore the concept of returning an action to the Physical Twin. So, a second configuration diagram is presented in the thesis, based on the knowledge learned in this project, which possibly can be further researched. The thesis concludes with that the methodologies acquired throughout the project present a good base for further research related to developing a Digital Twin by combining Carla and OpenModelica.