# Available Commands

**`activate_motor(motor_id)`** - Activates one particular motor which has the same ID as the argument.

```python
# Function
activate_motor(motor_id)

# Example Usage
hapticAPI.activate_motor(1)
```

**`delay(delay_time)`** - Pause for `delay_time` seconds before executing the next command.

```python
# Function
delay(delay_time)

# Example Usage
hapticAPI.delay(1)
```

**`stop_all_motors()`** - Stops the vibration of all motors on the whole jacket.

```python
# Function
stop_all_motors()

# Example Usage
hapticAPI.stop_all_motors()
```

### Example Complete API Call

```python
# This code will activate motor 1,2,3 and 4 in 1 second steps
# Then, drive the 4 modules simultaneously for 3 seconds

import hapticAPI

hapticAPI.activate_motor(1)
hapticAPI.delay(1)
hapticAPI.activate_motor(2)
hapticAPI.delay(1)
hapticAPI.activate_motor(3)
hapticAPI.delay(1)
hapticAPI.activate_motor(4)
hapticAPI.delay(3)
```


---

# 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://pi31415.gitbook.io/haptic-jacket/api-documentation/available-commands.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.
