> ## Documentation Index
> Fetch the complete documentation index at: https://docs.pcb.new/llms.txt
> Use this file to discover all available pages before exploring further.

# Bringup documentation

> Write board bringup and rework instructions for Diode Glass

# Bringup documentation

Create one `README.md` for each supported board version. Document required
rework, firmware installation, and verification procedures. Diode Glass renders
this file in the **Bringup** tab.

## File location

```
bringup/
  v1.0/
    README.md
    images/
      estop-rework.png
  v2.0/
    README.md
```

Store images in the `images/` directory beside the version README.

### Version matching

| Release  | Directory | Result                                  |
| -------- | --------- | --------------------------------------- |
| `v2.0`   | `v2.0/`   | Exact match                             |
| `v2.0.4` | `v2.0/`   | Prefix match for the same minor version |
| `v2.1.0` | `v2.0/`   | No match                                |

Create a directory for each minor version. Patch releases share that directory
unless a patch requires different instructions. Diode Glass reads the
documentation from `main`, not from the release archive.

## Document structure

```markdown theme={null}
# <Board> <Version> Bringup

Overview text.

## Reworks

### 1. Title of first rework

...

### 2. Title of second rework

...

## Firmware

Free-form markdown.

## Testing

Free-form markdown.
```

Diode Glass parses `## Reworks` into structured items. It renders other level-two
sections as collapsible Markdown.

## Rework items

Start each rework with a `### N. Title` heading. State the observed problem, the
required correction, its board location, and the version in which the design was
fixed. Do not encode status in a separate field.

### Link to components

Use the `pcb://` scheme for reference designators, for example
`[R1](pcb://R1)`. Diode Glass links these references to the PCB viewer.

### Add images

Store each image under `./images/` and use descriptive alternative text:
`![Reworked ESTOP resistor](./images/estop-rework.png)`.

## Example

```markdown theme={null}
# DM0001 v1.0 Bringup

Board version v1.0 requires three reworks before bringup.
Items 1–2 are fixed in v1.1. Item 3 requires a physical fix on each board.

## Reworks

### 1. Short ESTOP debounce resistor (fixed in v1.1)

The 47 kohm ESTOP debounce resistor
[R_ESTOP_DEBOUNCE](pcb://R_ESTOP_DEBOUNCE) forms a voltage divider with the
ESTOP LED. The divider produces approximately 1.5 V, below the AND gate's 2.0 V
input-high threshold. Bridge the resistor with solder or wire. It is an 0402
part beside the ESTOP connector, between the `ESTOP_RAW` and `ESTOP` nets.

![Bridged ESTOP debounce resistor](./images/estop-rework.png)

### 2. Replace decoupling capacitors (fixed in v1.1)

[C5](pcb://C5) and [C6](pcb://C6) provide insufficient 10 uF decoupling for
the [U1](pcb://U1) LDO. Replace both with 22 uF, 16 V X5R capacitors,
manufacturer part number `GRM188R61C226ME15`. Both parts are on the bottom side
beside [U1](pcb://U1).

### 3. CAN termination resistor

The [R12](pcb://R12) footprint is unpopulated. Install a 120 ohm 0402 resistor
to terminate the CAN bus.

## Firmware

### Prerequisites

- J-Link programmer
- Firmware v1.0.2: `dm0001-v1.0.2.bin`

### Flash procedure

1. Connect the J-Link programmer to SWD header [J5](pcb://J5).
2. Apply 12 V power to the board.
3. Run `JFlash -openprj dm0001.jflash -open dm0001-v1.0.2.bin -auto -exit`.
4. Confirm that [D1](pcb://D1) blinks at 1 Hz.

## Testing

### Power rail verification

| Rail | Test Point | Expected | Tolerance |
|------|-----------|----------|-----------|
| 3.3 V | [TP1](pcb://TP1) | 3.30 V | ±50 mV |
| 1.8 V | [TP2](pcb://TP2) | 1.80 V | ±30 mV |
| 5.0 V | [TP3](pcb://TP3) | 5.00 V | ±100 mV |

### CAN bus test

1. Connect a CAN analyzer to [J2](pcb://J2).
2. Send a frame with identifier `0x100`, DLC 8, and payload `0xFF`.
3. Confirm that the board responds on identifier `0x101` within 10 ms.

### ESTOP functional test

1. Short ESTOP connector pins 1 and 2.
2. Confirm that the `ESTOP_OUT` test point measures 3.3 V after rework 1.
3. Remove the short from the ESTOP connector.
4. Confirm that `ESTOP_OUT` measures 0 V.
```
