# Position Motion Mode

## Position Mode Configuration

### Overview

In **Position Mode**, positions are sent to the controller using millimeters (mm) for translational movements (Surge, Sway, Heave) and degrees (°) for rotational axes (Yaw, Roll, Pitch). These values are represented as 32-bit floating-point numbers (`float`). Additionally, a "Belt" value for the 7th actuator can be included as a 32-bit unsigned integer (`uint32`) when required. Each value (whether `float` or `uint32`) is 4 bytes in size, and the total packet length is fixed at 36 bytes.

### Data Structure

The position data is transmitted as follows:

* **Translational Movements**:
  * **Sway**: 4-byte `float` (in mm)
  * **Surge**: 4-byte `float` (in mm)
  * **Heave**: 4-byte `float` (in mm)
* **Rotational Axes**:
  * **Yaw**: 4-byte `float` (in degrees)
  * **Roll**: 4-byte `float` (in degrees)
  * **Pitch**: 4-byte `float` (in degrees)
* **Optional Actuator**:
  * **Belt** (7th actuator): 4-byte `uint32` (only when needed)
* **Placeholder**:
  * Axis 8: 4-byte filler (e.g., `0000`)

### Packet Format

The complete data packet adheres to a fixed structure:

* **Start Bytes**: `<252> <252>` (2 bytes)
* **Data Payload**: 8 × 4-byte values (32 bytes total)
* **Stop Bytes**: `<10> <13>` (2 bytes)

This results in a total packet length of **36 bytes**.

#### Handling Missing Values

If fewer than 8 values are used, the remaining slots must be padded with 4-byte placeholders (e.g., `0000`) to maintain the fixed 36-byte packet length. The "Belt" value (7th actuator) is optional and only included when needed; otherwise, its slot is filled with a 4-byte placeholder.

#### Example Packets

1. **Without Belt Value**:

   ```
   <252><252><PSway><PSurge><PHeave><PYaw><PRoll><PPitch><0000><0000><10><13>
   ```

   * `<PSway>`, `<PSurge>`, `<PHeave>`: 4-byte `float` values (in mm)
   * `<PYaw>`, `<PRoll>`, `<PPitch>`: 4-byte `float` values (in degrees)
   * `<0000><0000>`: 4-byte placeholders for unused axes (7 and 8)
   * Total length: 36 bytes
2. **With Belt Value**:

   ```
   <252><252><PSway><PSurge><PHeave><PYaw><PRoll><PPitch><PBelt><0000><10><13>
   ```

   * `<PSway>`, `<PSurge>`, `<PHeave>`: 4-byte `float` values (in mm)
   * `<PYaw>`, `<PRoll>`, `<PPitch>`: 4-byte `float` values (in degrees)
   * `<PBelt>`: 4-byte `uint32` value for the 7th actuator (Belt)
   * `<0000>`: 4-byte placeholder for unused Axis 8
   * Total length: 36 bytes

### Summary

* Translational and rotational axes use 32-bit (4-byte) `float` values.
* The optional "Belt" actuator (7th axis) uses a 32-bit (4-byte) `uint32` value, included only when needed.
* The packet always transmits 8 values (6 axes + optional Belt + 1 placeholder), totaling 32 bytes of data.
* Including start and stop bytes, the fixed packet size is 36 bytes.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.motion4sim.com/getting-started/publish-your-docs/position-motion-mode.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
