# HTD 5M pulley

> Component kind `htd5m-pulley` (category `mech`, DSL name `htd5mPulley`, API v1)

Synchronous timing-belt pulley with the HTD 5M profile (5 mm pitch, curved teeth) and optional side flanges. Meshes with HTD5M timing belts; 3D-printable.

## Parameters

- **`teeth`** — Tooth count. Pitch diameter = teeth * 5 / pi. Must be >= 8 to keep the groove profile well-formed.
- **`width`** — Total pulley width along the spin axis (mm) — toothed band plus both flanges.
- **`beltWidth`** — Axial length of the toothed band (mm). Match the timing-belt width with a small clearance. Each flange thickness = (width - beltWidth) / 2. Set beltWidth >= width or flangeHeight = 0 to disable flanges.
- **`flangeHeight`** — How far each flange extends radially beyond the toothed OD (mm). Default 3 mm — enough to keep an HTD5M belt seated.
- **`boreDiameter`** — Central bore diameter (mm), for mounting on a shaft.

## Parameters schema

| Parameter | Type | Default | Constraints |
| --- | --- | --- | --- |
| `teeth` | Number | 20 | min: 8 |
| `width` | Number | 12 | min: 1 |
| `beltWidth` | Number | 9 | min: 1 |
| `flangeHeight` | Number | 3 | min: 0 |
| `boreDiameter` | Number | 8 |  |
| `color` | String | — |  |

## Ports

| Port | Type | Description |
| --- | --- | --- |
| `axis` | `rotational` | Spin axis (rotational). Receives omega from the coupling or belt propagation. |

## Kinematics

Passive — omega is set by the belt or coupling attached to the axis port. Theta integrates from omega each tick. Two HTD5M pulleys on the same belt ratio by tooth count: omega_to = omega_from * (teeth_from / teeth_to).

## Example

```
htd5mPulley "P1" {
  teeth: 20
  width: 12
  beltWidth: 9
  flangeHeight: 3
  at: position(0, 0, 0)
}
```
