refactor mavsim into an app