> ## Documentation Index
> Fetch the complete documentation index at: https://scaledfoundations-rebrand.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# CarClient

## \_\_init\_\_

<ResponseField name="CarClient.__init__(ip=&#x22;&#x22;, port=41451, timeout_value=3600)">
  No description provided!
</ResponseField>

## rotate

<ResponseField name="CarClient.rotate(rate, duration, vehicle_name=&#x22;&#x22;)">
  No description provided!
</ResponseField>

## setCarControls

<ResponseField name="CarClient.setCarControls(controls, vehicle_name=&#x22;&#x22;)">
  Control the car using throttle, steering, brake, etc.

  <ResponseField name="Arguments">
    <ParamField query="controls" type="CarControls">
      ([CarControls](/simulation/airgen/reference/datatypes#carcontrols)): Struct containing control values
    </ParamField>

    <ParamField query="vehicle_name" type="str, optional">
      Name of vehicle to be controlled
    </ParamField>
  </ResponseField>
</ResponseField>

## enableCarSpeedControl

<ResponseField name="CarClient.enableCarSpeedControl(status, vehicle_name = &#x22;&#x22;)">
  Enable or disable speed control for the car.

  <ResponseField name="Arguments">
    <ParamField query="status" type="bool">
      True to enable, false to disable.
    </ParamField>

    <ParamField query="vehicle_name" type="str, optional">
      Name of the vehicle
    </ParamField>
  </ResponseField>
</ResponseField>

## setCarTargetSpeed

<ResponseField name="CarClient.setCarTargetSpeed(speed, vehicle_name = &#x22;&#x22;)">
  Set a target speed for the car.

  <ResponseField name="Arguments">
    <ParamField query="speed" type="float">
      Target speed in m/s
    </ParamField>

    <ParamField query="vehicle_name" type="str, optional">
      Name of vehicle to be controlled
    </ParamField>
  </ResponseField>
</ResponseField>

## getCarState

<ResponseField name="CarClient.getCarState(vehicle_name=&#x22;&#x22;)">
  The position inside the returned CarState is in the frame of the vehicle's starting point

  <ResponseField name="Arguments">
    <ParamField query="vehicle_name" type="str, optional">
      Name of vehicle
    </ParamField>
  </ResponseField>

  <ResponseField name="Returns">
    <ResponseField name="CarState" type="CarState">
      CarState
    </ResponseField>
  </ResponseField>
</ResponseField>

## getCarControls

<ResponseField name="CarClient.getCarControls(vehicle_name=&#x22;&#x22;)">
  No description provided!

  <ResponseField name="Arguments">
    <ParamField query="vehicle_name" type="str, optional">
      Name of vehicle
    </ParamField>
  </ResponseField>

  <ResponseField name="Returns">
    <ResponseField name="CarControls" type="CarControls">
      CarControls
    </ResponseField>
  </ResponseField>
</ResponseField>

## moveOnPath

<ResponseField
  name="CarClient.moveOnPath(
path,
velocity,
lookahead=-1,
adaptive_lookahead=1,
orientations=[],
vehicle_name=&#x22;&#x22;
)"
>
  Command the car to move along a specified path.

  This function sends commands to a car to follow a given path at a specified velocity.
  The path is a list of 3D vectors, and each vector represents a point in space that
  the car should follow.

  <ResponseField name="Arguments">
    <ParamField query="path" type="List[Vector3r]">
      A list of 3D vectors representing the path to follow.
    </ParamField>

    <ParamField query="velocity" type="float">
      The speed at which the car should move along the path, in meters per second.
    </ParamField>

    <ParamField query="timeout_sec" type="float, optional">
      The maximum time allowed for the car to reach the destination, in seconds. Defaults to 3e38.
    </ParamField>

    <ParamField query="lookahead" type="int, optional">
      The number of points the car should look ahead on the path for control decisions. Defaults to -1, which means no specific lookahead.
    </ParamField>

    <ParamField query="adaptive_lookahead" type="bool, optional">
      Whether to adjust the lookahead dynamically based on the car's speed. Defaults to True.
    </ParamField>

    <ParamField query="orientations" type="Optional[List[Quarterion]], optional">
      Optional list of orientations corresponding to each path point. Defaults to empty.
    </ParamField>

    <ParamField query="vehicle_name" type="str, optional">
      The name of the vehicle being controlled, if applicable. Defaults to "".
    </ParamField>
  </ResponseField>
</ResponseField>
