Borrar filtros
Borrar filtros

Get and update MioVel while simulation is running in highwaylane following with intelligent vehicles example

1 visualización (últimos 30 días)
I want to update mioVel such that i can control it with a knob while running the simulation with automated driving toolbox. how can I do that?

Respuestas (1)

Anurag
Anurag el 20 de Sept. de 2023
Hello Tirth,
From your question I understand that you want to add a knob to control the parameter “mioVel” in your simulation.
For doing the same, please follow the below steps:
  • Add a Knob Input: Start by adding a Knob input to your Simulink model. You can find the Knob input block in the Simulink Library Browser under "User-Defined Functions" or "Simulink Extras." Place the Knob block in your model.
  • Connect the Knob Input: Connect the output of the Knob block to a suitable input block that can accept a scalar value, such as a Constant block or a Gain block. This will be your control input for the “mioVel” block.
  • Configure the Knob Input: Double-click on the Knob block to open its parameter dialog box. Configure the knob's properties, such as the minimum and maximum values, the initial value, and the step size. Adjust these properties according to your desired control range and precision.
  • Connect the Control Input: Connect the output of the Constant or Gain block (connected to the Knob block) to the control input of the “mioVel” block. This will allow the knob input to control the velocity of the “mioVel” block during simulation.
  • Run the Simulation: Start the simulation and observe the behavior of the “mioVel” block. As you rotate the knob input, the velocity of the “mioVel” block should change accordingly.
Hope this helped.

Productos


Versión

R2023a

Community Treasure Hunt

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

Start Hunting!

Translated by