Clear Filters
Clear Filters

How to change path scenario in Virtual Vehicle Composer?

3 views (last 30 days)
Hello, I am developing some control logic in Virtual Vehicle Composer (VVC). There are some example scenarios like the one below. However, when I use the "Double lane change" scenario, the steering response is a bit weird (too sudden compared to other simulations such as CarSim). So, I want to know how to change the scenario or manually replace the driver model.
I tried once, but it was difficult to consider the related signals from other vehicles. If anyone has attempted this or if I could get some help regarding this, I would appreciate it.

Answers (1)

Mike Sasena
Mike Sasena about 21 hours ago
Hi JGP,
Yes, you're able to customize the models generated by the Virtual Vehicle Composer. There are lots of things you could do to tailor the model to your needs, but I'll give you a few ideas to get you started.
If you want to replace the driver model, you could select the "Open Loop" option by double-clicking on the driver block mask. This will add 4 inports where you can directly specify the steer, accel, brake and gear commands. That would let you bring in your own driver model that behaves the way you'd like.
In a similar way, you could double-click on the Scenarios subsystem and turn on the external inputs for driver reference and driver commands. This lets you override our scenario with your own.
To create your own path for the vehicle to follow, check out the "Follow Waypoints Around Oval Track" example. Hopefully that should give you a few ideas of how to customize the model to better suit your application.

Categories

Find more on Vehicle Scenarios in Help Center and File Exchange

Products


Release

R2023b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!