# /manufacturing/drill

Drill files and hole specifications for PCB fabrication.

## Purpose
This directory contains drill files that specify the location, size, and type of all holes in your PCB. These files are essential for PCB manufacturing and must be included with your Gerber files.

## File Types
- **`.drl`**: Excellon drill files (standard format)
- **`.xln`**: Alternative Excellon format
- **`.txt`**: Drill report with hole sizes and counts
- **`.pdf`**: Drill drawing for visual reference

## Standard Drill Files
```
drill/
├── ProjectName.drl              # Main drill file (PTH + NPTH)
├── ProjectName-PTH.drl          # Plated through holes only
├── ProjectName-NPTH.drl         # Non-plated through holes only
├── ProjectName-drill_report.txt # Drill sizes and quantities
└── ProjectName-drill_map.pdf    # Visual drill map
```

## Generating Drill Files from KiCad
1. Open PCB (`.kicad_pcb`)
2. **File → Fabrication Outputs → Gerbers**
3. Click **Generate Drill Files**
4. Configure settings:
   - **Output directory**: `manufacturing/drill/`
   - **Drill file format**: Excellon
   - **Drill units**: Millimeters (preferred)
   - **Zeros format**: Suppress leading zeros
   - **Drill origin**: Absolute coordinates
5. Generate files

## Drill File Settings
### Recommended Settings
- **Format**: Excellon
- **Units**: Millimeters
- **Coordinate format**: 3.3 (mm) or 2.4 (inches)
- **Zero suppression**: Leading zeros suppressed
- **Drill origin**: Absolute (0,0 at board origin)

### File Options
- **PTH and NPTH in single file**: Most common
- **Separate PTH/NPTH files**: Some manufacturers prefer
- **Generate drill report**: Always recommended
- **Generate drill map**: Helpful for verification

## Drill Sizes and Types
### Common Drill Sizes
- **0.2mm - 0.3mm**: Vias and small component holes
- **0.6mm - 0.8mm**: Standard component leads
- **1.0mm - 1.2mm**: Larger component holes
- **2.0mm+**: Mounting holes and connectors

### Hole Types
- **PTH (Plated Through Holes)**: Electrical connections
- **NPTH (Non-Plated Through Holes)**: Mounting holes, mechanical
- **Via holes**: Layer-to-layer connections
- **Component holes**: Through-hole component mounting

## Quality Control
- [ ] All holes present in drill file
- [ ] Drill sizes match component requirements
- [ ] PTH/NPTH classification correct
- [ ] Drill report shows reasonable hole counts
- [ ] No duplicate or overlapping holes
- [ ] Drill sizes within manufacturer capabilities

## Manufacturer Specifications
Check with your PCB manufacturer for:
- **Minimum drill size**: Typically 0.15mm - 0.2mm
- **Maximum drill size**: Usually 6mm+
- **Drill tolerance**: Typically ±0.05mm
- **Aspect ratio limits**: Depth vs. diameter ratio
- **Via specifications**: Minimum via size and annular ring

## Common Issues
- **Missing holes**: Check component footprints
- **Wrong drill sizes**: Verify component specifications
- **Incorrect hole types**: PTH vs NPTH classification
- **Overlapping holes**: Check component placement
- **Out of tolerance**: Verify manufacturer capabilities

## Drill Report Contents
The drill report typically includes:
- Total hole count by size
- PTH vs NPTH breakdown
- Drill tool assignments
- Coordinate listings
- File generation settings

## Integration with Gerbers
Drill files must be coordinated with Gerber files:
- Same coordinate system and origin
- Matching hole locations with pads
- Consistent units (mm or inches)
- Same board outline reference
