> ## 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.

# Velocity Client

## VelocityClient

Inherits from: [ROSClient](/robot-api/grid/comm/ros/base_client#rosclient)

A ROS client for handling velocity messages.

This class inherits from ROSClient and provides functionality for publishing and
receiving velocity messages over ROS topics.

### VelocityClient

```python
VelocityClient(client_dict, agent_dict)
```

Initialize the velocity client.

<ResponseField name="Arguments">
  <ParamField query="client_dict (dict)" type="" required>
    Configuration dictionary for the client
  </ParamField>

  <ParamField query="agent_dict (dict), optional" type="">
    defaults to None.
    Dictionary of agent parameters. Defaults to None.
  </ParamField>
</ResponseField>

### publish\_velocity

```python
VelocityClient.publish_velocity(linear_velocity, angular_velocity)
```

Publish a velocity message.

<ResponseField name="Arguments">
  <ParamField query="linear_velocity (array-like)" type="" required>
    Linear velocity as \[x, y, z]
  </ParamField>

  <ParamField query="angular_velocity (array-like)" type="" required>
    Angular velocity as \[x, y, z]
  </ParamField>
</ResponseField>

### process\_latest\_msg

```python
VelocityClient.process_latest_msg()
```

Process the latest received velocity message.
Gets the latest message and updates the stored velocities. If an agent is
connected, calls moveByVelocity with the new velocities.

<ResponseField name="Returns" />

### get\_linear\_velocity

```python
VelocityClient.get_linear_velocity()
```

Get the current linear velocity.

<ResponseField name="Returns">
  Current linear velocity as \[x, y, z]
</ResponseField>

### get\_angular\_velocity

```python
VelocityClient.get_angular_velocity()
```

Get the current angular velocity.

<ResponseField name="Returns">
  Current angular velocity as \[x, y, z]
</ResponseField>
